added
stringlengths
32
32
created
int64
1,236B
1,694B
id
stringlengths
40
40
int_score
int64
2
5
metadata
dict
score
float64
2.31
5.03
source
stringclasses
1 value
text
stringlengths
330
19.3k
num_lines
int64
16
648
avg_line_length
float64
15.5
59.3
max_line_length
int64
37
179
ast_depth
int64
8
38
length
int64
102
3.79k
lang
stringclasses
1 value
sast_codeql_findings
stringlengths
1.11k
276k
sast_codeql_findings_count
int64
1
33
sast_codeql_success
bool
1 class
sast_codeql_error
stringclasses
1 value
cwe_ids
listlengths
1
33
rule_ids
listlengths
1
33
confidences
listlengths
1
33
severities
listlengths
1
33
messages
listlengths
1
33
line_starts
listlengths
1
33
line_ends
listlengths
1
33
column_starts
listlengths
1
33
column_ends
listlengths
1
33
2024-11-19T00:11:34.786190+00:00
1,395,948,215,000
7c2bf84732a95f6696ab8c08729313c683068926
3
{ "blob_id": "7c2bf84732a95f6696ab8c08729313c683068926", "branch_name": "refs/heads/master", "committer_date": 1395948215000, "content_id": "483cc7053bc5ff2f6e142e87342d3b25bc70db28", "detected_licenses": [ "MIT" ], "directory_id": "762cd81b9858c76e97d061f5bd6ea3563d943429", "extension": "py", "fi...
2.6875
stackv2
import os import urllib2 from paramiko import SSHClient, WarningPolicy from paramiko import SFTPClient as BaseSFTPClient class Archiver(object): """ Responsible for reading the artifacts from jenkins and writing them to the target archive. """ def __init__(self, policy, target): self.poli...
106
27.67
79
16
640
python
[{"finding_id": "codeql_py/paramiko-missing-host-key-validation_37021cf18b9d2606_3c2f68dd", "tool_name": "codeql", "rule_id": "py/paramiko-missing-host-key-validation", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Setting missing host key policy to WarningPolicy may be unsafe.", "r...
1
true
[ "CWE-295" ]
[ "py/paramiko-missing-host-key-validation" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "Setting missing host key policy to WarningPolicy may be unsafe." ]
[ 82 ]
[ null ]
[ 9 ]
[ 69 ]
2024-11-19T00:37:04.085208+00:00
1,611,683,095,000
b8047cdc43b1fc0bb6f369288db159cdc2c30edc
3
{ "blob_id": "b8047cdc43b1fc0bb6f369288db159cdc2c30edc", "branch_name": "refs/heads/main", "committer_date": 1611683095000, "content_id": "2e777a4e1e832bc2f95c2ff834f7ac831938a3b6", "detected_licenses": [ "Apache-2.0" ], "directory_id": "6a0d88b00d70754b96896f2e27cb3bfabb14830d", "extension": "py", ...
3.203125
stackv2
import argparse import os import re import json error_string = "***error***" parser = argparse.ArgumentParser(description='Parse KPP File with many unstated assumptions on format.') parser.add_argument('filename', metavar='filename', type=str, nargs=None, help='kpp file to be digested') args = p...
243
30.16
131
16
1,863
python
[{"finding_id": "codeql_py/overly-large-range_015f2e3f88d2ebce_258d0292", "tool_name": "codeql", "rule_id": "py/overly-large-range", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Suspicious character range that is equivalent to \\[A-Z\\\\[\\\\\\\\]^_`a-z\\].", "remediation": "", "lo...
1
true
[ "CWE-020" ]
[ "py/overly-large-range" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "Suspicious character range that is equivalent to \\[A-Z\\\\[\\\\\\\\]^_`a-z\\]." ]
[ 152 ]
[ null ]
[ 33 ]
[ 36 ]
2024-11-19T01:26:13.208050+00:00
1,588,681,807,000
8c6143dbf7bb52c4627fc2c28767d441d1c987c1
3
{ "blob_id": "8c6143dbf7bb52c4627fc2c28767d441d1c987c1", "branch_name": "refs/heads/master", "committer_date": 1588681807000, "content_id": "5ac72164398952c3fa3bb12113f3259e6c8d13cc", "detected_licenses": [ "MIT" ], "directory_id": "4c97922e9bfd2d67d5d24fa1497bd23ec187c081", "extension": "py", "fi...
2.53125
stackv2
#! /usr/bin/env python3 # coding: utf-8 """ Agor@aphon views """ import os from flask import render_template, request, send_file from app import app from .modules.search import TopicSeeker from .modules.scrap import PostSeeker from .modules.analytics import Analyzer from .modules.nlp import NlProcess from .modules.pr...
170
23.46
61
14
978
python
[{"finding_id": "codeql_py/path-injection_e54be94fe4f60b00_9e081497", "tool_name": "codeql", "rule_id": "py/path-injection", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This path depends on a [user-provided value](1).", "remediation": "", "location": {"file_path": "unknown", ...
1
true
[ "CWE-022" ]
[ "py/path-injection" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This path depends on a [user-provided value](1)." ]
[ 157 ]
[ null ]
[ 22 ]
[ 26 ]
2024-11-19T01:51:55.803877+00:00
1,693,155,568,000
b1bf9464c99a0681b7ca0910cb0f1cc0439be627
3
{ "blob_id": "b1bf9464c99a0681b7ca0910cb0f1cc0439be627", "branch_name": "refs/heads/main", "committer_date": 1693155568000, "content_id": "cbea9ca22e5e9634e0dfa2e726179d4f94453155", "detected_licenses": [ "MIT" ], "directory_id": "be63eb4f1e09a0220bf2ab39de03d10ce77aa9b0", "extension": "py", "file...
2.890625
stackv2
import os import yaml from jinja2 import Environment, FileSystemLoader # Get script's directory script_dir = os.path.dirname(os.path.abspath(__file__)) # Define the absolute path to the templates directory templates_dir = os.path.join(script_dir, '../docs/showcase') templates_dir = os.path.abspath(templates_dir) prin...
57
36.61
96
17
447
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_0cbac6fe264954dc_d232c552", "tool_name": "codeql", "rule_id": "py/jinja2/autoescape-false", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Using jinja2 templates with autoescape=False can potentially allow XSS attacks.", "remediati...
1
true
[ "CWE-079" ]
[ "py/jinja2/autoescape-false" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "Using jinja2 templates with autoescape=False can potentially allow XSS attacks." ]
[ 14 ]
[ null ]
[ 7 ]
[ 58 ]
2024-11-19T01:39:55.562118+00:00
1,599,888,693,000
8300e9d7450eff1448f2f8e44e3a43e88fcd659b
3
{ "blob_id": "8300e9d7450eff1448f2f8e44e3a43e88fcd659b", "branch_name": "refs/heads/master", "committer_date": 1599888693000, "content_id": "892ea3fede7df8175e4e801dd2960aca31ab8daf", "detected_licenses": [ "MIT" ], "directory_id": "6ed7392e843c45e36c6a5a37bd051bb6d0579213", "extension": "py", "fi...
2.546875
stackv2
import requests import re import json import execjs import time import os os.environ["EXECJS_RUNTIME"]="Node" #先get网页,得到一个加密的js代码1,解密后得到另外一个js代码2,运行代码2,会得到一个 __jsl_clearance ,用 __jsl_clearance #作为cookie再去get网页并且记录第二次get得到的cookie __jsluid, 会得到加密js代码3,解密后的得到js代码4,运行代码4,会得到最终的 __jsl_clearance #将第二次记录下的__jsluid和通过运行js代码4得到...
96
38.65
142
16
1,303
python
[{"finding_id": "codeql_py/bad-tag-filter_b8fc4f97ea12a72f_3e4fb56b", "tool_name": "codeql", "rule_id": "py/bad-tag-filter", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "This regular expression does not match upper case <SCRIPT> tags.", "remediation": "", "location": {"file_path": ...
1
true
[ "CWE-116" ]
[ "py/bad-tag-filter" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This regular expression does not match upper case <SCRIPT> tags." ]
[ 37 ]
[ null ]
[ 32 ]
[ 54 ]
2024-11-18T23:43:08.915921+00:00
1,550,709,025,000
7dba4b7f931a77c0b7df34b367785ae10dc2cdf5
4
{ "blob_id": "7dba4b7f931a77c0b7df34b367785ae10dc2cdf5", "branch_name": "refs/heads/master", "committer_date": 1550709025000, "content_id": "3ac2ba2825df1807fd16cfce1ad88f56863b9629", "detected_licenses": [ "MIT" ], "directory_id": "44fc0ac30126992f2ca9aebfb30d3206ac375f1f", "extension": "py", "fi...
3.828125
stackv2
SALARY_RAISE_FACTOR = 0.05 STATE_CODE_MAP = {'WA': 'Washington', 'TX': 'Texas'} # This is the beginning of the script class Salary: def update_employee_record(rec): old_sal = rec['salary'] new_sal = old_sal * (1 + SALARY_RAISE_FACTOR) rec['salary'] = new_sal state_code = rec['stat...
34
25.71
54
12
238
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_509bff1d6978bb15_f982c16e", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (private)](1) as clear text.", "...
2
true
[ "CWE-312", "CWE-312" ]
[ "py/clear-text-logging-sensitive-data", "py/clear-text-logging-sensitive-data" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "This expression logs [sensitive data (private)](1) as clear text.", "This expression logs [sensitive data (private)](1) as clear text." ]
[ 33, 34 ]
[ null, null ]
[ 15, 15 ]
[ 46, 42 ]
2024-11-19T00:33:06.296847+00:00
1,602,222,729,000
22aba3a099405af390b1a2c3ce648081d7fc160d
2
{ "blob_id": "22aba3a099405af390b1a2c3ce648081d7fc160d", "branch_name": "refs/heads/master", "committer_date": 1602222729000, "content_id": "31685aae70542c6eb1fff7ffc38735dc0d5b2358", "detected_licenses": [ "MIT" ], "directory_id": "9bc14f9bbeb7ff5958611b5affac154c449c9e76", "extension": "py", "fi...
2.328125
stackv2
#!/usr/bin/env python3 from flask import Flask, render_template, request from urllib.parse import quote_plus, unquote_plus from flask_sqlalchemy import SQLAlchemy from waitress import serve import os import openpyxl import re import threading import json import logging import coloredlogs import config DATA_PATH = ...
331
31.23
80
22
2,225
python
[{"finding_id": "codeql_py/log-injection_1c18dd3f5b2cef27_9ccadc98", "tool_name": "codeql", "rule_id": "py/log-injection", "finding_type": "path-problem", "severity": "medium", "confidence": "medium", "message": "This log entry depends on a [user-provided value](1).", "remediation": "", "location": {"file_path": "unkno...
3
true
[ "CWE-117", "CWE-117", "CWE-117" ]
[ "py/log-injection", "py/log-injection", "py/log-injection" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "This log entry depends on a [user-provided value](1).", "This log entry depends on a [user-provided value](1).", "This log entry depends on a [user-provided value](1)." ]
[ 167, 245, 267 ]
[ null, null, null ]
[ 23, 23, 23 ]
[ 41, 43, 51 ]
2024-11-19T01:18:07.131649+00:00
1,580,542,271,000
a4ad6862fad3f739ae0b088d66eaba58f307f047
2
{ "blob_id": "a4ad6862fad3f739ae0b088d66eaba58f307f047", "branch_name": "refs/heads/master", "committer_date": 1580542271000, "content_id": "78922764cce79c524b5203b3adfb4b3856e263d6", "detected_licenses": [ "MIT" ], "directory_id": "44021581a747f92e064691384fa6be9aa85db38b", "extension": "py", "fi...
2.484375
stackv2
import hashlib import string from base64 import b64encode from random import choice from contextlib import contextmanager from ldap3 import ALL_ATTRIBUTES, SYNC, Connection, Server from decouple import config LDAP_SERVER_URL = "ldaps://ldap.csua.berkeley.edu" LDAP_SERVER = Server(LDAP_SERVER_URL) LDAP_CLIENT_STRATEG...
99
31.7
105
15
803
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_e0e47b627c979574_6459cec9", "tool_name": "codeql", "rule_id": "py/weak-sensitive-data-hashing", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "[Sensitive data (password)](1) is used in a hashing algorithm (SHA1) that is inse...
1
true
[ "CWE-327" ]
[ "py/weak-sensitive-data-hashing" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "[Sensitive data (password)](1) is used in a hashing algorithm (SHA1) that is insecure for password hashing, since it is not a computationally expensive hash function.\n[Sensitive data (password)](2) is used in a hashing algorithm (SHA1) that is insecure for password hashing, since it is not a computationally expen...
[ 44 ]
[ null ]
[ 24 ]
[ 48 ]
2024-11-19T01:18:07.813450+00:00
1,632,313,704,000
12751844118c7131aedc3ea37ecb65371cf304ff
3
{ "blob_id": "12751844118c7131aedc3ea37ecb65371cf304ff", "branch_name": "refs/heads/master", "committer_date": 1632313704000, "content_id": "8ef12c7ec72253b93b7a82efd264aa1cfc94a8fe", "detected_licenses": [ "MIT" ], "directory_id": "7cea076affab3b05c480622f4937ff7db00563cb", "extension": "py", "fi...
2.78125
stackv2
import flask import os from pathlib import Path from urllib.parse import urljoin import markdown from markdown.inlinepatterns import InlineProcessor, LinkInlineProcessor, ImageInlineProcessor, LINK_RE, IMAGE_LINK_RE from markdown.extensions import Extension class SnippetLinkProcessor(InlineProcessor): def ...
132
29.52
120
17
902
python
[{"finding_id": "codeql_py/path-injection_78df3550200d1e19_963bb0e9", "tool_name": "codeql", "rule_id": "py/path-injection", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This path depends on a [user-provided value](1).", "remediation": "", "location": {"file_path": "unknown", ...
4
true
[ "CWE-022", "CWE-022", "CWE-022", "CWE-022" ]
[ "py/path-injection", "py/path-injection", "py/path-injection", "py/path-injection" ]
[ "HIGH", "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "This path depends on a [user-provided value](1).", "This path depends on a [user-provided value](1).", "This path depends on a [user-provided value](1).", "This path depends on a [user-provided value](1)." ]
[ 120, 123, 132, 132 ]
[ null, null, null, null ]
[ 12, 19, 36, 32 ]
[ 23, 23, 40, 51 ]
2024-11-19T00:03:07.020474+00:00
1,493,069,142,000
4b8e1c0597f5f06e1c0593d0b474b457e430b3cd
3
{ "blob_id": "4b8e1c0597f5f06e1c0593d0b474b457e430b3cd", "branch_name": "refs/heads/master", "committer_date": 1493069142000, "content_id": "01d10f2bca5e297361bf7db93d5b8aa52db114ce", "detected_licenses": [ "MIT" ], "directory_id": "1a53ed24080841b5439df802381e00419beb8270", "extension": "py", "fi...
2.765625
stackv2
# -*- coding: utf-8 -*- import hashlib import sys import click import simplecrypt from . import sugar from .exceptions import ShipmentError from .helpers import prompt_password from .pickers import RandomPicker #: The default seed used for the RandomPicker DEFAULT_SEED = 7 @click.group() def cli(): """Ship ca...
83
29.05
79
16
540
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_7b6be75614c3ee60_a3b4959e", "tool_name": "codeql", "rule_id": "py/weak-sensitive-data-hashing", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "[Sensitive data (password)](1) is used in a hashing algorithm (SHA512) that is in...
2
true
[ "CWE-327", "CWE-327" ]
[ "py/weak-sensitive-data-hashing", "py/weak-sensitive-data-hashing" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "[Sensitive data (password)](1) is used in a hashing algorithm (SHA512) that is insecure for password hashing, since it is not a computationally expensive hash function.\n[Sensitive data (password)](2) is used in a hashing algorithm (SHA512) that is insecure for password hashing, since it is not a computationally e...
[ 46, 72 ]
[ null, null ]
[ 31, 31 ]
[ 55, 55 ]
2024-11-19T00:25:26.033795+00:00
1,563,545,479,000
568ac6f477e604e3764d2c50863b8ad5fea71e6c
3
{ "blob_id": "568ac6f477e604e3764d2c50863b8ad5fea71e6c", "branch_name": "refs/heads/master", "committer_date": 1563545479000, "content_id": "65316708203bc9f446a2bded6dd7557c8a24ac05", "detected_licenses": [ "MIT" ], "directory_id": "49be3ea1b097508e007611f86fedfbd7f9d28014", "extension": "py", "fi...
2.921875
stackv2
import hashlib from primes import prime_tickets import requests import re from bs4 import BeautifulSoup import json target = "http://127.0.0.1:8000" username = "veryUniqueUN" password = "veryUniquePW" def register(): print("Start registration U: " + username + " P: " + password, flush=True) data = {'usern...
80
25.34
118
15
537
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_bd13a3c21e49d97f_ca59fd22", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (password)](1) as clear text.", ...
1
true
[ "CWE-312" ]
[ "py/clear-text-logging-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression logs [sensitive data (password)](1) as clear text." ]
[ 15 ]
[ null ]
[ 11 ]
[ 68 ]
2024-11-19T00:25:26.892456+00:00
1,530,789,634,000
b8e093cee228c592d12ddac64cb3b73deb0682a8
2
{ "blob_id": "b8e093cee228c592d12ddac64cb3b73deb0682a8", "branch_name": "refs/heads/master", "committer_date": 1530789634000, "content_id": "49468ca00ea9d1dde95cf6e0e4f59e2936f0f648", "detected_licenses": [ "MIT" ], "directory_id": "b44322ba912dc583b88f149b0d49e96f73359315", "extension": "py", "fi...
2.34375
stackv2
from django.contrib import messages from django.http import HttpResponse from django.shortcuts import render, redirect from .forms import RegisterForm from django.contrib.auth.models import User # Create your views here. from .forms import LoginForm from django.contrib.auth import authenticate, login,logout ####### ...
86
28.88
111
12
557
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_9d1bf0516e26e002_fd792802", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (password)](1) as clear text.", ...
1
true
[ "CWE-312" ]
[ "py/clear-text-logging-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression logs [sensitive data (password)](1) as clear text." ]
[ 24 ]
[ null ]
[ 15 ]
[ 23 ]
2024-11-19T01:02:36.993235+00:00
1,622,639,610,000
5f5a3201edb0b5d6be96e1a067c8c24113758d3d
3
{ "blob_id": "5f5a3201edb0b5d6be96e1a067c8c24113758d3d", "branch_name": "refs/heads/master", "committer_date": 1622639610000, "content_id": "356a09ef0996c7ca654f67d52a6c38d1720d0592", "detected_licenses": [ "MIT" ], "directory_id": "3a5f7c67110d7d66a9a444aedfbdf29e1716a48f", "extension": "py", "fi...
2.546875
stackv2
#!/usr/bin/env python3 import json import requests from kavenegar import * def get_data(): """ what does this function do?""" with open('smsfy.json') as fp: json_data = json.load(fp) uptime_API_KEY = json_data['uptime']['api_key'] uptime_URL = json_data['uptime']['url'] kave...
50
28.54
82
13
393
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_b6caa6988e94e737_0acc8ac4", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (password)](1) as clear text.\nT...
1
true
[ "CWE-312" ]
[ "py/clear-text-logging-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression logs [sensitive data (password)](1) as clear text.\nThis expression logs [sensitive data (password)](2) as clear text." ]
[ 46 ]
[ null ]
[ 12 ]
[ 22 ]
2024-11-19T00:51:29.175626+00:00
1,682,677,104,000
e41333048b4d43f0254f585eb7a9518d3d464aa3
3
{ "blob_id": "e41333048b4d43f0254f585eb7a9518d3d464aa3", "branch_name": "refs/heads/master", "committer_date": 1682677291000, "content_id": "27bc36283704368cfaa2825d0deaca3760c24063", "detected_licenses": [ "MIT" ], "directory_id": "d513496067e4c6e63bb19be0b8886b4c97d41482", "extension": "py", "fi...
2.578125
stackv2
""" WDL template for running a *ChRIS* plugin on SLURM. Maybe it would be nice to set a workflow name instead of just "ChrisPlugin" but it doesn't really matter. """ import shlex from typing import Optional, Tuple, List from serde import from_dict, deserialize from jinja2 import Environment from pman.abstractmgr imp...
183
29.38
111
17
1,452
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_00e60f5d27de64a5_974b9d61", "tool_name": "codeql", "rule_id": "py/jinja2/autoescape-false", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Using jinja2 templates with autoescape=False can potentially allow XSS attacks.", "remediati...
1
true
[ "CWE-079" ]
[ "py/jinja2/autoescape-false" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "Using jinja2 templates with autoescape=False can potentially allow XSS attacks." ]
[ 21 ]
[ null ]
[ 12 ]
[ 25 ]
2024-11-19T02:01:05.603309+00:00
1,568,209,986,000
c16ed66689d526926d58b9c9684c4f8db1503876
3
{ "blob_id": "c16ed66689d526926d58b9c9684c4f8db1503876", "branch_name": "refs/heads/master", "committer_date": 1568209986000, "content_id": "6041eb6f29ea7cce41e2f5929c81f96b8efd966c", "detected_licenses": [ "MIT" ], "directory_id": "65fe5f573e0a7d365e32929d8d07d1ecf9320510", "extension": "py", "fi...
2.859375
stackv2
from requests import exceptions from requests_oauthlib import OAuth1 from requests import Session from requests.adapters import HTTPAdapter from operator import itemgetter import json import urllib3 import time import csv from src.config.config import CONSUMER_KEY, CONSUMER_SECRET, ACCESS_TOKEN, ACCESS_SECRET urllib3....
123
37.33
117
16
1,006
python
[{"finding_id": "codeql_py/request-without-cert-validation_16d277e374e97a74_a5691061", "tool_name": "codeql", "rule_id": "py/request-without-cert-validation", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "This request may run without certificate validation because [it is disabled]...
1
true
[ "CWE-295" ]
[ "py/request-without-cert-validation" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "This request may run without certificate validation because [it is disabled](1)." ]
[ 21 ]
[ 22 ]
[ 24 ]
[ 94 ]
2024-11-19T00:40:28.563209+00:00
1,613,823,877,000
45ee6f3d66befb0349f090378246cd68487ac085
3
{ "blob_id": "45ee6f3d66befb0349f090378246cd68487ac085", "branch_name": "refs/heads/master", "committer_date": 1613823877000, "content_id": "e5547ac23f5ab92d2031e2ce75b3cb6fb03a0857", "detected_licenses": [ "MIT" ], "directory_id": "f41da9b371f827cd4ac58aad15217509470a1838", "extension": "py", "fi...
2.75
stackv2
# coding=utf-8 import requests import hashlib import random import json from retrying import retry @retry(stop_max_attempt_number=5) def Translation(Str): """ 百度翻译接口调用,需要先注册百度云接口使用 英语转中文 """ appid = '' # 填写你的appid secretKey = '' # 填写你的密钥 httpClient = None myurl = 'http://api.fanyi...
39
21.82
107
20
297
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_2fe82458ecec2d7b_776da95f", "tool_name": "codeql", "rule_id": "py/weak-sensitive-data-hashing", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "[Sensitive data (secret)](1) is used in a hashing algorithm (MD5) that is insecur...
1
true
[ "CWE-327" ]
[ "py/weak-sensitive-data-hashing" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "[Sensitive data (secret)](1) is used in a hashing algorithm (MD5) that is insecure." ]
[ 27 ]
[ null ]
[ 24 ]
[ 37 ]
2024-11-19T01:06:08.833529+00:00
1,604,042,708,000
fac74c37a25f0433abe900b0e2acd846ac9a0d79
2
{ "blob_id": "fac74c37a25f0433abe900b0e2acd846ac9a0d79", "branch_name": "refs/heads/main", "committer_date": 1604042708000, "content_id": "b53f52640e11deb61dfc7e42f3b8e2c67477a1e8", "detected_licenses": [ "MIT" ], "directory_id": "0d07ead2c12ded26e870705f611342167dbf946f", "extension": "py", "file...
2.359375
stackv2
import os import string import json import cv2 from datetime import datetime from flask import Flask, request, make_response, jsonify import urllib from urllib.request import urlretrieve from process import ApiExample import ssl ssl._create_default_https_context = ssl._create_unverified_context # Initialize our Fla...
86
32.66
100
19
662
python
[{"finding_id": "codeql_py/path-injection_3a9e2e7ffe55d05f_7ab6ddd5", "tool_name": "codeql", "rule_id": "py/path-injection", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This path depends on a [user-provided value](1).", "remediation": "", "location": {"file_path": "unknown", ...
1
true
[ "CWE-022" ]
[ "py/path-injection" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This path depends on a [user-provided value](1)." ]
[ 69 ]
[ null ]
[ 31 ]
[ 41 ]
2024-11-19T01:06:09.348546+00:00
1,573,075,125,000
ef17e2e76feabed2db3d778d05aad772ba2f5733
2
{ "blob_id": "ef17e2e76feabed2db3d778d05aad772ba2f5733", "branch_name": "refs/heads/master", "committer_date": 1573099512000, "content_id": "60d1a5907ba80b8508fa51fd64f3bdb43cb97b7a", "detected_licenses": [ "Apache-2.0" ], "directory_id": "010505604e56d310e74bb60ca35c1413c13be5e9", "extension": "py"...
2.328125
stackv2
# Copyright 2019 Google, LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing,...
107
30.19
80
17
823
python
[{"finding_id": "codeql_py/stack-trace-exposure_6876978307d05ea5_d1e59179", "tool_name": "codeql", "rule_id": "py/stack-trace-exposure", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "[Stack trace information](1) flows to this location and may be exposed to an external user.", "...
2
true
[ "CWE-209", "CWE-209" ]
[ "py/stack-trace-exposure", "py/stack-trace-exposure" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "[Stack trace information](1) flows to this location and may be exposed to an external user.", "[Stack trace information](1) flows to this location and may be exposed to an external user." ]
[ 60, 104 ]
[ null, null ]
[ 26, 26 ]
[ 73, 64 ]
2024-11-19T01:17:33.230146+00:00
1,594,241,968,000
8fbb5dcbaf6f035048a0fe6ee8e33f4ffd4d8515
3
{ "blob_id": "8fbb5dcbaf6f035048a0fe6ee8e33f4ffd4d8515", "branch_name": "refs/heads/master", "committer_date": 1594241968000, "content_id": "117fb4334027fa59ae6fe1f78176527c4f87b180", "detected_licenses": [ "Apache-2.0" ], "directory_id": "81362db567df7c607c98944b2ca6ea156b0281bc", "extension": "py"...
3.046875
stackv2
#!/usr/bin/env python """ Download genome assemblies from Enterobase (enterobase.warwick.ac.uk) by their barcodes. This script is modified from C-Connor"s script EnterobaseGenomeAssemblyDownload.py, which is accessible at https://github.com/C-Connor/EnterobaseGenomeAssemblyDownload. Authors: C-Connor (github.com/C-Co...
83
46.35
174
13
893
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_59581064ec05a129_0615f964", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (password)](1) as clear text.", ...
1
true
[ "CWE-312" ]
[ "py/clear-text-logging-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression logs [sensitive data (password)](1) as clear text." ]
[ 57 ]
[ null ]
[ 11 ]
[ 47 ]
2024-11-19T01:15:16.766775+00:00
1,635,911,783,000
b4e0f12ff8dce8b453b9a38ed0c9a395ffe97308
2
{ "blob_id": "b4e0f12ff8dce8b453b9a38ed0c9a395ffe97308", "branch_name": "refs/heads/master", "committer_date": 1635911783000, "content_id": "3af062ec6664a36bfe5f9a9431bd940e5aa92ffb", "detected_licenses": [ "MIT" ], "directory_id": "ce19e17bf5e50f26a29d497c1b8c742be359539a", "extension": "py", "fi...
2.5
stackv2
import os import time import socket import requests import base64 import yaml from datetime import datetime, timedelta from flask import Flask, request, g, render_template, jsonify, Response app = Flask(__name__) app.config.from_object(__name__) # load config from this file , flaskr.py config = None with open(os.ge...
95
26.21
84
17
583
python
[{"finding_id": "codeql_py/path-injection_71858e96cac47353_5b56d2a5", "tool_name": "codeql", "rule_id": "py/path-injection", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This path depends on a [user-provided value](1).", "remediation": "", "location": {"file_path": "unknown", ...
3
true
[ "CWE-022", "CWE-022", "CWE-918" ]
[ "py/path-injection", "py/path-injection", "py/partial-ssrf" ]
[ "HIGH", "HIGH", "MEDIUM" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "This path depends on a [user-provided value](1).", "This path depends on a [user-provided value](1).", "Part of the URL of this request depends on a [user-provided value](1)." ]
[ 34, 35, 45 ]
[ null, null, null ]
[ 23, 19, 24 ]
[ 37, 33, 41 ]
2024-11-19T01:32:19.816369+00:00
1,494,941,459,000
5606958d54a20da725a18907b1d5ac4fae611d82
3
{ "blob_id": "5606958d54a20da725a18907b1d5ac4fae611d82", "branch_name": "refs/heads/master", "committer_date": 1494941459000, "content_id": "7745a228f853f6f539221996afb729b7be015cb2", "detected_licenses": [ "MIT" ], "directory_id": "ea287ab6c0944a3fe4069d56936002fa855e90fa", "extension": "py", "fi...
2.546875
stackv2
#-*- coding:utf-8 -*- from flask import Flask,render_template,request import MySQLdb,sys import base64 reload(sys) sys.setdefaultencoding("utf-8") MYSQL_HOST = '127.0.0.1' MYSQL_USER = 'root' MYSQL_PASS = 'root' MYSQL_DB = 'bot' app = Flask(__name__) @app.route('/view') def view(): conn = MySQLdb.connect(MYSQL_...
43
27.35
89
11
339
python
[{"finding_id": "codeql_py/flask-debug_98ec98185194d930_57cc65c8", "tool_name": "codeql", "rule_id": "py/flask-debug", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", ...
2
true
[ "CWE-215", "CWE-089" ]
[ "py/flask-debug", "py/sql-injection" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", "This SQL query depends on a [user-provided value](1)." ]
[ 41, 34 ]
[ null, null ]
[ 9, 20 ]
[ 65, 89 ]
2024-11-19T01:32:22.178787+00:00
1,607,684,857,000
1cf40745052b222cacbbdb579ed2a456815c90e6
2
{ "blob_id": "1cf40745052b222cacbbdb579ed2a456815c90e6", "branch_name": "refs/heads/master", "committer_date": 1607684857000, "content_id": "b94117f4ccf891d5a4641a3d74007da9faa70c6b", "detected_licenses": [ "MIT" ], "directory_id": "7ae6da3394f428223dd5c06fdc223638063fb852", "extension": "py", "fi...
2.4375
stackv2
#!/usr/bin/env python # -*- coding: UTF-8 -*- from whoosh.index import create_in, open_dir from whoosh.fields import * from whoosh.analysis import RegexAnalyzer import os import urllib2 from urlparse import urlparse import time import re import threading class FullText(object): js_websites = { 'www.quora....
175
34.3
116
18
1,433
python
[{"finding_id": "codeql_py/bad-tag-filter_4ac76e3f50f5aeee_76fe63cc", "tool_name": "codeql", "rule_id": "py/bad-tag-filter", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "This regular expression does not match upper case <SCRIPT> tags.", "remediation": "", "location": {"file_path": ...
2
true
[ "CWE-116", "CWE-116" ]
[ "py/bad-tag-filter", "py/bad-tag-filter" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "This regular expression does not match upper case <SCRIPT> tags.", "This regular expression does not match comments containing newlines." ]
[ 27, 28 ]
[ null, null ]
[ 38, 36 ]
[ 67, 46 ]
2024-11-19T01:43:47.872496+00:00
1,554,447,065,000
12386b7821286cb5ca7b05dc783e5a9975542ccf
3
{ "blob_id": "12386b7821286cb5ca7b05dc783e5a9975542ccf", "branch_name": "refs/heads/master", "committer_date": 1554447133000, "content_id": "a0fd1ef8256fd2af3f527187a73af9ffed7e490f", "detected_licenses": [ "Apache-2.0" ], "directory_id": "b02d3b33199deb884f24b65a4d9c040c8ea5d1a7", "extension": "py"...
2.515625
stackv2
import sys try: VM_count = sys.argv[1] except IndexError: print("VM_count was not specified") exit() #Impiorts from Jinja2 from jinja2 import Environment, FileSystemLoader #Load Jinja2 template env = Environment(loader = FileSystemLoader('./'), trim_blocks=True, lstrip_blocks=True) template = env.get_te...
19
22.42
88
12
112
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_b88d548a2b41eb85_aa99b7c0", "tool_name": "codeql", "rule_id": "py/jinja2/autoescape-false", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Using jinja2 templates with autoescape=False can potentially allow XSS attacks.", "remediati...
1
true
[ "CWE-079" ]
[ "py/jinja2/autoescape-false" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "Using jinja2 templates with autoescape=False can potentially allow XSS attacks." ]
[ 13 ]
[ null ]
[ 7 ]
[ 89 ]
2024-11-19T01:43:54.994369+00:00
1,548,716,773,000
04e71bd492b87812b4e8b8c30f5307899ae2c5c7
3
{ "blob_id": "04e71bd492b87812b4e8b8c30f5307899ae2c5c7", "branch_name": "refs/heads/master", "committer_date": 1548716965000, "content_id": "c8268a36cf09e669af69ebcda85ae00457d760cf", "detected_licenses": [ "MIT" ], "directory_id": "f86128b6e9f7b11716206bee57b5a8ff517371d9", "extension": "py", "fi...
3.109375
stackv2
""" Playing with CSV. Data set: 40,000 answer records from DOU (developers of Ukraine) from May 2015 until June 2018. Source: https://github.com/devua/csv/tree/master/salaries. """ import csv import glob from collections import defaultdict from functools import reduce, partial from operator import add f...
66
31.67
113
14
499
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_6a7279d8dda182ae_44dce9cb", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (private)](1) as clear text.", "...
1
true
[ "CWE-312" ]
[ "py/clear-text-logging-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression logs [sensitive data (private)](1) as clear text." ]
[ 65 ]
[ null ]
[ 15 ]
[ 52 ]
2024-11-19T01:43:59.582295+00:00
1,477,027,003,000
4d2b91af94623318f3b280f89362a9622839eeeb
3
{ "blob_id": "4d2b91af94623318f3b280f89362a9622839eeeb", "branch_name": "refs/heads/master", "committer_date": 1477027003000, "content_id": "64df96b9aaf5f7d908f00ad83a995d1fe9d3411a", "detected_licenses": [ "MIT" ], "directory_id": "d1e80b6aaca73991b3944acfb90b38e79465b87a", "extension": "py", "fi...
2.765625
stackv2
"""Train tickets query via comand-line. Usage: tickets [-gdtkz] <from> <to> <date> Options: -h,--help 显示帮助菜单 -g 高铁 -d 动车 -t 特快 -k 快速 -z 直达 Example: tickets beijing shanghai 2016-08-25 """ from docopt import docopt import requests from stations import...
35
25
150
10
271
python
[{"finding_id": "codeql_py/request-without-cert-validation_74ea978b1d9a4a94_db2c153a", "tool_name": "codeql", "rule_id": "py/request-without-cert-validation", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "This request may run without certificate validation because [it is disabled]...
1
true
[ "CWE-295" ]
[ "py/request-without-cert-validation" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "This request may run without certificate validation because [it is disabled](1)." ]
[ 29 ]
[ null ]
[ 9 ]
[ 39 ]
2024-11-19T01:43:59.929328+00:00
1,546,977,466,000
de1683e566eb683652ca2b843399bf26429a4cfb
3
{ "blob_id": "de1683e566eb683652ca2b843399bf26429a4cfb", "branch_name": "refs/heads/master", "committer_date": 1546977466000, "content_id": "ce822b03838dba02f26131caf567065422104cfd", "detected_licenses": [ "MIT" ], "directory_id": "a81c0dadf8622c3cb488016616434c6317d87f5c", "extension": "py", "fi...
2.859375
stackv2
class geotile(): class gps(): def __init__(self, latitude, longitude): self.latitude = latitude self.longitude = longitude if latitude < -90.0 or latitude > 90.0: raise ValueError("Latitude must be between -90 and 90") if longi...
359
35.65
156
18
3,517
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_b24672f5ebe172a4_acc9d02e", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (private)](1) as clear text.\nTh...
1
true
[ "CWE-312" ]
[ "py/clear-text-logging-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression logs [sensitive data (private)](1) as clear text.\nThis expression logs [sensitive data (private)](2) as clear text." ]
[ 323 ]
[ null ]
[ 19 ]
[ 63 ]
2024-11-19T01:44:06.104818+00:00
1,520,759,506,000
0381b049bad79f7c19b98d62d42d82417273ad14
3
{ "blob_id": "0381b049bad79f7c19b98d62d42d82417273ad14", "branch_name": "refs/heads/master", "committer_date": 1520759506000, "content_id": "a4f5ebc2839665842c88dc00e35fa2f49ce18f77", "detected_licenses": [ "BSD-3-Clause" ], "directory_id": "83957f263305c8021add5f05327381263cc6fdad", "extension": "p...
2.640625
stackv2
# -*- coding: utf-8 -*- import re from .exceptions import ValidationError from . import utils from .constants import _ EMAIL_REGEX = re.compile( # dot-atom r"(^[-!#$%&'*+/=?^_`{}|~0-9A-Z]+(\.[-!#$%&'*+/=?^_`{}|~0-9A-Z]+)*" # quoted-string r'|^"([\001-\010\013\014\016-\037!#-\[\]-\177]|\\[\001-011\013...
117
28.85
95
16
917
python
[{"finding_id": "codeql_py/redos_eff7a3177cd94943_86459bc0", "tool_name": "codeql", "rule_id": "py/redos", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "This part of the regular expression may cause exponential backtracking on strings starting with '\"' and containing many repetitio...
1
true
[ "CWE-1333" ]
[ "py/redos" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This part of the regular expression may cause exponential backtracking on strings starting with '\"' and containing many repetitions of '\\\\013'." ]
[ 13 ]
[ null ]
[ 10 ]
[ 84 ]
2024-11-19T01:44:11.273639+00:00
1,636,857,044,000
ed551087768c0cf8ea425af5bdefe62333efdcdc
3
{ "blob_id": "ed551087768c0cf8ea425af5bdefe62333efdcdc", "branch_name": "refs/heads/master", "committer_date": 1636857044000, "content_id": "6d8c93c702f35b2f530f587ef296126552087f27", "detected_licenses": [ "MIT" ], "directory_id": "98e7b466093046e93a34e93c4f5524c948b85b49", "extension": "py", "fi...
2.609375
stackv2
""" File watch commercial remover """ import os import subprocess import logging import shutil import sys import time from threading import Thread from queue import Queue WORK_ROOT = "/config/" _LOGGER = logging.getLogger(__name__) logging.basicConfig(filename=WORK_ROOT+'watcher.log', filemode='a', level=logging.DEBU...
159
34.82
172
20
1,220
python
[{"finding_id": "codeql_py/overly-permissive-file_51d8e5740c747f81_9416866e", "tool_name": "codeql", "rule_id": "py/overly-permissive-file", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Overly permissive mask in chmod sets file to world readable.", "remediation": "", "location": ...
1
true
[ "CWE-732" ]
[ "py/overly-permissive-file" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "Overly permissive mask in chmod sets file to world readable." ]
[ 82 ]
[ null ]
[ 13 ]
[ 39 ]
2024-11-19T02:19:52.719783+00:00
1,620,969,767,000
179235d5d5a74ee1f058f377637bd4412e3dde06
3
{ "blob_id": "179235d5d5a74ee1f058f377637bd4412e3dde06", "branch_name": "refs/heads/main", "committer_date": 1620969767000, "content_id": "7d37f7886f2626aef76e84f1048b9bfebcf12b08", "detected_licenses": [ "MIT" ], "directory_id": "3f4441d938bc4989ed6f95109b8424c2aa51e350", "extension": "py", "file...
3.203125
stackv2
""" **Example 0: Global and User Text Editor** This server demonstrates the access control of two endpoints: ``/text/global.txt`` ``/text/user/<username>.txt`` All registered users can read and write to the ``/text/global.txt``, however only a user can read and write to their own ``/text/us...
165
30.58
116
17
1,176
python
[{"finding_id": "codeql_py/flask-debug_e32f951878eab87a_1c0495e2", "tool_name": "codeql", "rule_id": "py/flask-debug", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", ...
5
true
[ "CWE-215", "CWE-022", "CWE-022", "CWE-022", "CWE-022" ]
[ "py/flask-debug", "py/path-injection", "py/path-injection", "py/path-injection", "py/path-injection" ]
[ "HIGH", "HIGH", "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", "This path depends on a [user-provided value](1).", "This path depends on a [user-provided value](1).", "This path depends on a [user-provided value](1).", "This path depends on a [user-pro...
[ 165, 126, 148, 151, 155 ]
[ null, null, null, null, null ]
[ 5, 23, 19, 19, 23 ]
[ 51, 59, 27, 27, 31 ]
2024-11-19T02:19:53.415164+00:00
1,623,742,296,000
8acb9f252ae029f963105852c50ee94b9d66b838
2
{ "blob_id": "8acb9f252ae029f963105852c50ee94b9d66b838", "branch_name": "refs/heads/main", "committer_date": 1623742296000, "content_id": "2cf97fb7f72ae56f51a782e0c30f31043756cd79", "detected_licenses": [ "MIT" ], "directory_id": "3cffef9a3ee6a131210f8a0ed06597dbc0853175", "extension": "py", "file...
2.328125
stackv2
import frappe import requests from frappe import _ import urllib import json # api/method/expensify_integration.expensify_integration.expensify_integration.handle_sample_expense # LOGIC TO INTERACT WITH FRAPPE def get_employee(full_name): employee_doc = frappe.get_doc(doctype="Employee", employee_name = full_name...
135
32.07
109
18
1,027
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_e198a8d4d1654d81_5411b420", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (private)](1) as clear text.", "...
2
true
[ "CWE-312", "CWE-312" ]
[ "py/clear-text-logging-sensitive-data", "py/clear-text-logging-sensitive-data" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "This expression logs [sensitive data (private)](1) as clear text.", "This expression logs [sensitive data (private)](1) as clear text." ]
[ 18, 20 ]
[ null, null ]
[ 11, 11 ]
[ 20, 27 ]
2024-11-19T02:19:55.239322+00:00
1,602,392,538,000
b63867dae253dfce83c4468ba3260e5e8f380171
4
{ "blob_id": "b63867dae253dfce83c4468ba3260e5e8f380171", "branch_name": "refs/heads/main", "committer_date": 1602392538000, "content_id": "4d6b093a794487df925fb84a3cd8843cf2595ca6", "detected_licenses": [ "MIT" ], "directory_id": "d36911d727029264fcd51dffd8b374b660063d79", "extension": "py", "file...
3.59375
stackv2
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Sun Sep 1 19:14:35 2019 @author: rohan devaki """ # Step 1 Load Data import pandas as pd dataset = pd.read_csv('credit_score_and_data.csv') X = dataset.iloc[:, :-1].values y = dataset.iloc[:,1].values # Step 2: Split data into training and testing from sk...
50
30.72
88
8
431
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_af5c3c4cfcb9d041_f230a8ab", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (private)](1) as clear text.", "...
1
true
[ "CWE-312" ]
[ "py/clear-text-logging-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression logs [sensitive data (private)](1) as clear text." ]
[ 50 ]
[ null ]
[ 71 ]
[ 87 ]
2024-11-19T00:59:36.236323+00:00
1,656,335,559,000
0a9565a57170620fd869a0c7b5d2f2d976905973
2
{ "blob_id": "0a9565a57170620fd869a0c7b5d2f2d976905973", "branch_name": "refs/heads/main", "committer_date": 1656335559000, "content_id": "72b51240ec07a8daa87c8dd7830d591e3617908f", "detected_licenses": [ "Apache-2.0" ], "directory_id": "ca0cac0203af193db440ab6d8e4e28287db22ca5", "extension": "py", ...
2.421875
stackv2
import io import logging import jsonpickle import numpy as np import torch from flask import Flask, request from tqdm import tqdm from model.model import ResMLP from utils import enable_dropout, forward_mc, read_json logging.basicConfig( level=logging.DEBUG, format="%(asctime)s.%(msecs)03d %(levelname)s %(mo...
88
26.62
90
15
601
python
[{"finding_id": "codeql_py/unsafe-deserialization_07ecc7e069f79aa9_826a9c8f", "tool_name": "codeql", "rule_id": "py/unsafe-deserialization", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "Unsafe deserialization depends on a [user-provided value](1).", "remediation": "", "locatio...
2
true
[ "CWE-502", "CWE-502" ]
[ "py/unsafe-deserialization", "py/unsafe-deserialization" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "Unsafe deserialization depends on a [user-provided value](1).", "Unsafe deserialization depends on a [user-provided value](1)." ]
[ 48, 56 ]
[ null, null ]
[ 30, 26 ]
[ 34, 36 ]
2024-11-19T01:00:06.126402+00:00
1,398,752,841,000
ac719559d217ffb8478c948767129be31d6554c6
3
{ "blob_id": "ac719559d217ffb8478c948767129be31d6554c6", "branch_name": "refs/heads/master", "committer_date": 1398752841000, "content_id": "3b77673cfceb24d34bdf76ef1c73fb20c1635d8b", "detected_licenses": [ "MIT" ], "directory_id": "c736130d241a0a3a5ec727646dcbf00f29c19fd9", "extension": "py", "fi...
2.578125
stackv2
import flask as f import peewee import models as md import re from functools import wraps import hashlib from gitgate import __version__ app = f.Flask(__name__) ### ---------------------------------------------------------------------------- ### Helper functions ### ---------------------------------------------------...
486
30.17
80
18
3,469
python
[{"finding_id": "codeql_py/polynomial-redos_204c31c40be1e5cb_d4a83de3", "tool_name": "codeql", "rule_id": "py/polynomial-redos", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This [regular expression](1) that depends on a [user-provided value](2) may run slow on strings with ma...
4
true
[ "CWE-1333", "CWE-327", "CWE-327", "CWE-601" ]
[ "py/polynomial-redos", "py/weak-sensitive-data-hashing", "py/weak-sensitive-data-hashing", "py/url-redirection" ]
[ "HIGH", "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "This [regular expression](1) that depends on a [user-provided value](2) may run slow on strings with many repetitions of 'a'.", "[Sensitive data (password)](1) is used in a hashing algorithm (SHA1) that is insecure for password hashing, since it is not a computationally expensive hash function.\n[Sensitive data ...
[ 64, 124, 175, 34 ]
[ null, null, null, null ]
[ 48, 38, 31, 35 ]
[ 62, 41, 39, 67 ]
2024-11-19T01:00:08.827864+00:00
1,621,593,565,000
1116ba04c66a20d469a26c6d6c125967d274e8a5
4
{ "blob_id": "1116ba04c66a20d469a26c6d6c125967d274e8a5", "branch_name": "refs/heads/master", "committer_date": 1621593565000, "content_id": "b3fbfb2a919e89e027252d6d0d36a68deef662cf", "detected_licenses": [ "MIT" ], "directory_id": "6eaff445cf1e53b60870e35dc9757f4a23b668ae", "extension": "py", "fi...
3.5
stackv2
import tkinter as tk import requests import hashlib def send_request_to_API(start_char): """ The function sends request to the API. """ # first 5 characters of hashed password added to the URL url = 'https://api.pwnedpasswords.com/range/' + start_char try: res = requests.get(url) ...
140
25.07
113
15
960
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_befcfad0166f1139_26a8605f", "tool_name": "codeql", "rule_id": "py/weak-sensitive-data-hashing", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "[Sensitive data (password)](1) is used in a hashing algorithm (SHA1) that is inse...
1
true
[ "CWE-327" ]
[ "py/weak-sensitive-data-hashing" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "[Sensitive data (password)](1) is used in a hashing algorithm (SHA1) that is insecure for password hashing, since it is not a computationally expensive hash function.\n[Sensitive data (password)](2) is used in a hashing algorithm (SHA1) that is insecure for password hashing, since it is not a computationally expen...
[ 49 ]
[ null ]
[ 29 ]
[ 54 ]
2024-11-19T01:11:47.572827+00:00
1,634,232,424,000
81c5c34d30678df0a9efc56fbdeee5fb93313951
3
{ "blob_id": "81c5c34d30678df0a9efc56fbdeee5fb93313951", "branch_name": "refs/heads/master", "committer_date": 1634232424000, "content_id": "daeb6862cba0076e825994ab1e568b71296ebf7a", "detected_licenses": [ "MIT" ], "directory_id": "bc9f1313a57d094b75a49c678e75f05fcfe93826", "extension": "py", "fi...
2.90625
stackv2
# Importando el libería de encriptación from hashlib import sha1 # Django from django.utils.crypto import get_random_string UNUSABLE_PASSWORD_PREFIX = '!' UNUSABLE_PASSWORD_SUFFIX_LENGTH = 40 def make_password(raw_password): """ Make a password compatible with metin2 database if raw_password is none t...
43
24.26
92
17
236
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_dbc817cb06c05009_6084931f", "tool_name": "codeql", "rule_id": "py/weak-sensitive-data-hashing", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "[Sensitive data (password)](1) is used in a hashing algorithm (SHA1) that is inse...
1
true
[ "CWE-327" ]
[ "py/weak-sensitive-data-hashing" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "[Sensitive data (password)](1) is used in a hashing algorithm (SHA1) that is insecure for password hashing, since it is not a computationally expensive hash function.\n[Sensitive data (password)](2) is used in a hashing algorithm (SHA1) that is insecure for password hashing, since it is not a computationally expen...
[ 23 ]
[ null ]
[ 13 ]
[ 34 ]
2024-11-19T01:21:33.929694+00:00
1,571,576,216,000
e713055921fa99a6eefda913c57619649826a54d
2
{ "blob_id": "e713055921fa99a6eefda913c57619649826a54d", "branch_name": "refs/heads/master", "committer_date": 1571576216000, "content_id": "db4fde97aace93f0ca388979f566a7e3e24e93c4", "detected_licenses": [ "Apache-2.0" ], "directory_id": "304435172bd5ba0413051766762975d3cd1137e8", "extension": "py"...
2.390625
stackv2
import os from flask import Flask, request, jsonify from convert.keras import KerasONNX import onnxruntime as rt import numpy as np from PIL import Image import requests from google.cloud import storage from io import BytesIO, StringIO from flask_cors import CORS from transferlearning.utils import TransferLearning fro...
148
27.28
151
17
1,026
python
[{"finding_id": "codeql_py/flask-debug_fea46a0b0050e05a_ba1777a5", "tool_name": "codeql", "rule_id": "py/flask-debug", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", ...
4
true
[ "CWE-215", "CWE-918", "CWE-022", "CWE-918" ]
[ "py/flask-debug", "py/full-ssrf", "py/path-injection", "py/partial-ssrf" ]
[ "HIGH", "HIGH", "HIGH", "MEDIUM" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", "The full URL of this request depends on a [user-provided value](1).", "This path depends on a [user-provided value](1).", "Part of the URL of this request depends on a [user-provided value](...
[ 148, 69, 54, 142 ]
[ null, null, null, null ]
[ 5, 16, 27, 9 ]
[ 51, 52, 44, 55 ]
2024-11-19T01:56:42.127605+00:00
1,563,394,962,000
99d8bc445e301b00469848996fdb65ee674cd2ee
2
{ "blob_id": "99d8bc445e301b00469848996fdb65ee674cd2ee", "branch_name": "refs/heads/master", "committer_date": 1563394962000, "content_id": "6dcf9d15b68ccd73c6708351a852a0da9acdff40", "detected_licenses": [ "Apache-2.0" ], "directory_id": "bda6425ad9e5a6cdf565d65dcd078a44c35b7e03", "extension": "py"...
2.4375
stackv2
import os import re import boto3 from botocore.exceptions import ClientError if not 'KAGGLE_CONFIG_DIR' in os.environ.keys(): os.environ['KAGGLE_CONFIG_DIR'] = os.getcwd() import kaggle def download_dataset(url, dest, unzip=True): try: dataset = re.search(r'kaggle.com/([^/]+)/([^/]+)', url).group() ...
40
33.95
87
14
318
python
[{"finding_id": "codeql_py/incomplete-url-substring-sanitization_201f9366026224b7_25035eb3", "tool_name": "codeql", "rule_id": "py/incomplete-url-substring-sanitization", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "The string [kaggle.com/](1) may be at an arbitrary position in the...
1
true
[ "CWE-020" ]
[ "py/incomplete-url-substring-sanitization" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "The string [kaggle.com/](1) may be at an arbitrary position in the sanitized URL." ]
[ 14 ]
[ null ]
[ 16 ]
[ 40 ]
2024-11-19T01:56:51.046577+00:00
1,515,014,361,000
88dd0a9e1c5c06747a6e5f0b1162d6b26c209853
3
{ "blob_id": "88dd0a9e1c5c06747a6e5f0b1162d6b26c209853", "branch_name": "refs/heads/master", "committer_date": 1515014361000, "content_id": "c673d136e7e2ac192224979c8754b5348ff262f8", "detected_licenses": [ "MIT" ], "directory_id": "1b8115f9b080a328e60b6effcaeb8c2f813d69bd", "extension": "py", "fi...
2.640625
stackv2
#!/usr/bin/env python """ Sets up Flask to simulate forwarding a call with answering machine detection. An inbound call is placed in a conference while an outbound API call is made to a target number. If an answering machine is detected, the call is terminated, a message is played to the inbound caller, and the inb...
161
35.12
101
14
1,337
python
[{"finding_id": "codeql_py/log-injection_94b34695b0751b58_3ae45421", "tool_name": "codeql", "rule_id": "py/log-injection", "finding_type": "path-problem", "severity": "medium", "confidence": "medium", "message": "This log entry depends on a [user-provided value](1).", "remediation": "", "location": {"file_path": "unkno...
1
true
[ "CWE-117" ]
[ "py/log-injection" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "This log entry depends on a [user-provided value](1)." ]
[ 84 ]
[ null ]
[ 56 ]
[ 68 ]
2024-11-19T02:45:23.887022+00:00
1,635,207,927,000
0c4f822c23d92b73435fdd897aabf07ad73901e1
3
{ "blob_id": "0c4f822c23d92b73435fdd897aabf07ad73901e1", "branch_name": "refs/heads/main", "committer_date": 1635207927000, "content_id": "f8ed088bdb415b540815f8b16ffe284df2b9b733", "detected_licenses": [ "BSD-3-Clause" ], "directory_id": "2eff5a335be48682379a363a05441fed72d80dc5", "extension": "py"...
2.578125
stackv2
# Python modules import sys import os import stat import subprocess import tempfile # Our modules import vespa.common.util.misc as util_misc """Creates double-clickable shortcuts for all Vespa apps. It will only work when Vespa has been successfully installed. This code is meant to be run like so: python -m 'vespa....
174
32.6
93
16
1,395
python
[{"finding_id": "codeql_py/overly-permissive-file_fec9ec635d5cf406_fdb532e1", "tool_name": "codeql", "rule_id": "py/overly-permissive-file", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Overly permissive mask in chmod sets file to world readable.", "remediation": "", "location": ...
1
true
[ "CWE-732" ]
[ "py/overly-permissive-file" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "Overly permissive mask in chmod sets file to world readable." ]
[ 74 ]
[ null ]
[ 9 ]
[ 34 ]
2024-11-19T02:45:33.924251+00:00
1,478,091,274,000
ec43afefd161c4f6d1bd95f83dc24f79abf346f6
2
{ "blob_id": "ec43afefd161c4f6d1bd95f83dc24f79abf346f6", "branch_name": "refs/heads/master", "committer_date": 1478091274000, "content_id": "39567ae0198fb55142c9af3f0de114831b0498b1", "detected_licenses": [ "MIT" ], "directory_id": "8fe387733323182713ceab6b4b0a4cb6c82fa4ef", "extension": "py", "fi...
2.375
stackv2
#!/usr/bin/env python3 import argparse import asyncio import json import itertools import requests from apscheduler.schedulers.asyncio import AsyncIOScheduler from decouple import config, Csv from influxdb import InfluxDBClient # suppress self-signed certificate warnings requests.packages.urllib3.disable_warnings() ...
96
30.53
99
15
736
python
[{"finding_id": "codeql_py/request-without-cert-validation_af30a953fe00b0a0_484e72ea", "tool_name": "codeql", "rule_id": "py/request-without-cert-validation", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "This request may run without certificate validation because [it is disabled]...
1
true
[ "CWE-295" ]
[ "py/request-without-cert-validation" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "This request may run without certificate validation because [it is disabled](1)." ]
[ 53 ]
[ null ]
[ 11 ]
[ 59 ]
2024-11-19T02:45:35.570160+00:00
1,617,019,946,000
7ec8901f72b0c71bf4b90e964e0fb0c3538ea547
3
{ "blob_id": "7ec8901f72b0c71bf4b90e964e0fb0c3538ea547", "branch_name": "refs/heads/master", "committer_date": 1617019946000, "content_id": "ccc30cf3b3ddbea016d4c66c9f4e247052cfe7f1", "detected_licenses": [ "MIT" ], "directory_id": "e14c03b8f486dcc1a3625a08d9a0784b879bba5f", "extension": "py", "fi...
2.671875
stackv2
# coding:utf-8 from io import BytesIO import numpy as np import requests import tensorflow as tf from PIL import Image from flask import Flask, request, make_response from ml_tools.object_detection.utils import label_map_util from ml_tools.object_detection.utils import visualization_utils as vis_util class ObjectDe...
116
40.28
112
18
992
python
[{"finding_id": "codeql_py/stack-trace-exposure_3533daf65b88dd58_cc3110d7", "tool_name": "codeql", "rule_id": "py/stack-trace-exposure", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "[Stack trace information](1) flows to this location and may be exposed to an external user.", "...
2
true
[ "CWE-209", "CWE-918" ]
[ "py/stack-trace-exposure", "py/full-ssrf" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "[Stack trace information](1) flows to this location and may be exposed to an external user.", "The full URL of this request depends on a [user-provided value](1)." ]
[ 107, 93 ]
[ null, null ]
[ 38, 34 ]
[ 58, 67 ]
2024-11-19T02:45:47.655042+00:00
1,535,255,264,000
97d965f80e382e028a0b4841952b0ed6cfc64bf5
2
{ "blob_id": "97d965f80e382e028a0b4841952b0ed6cfc64bf5", "branch_name": "refs/heads/master", "committer_date": 1535255264000, "content_id": "b4ea1d8313d49ffcdd7cff6ace59c0c934fccf7d", "detected_licenses": [ "MIT" ], "directory_id": "b61711f4b7b559517cdce14a4a79a67d58f93168", "extension": "py", "fi...
2.3125
stackv2
import os from collections import namedtuple from jinja2 import Environment Generator = namedtuple('Generator', ['generate_project']) def get_generator(template_string, filters=None): def generate_project(program, out_directory): env = Environment() if filters: import importlib ...
34
28.06
81
16
185
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_440db155100c44f8_1211219e", "tool_name": "codeql", "rule_id": "py/jinja2/autoescape-false", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Using jinja2 templates with autoescape=False can potentially allow XSS attacks.", "remediati...
1
true
[ "CWE-079" ]
[ "py/jinja2/autoescape-false" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "Using jinja2 templates with autoescape=False can potentially allow XSS attacks." ]
[ 13 ]
[ null ]
[ 15 ]
[ 28 ]
2024-11-19T02:45:52.866839+00:00
1,544,683,083,000
4580413d0cb36f565d04f3a732dde9562b00d325
3
{ "blob_id": "4580413d0cb36f565d04f3a732dde9562b00d325", "branch_name": "refs/heads/master", "committer_date": 1544683083000, "content_id": "5cd1140e6ed72d34e8c1231c3a2175435626cc9f", "detected_licenses": [ "MIT" ], "directory_id": "8b9de6412a9c9393f6b0e3d6ddc4daa5c08e648b", "extension": "py", "fi...
3.21875
stackv2
# code referenced from: https://stackoverflow.com/a/30888321 def tar_extract(file_name): """ This function extracts a compressed .tar or .tar.gz file. :param file_name: File name to extract. :type file_name: str. :return: None """ import tarfile if file_name.endswith("tar.gz"): ...
20
25.5
61
12
135
python
[{"finding_id": "codeql_py/tarslip_6a365d3d553cbe1d_55a90aba", "tool_name": "codeql", "rule_id": "py/tarslip", "finding_type": "path-problem", "severity": "medium", "confidence": "medium", "message": "This file extraction depends on a [potentially untrusted source](1).", "remediation": "", "location": {"file_path": "un...
2
true
[ "CWE-022", "CWE-022" ]
[ "py/tarslip", "py/tarslip" ]
[ "MEDIUM", "MEDIUM" ]
[ "MEDIUM", "MEDIUM" ]
[ "This file extraction depends on a [potentially untrusted source](1).", "This file extraction depends on a [potentially untrusted source](1)." ]
[ 15, 19 ]
[ null, null ]
[ 9, 9 ]
[ 12, 12 ]
2024-11-19T02:45:57.703413+00:00
1,509,366,957,000
fe36ebadacdc7dccccf286e4f14226a17838d061
2
{ "blob_id": "fe36ebadacdc7dccccf286e4f14226a17838d061", "branch_name": "refs/heads/master", "committer_date": 1509366957000, "content_id": "e7b2149a60d35511889eb259d80525464d279240", "detected_licenses": [ "MIT" ], "directory_id": "e5b4d9e3240b3302db47d770260dd1bcff93d5ef", "extension": "py", "fi...
2.359375
stackv2
#!/usr/bin/env python # -*- coding: utf-8 -*- # @Time : 17-8-26 下午10:08 # @Author : xiongzhibiao # @Email : 158349411@qqcom # @File : batchrun.py # @Software: PyCharm import sys sys.path.append('/home/xiongzhibiao/github/python-S14/Common/common') import paramiko from multiprocessing import Process,Pool,Lock...
151
23.83
86
13
967
python
[{"finding_id": "codeql_py/paramiko-missing-host-key-validation_4be9b1a189b0dace_c96d9f31", "tool_name": "codeql", "rule_id": "py/paramiko-missing-host-key-validation", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Setting missing host key policy to AutoAddPolicy may be unsafe.", "r...
1
true
[ "CWE-295" ]
[ "py/paramiko-missing-host-key-validation" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "Setting missing host key policy to AutoAddPolicy may be unsafe." ]
[ 51 ]
[ null ]
[ 9 ]
[ 66 ]
2024-11-19T02:57:17.363889+00:00
1,620,409,773,000
8ab4a047738a058b662d4e8204cb66ba9bf6ee73
3
{ "blob_id": "8ab4a047738a058b662d4e8204cb66ba9bf6ee73", "branch_name": "refs/heads/master", "committer_date": 1620409773000, "content_id": "be08ec9c1a8340ea5d1f01b01f3fac4463d04c4f", "detected_licenses": [ "BSD-2-Clause-Views" ], "directory_id": "aab5a0958969db1a6cb6bcada6a14bab48f73a4f", "extensio...
2.53125
stackv2
#!/usr/bin/env python # script to test the orient.py running script. import stdb import pickle import os.path import numpy as np from obspy.clients.fdsn import Client from obspy.taup import TauPyModel from orientpy import BNG, arguments from pathlib import Path def main(): # Run the Input Parser args = arg...
225
36.8
82
22
1,962
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_8f321f00dad42b20_498d8bd8", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (private)](1) as clear text.\nTh...
1
true
[ "CWE-312" ]
[ "py/clear-text-logging-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression logs [sensitive data (private)](1) as clear text.\nThis expression logs [sensitive data (private)](2) as clear text." ]
[ 86 ]
[ 87 ]
[ 19 ]
[ 45 ]
2024-11-19T02:57:20.337997+00:00
1,443,081,430,000
2ba2592e7f5e6a0b26ce64bf6bb2f620689f0545
3
{ "blob_id": "2ba2592e7f5e6a0b26ce64bf6bb2f620689f0545", "branch_name": "refs/heads/master", "committer_date": 1443081430000, "content_id": "518cda678dc03dcf840c034e6cbf4a422b02bb46", "detected_licenses": [ "Apache-2.0" ], "directory_id": "8cdd1ef2105e49ac5b40a8d9231bb34b74da4433", "extension": "py"...
2.609375
stackv2
# -*- coding: utf-8 -*- import base64 from functools import wraps import hashlib from Crypto.Cipher import PKCS1_OAEP from Crypto.PublicKey import RSA from flask import Flask, session, jsonify, request, escape import redis redis_connections = redis.Redis() app = Flask(__name__) app.config['SECRET_KEY'] = 'mapia' @...
98
27.99
88
17
728
python
[{"finding_id": "codeql_py/flask-debug_b75c54fca1130ccd_d6a2e6ea", "tool_name": "codeql", "rule_id": "py/flask-debug", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", ...
3
true
[ "CWE-215", "CWE-326", "CWE-327" ]
[ "py/flask-debug", "py/weak-crypto-key", "py/weak-sensitive-data-hashing" ]
[ "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", "Creation of an RSA key uses [1024](1) bits, which is below 2048 and considered breakable.", "[Sensitive data (id)](1) is used in a hashing algorithm (SHA1) that is insecure." ]
[ 96, 66, 58 ]
[ null, null, null ]
[ 5, 19, 34 ]
[ 49, 37, 42 ]
2024-11-19T03:12:13.433108+00:00
1,594,313,200,000
6a86bf1c6796ccd5f8f34b137c756f7c7e2b17f4
3
{ "blob_id": "6a86bf1c6796ccd5f8f34b137c756f7c7e2b17f4", "branch_name": "refs/heads/master", "committer_date": 1594313200000, "content_id": "b52747e8490d0975f349bbb099e6fa3200c8951b", "detected_licenses": [ "MIT" ], "directory_id": "164ebc3cb0381d572f36a29f8c5e8bf2c7f99f26", "extension": "py", "fi...
2.53125
stackv2
#!/usr/bin/python3 from pathlib import Path from ftplib import FTP # FTP_TLS import imgkit from jinja2 import Template def get_data(): import sunspec.core.client as client import sunspec.core.modbus as modbus try: d = client.SunSpecClientDevice(client.TCP, 126, ipaddr='192.168.0.170') #...
84
30.93
112
16
730
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_61351389922b51fc_cdca9c47", "tool_name": "codeql", "rule_id": "py/jinja2/autoescape-false", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Using jinja2 templates with autoescape=False can potentially allow XSS attacks.", "remediati...
1
true
[ "CWE-079" ]
[ "py/jinja2/autoescape-false" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "Using jinja2 templates with autoescape=False can potentially allow XSS attacks." ]
[ 69 ]
[ null ]
[ 20 ]
[ 38 ]
2024-11-19T03:12:25.121675+00:00
1,570,384,636,000
84edbee7f294fd053dc456ea171467edc4225f2b
3
{ "blob_id": "84edbee7f294fd053dc456ea171467edc4225f2b", "branch_name": "refs/heads/master", "committer_date": 1570384636000, "content_id": "c93f52f70b48778ca2ac67ef0852c2d151dea7d2", "detected_licenses": [ "MIT" ], "directory_id": "45842cf6d44a8ed8efb6909d8862a266000dae87", "extension": "py", "fi...
2.625
stackv2
import json from flask import Blueprint, request from services.database.DBConn import database from security.jwtSecurity import session_cookie userDB = database.users auth_api = Blueprint('auth_api', __name__) @auth_api.route("/login", methods=['GET']) def user_login(): """Generated End-Point Sample http://...
33
35.61
92
17
293
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_24ffc781b7324cdf_e1fdc793", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (password)](1) as clear text.", ...
2
true
[ "CWE-312", "CWE-312" ]
[ "py/clear-text-logging-sensitive-data", "py/clear-text-logging-sensitive-data" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "This expression logs [sensitive data (password)](1) as clear text.", "This expression logs [sensitive data (password)](1) as clear text." ]
[ 28, 28 ]
[ null, null ]
[ 15, 31 ]
[ 23, 45 ]
2024-11-19T01:57:17.575154+00:00
1,609,087,254,000
bf913e616f79d2051bb827e77cccf4ea12a873b4
4
{ "blob_id": "bf913e616f79d2051bb827e77cccf4ea12a873b4", "branch_name": "refs/heads/master", "committer_date": 1609087254000, "content_id": "0915013e0b37f3691c55a6ea61ffe94b1b1d2dea", "detected_licenses": [ "MIT" ], "directory_id": "a1ffa9b86dc30b8589ef0c03d5d66306aa8e9f88", "extension": "py", "fi...
3.921875
stackv2
# File system, where one can create and edit files protected with Login system. You can call it Personal Diary. def menu(): print("***Menu***") inp = input("Welcome user... \nWant to Login(lgn) or Register(reg) (lgn/reg)? ") if inp == 'lgn': loginAcct() elif inp == 'reg': regAcct() ...
140
27.03
111
15
934
python
[{"finding_id": "codeql_py/clear-text-storage-sensitive-data_e6d5a0379600c650_4e26dd23", "tool_name": "codeql", "rule_id": "py/clear-text-storage-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression stores [sensitive data (password)](1) as clear text.\...
1
true
[ "CWE-312" ]
[ "py/clear-text-storage-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression stores [sensitive data (password)](1) as clear text.\nThis expression stores [sensitive data (password)](2) as clear text." ]
[ 47 ]
[ null ]
[ 20 ]
[ 43 ]
2024-11-19T01:57:24.805620+00:00
1,494,522,922,000
d670ccfc1a32e6a8603a2c46cd948ae027f733a1
3
{ "blob_id": "d670ccfc1a32e6a8603a2c46cd948ae027f733a1", "branch_name": "refs/heads/master", "committer_date": 1494522922000, "content_id": "11dd4db9c5781ba2142f671318c1b0f15d96b2b3", "detected_licenses": [ "Apache-2.0" ], "directory_id": "8ea761ccbe1089161c101527f68055834bac81c0", "extension": "py"...
2.734375
stackv2
#!/usr/bin/env python # -*- coding: utf-8 -*- from __future__ import print_function from future.standard_library import install_aliases install_aliases() from urllib.parse import urlparse, urlencode from urllib.request import urlopen, Request from urllib.error import HTTPError import json import os import urllib2 f...
105
22.62
116
17
624
python
[{"finding_id": "codeql_py/partial-ssrf_e04fdd29f22975cf_f5caaadc", "tool_name": "codeql", "rule_id": "py/partial-ssrf", "finding_type": "path-problem", "severity": "medium", "confidence": "medium", "message": "Part of the URL of this request depends on a [user-provided value](1).", "remediation": "", "location": {"fil...
1
true
[ "CWE-918" ]
[ "py/partial-ssrf" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "Part of the URL of this request depends on a [user-provided value](1)." ]
[ 58 ]
[ null ]
[ 15 ]
[ 117 ]
2024-11-19T02:10:49.450930+00:00
1,594,054,646,000
77f1195a10b4f532780f341fe86c23543f7f6669
3
{ "blob_id": "77f1195a10b4f532780f341fe86c23543f7f6669", "branch_name": "refs/heads/master", "committer_date": 1594054646000, "content_id": "a90e217f61bdec9a8a1a9c46b4837b997b82ff69", "detected_licenses": [ "Apache-2.0" ], "directory_id": "4cf99b4b9c71a0477081cafb07e2daf3afc1159b", "extension": "py"...
2.6875
stackv2
from django.core.management.base import BaseCommand from django.utils.crypto import get_random_string class Command(BaseCommand): help = "\n" help += "usage: ./manage.py secret_key [option]\n" help += "--------------------------------------\n" help += "example: ./manage.py secret_key generate\n" h...
54
41.85
117
19
559
python
[{"finding_id": "codeql_py/clear-text-storage-sensitive-data_69d1bbf9f25adf9d_94ae3660", "tool_name": "codeql", "rule_id": "py/clear-text-storage-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression stores [sensitive data (secret)](1) as clear text.\nT...
1
true
[ "CWE-312" ]
[ "py/clear-text-storage-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression stores [sensitive data (secret)](1) as clear text.\nThis expression stores [sensitive data (secret)](2) as clear text." ]
[ 41 ]
[ null ]
[ 24 ]
[ 34 ]
2024-11-19T02:10:55.000955+00:00
1,516,957,295,000
d898c38f20b44a8fa5122e9daeb0fd80f10f85aa
4
{ "blob_id": "d898c38f20b44a8fa5122e9daeb0fd80f10f85aa", "branch_name": "refs/heads/master", "committer_date": 1516957295000, "content_id": "539d28f308fea68a166385c9b4d2a4252570d6ab", "detected_licenses": [ "Apache-2.0" ], "directory_id": "550d6012c5f14e87803dbb29abc9edf8a34a1ca9", "extension": "py"...
3.828125
stackv2
# 18 세금 계산 프로그램 #ismarried = input('결혼 여부를 입력하세요 (y/n)') #if ismarried == 'n': #salary = int(input('연봉을 입력하세요 (단위: 만원)')) #if salary < 3000: # print("당신의 세금은 %d만원 입니다" % (salary * 0.1)) #else: # print("당신의 세금은 %d만원 입니다" % (salary * 0.25)) #elif ismarried == 'y': # salary2 = int(input('연...
181
20.02
72
11
1,716
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_90ea0fb656f3b9d9_4345c630", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (private)](1) as clear text.", "...
4
true
[ "CWE-312", "CWE-312", "CWE-312", "CWE-312" ]
[ "py/clear-text-logging-sensitive-data", "py/clear-text-logging-sensitive-data", "py/clear-text-logging-sensitive-data", "py/clear-text-logging-sensitive-data" ]
[ "HIGH", "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "This expression logs [sensitive data (private)](1) as clear text.", "This expression logs [sensitive data (private)](1) as clear text.", "This expression logs [sensitive data (private)](1) as clear text.", "This expression logs [sensitive data (private)](1) as clear text." ]
[ 30, 33, 37, 40 ]
[ null, null, null, null ]
[ 15, 15, 15, 15 ]
[ 18, 18, 18, 18 ]
2024-11-19T02:11:16.680400+00:00
1,693,574,052,000
486d8beeaf3721fed88d6bec8ae3aeaacbc2e4a1
3
{ "blob_id": "486d8beeaf3721fed88d6bec8ae3aeaacbc2e4a1", "branch_name": "refs/heads/master", "committer_date": 1693574052000, "content_id": "46630188e18e0562493c073fa847a9a7c1b1523d", "detected_licenses": [ "MIT" ], "directory_id": "184f13269249b08e5b62444ece10af8a3a35c9a5", "extension": "py", "fi...
2.6875
stackv2
#!/usr/bin/python # -*- coding: utf-8 -*- """ [path] cd /Users/brunoflaven/Documents/01_work/blog_articles/stop_starting_start_stopping/pandas_convert_json/ [file] START WP LOCALLY ! wp apis https://yalla.pythonista.mydomain.priv/wordpress/wp-json/wp/v2 https://yalla.pythonista.mydomain.priv/wordpress/wp-json/wp/v2...
95
23.54
149
12
618
python
[{"finding_id": "codeql_py/request-without-cert-validation_152686e1e3570b8a_fdd7643c", "tool_name": "codeql", "rule_id": "py/request-without-cert-validation", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "This request may run without certificate validation because [it is disabled]...
1
true
[ "CWE-295" ]
[ "py/request-without-cert-validation" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "This request may run without certificate validation because [it is disabled](1)." ]
[ 57 ]
[ null ]
[ 16 ]
[ 63 ]
2024-11-19T02:11:26.290844+00:00
1,590,311,199,000
88d7822ed205b22bb8918e9b41d626a38f1aceaa
3
{ "blob_id": "88d7822ed205b22bb8918e9b41d626a38f1aceaa", "branch_name": "refs/heads/master", "committer_date": 1590311199000, "content_id": "f6d297bf7708b8eca25ae65b8f8940e52272c566", "detected_licenses": [ "MIT" ], "directory_id": "0b6c88e4829086e5d64222e8cb1c2cd31dbb791e", "extension": "py", "fi...
2.65625
stackv2
from flask import Flask, jsonify, request, make_response import csv, string, collections, datetime from sqlite3 import connect import requests ride_share = Flask(__name__) ip = "http://0.0.0.0:80" host = "0.0.0.0" port = 80 # Function to construct the SQL query def construct_query(data): # data is of JSON type # op...
244
25.68
122
19
1,830
python
[{"finding_id": "codeql_py/flask-debug_0517155a7a36db6d_1403097d", "tool_name": "codeql", "rule_id": "py/flask-debug", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", ...
3
true
[ "CWE-215", "CWE-089", "CWE-089" ]
[ "py/flask-debug", "py/sql-injection", "py/sql-injection" ]
[ "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", "This SQL query depends on a [user-provided value](1).", "This SQL query depends on a [user-provided value](1)." ]
[ 244, 199, 217 ]
[ null, null, null ]
[ 2, 17, 17 ]
[ 50, 25, 25 ]
2024-11-19T02:11:47.224559+00:00
1,595,843,344,000
e2003b00a6917edeabfaacf274b11e4e304a4f09
2
{ "blob_id": "e2003b00a6917edeabfaacf274b11e4e304a4f09", "branch_name": "refs/heads/master", "committer_date": 1595845764000, "content_id": "49df7f36546b8ed125058e80bf0abbc8bf417839", "detected_licenses": [ "Apache-2.0" ], "directory_id": "40e7fd21ee7cb090650eb2ce122abde0b17147d0", "extension": "py"...
2.3125
stackv2
import os import logging import ast import sys import importlib from glob import glob from itertools import product, chain import yaml import networkx as nx from jinja2 import Template logger = logging.getLogger('soil') logger.setLevel(logging.INFO) def load_network(network_params, dir_path=None): if network_...
201
28.05
81
17
1,356
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_be35027ba3af8b52_4133eded", "tool_name": "codeql", "rule_id": "py/jinja2/autoescape-false", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Using jinja2 templates with autoescape=False can potentially allow XSS attacks.", "remediati...
1
true
[ "CWE-079" ]
[ "py/jinja2/autoescape-false" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "Using jinja2 templates with autoescape=False can potentially allow XSS attacks." ]
[ 69 ]
[ null ]
[ 16 ]
[ 44 ]
2024-11-19T02:11:50.301217+00:00
1,614,613,076,000
3d4e10065a1f55290b8a94fe1655befc9900d1e8
3
{ "blob_id": "3d4e10065a1f55290b8a94fe1655befc9900d1e8", "branch_name": "refs/heads/master", "committer_date": 1614613076000, "content_id": "9081f9cdf6ed2a12501db117d8abb900f1d58bea", "detected_licenses": [ "Apache-2.0" ], "directory_id": "895a26b545993b71aab920f34799b200e43e6170", "extension": "py"...
2.828125
stackv2
import strat_models import networkx as nx import numpy as np import pandas as pd from sklearn.model_selection import train_test_split from sklearn.preprocessing import StandardScaler import matplotlib.pyplot as plt np.random.seed(123) """ Cardiovascular disease dataset data is from https://www.kaggle.com/sulianova...
188
29.62
113
12
1,750
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_cc5ad177390592e9_ad3cad85", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (private)](1) as clear text.", "...
2
true
[ "CWE-312", "CWE-312" ]
[ "py/clear-text-logging-sensitive-data", "py/clear-text-logging-sensitive-data" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "This expression logs [sensitive data (private)](1) as clear text.", "This expression logs [sensitive data (private)](1) as clear text." ]
[ 145, 181 ]
[ null, null ]
[ 7, 7 ]
[ 61, 82 ]
2024-11-19T02:32:48.573411+00:00
1,687,538,038,000
669b0c70a4ef85a0b24e166bda71857aee91d150
2
{ "blob_id": "669b0c70a4ef85a0b24e166bda71857aee91d150", "branch_name": "refs/heads/main", "committer_date": 1687538038000, "content_id": "2b030732fba85b7365890f68c7d98b3189acb629", "detected_licenses": [ "MIT" ], "directory_id": "060ce17de7b5cdbd5f7064d1fceb4ded17a23649", "extension": "py", "file...
2.359375
stackv2
# -*- coding: utf-8 -*- # pragma pylint: disable=unused-argument, no-self-use # (c) Copyright IBM Corp. 2010, 2018. All Rights Reserved. from resilient_lib import RequestsCommon import json import base64 import time import datetime import logging from resilient_circuits import FunctionError try: from urlparse imp...
186
45.21
154
19
1,852
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_2f5e1f5e57179709_c43e8b85", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (password)](1) as clear text.\nT...
1
true
[ "CWE-312" ]
[ "py/clear-text-logging-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression logs [sensitive data (password)](1) as clear text.\nThis expression logs [sensitive data (password)](2) as clear text." ]
[ 131 ]
[ null ]
[ 19 ]
[ 35 ]
2024-11-19T02:32:58.712151+00:00
1,593,521,556,000
94074231992b9be3ca24dd371844042695fe7b15
3
{ "blob_id": "94074231992b9be3ca24dd371844042695fe7b15", "branch_name": "refs/heads/master", "committer_date": 1593521556000, "content_id": "f3d39b28ef84f7779ac9fb3d64e164fa37ead478", "detected_licenses": [ "Apache-2.0" ], "directory_id": "e54fe7926d65149dd3e73b3c2c2689f99ccf7952", "extension": "py"...
2.53125
stackv2
from __future__ import absolute_import from __future__ import division from __future__ import print_function import datetime import os.path import random import re import tarfile try: import unzip_requirements open('/tmp/sls-py-req/google/__init__.py', 'a').close() # fixing `import google.protobuf` except Im...
193
31.69
99
18
1,435
python
[{"finding_id": "codeql_py/tarslip_75f7f4c7757b05ee_40641cd2", "tool_name": "codeql", "rule_id": "py/tarslip", "finding_type": "path-problem", "severity": "medium", "confidence": "medium", "message": "This file extraction depends on a [potentially untrusted source](1).", "remediation": "", "location": {"file_path": "un...
1
true
[ "CWE-022" ]
[ "py/tarslip" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "This file extraction depends on a [potentially untrusted source](1)." ]
[ 150 ]
[ null ]
[ 5 ]
[ 35 ]
2024-11-19T02:33:29.010697+00:00
1,596,682,947,000
6e8d81c18f2c6a41a90b9c15d3511285736db80a
3
{ "blob_id": "6e8d81c18f2c6a41a90b9c15d3511285736db80a", "branch_name": "refs/heads/master", "committer_date": 1596682947000, "content_id": "1ad1c5c3e09dc135de59e1df7fac20b48b186c9b", "detected_licenses": [ "MIT" ], "directory_id": "23a49d4141c9ab6ea570365db8431a4edff8318c", "extension": "py", "fi...
2.515625
stackv2
#!/usr/bin/env python3 ''' Run this script using python3 because of the urllib script ''' import os import shutil import urllib.request import tarfile MODEL_NAME = 'mobilenetv2_coco_voctrainval' #creating the downlaod link for the model selected _DOWNLOAD_URL_PREFIX = 'http://download.tensorflow.org/models/' # Som...
54
26.56
88
8
430
python
[{"finding_id": "codeql_py/tarslip_59224b116fbf01a8_c596c9fa", "tool_name": "codeql", "rule_id": "py/tarslip", "finding_type": "path-problem", "severity": "medium", "confidence": "medium", "message": "This file extraction depends on a [potentially untrusted source](1).", "remediation": "", "location": {"file_path": "un...
1
true
[ "CWE-022" ]
[ "py/tarslip" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "This file extraction depends on a [potentially untrusted source](1)." ]
[ 50 ]
[ null ]
[ null ]
[ 4 ]
2024-11-19T02:33:38.757497+00:00
1,529,333,158,000
2601c5fd138984dccd773eb9ac66664b4de18ad8
3
{ "blob_id": "2601c5fd138984dccd773eb9ac66664b4de18ad8", "branch_name": "refs/heads/master", "committer_date": 1529333158000, "content_id": "93beca0ea3a97497af33377df4c607916fe257e0", "detected_licenses": [ "Apache-2.0" ], "directory_id": "216582571d3136c0322b39e042c9da00ffe9a4d3", "extension": "py"...
2.515625
stackv2
import requests import re from pyquery import PyQuery as pq se=requests.Session() headers={'User-Agent':'Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/67.0.3396.62 Safari/537.36'} info=se.get('https://nyaa.si/?p=21',verify=False,headers=headers) html=pq(info.text) successTr=html("....
46
34.93
134
16
545
python
[{"finding_id": "codeql_py/request-without-cert-validation_325b8334ee276832_fe4efa04", "tool_name": "codeql", "rule_id": "py/request-without-cert-validation", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "This request may run without certificate validation because [it is disabled]...
1
true
[ "CWE-295" ]
[ "py/request-without-cert-validation" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "This request may run without certificate validation because [it is disabled](1)." ]
[ 7 ]
[ null ]
[ 6 ]
[ 66 ]
2024-11-19T02:46:21.488719+00:00
1,611,402,968,000
a5d5bcc068c691cec15bb5c675aab54730d4428e
3
{ "blob_id": "a5d5bcc068c691cec15bb5c675aab54730d4428e", "branch_name": "refs/heads/main", "committer_date": 1611402968000, "content_id": "af8f8cae3ba6d56e5a20c7e3e97e1bb1cb71a555", "detected_licenses": [ "MIT" ], "directory_id": "479b1e59d99b30c7c9440416a2e95702cef7e3e1", "extension": "py", "file...
2.96875
stackv2
# Importing required packages from pprint import pprint import requests from bs4 import BeautifulSoup # Getting page Content page = requests.get('https://www.carwale.com/mahindra-cars/marazzo/userreviews/', verify=False) contents = page.content # parsing DOM using Soup soup = BeautifulSoup(contents, 'html.parser') # ...
21
38.19
120
16
198
python
[{"finding_id": "codeql_py/request-without-cert-validation_0814d8c2638136f0_c5dbdfad", "tool_name": "codeql", "rule_id": "py/request-without-cert-validation", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "This request may run without certificate validation because [it is disabled]...
1
true
[ "CWE-295" ]
[ "py/request-without-cert-validation" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "This request may run without certificate validation because [it is disabled](1)." ]
[ 8 ]
[ null ]
[ 8 ]
[ 96 ]
2024-11-19T02:59:18.477319+00:00
1,622,575,582,000
8554ee43ce2a5aee95e8d2614289a570b8206342
3
{ "blob_id": "8554ee43ce2a5aee95e8d2614289a570b8206342", "branch_name": "refs/heads/master", "committer_date": 1622575582000, "content_id": "03d1208c8dc95ea66212f4c52b9a42c89a36b14e", "detected_licenses": [ "Apache-2.0" ], "directory_id": "c7c4d18384cfcbdb979e099d503ac88bc1e59d3e", "extension": "py"...
2.546875
stackv2
import os import contextlib import shutil from pathlib import Path from fnmatch import fnmatch import tarfile import gzip import bz2 import io from zipfile import ZipFile import ir_datasets from ir_datasets import util __all__ = ['IterStream', 'Cache', 'TarExtract', 'TarExtractAll', 'RelativePath', 'GzipExtract', 'Zi...
251
31.73
142
23
1,796
python
[{"finding_id": "codeql_py/tarslip_2fbd6a6503ce1b64_142e0358", "tool_name": "codeql", "rule_id": "py/tarslip", "finding_type": "path-problem", "severity": "medium", "confidence": "medium", "message": "This file extraction depends on a [potentially untrusted source](1).", "remediation": "", "location": {"file_path": "un...
2
true
[ "CWE-022", "CWE-022" ]
[ "py/tarslip", "py/tarslip" ]
[ "MEDIUM", "MEDIUM" ]
[ "MEDIUM", "MEDIUM" ]
[ "This file extraction depends on a [potentially untrusted source](1).", "This file extraction depends on a [potentially untrusted source](1)." ]
[ 122, 126 ]
[ null, null ]
[ 25, 46 ]
[ 29, 52 ]
2024-11-19T02:59:18.799790+00:00
1,594,546,682,000
38b12fd6c229bd54702615f36b13e0fa3201144d
2
{ "blob_id": "38b12fd6c229bd54702615f36b13e0fa3201144d", "branch_name": "refs/heads/master", "committer_date": 1594546682000, "content_id": "0450392d2da0c73f1d4d55daa4592506b0ec8a4a", "detected_licenses": [], "directory_id": "8d889b4c36f6ca4a7727120f5dc1ebf5a244e0f3", "extension": "py", "filename": "gen...
2.4375
stackv2
#!/usr/bin/env python3 """This is main runner of generator """ import datetime import logging import re import sys from argparse import ArgumentParser from collections import namedtuple, OrderedDict from inspect import getfile from os.path import basename from pprint import pformat from time import sleep from xml.etre...
442
42.56
120
25
3,768
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_8da215e1a208b0ce_9162f883", "tool_name": "codeql", "rule_id": "py/jinja2/autoescape-false", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Using jinja2 templates with autoescape=False can potentially allow XSS attacks.", "remediati...
1
true
[ "CWE-079" ]
[ "py/jinja2/autoescape-false" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "Using jinja2 templates with autoescape=False can potentially allow XSS attacks." ]
[ 69 ]
[ null ]
[ 25 ]
[ 68 ]
2024-11-19T02:59:19.407537+00:00
1,617,272,022,000
8dea97a28a7f832933c8cfea837c598a834cc5ee
3
{ "blob_id": "8dea97a28a7f832933c8cfea837c598a834cc5ee", "branch_name": "refs/heads/master", "committer_date": 1617272022000, "content_id": "b7dea8527d20bc7699a1b43250d6b5b8e26177cd", "detected_licenses": [ "MIT" ], "directory_id": "1e5905097c1fbc99f9711374bb82ea8360c1c9a5", "extension": "py", "fi...
2.765625
stackv2
#!/usr/bin/env python3 """ Script for converting the main SIMMC datasets (.JSON format) into the line-by-line stringified format (and back). The reformatted data is used as input for the GPT-2 based DST model baseline. """ import json import re import os # DSTC style dataset fieldnames FIELDNAME_DIALO...
204
31.1
91
25
1,507
python
[{"finding_id": "codeql_py/overly-large-range_443c7d27bd9408c7_d5f99b00", "tool_name": "codeql", "rule_id": "py/overly-large-range", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Suspicious character range that overlaps with 0-9 in the same character class, and is equivalent to \\[....
1
true
[ "CWE-020" ]
[ "py/overly-large-range" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "Suspicious character range that overlaps with 0-9 in the same character class, and is equivalent to \\[.\\/0-9:\\]." ]
[ 180 ]
[ null ]
[ 43 ]
[ 46 ]
2024-11-19T02:59:22.527289+00:00
1,468,472,966,000
e820d5842421bc3a60d5159c5a5d9f81bed6964f
3
{ "blob_id": "e820d5842421bc3a60d5159c5a5d9f81bed6964f", "branch_name": "refs/heads/master", "committer_date": 1468472966000, "content_id": "47d6cc804e77784d4b0505fdf7d4580668d472d6", "detected_licenses": [ "MIT" ], "directory_id": "6c6a90661880b97e66d7db15db3e8053b70242cd", "extension": "py", "fi...
2.53125
stackv2
#!/usr/bin/env python3 import argparse import json import os import re from urllib.request import urlopen import urllib def loadf(filename): try: with open(filename,'r') as f: return json.load(f) except: return None def dumpf(obj, filename): try: with open(filename,'w'...
240
34.35
147
19
2,139
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_10630b925a6477b2_b759c6ef", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (private)](1) as clear text.", "...
1
true
[ "CWE-312" ]
[ "py/clear-text-logging-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression logs [sensitive data (private)](1) as clear text." ]
[ 125 ]
[ null ]
[ 19 ]
[ 25 ]
2024-11-19T01:37:33.861734+00:00
1,553,768,714,000
094219126b549145bedf17100f38bc81872001f8
4
{ "blob_id": "094219126b549145bedf17100f38bc81872001f8", "branch_name": "refs/heads/master", "committer_date": 1553768714000, "content_id": "4f712cc87964b0233285468156eab18c0f9bfacb", "detected_licenses": [ "Apache-2.0" ], "directory_id": "a4ac7d37dcbe6a8b9bb3c81a79bcf329c034097b", "extension": "py"...
3.75
stackv2
#!/usr/bin/python # -*- coding: utf-8 -*- # 作者: itdeer # 时间: 2019/3/23 # 输入资产 flag = True while flag: salary = input("请输入您当前的工资:") if salary.isdigit(): salary = int(salary) flag = False else: print("您输入的工资格式不对,重新输入...") print("您当前的资产是: %d %s" % salary, "元") # 商品列表 products = [('...
49
23.02
98
16
380
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_d08847e9dc3be551_6a990bcb", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (private)](1) as clear text.\nTh...
3
true
[ "CWE-312", "CWE-312", "CWE-312" ]
[ "py/clear-text-logging-sensitive-data", "py/clear-text-logging-sensitive-data", "py/clear-text-logging-sensitive-data" ]
[ "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "This expression logs [sensitive data (private)](1) as clear text.\nThis expression logs [sensitive data (private)](2) as clear text.", "This expression logs [sensitive data (private)](1) as clear text.\nThis expression logs [sensitive data (private)](2) as clear text.\nThis expression logs [sensitive data (priva...
[ 18, 39, 46 ]
[ null, null, null ]
[ 7, 23, 15 ]
[ 32, 48, 34 ]
2024-11-19T01:37:34.051616+00:00
1,631,739,014,000
4cf247b6fa14cb3236033615e3e6e61f8c69f972
3
{ "blob_id": "4cf247b6fa14cb3236033615e3e6e61f8c69f972", "branch_name": "refs/heads/master", "committer_date": 1631739014000, "content_id": "c72d29599582d0fce6422d5aeba25e108b9a35a0", "detected_licenses": [ "Apache-2.0" ], "directory_id": "e62c28c5bdf35958e3e7c2b9bdc08e7223ac7d44", "extension": "py"...
2.578125
stackv2
from flask import Flask, escape, request, redirect, render_template, flash, url_for, send_from_directory from werkzeug.utils import secure_filename import os import shutil import ntpath from zipfile import ZipFile import sys from converter import gtlf2glb_call, obj2glb_call, fbx2glb_call from pathlib import Path UPLO...
235
42.53
165
22
2,319
python
[{"finding_id": "codeql_py/flask-debug_3b9177770305d0f5_695c7a32", "tool_name": "codeql", "rule_id": "py/flask-debug", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", ...
6
true
[ "CWE-215", "CWE-022", "CWE-022", "CWE-022", "CWE-022", "CWE-022" ]
[ "py/flask-debug", "py/path-injection", "py/path-injection", "py/path-injection", "py/path-injection", "py/path-injection" ]
[ "HIGH", "HIGH", "HIGH", "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", "This path depends on a [user-provided value](1).", "This path depends on a [user-provided value](1).", "This path depends on a [user-provided value](1).", "This path depends on a [user-pro...
[ 234, 85, 86, 87, 91, 217 ]
[ null, null, null, null, null, null ]
[ 5, 27, 27, 21, 25, 27 ]
[ 51, 31, 31, 25, 35, 31 ]
2024-11-19T01:37:35.925245+00:00
1,524,331,343,000
4e61cadbe8a9fa492fd474c5fa143d73cd7488b7
3
{ "blob_id": "4e61cadbe8a9fa492fd474c5fa143d73cd7488b7", "branch_name": "refs/heads/master", "committer_date": 1524331343000, "content_id": "269d966fed24365dac82c5c0a1095156234c408b", "detected_licenses": [ "MIT" ], "directory_id": "0691b9de1e1075a80c35c692bf524e02b5f77b2e", "extension": "py", "fi...
2.5625
stackv2
import argparse import time import datetime as dt from datetime import datetime from dateutil.tz import gettz from dateutil.parser import parse import calendar import requests import json import hashlib from tqdm import tqdm import mmap def get_num_lines(file_path): fp = open(file_path, "r+") buf = mmap.mmap(...
100
29.73
88
14
777
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_2e108f400bd1e02c_ae85bdb8", "tool_name": "codeql", "rule_id": "py/weak-sensitive-data-hashing", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "[Sensitive data (secret)](1) is used in a hashing algorithm (SHA1) that is insecu...
1
true
[ "CWE-327" ]
[ "py/weak-sensitive-data-hashing" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "[Sensitive data (secret)](1) is used in a hashing algorithm (SHA1) that is insecure." ]
[ 45 ]
[ null ]
[ 30 ]
[ 61 ]
2024-11-19T01:38:03.315704+00:00
1,674,036,633,000
b5ad5b46e8596c4b2b1ffa58a2ffd3b884febebb
3
{ "blob_id": "b5ad5b46e8596c4b2b1ffa58a2ffd3b884febebb", "branch_name": "refs/heads/master", "committer_date": 1674036633000, "content_id": "2fb4d34bfd0fa8b1213fd4f898d836b277a1ca25", "detected_licenses": [ "MIT" ], "directory_id": "33be4b8a076a83adb73ff6b267d8135dbbdd16fc", "extension": "py", "fi...
3.046875
stackv2
import paramiko import socket import time def brute_force_ssh(hostname,port,user,password): log = paramiko.util.log_to_file('log.log') ssh_client = paramiko.SSHClient() ssh_client.load_system_host_keys() ssh_client.set_missing_host_key_policy(paramiko.AutoAddPolicy()) try: print('Testing cr...
35
31.69
89
13
238
python
[{"finding_id": "codeql_py/paramiko-missing-host-key-validation_58b43af4105a6bbb_c38bfdf4", "tool_name": "codeql", "rule_id": "py/paramiko-missing-host-key-validation", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Setting missing host key policy to AutoAddPolicy may be unsafe.", "r...
3
true
[ "CWE-295", "CWE-312", "CWE-312" ]
[ "py/paramiko-missing-host-key-validation", "py/clear-text-logging-sensitive-data", "py/clear-text-logging-sensitive-data" ]
[ "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "Setting missing host key policy to AutoAddPolicy may be unsafe.", "This expression logs [sensitive data (password)](1) as clear text.\nThis expression logs [sensitive data (password)](2) as clear text.\nThis expression logs [sensitive data (password)](3) as clear text.\nThis expression logs [sensitive data (pass...
[ 9, 11, 13 ]
[ null, null, null ]
[ 5, 15, 15 ]
[ 69, 64, 59 ]
2024-11-19T01:38:19.701666+00:00
1,535,748,134,000
adfa9168d64856ed0b311f76517b829e7080efcf
3
{ "blob_id": "adfa9168d64856ed0b311f76517b829e7080efcf", "branch_name": "refs/heads/master", "committer_date": 1535748134000, "content_id": "cfc2fc9753a9405415f14de20c54a543a2e0802f", "detected_licenses": [ "MIT" ], "directory_id": "14ef4570accc7f755ff88fed19523947d45c37ae", "extension": "py", "fi...
2.921875
stackv2
import os import csv import codecs import logging import pandas __author__ = 'robodasha' __email__ = 'damirah@live.com' class DataParser(object): # mapping of columns in the responses.csv file _MAPPING = { 'response': { 0: 'timestamp', 1: 'research_area', 2: 'research_area_details', ...
151
35.74
80
19
1,301
python
[{"finding_id": "codeql_py/incomplete-url-substring-sanitization_074866bdb9574c5b_593b6b16", "tool_name": "codeql", "rule_id": "py/incomplete-url-substring-sanitization", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "The string [dx.doi.org/](1) may be at an arbitrary position in the...
1
true
[ "CWE-020" ]
[ "py/incomplete-url-substring-sanitization" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "The string [dx.doi.org/](1) may be at an arbitrary position in the sanitized URL." ]
[ 126 ]
[ null ]
[ 20 ]
[ 66 ]
2024-11-19T01:38:38.040889+00:00
1,675,346,812,000
694dc1cbbe75a4b767a5e8d0df1e364178ae5e34
3
{ "blob_id": "694dc1cbbe75a4b767a5e8d0df1e364178ae5e34", "branch_name": "refs/heads/master", "committer_date": 1675346812000, "content_id": "5d364b172b8531ed351be991b8d7337cb35751d9", "detected_licenses": [ "MIT" ], "directory_id": "878b68ca4f7490ec98c6b0053f8c07d65c8acc14", "extension": "py", "fi...
2.65625
stackv2
#! /usr/bin/env python3 from flask import Flask from flask import request from flask import jsonify from flask_cors import CORS from connect4 import Connect4 import requests app = Flask(__name__) CORS(app) @app.route("/game", methods=['GET']) def run_game(): player1_url = request.args.get('player1_url') pl...
73
28.05
115
16
549
python
[{"finding_id": "codeql_py/flask-debug_ac63d74eed0d37fa_36ebc5e3", "tool_name": "codeql", "rule_id": "py/flask-debug", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", ...
3
true
[ "CWE-215", "CWE-918", "CWE-918" ]
[ "py/flask-debug", "py/full-ssrf", "py/full-ssrf" ]
[ "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", "The full URL of this request depends on a [user-provided value](1).", "The full URL of this request depends on a [user-provided value](1)." ]
[ 67, 25, 43 ]
[ null, 31, 49 ]
[ null, 23, 23 ]
[ 47, 19, 19 ]
2024-11-19T01:38:40.769351+00:00
1,570,498,990,000
72dd2a14b954b172f37ada80c4f1712231f67926
3
{ "blob_id": "72dd2a14b954b172f37ada80c4f1712231f67926", "branch_name": "refs/heads/master", "committer_date": 1570498990000, "content_id": "b356b1928b8d239952630245a29bdcd5a9e08418", "detected_licenses": [ "MIT" ], "directory_id": "0650c15a9af6458dde1bebc83a522ac94632335b", "extension": "py", "fi...
2.53125
stackv2
import sys import os import hashlib import tempfile import difflib import re import glob """ This file contains a simple program to store a list of static webpages, and ot fetch them to check for differences since the first save. It uses a linux style .pagewatch directionr in the users home dir in order to save the l...
227
28.84
107
19
1,920
python
[{"finding_id": "codeql_py/bad-tag-filter_748cf3b1a4be1437_b84cb10d", "tool_name": "codeql", "rule_id": "py/bad-tag-filter", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "This regular expression does not match upper case <SCRIPT> tags.", "remediation": "", "location": {"file_path": ...
1
true
[ "CWE-116" ]
[ "py/bad-tag-filter" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This regular expression does not match upper case <SCRIPT> tags." ]
[ 63 ]
[ null ]
[ 25 ]
[ 43 ]
2024-11-19T01:39:05.742877+00:00
1,553,794,286,000
6c5f40cf09400085a5653ef26874f3afc7d5d024
3
{ "blob_id": "6c5f40cf09400085a5653ef26874f3afc7d5d024", "branch_name": "refs/heads/master", "committer_date": 1553794286000, "content_id": "4ee14a70fe4b45415f7ed4c7a407a411622477d6", "detected_licenses": [ "MIT" ], "directory_id": "883f91664c585363c2704bb147d99cb34f51abca", "extension": "py", "fi...
2.75
stackv2
import sys import traceback from IPython import display from IPython.core.magic import register_cell_magic, Magics, magics_class, cell_magic, line_cell_magic, line_magic import jinja2 import yaml import argparse import re from typing import Optional, Dict def identity(v): return v # PyYAML deprecates the load() ...
260
36.15
116
18
2,200
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_6f2b4c7459220d46_dc33de69", "tool_name": "codeql", "rule_id": "py/jinja2/autoescape-false", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Using jinja2 templates with autoescape=False can potentially allow XSS attacks.", "remediati...
1
true
[ "CWE-079" ]
[ "py/jinja2/autoescape-false" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "Using jinja2 templates with autoescape=False can potentially allow XSS attacks." ]
[ 80 ]
[ null ]
[ 13 ]
[ 34 ]
2024-11-19T01:51:56.809787+00:00
1,689,287,924,000
bdea688c6a167aeea7a2f7fc2fcdc36f4b7cbacd
3
{ "blob_id": "bdea688c6a167aeea7a2f7fc2fcdc36f4b7cbacd", "branch_name": "refs/heads/master", "committer_date": 1689287924000, "content_id": "454c4b696b2255fe9bc41b22573717e9be6a2e2d", "detected_licenses": [ "BSD-3-Clause" ], "directory_id": "6186a3787d1e74f1866844491da48b9643c8f1a9", "extension": "p...
2.6875
stackv2
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # Standard Libraries import json import random import socket import string import struct import sys from time import sleep try: import requests # noqa isort:skip except ImportError: print("[!] Need the `requests` library installed\n\n" "\tpython install -U reque...
180
29.89
122
15
1,534
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_8817441e4002b03a_2621ef6e", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (password)](1) as clear text.", ...
1
true
[ "CWE-312" ]
[ "py/clear-text-logging-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression logs [sensitive data (password)](1) as clear text." ]
[ 57 ]
[ null ]
[ 11 ]
[ 92 ]
2024-11-19T01:52:01.788290+00:00
1,503,296,476,000
0dca2d06344d4115433a8a60f862e08e8f64bf8c
3
{ "blob_id": "0dca2d06344d4115433a8a60f862e08e8f64bf8c", "branch_name": "refs/heads/master", "committer_date": 1503296476000, "content_id": "c989aac677c5503a247b9a9fb68e7f7d677324c7", "detected_licenses": [ "MIT" ], "directory_id": "cb9dcc12ec28c8ab1fa3fcf133b451cb332a7bee", "extension": "py", "fi...
2.6875
stackv2
"""Class for dropbeat app api custom extensions """ from django.conf import settings from django.conf.urls import url, include from django.core.exceptions import ImproperlyConfigured from django.core.urlresolvers import reverse from django.http import HttpResponse, HttpResponseBadRequest class ApiError(Exception): ...
100
30.25
79
22
639
python
[{"finding_id": "codeql_py/stack-trace-exposure_3c7f8ac76a93ee61_86b828f7", "tool_name": "codeql", "rule_id": "py/stack-trace-exposure", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "[Stack trace information](1) flows to this location and may be exposed to an external user.", "...
1
true
[ "CWE-209" ]
[ "py/stack-trace-exposure" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "[Stack trace information](1) flows to this location and may be exposed to an external user." ]
[ 53 ]
[ null ]
[ 47 ]
[ 48 ]
2024-11-19T01:52:18.069696+00:00
1,448,291,688,000
13ddb4c11f2df74a7056f54a337430f64a011178
3
{ "blob_id": "13ddb4c11f2df74a7056f54a337430f64a011178", "branch_name": "refs/heads/master", "committer_date": 1448291688000, "content_id": "1192d6f67bedb62996e759be419a8686db748a94", "detected_licenses": [ "MIT" ], "directory_id": "91ca20f8ad23abd62387f1e3a8756d4da59a98b1", "extension": "py", "fi...
2.671875
stackv2
#!/usr/bin/env python # coding: utf-8 import json import struct import socket import ssl import binascii import config import click deviceToken = config.device_token pushServer = "gateway.sandbox.push.apple.com" port = 2195 keyfile = config.certificates_dir + "/key.pem" certfile = config.certificates_dir + "/pushcert....
54
25.57
81
13
346
python
[{"finding_id": "codeql_py/insecure-default-protocol_b55ac82645f4a5f0_228ddcb2", "tool_name": "codeql", "rule_id": "py/insecure-default-protocol", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Call to deprecated method ssl.wrap_socket does not specify a protocol, which may result in...
1
true
[ "CWE-327" ]
[ "py/insecure-default-protocol" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "Call to deprecated method ssl.wrap_socket does not specify a protocol, which may result in an insecure default being used." ]
[ 31 ]
[ null ]
[ 20 ]
[ 57 ]
2024-11-19T02:04:18.956132+00:00
1,692,956,685,000
1babcb50dd1c6e975fc41dc5472efe7ffbae17ba
3
{ "blob_id": "1babcb50dd1c6e975fc41dc5472efe7ffbae17ba", "branch_name": "refs/heads/master", "committer_date": 1692956685000, "content_id": "8fae798a738984529b868bce3d8702f02d474b5d", "detected_licenses": [ "MIT" ], "directory_id": "1d2200e75f7353a1226a8f9fbce301ce6f2b7e4a", "extension": "py", "fi...
2.5625
stackv2
# Script Author: Valdir Junior # Author E-mail: valdirjunior011@hotmail.comimport csv import csv import re import requests from bs4 import BeautifulSoup import time import requests import urllib3 urllib3.disable_warnings(urllib3.exceptions.InsecureRequestWarning) requests.packages.urllib3.disable_warnings() filename ...
50
29.3
145
14
383
python
[{"finding_id": "codeql_py/request-without-cert-validation_53e0223a741eb28f_de0e92ef", "tool_name": "codeql", "rule_id": "py/request-without-cert-validation", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "This request may run without certificate validation because [it is disabled]...
2
true
[ "CWE-295", "CWE-295" ]
[ "py/request-without-cert-validation", "py/request-without-cert-validation" ]
[ "MEDIUM", "MEDIUM" ]
[ "MEDIUM", "MEDIUM" ]
[ "This request may run without certificate validation because [it is disabled](1).", "This request may run without certificate validation because [it is disabled](1)." ]
[ 28, 40 ]
[ null, null ]
[ 12, 15 ]
[ 146, 52 ]
2024-11-19T02:28:09.586649+00:00
1,590,286,587,000
77df2414671385d161add3d6c1924d0ce38db4db
2
{ "blob_id": "77df2414671385d161add3d6c1924d0ce38db4db", "branch_name": "refs/heads/master", "committer_date": 1590286587000, "content_id": "994601c8ee7a5fb83f97ef37a3f2cba32970ebb8", "detected_licenses": [ "MIT" ], "directory_id": "f74c992107671bc047b19df39541c8901f7abd2d", "extension": "py", "fi...
2.3125
stackv2
import json import logging import os from collections import OrderedDict from flask import Flask, redirect, request from flask_restplus import Resource, Api, fields from flask_cors import CORS from pymongo import UpdateOne from db.config import configure_mongo, MONGO_DB app = Flask(__name__) api = Api(app) cors = CORS...
156
29.68
105
18
1,376
python
[{"finding_id": "codeql_py/log-injection_d1c9bfc57a4b44b8_e4535b8b", "tool_name": "codeql", "rule_id": "py/log-injection", "finding_type": "path-problem", "severity": "medium", "confidence": "medium", "message": "This log entry depends on a [user-provided value](1).", "remediation": "", "location": {"file_path": "unkno...
3
true
[ "CWE-117", "CWE-117", "CWE-117" ]
[ "py/log-injection", "py/log-injection", "py/log-injection" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "This log entry depends on a [user-provided value](1).", "This log entry depends on a [user-provided value](1).", "This log entry depends on a [user-provided value](1)." ]
[ 86, 87, 88 ]
[ null, null, null ]
[ 21, 21, 21 ]
[ 24, 27, 26 ]
2024-11-19T02:28:16.090807+00:00
1,526,464,188,000
4bf47ad883360e405fba7ec8575010bbaac5afa0
2
{ "blob_id": "4bf47ad883360e405fba7ec8575010bbaac5afa0", "branch_name": "refs/heads/master", "committer_date": 1526464188000, "content_id": "4a0c926ac25daae7edd42b8fc79d9161cc87a7a1", "detected_licenses": [ "MIT" ], "directory_id": "29bc0157a06748a312871bb538d7ba3c9dbfed0a", "extension": "py", "fi...
2.390625
stackv2
#!/usr/bin/env python3 from jinja2 import Template, Environment, BaseLoader, FileSystemLoader import json import datetime import os template_file = None content_file = None content = None INFO_FILEPATH = "info.json" COVER_BLOCKS_DIR = "cover-letter" TEMPLATE_CV_PREVIEW = "templates/cv-preview...
128
28.17
73
18
924
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_dc6db7c8ceb37902_14a0db7e", "tool_name": "codeql", "rule_id": "py/jinja2/autoescape-false", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Using jinja2 templates with autoescape=False can potentially allow XSS attacks.", "remediati...
1
true
[ "CWE-079" ]
[ "py/jinja2/autoescape-false" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "Using jinja2 templates with autoescape=False can potentially allow XSS attacks." ]
[ 90 ]
[ null ]
[ 11 ]
[ 60 ]
2024-11-19T02:28:45.826699+00:00
1,620,620,520,000
eaa65f977554e3906ce6d9d3b85c960dfa541f01
3
{ "blob_id": "eaa65f977554e3906ce6d9d3b85c960dfa541f01", "branch_name": "refs/heads/main", "committer_date": 1620620520000, "content_id": "9df664988265fcbf534a32c205e088d0f41af324", "detected_licenses": [ "Apache-2.0" ], "directory_id": "e5d636ed2d6334c2a0a24482d0c0969d4eda07ca", "extension": "py", ...
3.1875
stackv2
import sys import logging import re from argparse import ArgumentParser from typing import Dict, List from util.calculate_payment import CalculatePayment def get_argument_parser() -> ArgumentParser: """Params definition""" parser = ArgumentParser() parser.add_argument( "--input_file_name", help=...
69
31.64
86
16
463
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_d6deb637e971c81e_700252a2", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (private)](1) as clear text.\nTh...
1
true
[ "CWE-312" ]
[ "py/clear-text-logging-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression logs [sensitive data (private)](1) as clear text.\nThis expression logs [sensitive data (private)](2) as clear text." ]
[ 58 ]
[ null ]
[ 23 ]
[ 82 ]
2024-11-19T02:36:55.275299+00:00
1,547,205,504,000
214d76f7cd547a7c418a97086fac50bb2877e778
2
{ "blob_id": "214d76f7cd547a7c418a97086fac50bb2877e778", "branch_name": "refs/heads/master", "committer_date": 1547205504000, "content_id": "428633b2c8a71ab91d31e2b64787d1664c49e13e", "detected_licenses": [ "MIT" ], "directory_id": "778b88a58b6930a67aaa64ba222bcf71ce5d5335", "extension": "py", "fi...
2.34375
stackv2
import flask import requests from jinja2 import Template from flask import request, send_from_directory from flask_caching import Cache import mirador_settings from flask_cors import CORS import sys import logging def cache_key(): return request.url app = flask.Flask(__name__, static_folder="build") CORS(app) c...
77
33.47
99
25
542
python
[{"finding_id": "codeql_py/flask-debug_48a1b44ede5119cb_c42b88c0", "tool_name": "codeql", "rule_id": "py/flask-debug", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", ...
3
true
[ "CWE-215", "CWE-918", "CWE-079" ]
[ "py/flask-debug", "py/full-ssrf", "py/jinja2/autoescape-false" ]
[ "HIGH", "HIGH", "MEDIUM" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", "The full URL of this request depends on a [user-provided value](1).", "Using jinja2 templates with autoescape=False can potentially allow XSS attacks." ]
[ 77, 44, 38 ]
[ null, null, null ]
[ 5, 21, 13 ]
[ 66, 43, 39 ]
2024-11-19T02:37:17.054351+00:00
1,603,740,682,000
a6bc2ef85372b32b2f85a5393a9a2cae07148846
4
{ "blob_id": "a6bc2ef85372b32b2f85a5393a9a2cae07148846", "branch_name": "refs/heads/master", "committer_date": 1603740682000, "content_id": "1195b40c8164f2c866a3e39cf9bc32b453d7b70c", "detected_licenses": [ "MIT" ], "directory_id": "7a20dac7b15879b9453150b1a1026e8760bcd817", "extension": "py", "fi...
3.75
stackv2
salary = float(input()) tax = answer = base = 0 if salary < 2000: print("Isento") else: if salary <= 3000: salary -= 2000 salary = salary * 8 / 100 elif salary <= 4500: salary -= 2000 base = salary - 1000 base = base * 18 / 100 base2 = 1000 * 8 / 100 s...
22
25.32
37
12
237
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_760f79bde4cbc2b5_4c7ebe7a", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (private)](1) as clear text.\nTh...
1
true
[ "CWE-312" ]
[ "py/clear-text-logging-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression logs [sensitive data (private)](1) as clear text.\nThis expression logs [sensitive data (private)](2) as clear text.\nThis expression logs [sensitive data (private)](3) as clear text." ]
[ 22 ]
[ null ]
[ 11 ]
[ 29 ]
2024-11-19T02:37:31.386397+00:00
1,593,600,280,000
05399a1175d39ab6dced4403af7a084970ada803
3
{ "blob_id": "05399a1175d39ab6dced4403af7a084970ada803", "branch_name": "refs/heads/master", "committer_date": 1593600280000, "content_id": "8f60bc6b4774a3f78cd60474a678f333df241cec", "detected_licenses": [ "MIT" ], "directory_id": "705c4a062a3404e9acaea3c9fa1eaa3c91f368ec", "extension": "py", "fi...
2.765625
stackv2
# This is the file that implements a flask server to do inferences. import os import json import flask import pandas as pd from io import StringIO, BytesIO import mindsdb # Define the path prefix = '/opt/ml/' model_path = os.path.join(prefix, 'model') def parse_data(content_type, data): ''' Get the request c...
78
30.42
89
13
550
python
[{"finding_id": "codeql_py/stack-trace-exposure_ef8cb048b5fa173d_596dd081", "tool_name": "codeql", "rule_id": "py/stack-trace-exposure", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "[Stack trace information](1) flows to this location and may be exposed to an external user.", "...
1
true
[ "CWE-209" ]
[ "py/stack-trace-exposure" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "[Stack trace information](1) flows to this location and may be exposed to an external user." ]
[ 50 ]
[ null ]
[ 36 ]
[ 44 ]
2024-11-19T02:37:49.801562+00:00
1,601,026,981,000
724db34d39ec93f98b7ebf7556186dc5f350fc17
2
{ "blob_id": "724db34d39ec93f98b7ebf7556186dc5f350fc17", "branch_name": "refs/heads/master", "committer_date": 1601026981000, "content_id": "62d1c5804ca0b5642864f56774bdd9ed483ba355", "detected_licenses": [ "MIT" ], "directory_id": "ea1d6ed8bdf4e74d9b9ea833cb5b4ed7b9c3b59b", "extension": "py", "fi...
2.5
stackv2
import requests from requests.auth import HTTPBasicAuth import sys import json import urllib3 urllib3.disable_warnings() import time # Global static parameters DNAC = "sandboxdnac.cisco.com" # DNAC address DNAC_USER = "devnetuser" # DNAC username DNAC_PASSWORD = "Cisco123!" # DNAC passowrd DNAC_PORT = 443 # DNAC RE...
125
32.38
112
15
1,018
python
[{"finding_id": "codeql_py/request-without-cert-validation_48bdef4a0c3ed7c8_7c15830d", "tool_name": "codeql", "rule_id": "py/request-without-cert-validation", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "This request may run without certificate validation because [it is disabled]...
3
true
[ "CWE-295", "CWE-295", "CWE-295" ]
[ "py/request-without-cert-validation", "py/request-without-cert-validation", "py/request-without-cert-validation" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "This request may run without certificate validation because [it is disabled](1).", "This request may run without certificate validation because [it is disabled](1).", "This request may run without certificate validation because [it is disabled](1)." ]
[ 26, 45, 70 ]
[ null, null, null ]
[ 14, 20, 16 ]
[ 102, 68, 94 ]
2024-11-19T02:49:15.459510+00:00
1,442,500,691,000
783c39f2e1cbe69502c2c393ebf75632429e669d
3
{ "blob_id": "783c39f2e1cbe69502c2c393ebf75632429e669d", "branch_name": "refs/heads/master", "committer_date": 1442500691000, "content_id": "41599b6569b61791ad84e7c331599a64682414da", "detected_licenses": [ "Apache-2.0" ], "directory_id": "eaecda69fec7b1c1d0c2e828bc9059e91b25857b", "extension": "py"...
2.859375
stackv2
import tornado.ioloop import tornado.web class MainHandler(tornado.web.RequestHandler): def get(self): #self.write("Hello, world") items = ["Item 1", "Item 2", "Item 3"] self.render("temp.html", title="My title", items=items) class LoginHandler(tornado.web.RequestHandler): file_name = ...
34
26.47
69
12
236
python
[{"finding_id": "codeql_py/reflective-xss_36d43288607281b3_b895bcf5", "tool_name": "codeql", "rule_id": "py/reflective-xss", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "Cross-site scripting vulnerability due to a [user-provided value](1).", "remediation": "", "location": {"fi...
1
true
[ "CWE-079" ]
[ "py/reflective-xss" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "Cross-site scripting vulnerability due to a [user-provided value](1)." ]
[ 20 ]
[ null ]
[ 20 ]
[ 69 ]
2024-11-19T02:49:25.006736+00:00
1,544,416,777,000
9f798a4e6f10f260063587c73b457944e24053eb
3
{ "blob_id": "9f798a4e6f10f260063587c73b457944e24053eb", "branch_name": "refs/heads/master", "committer_date": 1544416777000, "content_id": "69b320b58628a795f57f7920bc0344d78532aff0", "detected_licenses": [ "MIT" ], "directory_id": "22553f10dbdcb1348ffb973e4ffdcf9f8d22a25e", "extension": "py", "fi...
2.734375
stackv2
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ translator ~~~~~~~~~~ A translator for command line based on api.fanyi.baidu.com. It't simple and convenient. :copyright: (c) 2017 by Jason Wang. :license: MIT, see LICENSE for more details. """ import argparse import hashlib import random imp...
143
31.01
80
19
1,085
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_d9d9d42a5d1b1306_8586ad15", "tool_name": "codeql", "rule_id": "py/weak-sensitive-data-hashing", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "[Sensitive data (secret)](1) is used in a hashing algorithm (MD5) that is insecur...
1
true
[ "CWE-327" ]
[ "py/weak-sensitive-data-hashing" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "[Sensitive data (secret)](1) is used in a hashing algorithm (MD5) that is insecure." ]
[ 36 ]
[ null ]
[ 20 ]
[ 24 ]
2024-11-19T03:00:12.357295+00:00
1,599,335,696,000
3e576acaf4d75dd7088238476dabb5cf7542b299
3
{ "blob_id": "3e576acaf4d75dd7088238476dabb5cf7542b299", "branch_name": "refs/heads/master", "committer_date": 1599335696000, "content_id": "d79062714c099ae23e63a2361b70c2eb245d9426", "detected_licenses": [ "MIT" ], "directory_id": "0e718235911dee9d993e46bf3687e43675b37346", "extension": "py", "fi...
3.0625
stackv2
"""Module containing persistence functions used to connect to postgres server""" import logging import uuid import hashlib from datetime import timedelta, datetime from contextlib import contextmanager import psycopg2 import psycopg2.extras from config import POSTGRES_HOST, POSTGRES_PORT, POSTGRES_DB, POSTGRES_USER...
92
35.11
139
15
717
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_8881397720201e1c_dea40c56", "tool_name": "codeql", "rule_id": "py/weak-sensitive-data-hashing", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "[Sensitive data (password)](1) is used in a hashing algorithm (SHA256) that is in...
1
true
[ "CWE-327" ]
[ "py/weak-sensitive-data-hashing" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "[Sensitive data (password)](1) is used in a hashing algorithm (SHA256) that is insecure for password hashing, since it is not a computationally expensive hash function.\n[Sensitive data (password)](2) is used in a hashing algorithm (SHA256) that is insecure for password hashing, since it is not a computationally e...
[ 56 ]
[ null ]
[ 27 ]
[ 60 ]
2024-11-19T03:00:27.563016+00:00
1,634,175,878,000
c7b111a2be305ee03a3027f5d4ffc8bf6a2eac10
3
{ "blob_id": "c7b111a2be305ee03a3027f5d4ffc8bf6a2eac10", "branch_name": "refs/heads/master", "committer_date": 1634175878000, "content_id": "5e4066845ed321519638c7f011df648fa7b513a3", "detected_licenses": [ "MIT" ], "directory_id": "2609447f0dc04b110fa963932b23f7ce3ba92170", "extension": "py", "fi...
2.75
stackv2
""" Requirements: > pip install -r requirements.txt Usage: hathi [-h] [--usernames USERNAMES] [--passwords PASSWORDS] [--results RESULTS] [--hostname HOSTNAME] [--verbose] host [host ...] Port scan and dictionary attack postgresql servers. positional arguments: host host to connect to optional ...
257
28.86
135
17
1,709
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_e01f64f13b52ce80_8efc1504", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (password)](1) as clear text.", ...
1
true
[ "CWE-312" ]
[ "py/clear-text-logging-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression logs [sensitive data (password)](1) as clear text." ]
[ 221 ]
[ 232 ]
[ 13 ]
[ 14 ]
2024-11-19T03:00:30.327297+00:00
1,615,500,633,000
095546090a680e509899325534c635adf4b5434b
3
{ "blob_id": "095546090a680e509899325534c635adf4b5434b", "branch_name": "refs/heads/main", "committer_date": 1615500633000, "content_id": "40e9c518170f519e7badb260b631c8acc7d130db", "detected_licenses": [ "BSD-3-Clause" ], "directory_id": "3307f89c42581a974e7a6463f051435af11d8d9b", "extension": "py"...
2.71875
stackv2
from grafana_reporter.panel import Panel from collections import deque from collections import OrderedDict import jinja2 from multiprocessing import Pool from functools import partial import shutil class Dashboard: def __init__(self, uid, connector): """ Initializes a dashboard object, which foll...
129
47.82
128
18
1,354
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_bbd3c5187060e42d_8ef5e3be", "tool_name": "codeql", "rule_id": "py/jinja2/autoescape-false", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Using jinja2 templates with autoescape=False can potentially allow XSS attacks.", "remediati...
1
true
[ "CWE-079" ]
[ "py/jinja2/autoescape-false" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "Using jinja2 templates with autoescape=False can potentially allow XSS attacks." ]
[ 69 ]
[ null ]
[ 24 ]
[ 66 ]
2024-11-19T03:11:38.213231+00:00
1,529,496,958,000
02ace67afd702cbe2d12f62f993365ef7e685976
2
{ "blob_id": "02ace67afd702cbe2d12f62f993365ef7e685976", "branch_name": "refs/heads/master", "committer_date": 1529496958000, "content_id": "2ad3cc59e8c1983f316d5c4602bb2b57174a1827", "detected_licenses": [ "MIT" ], "directory_id": "e52b65a76a9c7042de08e0e1b154d4f270d3f1ab", "extension": "py", "fi...
2.390625
stackv2
import os import sys import json import time from datetime import datetime import requests from flask import Flask, request from celery import Celery from celery.schedules import crontab app = Flask(__name__) # Celery configuration app.config['CELERY_BROKER_URL'] = os.environ['REDIS_URL'] # Initialize Celery celer...
192
34.93
132
24
1,587
python
[{"finding_id": "codeql_py/flask-debug_cdd587f1a3b8868f_387ef531", "tool_name": "codeql", "rule_id": "py/flask-debug", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", ...
2
true
[ "CWE-215", "CWE-079" ]
[ "py/flask-debug", "py/reflective-xss" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", "Cross-site scripting vulnerability due to a [user-provided value](1)." ]
[ 192, 50 ]
[ null, null ]
[ 5, 16 ]
[ 24, 50 ]
2024-11-19T03:11:50.682687+00:00
1,615,166,988,000
e1e87f2fef90bb597d48bc2a218e14c8fef6a5c9
3
{ "blob_id": "e1e87f2fef90bb597d48bc2a218e14c8fef6a5c9", "branch_name": "refs/heads/master", "committer_date": 1615166988000, "content_id": "8bd0460a4b17959badee55ec8952d76113603236", "detected_licenses": [ "MIT" ], "directory_id": "f5758bd67d18f30e7e6eea7d0342f9ad04acaecf", "extension": "py", "fi...
2.59375
stackv2
import pathlib from typing import Dict from jinja2 import Environment, FileSystemLoader, Template class Jinja2Renderer: themes_dir = pathlib.Path(__file__).parent / "themes" def __init__(self, theme: str, encoding: str = "utf8", ext: str = "j2"): self.env = Environment( loader=FileSyste...
28
32.04
76
21
215
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_7153231c9b49f2a8_20d968c4", "tool_name": "codeql", "rule_id": "py/jinja2/autoescape-false", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Using jinja2 templates with autoescape=False can potentially allow XSS attacks.", "remediati...
1
true
[ "CWE-079" ]
[ "py/jinja2/autoescape-false" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "Using jinja2 templates with autoescape=False can potentially allow XSS attacks." ]
[ 12 ]
[ 17 ]
[ 20 ]
[ 10 ]
2024-11-19T03:12:14.597118+00:00
1,626,881,916,000
7a02a98208f20b3ea04f03babf1689cdfc71a4a0
3
{ "blob_id": "7a02a98208f20b3ea04f03babf1689cdfc71a4a0", "branch_name": "refs/heads/master", "committer_date": 1626881916000, "content_id": "d179bc889d955939488f9e41eca783c253b677f8", "detected_licenses": [ "BSD-3-Clause" ], "directory_id": "e924380991d117a176f5ab7f9b68c606eef3acc2", "extension": "p...
3.40625
stackv2
""" Comparing encoders of a dirty categorical columns ================================================== The column *Employee Position Title* of the dataset `employee salaries <https://catalog.data.gov/dataset/employee-salaries-2016>`_ contains dirty categorical data. Here, we compare different categorical encodings ...
150
36.57
113
14
1,084
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_d1739f230cf36b2b_83b1d9bc", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (private)](1) as clear text.", "...
1
true
[ "CWE-312" ]
[ "py/clear-text-logging-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression logs [sensitive data (private)](1) as clear text." ]
[ 20 ]
[ null ]
[ 7 ]
[ 33 ]
2024-11-19T03:12:15.560793+00:00
1,591,936,906,000
153de98a8ecc8bec14b7cab984a80418477e6753
2
{ "blob_id": "153de98a8ecc8bec14b7cab984a80418477e6753", "branch_name": "refs/heads/master", "committer_date": 1591936906000, "content_id": "8f17333e1d6962126b1642ba0c68e875d3d70319", "detected_licenses": [ "MIT" ], "directory_id": "6963751ce3c354b6f2b7f915c5bfc5aed9e8d35f", "extension": "py", "fi...
2.3125
stackv2
import click import webbrowser from halo import Halo import requests import os import dotenv import time from box import Box from rich import print from rich.table import Table, Column # from click_configfile import ConfigFileReader, Param, SectionSchema, matches_section # class ConfigFileLayout(object): # @matche...
272
38.53
135
17
2,482
python
[{"finding_id": "codeql_py/request-without-cert-validation_2338c3970bd5ee34_dfabd203", "tool_name": "codeql", "rule_id": "py/request-without-cert-validation", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "This request may run without certificate validation because [it is disabled]...
2
true
[ "CWE-295", "CWE-295" ]
[ "py/request-without-cert-validation", "py/request-without-cert-validation" ]
[ "MEDIUM", "MEDIUM" ]
[ "MEDIUM", "MEDIUM" ]
[ "This request may run without certificate validation because [it is disabled](1).", "This request may run without certificate validation because [it is disabled](1)." ]
[ 89, 116 ]
[ null, null ]
[ 23, 26 ]
[ 85, 73 ]
2024-11-19T03:12:27.003612+00:00
1,628,924,374,000
f88857c372fb759fbf1b5c1fbc0c09dd2b2bcbbf
3
{ "blob_id": "f88857c372fb759fbf1b5c1fbc0c09dd2b2bcbbf", "branch_name": "refs/heads/master", "committer_date": 1628924374000, "content_id": "5b047c1c221ba67450d32be7352f96391d774307", "detected_licenses": [ "MIT" ], "directory_id": "1000884faf988644d9abe02525c885307fd36f98", "extension": "py", "fi...
3.015625
stackv2
import hashlib buList = ['添加业务线','删除业务线','修改业务线','查看业务线'] hostlist = ['添加主机','删除主机','修改主机','查看主机'] #密码加密 def secrect(arg): salt = b'secrecttopassword' md5_s = hashlib.md5(salt) md5_s.update(arg.encode('utf-8')) res = md5_s.hexdigest() return res def show(type): if type == 3: l = bu...
160
19.46
106
13
1,061
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_de32453cecf10eeb_53682d24", "tool_name": "codeql", "rule_id": "py/weak-sensitive-data-hashing", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "[Sensitive data (password)](1) is used in a hashing algorithm (MD5) that is insec...
1
true
[ "CWE-327" ]
[ "py/weak-sensitive-data-hashing" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "[Sensitive data (password)](1) is used in a hashing algorithm (MD5) that is insecure for password hashing, since it is not a computationally expensive hash function.\n[Sensitive data (password)](2) is used in a hashing algorithm (MD5) that is insecure for password hashing, since it is not a computationally expensi...
[ 12 ]
[ null ]
[ 18 ]
[ 37 ]
2024-11-19T03:12:38.734349+00:00
1,527,317,232,000
889f1f73ea41c28ab1ea92ece00f18b7b71a6473
3
{ "blob_id": "889f1f73ea41c28ab1ea92ece00f18b7b71a6473", "branch_name": "refs/heads/master", "committer_date": 1527317232000, "content_id": "bee725c4d618439a5686b0a6263cf9fc047e1cc5", "detected_licenses": [ "MIT" ], "directory_id": "aa5e817b719729d11af268b1408e8b2659e1a039", "extension": "py", "fi...
2.78125
stackv2
import network, time, settings import webrepl wlan = network.WLAN(0) ap = network.WLAN(1) def setup_network(): if settings.AP_password == "": ap.active(False) else: ap.active(True) ap.config(essid = "ESP-"+str(int(ap.config("mac")[4]))+str(int(ap.config("mac")[5]...
49
36.96
107
21
424
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_216a96b85b421576_0411f09e", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (password)](1) as clear text.", ...
1
true
[ "CWE-312" ]
[ "py/clear-text-logging-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression logs [sensitive data (password)](1) as clear text." ]
[ 14 ]
[ null ]
[ 19 ]
[ 88 ]
2024-11-19T03:12:46.935885+00:00
1,620,720,359,000
49dbcc16d7a9d77572bddb6c70880ab93b682f1d
3
{ "blob_id": "49dbcc16d7a9d77572bddb6c70880ab93b682f1d", "branch_name": "refs/heads/master", "committer_date": 1620720359000, "content_id": "1ff9198e3d23f2506539716cc6ee5bec6e961afe", "detected_licenses": [ "MIT" ], "directory_id": "17b82e7a84400ae823801c937cb5b18541e4418c", "extension": "py", "fi...
2.78125
stackv2
#!/usr/bin/env python3 import requests def get_position_from_spi(date_str): auth = (user, password) params = {'date': date_str} r = requests.get('https://scdm-ace.swisspolar.ch/api/position', params=params, auth=auth) result = r.json() return result['latitude'], result['longitude'] position ...
18
20.61
93
9
115
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_ecc3e1a43591c3c3_4b739b42", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (private)](1) as clear text.\nTh...
1
true
[ "CWE-312" ]
[ "py/clear-text-logging-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression logs [sensitive data (private)](1) as clear text.\nThis expression logs [sensitive data (private)](2) as clear text." ]
[ 18 ]
[ null ]
[ 7 ]
[ 15 ]
2024-11-19T03:25:24.672099+00:00
1,506,635,289,000
2c16044779b8abefd16a114059f83e466a5c55bc
2
{ "blob_id": "2c16044779b8abefd16a114059f83e466a5c55bc", "branch_name": "refs/heads/master", "committer_date": 1506635289000, "content_id": "94d2785cd49c4ce58d392afe0e4a946df448f9ab", "detected_licenses": [ "Apache-2.0" ], "directory_id": "10d738d622bf1605d8946c855da1548675f67fe8", "extension": "py"...
2.5
stackv2
import os import re from multiprocessing import Process try: from SimpleHTTPServer import SimpleHTTPRequestHandler as Handler from SocketServer import TCPServer as Server except ImportError: from http.server import BaseHTTPRequestHandler as Handler from http.server import HTTPServer as Server import Generate_...
105
32.6
94
21
806
python
[{"finding_id": "codeql_py/polynomial-redos_1c625613e1896253_05aea0cb", "tool_name": "codeql", "rule_id": "py/polynomial-redos", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This [regular expression](1) that depends on a [user-provided value](2) may run slow on strings startin...
2
true
[ "CWE-1333", "CWE-022" ]
[ "py/polynomial-redos", "py/path-injection" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "This [regular expression](1) that depends on a [user-provided value](2) may run slow on strings starting with 'a' and with many repetitions of 'css'.\nThis [regular expression](1) that depends on a [user-provided value](3) may run slow on strings starting with 'a' and with many repetitions of 'css'.\nThis [regular...
[ 24, 62 ]
[ null, null ]
[ 47, 30 ]
[ 56, 63 ]
2024-11-19T03:25:38.061175+00:00
1,558,956,009,000
2a4a14dd73397d223eda5aa906d03d7b3307aa80
2
{ "blob_id": "2a4a14dd73397d223eda5aa906d03d7b3307aa80", "branch_name": "refs/heads/master", "committer_date": 1558956009000, "content_id": "82ace26526ff25f0fe0210acd55e9bae79206772", "detected_licenses": [ "MIT" ], "directory_id": "c5cae6b314c8ca6124a0a8600a4f767afcb32f46", "extension": "py", "fi...
2.34375
stackv2
from hashlib import sha3_256 from random import choice, randint, choices from backstage.models import College, Major, AdmClass, Student, \ Teacher, ClassRoom, MajorPlan, User from courseScheduling.models import Course, Teaching from django.db.utils import IntegrityError def make_encode(password: str): m = sha...
44
23.52
65
11
238
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_7463cc1385bd4d81_1111fa3c", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (password)](1) as clear text.", ...
2
true
[ "CWE-312", "CWE-327" ]
[ "py/clear-text-logging-sensitive-data", "py/weak-sensitive-data-hashing" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "This expression logs [sensitive data (password)](1) as clear text.", "[Sensitive data (password)](1) is used in a hashing algorithm (SHA3256) that is insecure for password hashing, since it is not a computationally expensive hash function.\n[Sensitive data (password)](2) is used in a hashing algorithm (SHA3256) ...
[ 37, 10 ]
[ null, null ]
[ 15, 18 ]
[ 25, 35 ]
2024-11-19T03:35:46.189398+00:00
1,613,681,333,000
9d1443a2effd1a8843ea464e93151bc742beaae8
3
{ "blob_id": "9d1443a2effd1a8843ea464e93151bc742beaae8", "branch_name": "refs/heads/main", "committer_date": 1613681333000, "content_id": "93f04702a918e7e34fcdfea26b3f9b38c34cf028", "detected_licenses": [ "MIT" ], "directory_id": "5347213f1db74f5a860f4f33096f0e465dcdb066", "extension": "py", "file...
3.09375
stackv2
""" Author: Christopher Schicho Project: Conway's Game of Life Version: 0.0 """ # NOTE: this script uses the ffmpeg software for creating the video file. # you can download it from this website: https://ffmpeg.org/ # you can find the rules for this simulation on the following website: # https://en.wikipedia.org/wiki/...
253
35.76
119
23
1,949
python
[{"finding_id": "codeql_py/redos_1a058754baa9eaa5_c416b122", "tool_name": "codeql", "rule_id": "py/redos", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "This part of the regular expression may cause exponential backtracking on strings containing many repetitions of ' '.", "remediati...
1
true
[ "CWE-1333" ]
[ "py/redos" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This part of the regular expression may cause exponential backtracking on strings containing many repetitions of ' '." ]
[ 70 ]
[ null ]
[ 51 ]
[ 58 ]
2024-11-19T03:35:49.071027+00:00
1,679,319,060,000
1d4e8f35381f3d2d6118a4e3c4e9d0d85c5ad039
3
{ "blob_id": "1d4e8f35381f3d2d6118a4e3c4e9d0d85c5ad039", "branch_name": "refs/heads/master", "committer_date": 1679319322000, "content_id": "855eb3988c99ac9ce5faecaa758669521386bb38", "detected_licenses": [ "MIT" ], "directory_id": "de244487a2950022811c7e5743118d2ed5825a6e", "extension": "py", "fi...
3.125
stackv2
import collections import random random.seed(42) import gst import jinja2 # Let match_edge = { # < 0, if starting pos of a match # > 0, if ending pos of a match # = 0, otherwise # } Char = collections.namedtuple("Char", ("char", "match_edge", "match_number")) output_html_path = "index.html" min_match_length = ...
49
34.61
97
13
507
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_2097f2bec470adbe_c9843ba2", "tool_name": "codeql", "rule_id": "py/jinja2/autoescape-false", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Using jinja2 templates with autoescape=False can potentially allow XSS attacks.", "remediati...
1
true
[ "CWE-079" ]
[ "py/jinja2/autoescape-false" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "Using jinja2 templates with autoescape=False can potentially allow XSS attacks." ]
[ 40 ]
[ null ]
[ 12 ]
[ 67 ]