added
stringlengths
32
32
created
int64
1,244B
1,694B
id
stringlengths
40
40
int_score
int64
2
5
metadata
dict
score
float64
2.31
5.25
source
stringclasses
1 value
text
stringlengths
324
20.1k
num_lines
int64
16
598
avg_line_length
float64
15.1
58.3
max_line_length
int64
33
179
ast_depth
int64
8
39
length
int64
101
3.8k
lang
stringclasses
1 value
sast_codeql_findings
stringlengths
1.1k
265k
sast_codeql_findings_count
int64
1
45
sast_codeql_success
bool
1 class
sast_codeql_error
stringclasses
1 value
cwe_ids
listlengths
1
45
rule_ids
listlengths
1
45
confidences
listlengths
1
45
severities
listlengths
1
45
messages
listlengths
1
45
line_starts
listlengths
1
45
line_ends
listlengths
1
45
column_starts
listlengths
1
45
column_ends
listlengths
1
45
2024-11-19T01:00:08.081552+00:00
1,393,174,315,000
360b8dbce0ae4396b69be6d18b055c21515d11ce
3
{ "blob_id": "360b8dbce0ae4396b69be6d18b055c21515d11ce", "branch_name": "refs/heads/master", "committer_date": 1393174315000, "content_id": "352ae76e3abe9af8c69bde5970a7aaf712b9594f", "detected_licenses": [ "Apache-2.0" ], "directory_id": "282e7237996f25686990e44bda50fd743acc22bc", "extension": "py"...
3.1875
stackv2
""" Model for user management """ import sqlite3 from hashlib import md5 class Users: def __init__(self, connection): self.db = connection self.cursor = self.db.cursor() def user_exists(self, username): return not self.cursor.execute( "select username from users where user...
59
27.32
75
16
327
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_b82e67dc354c4e3f_94541308", "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...
[ 31 ]
[ null ]
[ 21 ]
[ 45 ]
2024-11-19T01:11:40.888613+00:00
1,599,571,793,000
da140b723ac39c8581376bf0557f917fbeeb68a6
3
{ "blob_id": "da140b723ac39c8581376bf0557f917fbeeb68a6", "branch_name": "refs/heads/master", "committer_date": 1599571793000, "content_id": "93b15e24565224f6d4507fe99791c03f456a7d7c", "detected_licenses": [ "MIT" ], "directory_id": "aa2b7a428ba257cf09682fa722b408b966d8de82", "extension": "py", "fi...
3.359375
stackv2
# Generate random addresses from random cities in US import requests import numpy import json from pprint import pprint from random import randint from time import sleep NOMINATIM_API_URL = 'https://nominatim.openstreetmap.org/reverse?format=json&lat={}&lon={}&zoom=18' NUMBER_OF_ADDR = 500 DISTANCE = 100 * 1000 API_CA...
44
30.3
99
15
388
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_ee17652bd1d89db3_0057fc7c", "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." ]
[ 42 ]
[ null ]
[ 15 ]
[ 27 ]
2024-11-19T01:11:47.225158+00:00
1,693,230,751,000
fea1916a7a86fbe515e2bc84aedc4a5cd9957d4a
3
{ "blob_id": "fea1916a7a86fbe515e2bc84aedc4a5cd9957d4a", "branch_name": "refs/heads/master", "committer_date": 1693230751000, "content_id": "a94a99eff6466f2bb4e6434ef98cc57c3e351cb3", "detected_licenses": [ "Apache-2.0" ], "directory_id": "52a677b94056d3397b4a499bc9185adb68a63f05", "extension": "py"...
2.546875
stackv2
""" Provides helper methods and templates for generating cloud config for running containers. Originally from https://github.com/DevTable/container-cloud-config """ import json import logging import os from urllib.parse import quote as urlquote from jinja2 import Environment, FileSystemLoader, StrictUndefined logge...
112
31.05
93
14
753
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_593717bc14578a4f_5cdc8cc6", "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." ]
[ 66 ]
[ 68 ]
[ 15 ]
[ 10 ]
2024-11-19T01:21:25.927399+00:00
1,658,830,257,000
d2025bbcdb94f48ead7ed1833e0abe566d1cf8ba
2
{ "blob_id": "d2025bbcdb94f48ead7ed1833e0abe566d1cf8ba", "branch_name": "refs/heads/master", "committer_date": 1658830257000, "content_id": "b81d457dc65d441b0ce8acbc6427578d867331e6", "detected_licenses": [ "MIT" ], "directory_id": "f878e537003c6f698bfa5e5e1afd8c0f2faa025f", "extension": "py", "fi...
2.484375
stackv2
#!/usr/bin/env python #--coding:utf-8-- from http.server import BaseHTTPRequestHandler, HTTPServer from os import path from urllib.parse import urlparse curdir = path.dirname(path.realpath(__file__)) sep = '/' # MIME-TYPE mimedic = [ ('.html', 'text/html'), ('.htm', 'text/html'), ('.js', 'application/javascrip...
64
23.3
66
20
432
python
[{"finding_id": "codeql_py/path-injection_9297fd69694b4823_87ad77c9", "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)." ]
[ 44 ]
[ null ]
[ 15 ]
[ 53 ]
2024-11-19T01:21:26.050224+00:00
1,554,815,258,000
34ee690e2b93c47bbdb9b97af737925b868ca35c
3
{ "blob_id": "34ee690e2b93c47bbdb9b97af737925b868ca35c", "branch_name": "refs/heads/master", "committer_date": 1554815258000, "content_id": "9af7bab43af2a78bd43fd17cb070e26ae8c8caf4", "detected_licenses": [ "MIT" ], "directory_id": "4ade314dfe3821e28225c529f626c696e0eaa283", "extension": "py", "fi...
2.8125
stackv2
from flask import Flask, request, jsonify, g import sqlite3 import os import sys app = Flask(__name__) @app.route('/', methods=['GET']) def home(): return "<h1>Basic Documentation</h1>" +\ "<h3>An API to return data regarding BV's song database in JSON format</h3>" +\ "<h3>Sample requests:</h3><h...
120
36.97
156
18
1,292
python
[{"finding_id": "codeql_py/flask-debug_80bb8e22fc0f0238_e556706e", "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-215", "CWE-089" ]
[ "py/flask-debug", "py/flask-debug", "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.", "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)." ]
[ 118, 120, 99 ]
[ null, null, null ]
[ 9, 9, 31 ]
[ 73, 44, 36 ]
2024-11-19T01:21:44.082714+00:00
1,492,941,114,000
41846705fe43d37d0c362bf021fa36a64ce7aeec
3
{ "blob_id": "41846705fe43d37d0c362bf021fa36a64ce7aeec", "branch_name": "refs/heads/master", "committer_date": 1492941114000, "content_id": "8552ff04004b088d47c8d2c95f7e5bac58c43b9e", "detected_licenses": [ "MIT" ], "directory_id": "56e8025f373be95030f78d66d685a1e86b02d909", "extension": "py", "fi...
2.640625
stackv2
from flask import Flask, send_from_directory, jsonify, abort, make_response, url_for import requests, os, json app = Flask(__name__) pokemonData = None # Open pokemon database file. with open('database/pokemon.json', 'r', encoding='utf8') as file: pokemonData = json.load(file) file.close() @app.route('/favi...
234
33.37
166
24
2,200
python
[{"finding_id": "codeql_py/flask-debug_3a45163e6699d026_bcbac10e", "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-918" ]
[ "py/flask-debug", "py/partial-ssrf" ]
[ "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.", "Part of the URL of this request depends on a [user-provided value](1).\nPart of the URL of this request depends on a [user-provided value](2)." ]
[ 234, 38 ]
[ null, null ]
[ 5, 9 ]
[ 24, 30 ]
2024-11-19T01:33:43.699033+00:00
1,532,025,431,000
60295fca878dfe38ad14eea63bb895f143302dc8
3
{ "blob_id": "60295fca878dfe38ad14eea63bb895f143302dc8", "branch_name": "refs/heads/master", "committer_date": 1532025431000, "content_id": "0c14479253d53cd2a96def5438fbc1d4a63515ec", "detected_licenses": [ "MIT" ], "directory_id": "610e2032a5f813f66e3c9e4a3308e0137a486512", "extension": "py", "fi...
3.484375
stackv2
# solution to http://cryptopals.com/sets/3/challenges/20 # break a group of AES CTR ciphertexts statistically import random import math import struct import repeatingXOR import base64 import repeatingXOR from Crypto.Cipher import AES # generates a random sequence of bytes. length is determined by length argument (in...
84
34
104
16
762
python
[{"finding_id": "codeql_py/weak-cryptographic-algorithm_ddc3f1ef0e362d77_a467f28f", "tool_name": "codeql", "rule_id": "py/weak-cryptographic-algorithm", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "[The block mode ECB](1) is broken or weak, and should not be used.", "remediation": ...
1
true
[ "CWE-327" ]
[ "py/weak-cryptographic-algorithm" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "[The block mode ECB](1) is broken or weak, and should not be used." ]
[ 29 ]
[ null ]
[ 9 ]
[ 35 ]
2024-11-19T01:56:46.756619+00:00
1,634,584,937,000
72113227088caac15abfb96a9b0179b7ca102341
2
{ "blob_id": "72113227088caac15abfb96a9b0179b7ca102341", "branch_name": "refs/heads/master", "committer_date": 1634584937000, "content_id": "7065351f6f976f2958e1ebad23d49f1fac75f86c", "detected_licenses": [ "MIT" ], "directory_id": "7c474c2d75bddd6f94ac7a937bc2798781c78d66", "extension": "py", "fi...
2.4375
stackv2
import collections from jinja2 import Environment, FileSystemLoader def _flatten(excavation): flattened = dict() for (path, excavations) in excavation.items(): distribution = collections.Counter(excavations) flattened[path] = sorted( distribution.items(), key=lambda i: i[1], rever...
34
26.74
74
13
196
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_9977821867d4ca8a_c11b73e0", "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." ]
[ 19 ]
[ null ]
[ 23 ]
[ 49 ]
2024-11-19T02:10:25.120645+00:00
1,476,385,749,000
e5b692f78e2c51ad91d4705bc57e96da83b42f60
2
{ "blob_id": "e5b692f78e2c51ad91d4705bc57e96da83b42f60", "branch_name": "refs/heads/master", "committer_date": 1476385749000, "content_id": "dac6ee2bdc3a7bb4931f1bddaba1430c7bce8018", "detected_licenses": [ "MIT" ], "directory_id": "73522c182dcea84f1e15773a35e78ce1dc9c3927", "extension": "py", "fi...
2.3125
stackv2
# encoding=utf-8 from jinja2 import Environment, PackageLoader from utils import ks_manager as km import sys def make_pages (exp_dir): env = Environment(loader=PackageLoader('page', 'templates')) template = env.get_template('ks_project/base.html') for page in km.fetch_crawler_data(): url = page['u...
18
30.67
64
15
144
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_165cb5f1c4dd8a10_2e607bc5", "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." ]
[ 8 ]
[ null ]
[ 11 ]
[ 65 ]
2024-11-19T02:10:46.418280+00:00
1,499,168,923,000
27f05e1f7468aeb99c96d7999b8ab1093f2215f3
3
{ "blob_id": "27f05e1f7468aeb99c96d7999b8ab1093f2215f3", "branch_name": "refs/heads/master", "committer_date": 1499168923000, "content_id": "d4122d6442989e1a62d53ade3224b7acb3b9a839", "detected_licenses": [ "MIT" ], "directory_id": "58f41c2ad56d2eb969f3436854f50c4a8a20ab2f", "extension": "py", "fi...
2.890625
stackv2
#!/usr/bin/env python3 # encoding: utf-8 import secrets import string import sys import argparse import os from tqdm import tqdm #progress bar # import time # from datetime import timedelta #check python version if sys.version_info<(3,0,0): sys.stderr.write("Get Python 3 you idiot : https://www.python.org/downlo...
166
31.11
153
16
1,258
python
[{"finding_id": "codeql_py/clear-text-storage-sensitive-data_c8c27b389c48268a_a6e7fa93", "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.\...
4
true
[ "CWE-312", "CWE-312", "CWE-312", "CWE-312" ]
[ "py/clear-text-storage-sensitive-data", "py/clear-text-storage-sensitive-data", "py/clear-text-logging-sensitive-data", "py/clear-text-logging-sensitive-data" ]
[ "HIGH", "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "This expression stores [sensitive data (password)](1) as clear text.\nThis expression stores [sensitive data (password)](2) as clear text.", "This expression stores [sensitive data (password)](1) as clear text.\nThis expression stores [sensitive data (password)](2) as clear text.\nThis expression stores [sensiti...
[ 46, 102, 40, 95 ]
[ null, null, null, null ]
[ 27, 27, 15, 15 ]
[ 47, 49, 23, 25 ]
2024-11-19T02:45:21.082228+00:00
1,527,027,797,000
103960866a2f9d4ab9d96c9400fdebf1c7a976ab
2
{ "blob_id": "103960866a2f9d4ab9d96c9400fdebf1c7a976ab", "branch_name": "refs/heads/master", "committer_date": 1527027797000, "content_id": "11a3fd27ecd42131e7fcd6a1fc7cd2e83a48711f", "detected_licenses": [ "MIT" ], "directory_id": "93149811790067d45fd31d20fce30d130a936821", "extension": "py", "fi...
2.46875
stackv2
from flask import Flask, request import re, string, json, random from flask_cors import CORS from datamuse import datamuse from PyDictionary import PyDictionary from generate_poem import generate_poem_suggestion from utils.data_processing import get_vocab import requests import json import os app = Flask(__name__) a...
118
24.78
113
19
863
python
[{"finding_id": "codeql_py/reflective-xss_7951dc036abbdb71_2bf7de05", "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...
2
true
[ "CWE-079", "CWE-918" ]
[ "py/reflective-xss", "py/partial-ssrf" ]
[ "HIGH", "MEDIUM" ]
[ "MEDIUM", "MEDIUM" ]
[ "Cross-site scripting vulnerability due to a [user-provided value](1).", "Part of the URL of this request depends on a [user-provided value](1)." ]
[ 40, 68 ]
[ null, null ]
[ 12, 7 ]
[ 16, 74 ]
2024-11-19T02:45:26.327661+00:00
1,509,561,901,000
5a804a402de4ba6c2a0044ba6d8808757006ed7d
2
{ "blob_id": "5a804a402de4ba6c2a0044ba6d8808757006ed7d", "branch_name": "refs/heads/master", "committer_date": 1509561901000, "content_id": "69fe1d2ca4f0e0d30f5a0324c995e85fff52263b", "detected_licenses": [ "MIT" ], "directory_id": "5b0d52edfdb5c050ebfe3de4527e6384ba2696d1", "extension": "py", "fi...
2.3125
stackv2
__version__ = "1.1.0" "Module version string." version = (1,1,0) "Module version tuple." import sys import mpycompat if 0: try: import time except ImportError: import utime as time builtins.time =time # import uos as os # sys.modules['os']=os #builtins.IOError ...
139
20.81
66
17
779
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_58c4b78be12f6fb8_2c29765c", "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." ]
[ 85 ]
[ null ]
[ 11 ]
[ 19 ]
2024-11-19T02:45:47.145041+00:00
1,573,550,091,000
4435d0a269c5f700cdbebc385616ab2d594f4f44
3
{ "blob_id": "4435d0a269c5f700cdbebc385616ab2d594f4f44", "branch_name": "refs/heads/master", "committer_date": 1573550091000, "content_id": "a193df2a0a46436e6c5e36074c575faa30582eb2", "detected_licenses": [ "MIT" ], "directory_id": "3c4fb0f85c19f9e12f74c217e53d25b2d9a9c3ae", "extension": "py", "fi...
3.1875
stackv2
#!/usr/bin/env python3.6 import os import pyperclip from credentials import Credentials def generate_password(): ''' generate password ''' return os.urandom(8) print("Hello! Welcome to Password Locker app where passwords are found") print("****** Use Yes or No as shortcodes to navigate***********...
88
26.67
93
13
521
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_c817a5a87b2e85e3_4a37e8c7", "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." ]
[ 60 ]
[ null ]
[ 15 ]
[ 50 ]
2024-11-19T02:45:57.146649+00:00
1,565,042,149,000
16c384b6569844cdf25f8bae7e5fafddbdefe8f1
2
{ "blob_id": "16c384b6569844cdf25f8bae7e5fafddbdefe8f1", "branch_name": "refs/heads/master", "committer_date": 1565042149000, "content_id": "6ed439862cd66452c3cef021f77b7c8fe01fc531", "detected_licenses": [ "MIT" ], "directory_id": "222d9e9e8c012ffb68938d2d850dbaa90ebd629d", "extension": "py", "fi...
2.34375
stackv2
""" ``splunk_saml_cli_auth`` is a helper tool for authenticating with Splunk on the CLI when using SAML authentication. This can also be used indirectly to interact with the Splunk REST API. """ import argparse from urllib.parse import urlparse, urlunparse import requests from pycookiecheat import chrome_cookies de...
83
32.86
99
14
608
python
[{"finding_id": "codeql_py/request-without-cert-validation_3e1b040176bc3a0f_2e66def9", "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)." ]
[ 44, 61 ]
[ 57, 74 ]
[ 16, 16 ]
[ 6, 6 ]
2024-11-19T02:57:17.096692+00:00
1,585,146,120,000
dfbb27cc4954536bd33e09f38cefb1ab3faf347a
2
{ "blob_id": "dfbb27cc4954536bd33e09f38cefb1ab3faf347a", "branch_name": "refs/heads/master", "committer_date": 1585146120000, "content_id": "beb65e31d7a698a3906c0588b87fd549289ba602", "detected_licenses": [ "MIT" ], "directory_id": "4ae6c35ec6f0d008eaa0eff225a22bc2329dca2d", "extension": "py", "fi...
2.46875
stackv2
from flask import Flask, render_template, request from PredictionClass_WorldWar2 import Predict app = Flask(__name__, template_folder='template') app.config['SEND_FILE_MAX_AGE_DEFAULT'] = 0 @app.route('/', methods = ['POST', 'GET']) def home(): summ = "No File" if request.method == 'POST': f = requ...
19
26.74
54
12
134
python
[{"finding_id": "codeql_py/flask-debug_3310c3383dee62a4_a1d7b8e3", "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-022" ]
[ "py/flask-debug", "py/path-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 path depends on a [user-provided value](1)." ]
[ 19, 12 ]
[ null, null ]
[ 5, 16 ]
[ 40, 26 ]
2024-11-19T02:57:26.133389+00:00
1,606,871,301,000
03e3f77d4f86740e6f880992e6ef2d6d279395fe
3
{ "blob_id": "03e3f77d4f86740e6f880992e6ef2d6d279395fe", "branch_name": "refs/heads/master", "committer_date": 1606871301000, "content_id": "5ec0f76686383f784533ec941b762a439ae07f8e", "detected_licenses": [ "MIT" ], "directory_id": "841afe2940d2c45b245d2a14b817e9b698e2bd47", "extension": "py", "fi...
2.8125
stackv2
import csv import requests import itertools import json from datetime import datetime #API keys for two services constant NYTIMES_API_KEY = '' with open('keys.json', 'r', encoding='utf-8') as keys: keys = json.load(keys) NYTIMES_API_KEY= keys['nytimes_key'] def get_best_seller_info(isbn, author, title): b...
61
38.56
120
22
632
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_731b506d8ffafde7_5ccf95ca", "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." ]
[ 21 ]
[ null ]
[ 12 ]
[ 15 ]
2024-11-19T03:12:12.953855+00:00
1,611,843,605,000
c85d1ccb150bea9297cac926acd176531e2a48ad
2
{ "blob_id": "c85d1ccb150bea9297cac926acd176531e2a48ad", "branch_name": "refs/heads/master", "committer_date": 1611843605000, "content_id": "9c5d0f03048682d5f1d1f82d642496d19a5264c8", "detected_licenses": [ "BSD-2-Clause" ], "directory_id": "ecd75525b29ee54d6b5cde41da4f7e0f5dc3b2f8", "extension": "p...
2.453125
stackv2
import json import os from datetime import datetime from dateutil.parser import parse as parse_date_string from flask import request, jsonify, redirect from flask_login import current_user from flask_user import login_required from app import app from app import db from app.models.user_models import User @app.rout...
62
22.08
104
13
327
python
[{"finding_id": "codeql_py/url-redirection_617568c95a5b5137_9a0fb09f", "tool_name": "codeql", "rule_id": "py/url-redirection", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "Untrusted URL redirection depends on a [user-provided value](1).", "remediation": "", "location": {"file_...
1
true
[ "CWE-601" ]
[ "py/url-redirection" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "Untrusted URL redirection depends on a [user-provided value](1)." ]
[ 60 ]
[ null ]
[ 21 ]
[ 37 ]
2024-11-19T03:12:20.663552+00:00
1,517,403,947,000
c0a71ff8210e6ac4e2bf4889ebed37d17409b655
2
{ "blob_id": "c0a71ff8210e6ac4e2bf4889ebed37d17409b655", "branch_name": "refs/heads/master", "committer_date": 1517403947000, "content_id": "54f6f4c3c47b2967b0201fdbe307f64b63a72c60", "detected_licenses": [ "BSD-2-Clause" ], "directory_id": "c471f17acec0c2c58dc57b6731ebf30d71662ade", "extension": "p...
2.453125
stackv2
#!/usr/bin/python # -*- coding: utf-8 -*- # @CreateTime: Jan 30, 2017 11:26 PM # @Author: Aldo Sotolongo # @Contact: aldenso@gmail.com # @Last Modified By: Aldo Sotolongo # @Last Modified Time: Jun 18, 2017 1:43 AM # @Description: Create, Delete and list snapshots defined in csv file. from __future__ import print_fun...
296
40.1
97
21
2,545
python
[{"finding_id": "codeql_py/request-without-cert-validation_d875e6d7fa36578d_e1b9b8d7", "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)." ]
[ 94, 129, 153 ]
[ 95, 130, null ]
[ 15, 15, 15 ]
[ 70, 46, 78 ]
2024-11-19T03:12:23.738947+00:00
1,548,258,298,000
36fab9a4915229ea53053d1514951a0337fb500d
3
{ "blob_id": "36fab9a4915229ea53053d1514951a0337fb500d", "branch_name": "refs/heads/master", "committer_date": 1548258298000, "content_id": "1c760e149ea52567b648b52f6ecaaa636222e6a5", "detected_licenses": [ "MIT" ], "directory_id": "596092a109c25fd3743b8dad5f0dee5b81edb0b9", "extension": "py", "fi...
2.515625
stackv2
from flask import Flask,render_template, json, request import json import sys import os from pprint import pprint from cassandra.cluster import Cluster from cassandra.policies import DCAwareRoundRobinPolicy cluster = Cluster(load_balancing_policy=DCAwareRoundRobinPolicy()) app = Flask(__name__) @app.route("/") def in...
65
27.51
166
15
514
python
[{"finding_id": "codeql_py/reflective-xss_96553cf2abc0f320_f535eed7", "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...
2
true
[ "CWE-079", "CWE-089" ]
[ "py/reflective-xss", "py/sql-injection" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "Cross-site scripting vulnerability due to a [user-provided value](1).", "This SQL query depends on a [user-provided value](1)." ]
[ 19, 49 ]
[ null, null ]
[ 12, 35 ]
[ 16, 166 ]
2024-11-19T01:33:48.743595+00:00
1,521,975,648,000
f7682b4dbdd8962bc3c778111f3a33f521d30701
3
{ "blob_id": "f7682b4dbdd8962bc3c778111f3a33f521d30701", "branch_name": "refs/heads/master", "committer_date": 1521975648000, "content_id": "71e94c1e903ad0aef1d67f5fdb50b8a4020e03e4", "detected_licenses": [ "CC0-1.0" ], "directory_id": "6431c7514e92220e37f6448e53843d55ac0a18dc", "extension": "py", ...
2.65625
stackv2
# テンプレファイルから変数を取得したい。 # が、デフォルトでそんな機能はないっぽい。 # どんなキーを渡せばいいか不明なのは困る。 from jinja2 import Template, Environment, FileSystemLoader, meta import pathlib import datetime path_tpl = (pathlib.Path(__file__).parent.parent / 'res/templates').resolve() env = Environment(loader=FileSystemLoader(str(path_tpl ))) template = env.g...
22
26.5
77
12
178
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_f54c81d2e456051e_ed1b6c02", "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." ]
[ 10 ]
[ null ]
[ 7 ]
[ 59 ]
2024-11-19T01:57:15.446854+00:00
1,434,306,401,000
32520538684397e14f597abe19f78dc6edc789c7
3
{ "blob_id": "32520538684397e14f597abe19f78dc6edc789c7", "branch_name": "refs/heads/master", "committer_date": 1434306401000, "content_id": "45060cc2cf384530b0cfad91a0a997ef1fdd58dd", "detected_licenses": [ "Apache-2.0" ], "directory_id": "18ffe8199db4cb375d313d0a15e8b240a2a3fe55", "extension": "py"...
2.78125
stackv2
import sqlite3, random from flask import Flask, render_template, request app = Flask(__name__) conn = sqlite3.connect('bar.db',check_same_thread=False) db = conn.cursor() def bar_closed(): command = "SELECT * FROM ingredients WHERE stock>0;" db.execute(command) results = db.fetchall() if results != [...
83
26.88
114
17
518
python
[{"finding_id": "codeql_py/flask-debug_c855c2f3f1a3b352_86f8f846", "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)." ]
[ 82, 32 ]
[ null, null ]
[ 5, 20 ]
[ 24, 27 ]
2024-11-19T02:10:58.299867+00:00
1,625,965,840,000
a2b671a0a095cffc2e14d432362bb06dfd5873fc
2
{ "blob_id": "a2b671a0a095cffc2e14d432362bb06dfd5873fc", "branch_name": "refs/heads/main", "committer_date": 1625965840000, "content_id": "58eb9ae28f6090a5e05cd9670da4869a63c6b5ed", "detected_licenses": [ "MIT" ], "directory_id": "d24bcb72c6f6ef53f170f09a5df415996a9fb8ae", "extension": "py", "file...
2.359375
stackv2
# -*- coding: utf-8 -*- import hashlib import json import os import re import requests from requests import utils class TiebaCheckIn: def __init__(self, check_item): self.check_item = check_item @staticmethod def login_info(session): return session.get(url="https://zhidao.baidu.com/api/l...
95
37.29
129
19
970
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_09c968cd08698c34_e2e50089", "tool_name": "codeql", "rule_id": "py/weak-sensitive-data-hashing", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "[Sensitive data (id)](1) is used in a hashing algorithm (MD5) that is insecure.",...
1
true
[ "CWE-327" ]
[ "py/weak-sensitive-data-hashing" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "[Sensitive data (id)](1) is used in a hashing algorithm (MD5) that is insecure." ]
[ 55 ]
[ null ]
[ 31 ]
[ 85 ]
2024-11-19T02:11:33.638757+00:00
1,394,832,742,000
6b04a20132741ae51ace4e2347f2f13d8d3ccf95
3
{ "blob_id": "6b04a20132741ae51ace4e2347f2f13d8d3ccf95", "branch_name": "refs/heads/master", "committer_date": 1394832742000, "content_id": "56cdb2d8c491a85beb8fd578ef8ed875d087956e", "detected_licenses": [ "Apache-2.0" ], "directory_id": "14cb453f8d205bf796af1ce7f8b51c89619c21ca", "extension": "py"...
2.921875
stackv2
""" Jinja2 Environment loading helper functions. Confab uses the environments :meth:`jinja2.Environment.list_templates` method to abstract template location from rendering and synchronization. Note that the default Jinja2 Loaders assume a charset (default: utf-8). """ from jinja2 import (Environment, FileSystemLoader...
95
36.64
94
14
691
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_ec537bba76436630_a62e30fc", "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...
4
true
[ "CWE-079", "CWE-079", "CWE-079", "CWE-079" ]
[ "py/jinja2/autoescape-false", "py/jinja2/autoescape-false", "py/jinja2/autoescape-false", "py/jinja2/autoescape-false" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "Using jinja2 templates with autoescape=False can potentially allow XSS attacks.", "Using jinja2 templates with autoescape=False can potentially allow XSS attacks.", "Using jinja2 templates with autoescape=False can potentially allow XSS attacks.", "Using jinja2 templates with autoescape=False can potentially...
[ 31, 34, 54, 57 ]
[ null, 35, null, 58 ]
[ 20, 16, 20, 16 ]
[ 53, 54, 53, 54 ]
2024-11-19T02:11:38.600908+00:00
1,538,934,610,000
34b2775510385d0bbdb18bbef0f719ce76f0fb1e
2
{ "blob_id": "34b2775510385d0bbdb18bbef0f719ce76f0fb1e", "branch_name": "refs/heads/master", "committer_date": 1538934610000, "content_id": "ca5a3d378e3ce427156f6f6453976ff1ad5f36fe", "detected_licenses": [ "MIT" ], "directory_id": "df56a7ba9eb430e65686000348d899a759780ff6", "extension": "py", "fi...
2.375
stackv2
import requests import re from natas_utility import * current_level = 31 credentials = get_credentials(current_level) base_url = 'http://{}.natas.labs.overthewire.org'.format(credentials['username']) auth = (credentials['username'], credentials['password']) url = base_url + '?cat /etc/natas_webpass/natas32 | xargs e...
24
27.83
81
10
178
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_7996b2a9408c08be_2e42cec8", "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." ]
[ 22 ]
[ null ]
[ 7 ]
[ 20 ]
2024-11-19T02:32:40.896310+00:00
1,636,036,275,000
41040013d3c69edf3f267b49528d08ba0b4205a6
3
{ "blob_id": "41040013d3c69edf3f267b49528d08ba0b4205a6", "branch_name": "refs/heads/main", "committer_date": 1636036275000, "content_id": "f28b31a15a2c8da93c172ef2949ce0571a2342c7", "detected_licenses": [ "MIT" ], "directory_id": "f19514cd9ff3eff7b15c593a70bc7c7355315b02", "extension": "py", "file...
2.90625
stackv2
import sys import configparser import time import re import pandas as pd from pandas import Series,DataFrame #统计可能含日期的口令(连续数字位数大于等于4的) def countProbPasswd(passwdList): df = [] for i in range(len(passwdList)): passwd = str(passwdList[i]) struc = "" for ch in passwd: if ch.isdigit(): struc += 'D' eli...
277
28.77
175
19
3,256
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_1ee90a79bb82141a_72c0926c", "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." ]
[ 116, 188 ]
[ null, null ]
[ 8, 8 ]
[ 18, 18 ]
2024-11-19T02:33:23.286178+00:00
1,579,628,049,000
77e0449b43b8319467f0a6ab960b00080b86b271
4
{ "blob_id": "77e0449b43b8319467f0a6ab960b00080b86b271", "branch_name": "refs/heads/master", "committer_date": 1579628049000, "content_id": "3a6d1b77c3980fa83fed9bc0330235685f954ab5", "detected_licenses": [ "MIT" ], "directory_id": "314581cc93f20357cbc1d638786116ffd53f7f89", "extension": "py", "fi...
4.1875
stackv2
from string import ascii_letters from random import randint, choice, shuffle def RandomLetter(): lower_upper_alphabet = ascii_letters random_letter = choice(lower_upper_alphabet) return random_letter def RandomNumber(): random_number = randint(0, 9) return random_number def GeneratePassword(howLo...
39
27.85
62
14
251
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_d88bd62409778296_0b8ea7b0", "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.\nThis expression logs [sensitive data (password)](3) as clear text." ]
[ 34 ]
[ null ]
[ 19 ]
[ 58 ]
2024-11-19T02:33:27.734942+00:00
1,565,106,180,000
4babb646d02eeb74b60f845593af84d77fb38384
3
{ "blob_id": "4babb646d02eeb74b60f845593af84d77fb38384", "branch_name": "refs/heads/master", "committer_date": 1565106180000, "content_id": "672ab0d8b8d2ba96033f74076ac808cfb322178d", "detected_licenses": [ "MIT" ], "directory_id": "9fc762d2c9634689a02dac77089f34417e1a4be1", "extension": "py", "fi...
2.734375
stackv2
""" Script for building a VirtualBox image with Packer """ import argparse import os import subprocess AUTOUNATTEND_TEMPLATE = './answerfiles/windows10/Autounattend.xml.template' AUTOUNATTEND_XML = './answerfiles/windows10/Autounattend.xml' def run_packer(username, password, skip_window_updates): """Runs the pac...
58
37.6
93
11
457
python
[{"finding_id": "codeql_py/clear-text-storage-sensitive-data_f4cbc8ad4558b8bc_1cc8072c", "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.\nThis expression stores [sensitive data (password)](3) as clear text." ]
[ 28 ]
[ null ]
[ 29 ]
[ 49 ]
2024-11-19T02:33:29.535315+00:00
1,441,293,397,000
80293140db2666ee6cd4c9e15040c0f530def1a1
3
{ "blob_id": "80293140db2666ee6cd4c9e15040c0f530def1a1", "branch_name": "refs/heads/master", "committer_date": 1441293397000, "content_id": "4a2fa8666de20f1bff4e9df5492e8303a9a8752c", "detected_licenses": [ "Apache-2.0" ], "directory_id": "fed0b4eafe65ffcbf585eb4578db0f70694f1be1", "extension": "py"...
2.78125
stackv2
# coding: utf-8 from config import TWITTER_API """ twitter-authorize: - step through the process of creating and authorization a Twitter application. Based on: https://github.com/ideoforms/python-twitter-examples """ import twitter import time print("1. Create a new Twitter application here: https://apps.twitt...
53
25.36
92
11
325
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_951203ffa43f5842_9d8e727b", "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 (secret)](1) as clear text.\nThi...
1
true
[ "CWE-312" ]
[ "py/clear-text-logging-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression logs [sensitive data (secret)](1) as clear text.\nThis expression logs [sensitive data (secret)](2) as clear text." ]
[ 50 ]
[ null ]
[ 7 ]
[ 61 ]
2024-11-19T02:46:21.385193+00:00
1,543,260,096,000
ff8d860bd1556116e877d191b8072fe2f3402762
2
{ "blob_id": "ff8d860bd1556116e877d191b8072fe2f3402762", "branch_name": "refs/heads/master", "committer_date": 1543260096000, "content_id": "c9c0c3c3b58fac7cb41c683e534c52b304c9f570", "detected_licenses": [ "BSD-3-Clause" ], "directory_id": "da6ecdaac446c99a09fd4ad9d78491ec21458367", "extension": "p...
2.328125
stackv2
import random import string import pickle import cherrypy import numpy as np import pandas as pd from scipy.sparse import csr_matrix from scipy import sparse import re import os from jinja2 import Environment, FileSystemLoader path = os.path.abspath(os.path.dirname(__file__)) config = { 'global' : { 'tools.proxy...
114
34.11
124
18
951
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_60481182a6bbae3a_a1c4edf3", "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." ]
[ 31 ]
[ null ]
[ 7 ]
[ 76 ]
2024-11-19T02:59:22.037050+00:00
1,519,764,081,000
7d3a39c039e7ce8153271fbd5430900f14bad42f
3
{ "blob_id": "7d3a39c039e7ce8153271fbd5430900f14bad42f", "branch_name": "refs/heads/master", "committer_date": 1519764081000, "content_id": "99065fabe5d3b5ea58b5045968a77a75827b288a", "detected_licenses": [ "MIT" ], "directory_id": "dae87777377d6aa447a1f9b24f0ce590fae06e85", "extension": "py", "fi...
2.828125
stackv2
import requests, csv import datetime as dt, calendar from calendar import monthrange from time import sleep from secrets import API_KEY BASE_URL = f"https://api.darksky.net/forecast/{API_KEY}/" QUERY_PARAMS = "?units=si" BATH_LAT = 51.3758 BATH_LONG = 2.3599 BATH_URL = f"{BASE_URL}{BATH_LAT},{BATH_LONG}{QUERY_PARAMS}...
136
35.57
119
18
1,146
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_e0fed61cb73af7f1_81e7e094", "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." ]
[ 33 ]
[ null ]
[ 15 ]
[ 28 ]
2024-11-19T02:59:26.217065+00:00
1,657,889,028,000
d2b51bc5deba3768caa3d68c6e8a86793a6c239e
3
{ "blob_id": "d2b51bc5deba3768caa3d68c6e8a86793a6c239e", "branch_name": "refs/heads/master", "committer_date": 1657889028000, "content_id": "e3262921ab9a290da40e33030fbf2515158d01b5", "detected_licenses": [ "MIT" ], "directory_id": "67a442ecabcdca9f54f5920874d0095d57f98ede", "extension": "py", "fi...
2.5625
stackv2
"""Removes storms that pass outside continental United States (CONUS).""" import argparse import numpy import pandas from gewittergefahr.gg_utils import conus_boundary from gewittergefahr.gg_utils import temporal_tracking from gewittergefahr.gg_utils import echo_top_tracking from gewittergefahr.gg_utils import storm_t...
338
37.4
80
15
3,003
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_a07b133655f6d299_f911e1db", "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." ]
[ 159 ]
[ 161 ]
[ 11 ]
[ 6 ]
2024-11-19T02:59:36.018750+00:00
1,646,728,668,000
56691dcb91d0973c3ded3f2744e4651138d852f4
2
{ "blob_id": "56691dcb91d0973c3ded3f2744e4651138d852f4", "branch_name": "refs/heads/master", "committer_date": 1646728668000, "content_id": "f2e3247cba1d4ff9c05b8a2680324b0185d4c86d", "detected_licenses": [ "MIT" ], "directory_id": "41331c7a60b5fd8beb557175e95f16a547d8b5f4", "extension": "py", "fi...
2.46875
stackv2
from flask import Flask from flask import render_template from flask import request from flask import url_for from flask import has_request_context, request from flask.logging import default_handler import logging class RequestFormatter(logging.Formatter): def format(self, record): if has_request_contex...
214
27.25
112
16
1,436
python
[{"finding_id": "codeql_py/log-injection_e79b4d4f0f211e71_5acdbae5", "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).\nThis log entry depends on a [user-provided value](2)...
1
true
[ "CWE-117" ]
[ "py/log-injection" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "This log entry depends on a [user-provided value](1).\nThis log entry depends on a [user-provided value](2).\nThis log entry depends on a [user-provided value](3).\nThis log entry depends on a [user-provided value](4).\nThis log entry depends on a [user-provided value](1).\nThis log entry depends on a [user-provid...
[ 125 ]
[ null ]
[ 29 ]
[ 80 ]
2024-11-19T02:59:36.485856+00:00
1,592,506,246,000
d365e03943d1e38bb772a323e586f355631851f4
4
{ "blob_id": "d365e03943d1e38bb772a323e586f355631851f4", "branch_name": "refs/heads/master", "committer_date": 1592506246000, "content_id": "a598d7b09281cca5934120d45bbd754ab14a3604", "detected_licenses": [ "MIT" ], "directory_id": "edd1b9a65ac22d05c34c25f4167455649ae01991", "extension": "py", "fi...
3.828125
stackv2
# -*- coding: utf-8 -*- """ Created on Sun Jun 24 15:35:22 2018 @author: joshu """ # Enter a string to hide in uppercase : HIDE # Secret Message : 35647890 # Original Message : HIDE message =input("Enter a string to hide: ") secret_message = '' for i in range(len(message)): secret_message += str(ord(message[...
32
23.25
89
11
200
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_b143c83f19745c56_102d924a", "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 (secret)](1) as clear text.\nThi...
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 (secret)](1) as clear text.\nThis expression logs [sensitive data (secret)](2) as clear text.", "This expression logs [sensitive data (secret)](1) as clear text.\nThis expression logs [sensitive data (secret)](2) as clear text.", "This expression logs [sensitive data (secre...
[ 20, 21, 26 ]
[ null, null, null ]
[ 7, 7, 49 ]
[ 72, 89, 68 ]
2024-11-19T03:12:16.465565+00:00
1,602,667,445,000
41ee2f5d284def10629c55d5c42277dd652518dd
4
{ "blob_id": "41ee2f5d284def10629c55d5c42277dd652518dd", "branch_name": "refs/heads/master", "committer_date": 1602667445000, "content_id": "e31445c2bc6d9f0e44efc1a89ae7f01b648f9498", "detected_licenses": [ "Apache-2.0" ], "directory_id": "671d0222ed8fc37f7c716cbb1e0367f7fd796cc3", "extension": "py"...
4.21875
stackv2
birthdays={'熊珍龙':'7-8','王海东':'1-9'} while True : print('请输入姓名:') name=input() if name=='': break if name in birthdays: print(birthdays[name]+'是'+name+'的生日') else : print('没有'+name+'的生日信息,请输入生日:') birthday=input() birthdays[name]=birthday print('生日信息更新成...
28
19.32
45
13
172
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_1e54ddb0a4d9e8a3_bf83d10c", "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.", "...
5
true
[ "CWE-312", "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", "py/clear-text-logging-sensitive-data" ]
[ "HIGH", "HIGH", "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "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.", "This expression logs [sensitive...
[ 10, 19, 22, 25, 28 ]
[ null, null, null, null, null ]
[ 15, 11, 11, 11, 11 ]
[ 45, 12, 12, 18, 33 ]
2024-11-19T01:26:55.363171+00:00
1,584,468,786,000
97669f778f011149bfc44ff4f361c94b4fa01fe2
3
{ "blob_id": "97669f778f011149bfc44ff4f361c94b4fa01fe2", "branch_name": "refs/heads/master", "committer_date": 1584468786000, "content_id": "4e186b07ede6d510c86000d263c067ad600173c2", "detected_licenses": [ "MIT" ], "directory_id": "59fc4dfa4e0163433049879bbd85a348cb3d797f", "extension": "py", "fi...
2.765625
stackv2
import os import argparse parser = argparse.ArgumentParser(description='Make user accounts given usernames and passwords.') parser.add_argument('name', help='name which is used in assumed users and passwords file name', type=str) args = parser.parse_args() name = args.name fu = open('users_' + name + '.txt') fp = ope...
21
34.05
105
14
184
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_9bed116e8b4efaab_159e14a6", "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." ]
[ 20 ]
[ null ]
[ 11 ]
[ 18 ]
2024-11-19T01:27:01.717411+00:00
1,632,241,741,000
c2847ff54da2ce67aaea5f51381b774b3684b612
2
{ "blob_id": "c2847ff54da2ce67aaea5f51381b774b3684b612", "branch_name": "refs/heads/master", "committer_date": 1632241741000, "content_id": "25d1b387f89dd86cbd155ac07caa5583c2f94b45", "detected_licenses": [ "Apache-2.0" ], "directory_id": "4a9ba91f6f05fc906ceb39960d8d21e66e4556e5", "extension": "py"...
2.5
stackv2
import os import time import datetime import yaml import psutil import streamlit as st from alphapept.paths import FILE_WATCHER_FILE, DEFAULT_SETTINGS_PATH, QUEUE_PATH from alphapept.gui.utils import check_process, init_process, start_process, get_size from alphapept.settings import load_settings_as_template, save_set...
223
32.83
103
22
1,600
python
[{"finding_id": "codeql_py/path-injection_ba1cfe692f63ad8a_0fd5206b", "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-022" ]
[ "py/path-injection", "py/path-injection", "py/path-injection" ]
[ "HIGH", "HIGH", "HIGH" ]
[ "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)." ]
[ 157, 175, 194 ]
[ null, null, null ]
[ 26, 27, 41 ]
[ 32, 44, 47 ]
2024-11-19T01:38:05.567629+00:00
1,587,006,716,000
77537512881f3904262d912d9328cca25c5296fa
3
{ "blob_id": "77537512881f3904262d912d9328cca25c5296fa", "branch_name": "refs/heads/master", "committer_date": 1587006716000, "content_id": "9cf6455d7dc257b113e42e96dc33ae04e8b6435c", "detected_licenses": [ "Apache-2.0" ], "directory_id": "8a4c83106cd7296a7cf7da48c5191ac5e25cb675", "extension": "py"...
2.578125
stackv2
from absl import logging import os import sys import codecs from athena import get_wave_file_length import pandas import tensorflow as tf import fnmatch import tarfile import tempfile from six.moves import urllib SUBSETS = ["train", "dev", "test"] def download_and_extract(directory, url): """Download and extract...
126
34.37
86
16
1,056
python
[{"finding_id": "codeql_py/tarslip_2d4f97ddd1473964_93af0514", "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)." ]
[ 47 ]
[ null ]
[ 13 ]
[ 16 ]
2024-11-19T01:38:07.312018+00:00
1,604,461,306,000
a30da185ea15025cb3062fb936f47124500c1345
3
{ "blob_id": "a30da185ea15025cb3062fb936f47124500c1345", "branch_name": "refs/heads/master", "committer_date": 1604461306000, "content_id": "8d672b0f53b006c1dcb88be9696963bf11ad4a2f", "detected_licenses": [ "Apache-2.0" ], "directory_id": "6ffea319d68339a24a1d6ea96ae75fda66b08d4b", "extension": "py"...
2.78125
stackv2
# Name: user.py # Author: HuangHao # Time: 2020/9/18 11:02 from django.http import HttpResponse, JsonResponse from zooapi.models import User import hashlib, time # api接口,url相同,按照请求方法不懂,分到到特定函数去处理。 def process_method(request): if request.method == 'GET': return get(request) elif request.method == 'POS...
143
36.48
110
20
1,288
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_97fe22b60c169028_c7d628e0", "tool_name": "codeql", "rule_id": "py/weak-sensitive-data-hashing", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "[Sensitive data (id)](1) is used in a hashing algorithm (MD5) that is insecure.",...
4
true
[ "CWE-327", "CWE-327", "CWE-327", "CWE-327" ]
[ "py/weak-sensitive-data-hashing", "py/weak-sensitive-data-hashing", "py/weak-sensitive-data-hashing", "py/weak-sensitive-data-hashing" ]
[ "HIGH", "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "[Sensitive data (id)](1) is used in a hashing algorithm (MD5) that is insecure.", "[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.", "[Sensitive data (password)](1) is used in a hashing algorit...
[ 66, 67, 106, 108 ]
[ null, null, null, null ]
[ 28, 32, 49, 45 ]
[ 86, 76, 77, 89 ]
2024-11-19T01:38:17.945452+00:00
1,550,100,757,000
e1b19e1ced5b52dcd61411556f5bb628eed87533
3
{ "blob_id": "e1b19e1ced5b52dcd61411556f5bb628eed87533", "branch_name": "refs/heads/master", "committer_date": 1550100757000, "content_id": "644bee8ec22f4e11d5f850de14114784aaeb5f6f", "detected_licenses": [ "MIT" ], "directory_id": "43d998458f95237fddc48b34491250d4bb3ac1de", "extension": "py", "fi...
2.796875
stackv2
import tarfile import os import json import random import tensorflow as tf import numpy as np """Download data. """ def download_and_extract_data(tarfile_path, cam_num): output_dir = os.path.dirname(tarfile_path) if os.path.exists(os.path.join(output_dir, cam_num)): return output_dir tar = tarfi...
82
32
100
28
618
python
[{"finding_id": "codeql_py/tarslip_5236a62b8998fe4a_1baf0942", "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)." ]
[ 17 ]
[ null ]
[ 5 ]
[ 8 ]
2024-11-19T01:38:18.217542+00:00
1,590,271,968,000
9882f6755f716e6a1318e44b5457113de29733ce
3
{ "blob_id": "9882f6755f716e6a1318e44b5457113de29733ce", "branch_name": "refs/heads/main", "committer_date": 1590271968000, "content_id": "b93bc83526c8933ba5bc9dad144f13aa947cf51d", "detected_licenses": [ "MIT" ], "directory_id": "7357d367b0af4650ccc5b783b7a59090fdde47bb", "extension": "py", "file...
2.546875
stackv2
import git import uuid import os from jinja2 import Template def clone_git_repo(repo_url): """ input: repo_url output: path of the cloned repository steps: 1. clone the repo 2. parse 'site' into for templating assumptions: repo_url = "git@github.com:littleq0903/django-deployer-t...
68
40.4
131
13
659
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_4fb248056fed46a0_1333b834", "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." ]
[ 65 ]
[ null ]
[ 14 ]
[ 44 ]
2024-11-19T01:38:28.838022+00:00
1,480,716,269,000
2d8a6f2fc0af7065c8a0005f615066994d542ea3
2
{ "blob_id": "2d8a6f2fc0af7065c8a0005f615066994d542ea3", "branch_name": "refs/heads/master", "committer_date": 1480716269000, "content_id": "11d93a2b4466a792ef375db013d58d6eccec4f41", "detected_licenses": [ "MIT" ], "directory_id": "9b1027f54ab10633afb5fc5a2d2d93e25dce95b0", "extension": "py", "fi...
2.421875
stackv2
import flask import ujson as json import os import reversedict app = flask.Flask(__name__) @app.route('/instructions') def instruction(): return flask.jsonify(how_to='GET request to /lookup/{description}/ or POST to /lookup/ with parameter `description`.', tip='You can also use `synonym...
32
35.84
122
14
256
python
[{"finding_id": "codeql_py/flask-debug_b0413c89f9072502_9f62fdbc", "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)." ]
[ 30, 25 ]
[ 32, 26 ]
[ 5, 12 ]
[ 54, 65 ]
2024-11-19T01:38:38.041014+00:00
1,635,158,659,000
01ba6e7378681ae9748b15c0c17a63bb906f02af
4
{ "blob_id": "01ba6e7378681ae9748b15c0c17a63bb906f02af", "branch_name": "refs/heads/master", "committer_date": 1635158659000, "content_id": "733c5381c4fea09e8da038e1a0521ed6d437575b", "detected_licenses": [ "MIT" ], "directory_id": "112442cfc372a0540768ac1739eb44b779738c09", "extension": "py", "fi...
3.65625
stackv2
#!/usr/bin/env python3.8 import string import random from password import Password from credentials import Credentials def create_password(userName,userPassword): ''' Function to create a new user in our password class ''' new_password = Password(userName,userPassword) return new_password def sav...
169
29.63
156
19
974
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_a90d44bb67bd6f08_aea9f656", "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.", ...
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 (password)](1) as clear text.", "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 (p...
[ 91, 125, 153 ]
[ null, null, null ]
[ 19, 19, 27 ]
[ 97, 156, 103 ]
2024-11-19T01:38:39.088617+00:00
1,524,204,433,000
318bd31e1a0041145b9b0d2f51563b4b210c225c
2
{ "blob_id": "318bd31e1a0041145b9b0d2f51563b4b210c225c", "branch_name": "refs/heads/master", "committer_date": 1524204433000, "content_id": "24bfe9ea4b4c7deba763a91e425efff6926968da", "detected_licenses": [ "Apache-2.0" ], "directory_id": "cc59bbccd7dc50db9d7153999b90d4e16bca8278", "extension": "py"...
2.328125
stackv2
#-*- coding: utf-8 -*- #!/usr/bin/python import paramiko import re import pdb #pdb.set_trace() def execShellCmd(ip,username,passwd,callback): try: client = paramiko.SSHClient() client.set_missing_host_key_policy(paramiko.AutoAddPolicy()) client.connect(ip,2222,username,passwd,timeout=5) ...
37
23.73
68
14
241
python
[{"finding_id": "codeql_py/paramiko-missing-host-key-validation_33ca4890decb23de_c5502899", "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." ]
[ 12 ]
[ null ]
[ 9 ]
[ 69 ]
2024-11-19T01:39:03.170020+00:00
1,632,321,447,000
8bff132ab121b8f93be5d6c87b4aa09367bbd980
3
{ "blob_id": "8bff132ab121b8f93be5d6c87b4aa09367bbd980", "branch_name": "refs/heads/master", "committer_date": 1632321447000, "content_id": "1e40d841f95437266cd7f3e1cbcddf2ae05983af", "detected_licenses": [ "MIT" ], "directory_id": "fee0008f9ade435645ab5921a69bc7ce6f3c5429", "extension": "py", "fi...
2.921875
stackv2
def HashPassword(password): import hashlib hash = hashlib.sha512( str( password ).encode("utf-8") ).hexdigest() return hash def GenerateToken(length): import random import string lower = string.ascii_lowercase upper = string.ascii_uppercase digits = "0123456789" final = digits+lowe...
24
35.12
142
14
215
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_fa72af26e3005c32_19e4f5ce", "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...
1
true
[ "CWE-327" ]
[ "py/weak-sensitive-data-hashing" ]
[ "HIGH" ]
[ "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." ]
[ 4 ]
[ null ]
[ 28 ]
[ 59 ]
2024-11-19T01:52:24.710139+00:00
1,585,392,177,000
05dbc6f35fcd2ef410ca91dac27690c0da3d7677
2
{ "blob_id": "05dbc6f35fcd2ef410ca91dac27690c0da3d7677", "branch_name": "refs/heads/master", "committer_date": 1585392177000, "content_id": "49f97f3989a4fc41c247b91b2ae4b7fd475daf4b", "detected_licenses": [ "MIT" ], "directory_id": "6f805a098565b36d16759aa6ecbd9b362a988312", "extension": "py", "fi...
2.375
stackv2
import argparse import json import logging import os from pathlib import Path from flask import abort, Flask, redirect, render_template, request, Response app = Flask(__name__) def scan_next(file=None): try: i = app.sequence.index(file) + 1 except ValueError: i = 0 while i < len(app.sequ...
117
26.07
97
17
765
python
[{"finding_id": "codeql_py/path-injection_790c19a3ba979dc6_834071ab", "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-022" ]
[ "py/path-injection", "py/path-injection", "py/path-injection" ]
[ "HIGH", "HIGH", "HIGH" ]
[ "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)." ]
[ 40, 49, 84 ]
[ null, null, null ]
[ 19, 15, 26 ]
[ 30, 26, 44 ]
2024-11-19T01:52:26.609998+00:00
1,620,240,626,000
2166e8fd604b4ec746e6dd3e96158901addf743e
3
{ "blob_id": "2166e8fd604b4ec746e6dd3e96158901addf743e", "branch_name": "refs/heads/main", "committer_date": 1620240626000, "content_id": "0b8e3d4a010cd1b4ea56fd682cc0c40c750d761f", "detected_licenses": [ "MIT" ], "directory_id": "6a5bb97c4b5cec433d7e4dcf60c5bdb6255f7a71", "extension": "py", "file...
2.515625
stackv2
from rest_framework.views import APIView from rest_framework.response import Response from rest_framework.exceptions import ParseError from django.http import Http404 from datetime import date import json from ..models import * from ..serializers import PollSerializer, QuestionSerializer, UserOptionSerializer, UserRes...
165
39.32
112
22
1,171
python
[{"finding_id": "codeql_py/stack-trace-exposure_326641a961f2f219_36a556cb", "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.", "...
3
true
[ "CWE-209", "CWE-209", "CWE-209" ]
[ "py/stack-trace-exposure", "py/stack-trace-exposure", "py/stack-trace-exposure" ]
[ "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "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.", "[Stack trace information](1) flows to this location and may be exposed to an external user." ]
[ 46, 125, 165 ]
[ null, null, null ]
[ 30, 30, 30 ]
[ 32, 32, 32 ]
2024-11-19T02:04:26.460201+00:00
1,492,083,136,000
0deb9b0f5d338977504fad201b39d81419cf0270
2
{ "blob_id": "0deb9b0f5d338977504fad201b39d81419cf0270", "branch_name": "refs/heads/master", "committer_date": 1492083136000, "content_id": "903c2cc2e48682882076c85b66c77dabe7f20e61", "detected_licenses": [ "MIT" ], "directory_id": "56ce70d18c449114183e177dcd047296e96b2c7f", "extension": "py", "fi...
2.453125
stackv2
import os import sys import yaml from .utils import print_err from .fs_commands import mkdirp from jinja2 import Template, Environment, FileSystemLoader env = Environment(loader=FileSystemLoader('templates')) def get_config_vars(config): """\ Fetches the config values from the yaml config and returns a ...
43
29
89
14
290
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_1ed8c6b07a6ed66d_9ad5792f", "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." ]
[ 9 ]
[ null ]
[ 7 ]
[ 56 ]
2024-11-19T02:28:29.341540+00:00
1,464,539,059,000
8a586adcbef692b9ff7049d143dd9cdde41cd5cf
3
{ "blob_id": "8a586adcbef692b9ff7049d143dd9cdde41cd5cf", "branch_name": "refs/heads/master", "committer_date": 1464539059000, "content_id": "5d7bfde9ce3b4a8f0f86e809709fffd08d3b7096", "detected_licenses": [ "MIT" ], "directory_id": "fbdfc36f35d0571c250dbfe5e8f8de9881c1a8bb", "extension": "py", "fi...
2.578125
stackv2
import hashlib import uuid import appserversdao import constants from pymongo import MongoClient mongo = MongoClient(constants.MONGO_URI) mongodb = mongo[constants.MONGO_DATABASE] mongocollection = mongodb[constants.MONGO_USERS_COLLECTION] users = list() class User(object): def __init__(self, email, password): ...
94
26.26
93
17
552
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_fdb76e2d6ff2d0bb_a8fbda0b", "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...
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 (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...
[ 40, 45 ]
[ null, null ]
[ 31, 43 ]
[ 64, 81 ]
2024-11-19T02:28:40.873086+00:00
1,599,532,537,000
88054a6694d16108e4cc65fda99ad90b5fc3a283
4
{ "blob_id": "88054a6694d16108e4cc65fda99ad90b5fc3a283", "branch_name": "refs/heads/master", "committer_date": 1599532537000, "content_id": "847c7821a8c12a4d755d0d62aa64a644934cc53e", "detected_licenses": [ "MIT" ], "directory_id": "b9c8d1141315addf5bb4e2507eb45cfb1cfb08c4", "extension": "py", "fi...
3.921875
stackv2
import random import string working = True while working == True: """ This function is designated to help you create a randomized password with the length of your choosing. Args: length (int) = The lenth of the desired password wantNums (Requires a string value of 'y' or 'n') = This decide...
81
37.59
122
17
799
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_53e6ccec7f32566f_d4fd0ba4", "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...
5
true
[ "CWE-312", "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", "py/clear-text-logging-sensitive-data" ]
[ "HIGH", "HIGH", "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "This expression logs [sensitive data (password)](1) as clear text.\nThis expression logs [sensitive data (password)](2) as clear text.", "This expression logs [sensitive data (password)](1) as clear text.\nThis expression logs [sensitive data (password)](2) as clear text.", "This expression logs [sensitive dat...
[ 34, 43, 51, 59, 68 ]
[ null, null, null, null, null ]
[ 19, 19, 19, 19, 19 ]
[ 27, 27, 27, 27, 27 ]
2024-11-19T02:28:41.749155+00:00
1,573,492,876,000
e7ae0d626fba41e4eb032914e7f0976a83f0a68d
3
{ "blob_id": "e7ae0d626fba41e4eb032914e7f0976a83f0a68d", "branch_name": "refs/heads/master", "committer_date": 1573492876000, "content_id": "17273c1e0b651b2b3b3be0d424c614e09f673c3c", "detected_licenses": [ "MIT" ], "directory_id": "bb724d9e568113e379de56af6604a30af8e65f60", "extension": "py", "fi...
3.125
stackv2
import Crypto import Crypto.Random from Crypto.Hash import SHA from Crypto.PublicKey import RSA from Crypto.Signature import PKCS1_v1_5 import binascii class Wallet(object): """ A wallet is a private/public key pair """ def __init__(self): random_gen = Crypto.Random.new().read self._pr...
40
31.1
89
16
303
python
[{"finding_id": "codeql_py/weak-crypto-key_fef3a82dd6174e5c_64b0f13a", "tool_name": "codeql", "rule_id": "py/weak-crypto-key", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Creation of an RSA key uses [1024](1) bits, which is below 2048 and considered breakable.", "remediation": "",...
1
true
[ "CWE-326" ]
[ "py/weak-crypto-key" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "Creation of an RSA key uses [1024](1) bits, which is below 2048 and considered breakable." ]
[ 15 ]
[ null ]
[ 29 ]
[ 59 ]
2024-11-19T02:28:52.722437+00:00
1,609,960,601,000
e1249b23740d04fa3c772d5b73acc359b988c48f
3
{ "blob_id": "e1249b23740d04fa3c772d5b73acc359b988c48f", "branch_name": "refs/heads/main", "committer_date": 1609960601000, "content_id": "69b9ad3b5072f43e315d3b16d596f63656c3d13b", "detected_licenses": [ "MIT" ], "directory_id": "f363bb60cc968f69bda0619d9972eccf3fd93a32", "extension": "py", "file...
2.5625
stackv2
import datetime as dt import jwt from config import Config SECRET_KEY = Config.SECRET_KEY ENCRYPTION_ALGO = Config.ENCRYPTION_ALGO ACCESS_TOKEN_EXPIRE_MINUTES = Config.ACCESS_TOKEN_EXPIRE_MINUTES class Token: @staticmethod def create_access_token(data, expires_delta=None): to_encode = data.copy() ...
39
28.41
81
18
246
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_3c08fcd1f369fdef_d76bdb1f", "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 (secret)](1) as clear text.", "r...
1
true
[ "CWE-312" ]
[ "py/clear-text-logging-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression logs [sensitive data (secret)](1) as clear text." ]
[ 26 ]
[ null ]
[ 15 ]
[ 25 ]
2024-11-19T02:36:55.327034+00:00
1,374,607,179,000
eb9fe0e465e9e2ad0cd8e524f1fed17d2d57de6a
2
{ "blob_id": "eb9fe0e465e9e2ad0cd8e524f1fed17d2d57de6a", "branch_name": "refs/heads/master", "committer_date": 1374607179000, "content_id": "402c435fd622d2e41d8c466a95eced66140a5849", "detected_licenses": [ "Python-2.0", "CC0-1.0" ], "directory_id": "a3c56049119e2ba01f6c0a0f694c488db1d40b2f", "e...
2.375
stackv2
#!/usr/bin/env python # -*- coding: utf-8 -*- # -------------------------------------------------------------------------------------------------- # OpenSeaMap API - Web API for OpenSeaMap services. # # Written in 2012 by Dominik Fässler dfa@bezono.org # # To the extent possible under law, the author(s) have dedicated...
201
33.52
100
18
1,205
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_3c6ad32e8b9d4ee3_290779a8", "tool_name": "codeql", "rule_id": "py/weak-sensitive-data-hashing", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "[Sensitive data (id)](1) is used in a hashing algorithm (SHA1) that is insecure.\...
2
true
[ "CWE-327", "CWE-327" ]
[ "py/weak-sensitive-data-hashing", "py/weak-sensitive-data-hashing" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "[Sensitive data (id)](1) is used in a hashing algorithm (SHA1) that is insecure.\n[Sensitive data (id)](2) is used in a hashing algorithm (SHA1) that is insecure.\n[Sensitive data (id)](3) is used in a hashing algorithm (SHA1) that is insecure.\n[Sensitive data (id)](4) is used in a hashing algorithm (SHA1) that i...
[ 142, 175 ]
[ null, null ]
[ 26, 26 ]
[ 34, 41 ]
2024-11-19T02:37:04.150464+00:00
1,618,062,751,000
eb8599cf59258ca8408bb60abf86224f355858fc
2
{ "blob_id": "eb8599cf59258ca8408bb60abf86224f355858fc", "branch_name": "refs/heads/main", "committer_date": 1618062751000, "content_id": "3dd6c1842686a6666995b8dfa115d2117b568285", "detected_licenses": [ "MIT" ], "directory_id": "bf68b6094714e60d897186af4ccb8a20a634a885", "extension": "py", "file...
2.484375
stackv2
""" THProxyDetector Version: Build 5 License: MIT License Author: lokka30 More information: https://github.com/lokka30/TheHallwayScripts """ import json import requests from requests.exceptions import Timeout from twisted.internet import reactor # Set a key to "disabled" to disable it. PROXYCHECK_IO_KEY = "disabled" ...
119
44.62
166
21
1,246
python
[{"finding_id": "codeql_py/request-without-cert-validation_fab2429212b6c735_c868bc0c", "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)." ]
[ 52, 78, 105 ]
[ null, null, null ]
[ 28, 28, 28 ]
[ 107, 148, 127 ]
2024-11-19T02:37:15.414093+00:00
1,683,572,673,000
26e17ab4dbaf5cc4948e3b3da0b1e9c733ea3780
3
{ "blob_id": "26e17ab4dbaf5cc4948e3b3da0b1e9c733ea3780", "branch_name": "refs/heads/master", "committer_date": 1683572673000, "content_id": "edfbedde9129fb0e0db35967db3f90bbe24cf460", "detected_licenses": [ "MIT" ], "directory_id": "15c455b685817ac1c5c899c534df64862200085a", "extension": "py", "fi...
2.734375
stackv2
import wx,sys from tkinter import * from tkinter.filedialog import * from tkinter import Tk, ttk, messagebox from hashlib import sha256 import Image_operation_Library as op filename="" file_destination="" tc2 = "" tc1 = "" pwd = None #Input source file def File_Input(x): global filename root = Tk() filena...
222
28.22
114
18
1,562
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_51f7e9f2bbdebb32_4951e519", "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...
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 (SHA256) that is insecure for password hashing, since it is not a computationally expensive hash function.", "[Sensitive data (password)](1) is used in a hashing algorithm (SHA256) that is insecure for password hashing, since it is not a computational...
[ 185, 213 ]
[ null, null ]
[ 31, 31 ]
[ 48, 48 ]
2024-11-19T02:37:39.837901+00:00
1,613,417,868,000
32bcda85dc23ee99c20947d8e8a20b2ede0392b6
3
{ "blob_id": "32bcda85dc23ee99c20947d8e8a20b2ede0392b6", "branch_name": "refs/heads/main", "committer_date": 1613417868000, "content_id": "4acbd0cbd7b35addaf03f24e1fa4d33805db8c3a", "detected_licenses": [ "MIT", "Apache-2.0" ], "directory_id": "2af1a179c31f7d4fe61f1afff7fc4bd4b2b65872", "extensi...
2.8125
stackv2
import os import tarfile from abc import ABC, abstractmethod from glob import glob import shutil import random import zstandard """ This registry is for automatically downloading and extracting datasets. To register a class you need to inherit the DataDownloader class, provide name, filetype and url attributes, and (...
136
34.43
136
16
1,154
python
[{"finding_id": "codeql_py/tarslip_f43c3c62a4a688ff_2f8f36b8", "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)." ]
[ 57 ]
[ null ]
[ 13 ]
[ 24 ]
2024-11-19T02:37:40.120133+00:00
1,645,470,305,000
153fb48c0ee2a2e03c1d509f2de9321b40165397
3
{ "blob_id": "153fb48c0ee2a2e03c1d509f2de9321b40165397", "branch_name": "refs/heads/master", "committer_date": 1645470305000, "content_id": "9c63e5ac978a970892c49ebc04ab2b9725fab9c1", "detected_licenses": [ "MIT" ], "directory_id": "c6eeabb70a688802ce4894f237d811df71a84a9b", "extension": "py", "fi...
2.984375
stackv2
""" This module holds functionality for executing commands and filesystem operations in containers and host machines. """ import paramiko import getpass import weakref import time import config_data class ConnectionsHolder: """ This class holds the ssh connections to all the host machines in the CPF infras...
169
31.9
161
16
1,138
python
[{"finding_id": "codeql_py/paramiko-missing-host-key-validation_3424e3aea89c5e8b_c457799e", "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." ]
[ 66 ]
[ null ]
[ 9 ]
[ 79 ]
2024-11-19T03:11:31.737456+00:00
1,315,365,712,000
4f54212c67f12c93bad77c813eba05b852070eb2
3
{ "blob_id": "4f54212c67f12c93bad77c813eba05b852070eb2", "branch_name": "refs/heads/master", "committer_date": 1315365712000, "content_id": "37112ebd5c884a9078bd248120e634f2ac7ae27b", "detected_licenses": [ "MIT" ], "directory_id": "c8fd4350995d65ee40b9ac9dade0cdf477248479", "extension": "py", "fi...
2.671875
stackv2
#!/usr/bin/python import sys, re, tokenize, token def countPyFile(fname): f = open(fname) codelines = {} lastline = 0 IGNORE = (token.STRING, token.NEWLINE, token.INDENT, token.DEDENT) docstrlines = 0 for toktp,tokstr,start,end,line in tokenize.generate_tokens(f.xreadlines().next): #p...
85
24.92
85
11
670
python
[{"finding_id": "codeql_py/redos_308d2e4b2fa45620_7ff43d0f", "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 ')'." ]
[ 23 ]
[ null ]
[ 35 ]
[ 40 ]
2024-11-19T03:11:46.253681+00:00
1,671,552,951,000
74f66c29ab563faa7f5b95dbb3de5d7d397b10b9
3
{ "blob_id": "74f66c29ab563faa7f5b95dbb3de5d7d397b10b9", "branch_name": "refs/heads/master", "committer_date": 1671552951000, "content_id": "6446c802876e9fd1a9ac996c6760a7453e769019", "detected_licenses": [ "Apache-2.0" ], "directory_id": "52213e3a157e674d42126212725b223ec0176752", "extension": "py"...
2.84375
stackv2
# This is a demonstration of how to use RA-TLS without actually # interfacing with the RA-TLS library directly. Instead, the RA-TLS # key and certificate are generated at startup and exposed through the # file system. The application accesses the key and certificate by # reading from the file system. import base64 imp...
42
31.81
112
12
393
python
[{"finding_id": "codeql_py/insecure-default-protocol_0eb88bbbc8cac4dd_0e06088e", "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." ]
[ 41 ]
[ null ]
[ 16 ]
[ 113 ]
2024-11-19T03:11:56.842130+00:00
1,656,526,197,000
6626ae54128cef83b49b0e03302bd538bb7d5ba9
2
{ "blob_id": "6626ae54128cef83b49b0e03302bd538bb7d5ba9", "branch_name": "refs/heads/master", "committer_date": 1656526197000, "content_id": "dc81a616911237edeb96cda69759d785e6e1b139", "detected_licenses": [ "Apache-2.0" ], "directory_id": "36349e8e3f54d34a914220b3e6ca8ac1ccafaba2", "extension": "py"...
2.34375
stackv2
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Copyright 2017 CPqD. All rights reserved. # # 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/LICENS...
159
33.34
101
22
1,256
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_25324652f82b494e_a9e80470", "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." ]
[ 116 ]
[ null ]
[ 19 ]
[ 45 ]
2024-11-19T03:12:35.978458+00:00
1,589,942,037,000
3e2bfc89dc11d12651dbf41fa3b04de5bf708572
3
{ "blob_id": "3e2bfc89dc11d12651dbf41fa3b04de5bf708572", "branch_name": "refs/heads/master", "committer_date": 1589942037000, "content_id": "10716be388953a8ec36b3a185ef929391639e48e", "detected_licenses": [ "MIT" ], "directory_id": "6264798a6094cf0f484d17d8b7b4f87781fb9821", "extension": "py", "fi...
2.859375
stackv2
from flask import Flask, request from pymessenger.bot import Bot app = Flask(__name__) ACCESS_TOKEN = 'ACCESS_TOKEN' VERIFY_TOKEN = 'VERIFY_TOKEN' bot = Bot(ACCESS_TOKEN) @app.route('/', methods=['GET', 'POST']) def receive_message(): if request.method == 'GET': # Before allowing people to message you...
55
34.47
79
20
388
python
[{"finding_id": "codeql_py/reflective-xss_0d7e188307e481a8_ec92c0ff", "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 ]
[ 16 ]
[ 43 ]
2024-11-19T03:12:41.604710+00:00
1,688,462,213,000
4f907c20812c6fe5c42ccaf1cd65fe9d83b2c9bc
3
{ "blob_id": "4f907c20812c6fe5c42ccaf1cd65fe9d83b2c9bc", "branch_name": "refs/heads/master", "committer_date": 1688462213000, "content_id": "9704066ccdb015de1dd7aeb13046d4c0ae75248a", "detected_licenses": [ "BSD-2-Clause" ], "directory_id": "88dd10981b3a827ce76625bfdc857c2fff9ac1b5", "extension": "p...
2.734375
stackv2
""" initialises or removes TRAP tables in a database. """ import os import re import sys import tkp from tkp.db.model import SCHEMA_VERSION import tkp.db.database import tkp.db.model import tkp.db.quality from tkp.config import get_database_config from sqlalchemy.exc import ProgrammingError tkp_folder = tkp.__path__...
182
29.25
90
16
1,229
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_56f548125043c291_7c71ec68", "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." ]
[ 41 ]
[ null ]
[ 11 ]
[ 58 ]
2024-11-19T03:12:46.636884+00:00
1,682,388,382,000
5df17338f81f3bfb87588f5c37a31bcab26e5a1c
2
{ "blob_id": "5df17338f81f3bfb87588f5c37a31bcab26e5a1c", "branch_name": "refs/heads/master", "committer_date": 1682388382000, "content_id": "34e39ed67877172ee53cf74cedbf8e47d0dfbd8c", "detected_licenses": [ "BSD-3-Clause" ], "directory_id": "d907469cde3a8e326dba1eaa41c55faf8f04f550", "extension": "p...
2.3125
stackv2
#!/usr/bin/env python3 """ Update the redis.submodule in the redislite repo to the latest stable version """ import os import pathlib import shutil import urllib.request import tarfile import tempfile redis_version = os.environ.get('REDIS_VERSION', '6.2.7') url = f'http://download.redis.io/releases/redis-{redis_versi...
34
34
85
14
278
python
[{"finding_id": "codeql_py/tarslip_ec3f0366e98d4a09_7d5f45f1", "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)." ]
[ 25 ]
[ null ]
[ 9 ]
[ 11 ]
2024-11-19T03:35:46.317120+00:00
1,601,503,867,000
f49ccb028097abc42c0f966dcaa06803bfcaacae
3
{ "blob_id": "f49ccb028097abc42c0f966dcaa06803bfcaacae", "branch_name": "refs/heads/master", "committer_date": 1601503867000, "content_id": "3d10399a77969afb4b95bd345096eb0a977ecdd2", "detected_licenses": [ "MIT" ], "directory_id": "ec83dc3eda5c2672569965304db8e7567746a766", "extension": "py", "fi...
2.8125
stackv2
import re import discord from commanderbot_lib.logging import Logger, get_clogger from discord.ext.commands import Bot, Cog, Context, command class VoteCog(Cog): def __init__(self, bot: Bot): self.bot: Bot = bot self._log: Logger = get_clogger(self) def get_emojis(self, message: discord.Mess...
52
38.1
144
19
656
python
[{"finding_id": "codeql_py/overly-large-range_ca0812b168ba471e_7bfdb43e", "tool_name": "codeql", "rule_id": "py/overly-large-range", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Suspicious character range that overlaps with \\ufffd-\\ufffd in the same character class.", "remediatio...
10
true
[ "CWE-020", "CWE-020", "CWE-020", "CWE-020", "CWE-020", "CWE-020", "CWE-020", "CWE-020", "CWE-020", "CWE-020" ]
[ "py/overly-large-range", "py/overly-large-range", "py/overly-large-range", "py/overly-large-range", "py/overly-large-range", "py/overly-large-range", "py/overly-large-range", "py/overly-large-range", "py/overly-large-range", "py/overly-large-range" ]
[ "HIGH", "HIGH", "HIGH", "HIGH", "HIGH", "HIGH", "HIGH", "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "Suspicious character range that overlaps with \\ufffd-\\ufffd in the same character class.", "Suspicious character range that overlaps with \\ufffd-\\ufffd in the same character class.", "Suspicious character range that overlaps with \\ufffd-\\ufffd in the same character class.", "Suspicious character range ...
[ 18, 18, 18, 18, 18, 18, 18, 19, 19, 19 ]
[ null, null, null, null, null, null, null, null, null, null ]
[ 14, 17, 20, 23, 26, 29, 32, 14, 17, 26 ]
[ 18, 21, 24, 27, 30, 33, 36, 18, 21, 30 ]
2024-11-19T01:28:36.831299+00:00
1,628,332,447,000
bb791def08e7c04f8bca91cf40971d098b828b5c
4
{ "blob_id": "bb791def08e7c04f8bca91cf40971d098b828b5c", "branch_name": "refs/heads/main", "committer_date": 1628332447000, "content_id": "7381ee2414360ff3d63d68b018a167bb7f820cc0", "detected_licenses": [ "Apache-2.0" ], "directory_id": "c92bbec427e20bbf16285fd0f755766ad585839b", "extension": "py", ...
3.578125
stackv2
class Employee: salary = 4000 increment = 1.5 @property def salaryAfterIncrement(self): return self.salary * self.increment @salaryAfterIncrement.setter def salaryAfterIncrement(self,sai): self.increment = sai/self.salary e = Employee() print(e.salary) print(e.increment) # pr...
20
20.35
43
11
103
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_77f8b6d5269db715_8560b023", "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." ]
[ 15, 19 ]
[ null, null ]
[ 7, 7 ]
[ 15, 29 ]
2024-11-19T01:28:43.547738+00:00
1,562,768,425,000
bc8a0597b8b72091ca1955d2108ebff51e0830f1
3
{ "blob_id": "bc8a0597b8b72091ca1955d2108ebff51e0830f1", "branch_name": "refs/heads/master", "committer_date": 1562768425000, "content_id": "06cdd64d7bf9e36b403554c788a82252e9d4e755", "detected_licenses": [ "MIT" ], "directory_id": "0326d9e7bef56924cd6391406d549dca1e394aca", "extension": "py", "fi...
2.5625
stackv2
from werkzeug.routing import BaseConverter from flask import Flask, request app = Flask(__name__) # # request接收参数分为两种 # 01 路径拼接 # 1) 参数类型:参数名 eg:int:user_id default int any path float uuid # 2)参数类型(参数限制):参数名称 eg:int(min=1):user_id # 3)自定义 分3步 1 自定义类 regex 正则匹配 2 注册参数 3 装饰器中使用 记住Ba...
43
20.6
79
10
322
python
[{"finding_id": "codeql_py/reflective-xss_da7be61e7e8b72cd_bc81234f", "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)." ]
[ 25 ]
[ null ]
[ 12 ]
[ 40 ]
2024-11-19T01:28:47.832320+00:00
1,605,266,164,000
0519b965b0cb26d390ad7581a8ee298d5fa92301
3
{ "blob_id": "0519b965b0cb26d390ad7581a8ee298d5fa92301", "branch_name": "refs/heads/main", "committer_date": 1605266164000, "content_id": "2a842570a7d5ad04251de60a4d0393992bb56627", "detected_licenses": [ "MIT" ], "directory_id": "c299475e05667de30f016bf666449f5ad8738e5d", "extension": "py", "file...
2.546875
stackv2
from google.cloud import automl from flask import Flask, request import json app=Flask(__name__) @app.route ("/sentiment", methods=['POST']) def predictSentiment(): try: json_data = request.get_json(force=True) project_id = json_data["project_id"] model_id = json_data["model_id"] s...
28
39.64
107
15
256
python
[{"finding_id": "codeql_py/stack-trace-exposure_34fc181a26f43125_5ac4c2c0", "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." ]
[ 25 ]
[ null ]
[ 14 ]
[ 31 ]
2024-11-19T01:28:52.549596+00:00
1,675,884,890,000
a6979b831f916571d41cd91d4dd03fa20056d6bb
3
{ "blob_id": "a6979b831f916571d41cd91d4dd03fa20056d6bb", "branch_name": "refs/heads/master", "committer_date": 1675884890000, "content_id": "c2333d4232b169b330b62c118a17759d59a36e7f", "detected_licenses": [ "Apache-2.0" ], "directory_id": "30b06187f8c6f30de84b8a93f24bce5562afa947", "extension": "py"...
2.59375
stackv2
import json import requests def login_os(data, url): username = data['user'] password = data['password'] params = {'userName': username, 'password': password} proxies = {'http': None, 'https': None} url_login = url + "login-sessions" response = requests.post(url_login, verify=False, data=json...
30
31.67
106
12
238
python
[{"finding_id": "codeql_py/request-without-cert-validation_670e425c4852e4cc_9a5964e8", "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)." ]
[ 12, 26 ]
[ null, null ]
[ 16, 9 ]
[ 107, 83 ]
2024-11-19T01:28:54.354314+00:00
1,590,123,989,000
fbd5b5281873ad227b66ede15fe60a9eb0089917
4
{ "blob_id": "fbd5b5281873ad227b66ede15fe60a9eb0089917", "branch_name": "refs/heads/master", "committer_date": 1590123989000, "content_id": "93848d039fad60bff0d124316ef810312714e4e7", "detected_licenses": [ "Apache-2.0" ], "directory_id": "a2fe63284ba6b33e72fb1cf98e59f175221d4d52", "extension": "py"...
4.5
stackv2
# -*- coding: UTF-8 -*- ''' 在Class内部,可以有属性和方法,而外部代码可以通过直接调用实例变量的方法来操作数据,这样就隐藏了内部的复杂逻辑,但是,从前面Student类的定义来看, 外部代码还是可以自由地修改一个实例的name score属性 ''' class Student(object): def __init__(self,name,score): self.name = name self.score = score s1 = Student(name="carey",score=99) print(s1.score) s1.score...
52
17.06
83
9
334
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_e7695d621fa64e3d_9cded3fc", "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." ]
[ 52 ]
[ null ]
[ 7 ]
[ 22 ]
2024-11-19T01:29:08.190116+00:00
1,528,469,253,000
99cf61821e2592d14846f879558dad19d70760da
2
{ "blob_id": "99cf61821e2592d14846f879558dad19d70760da", "branch_name": "refs/heads/master", "committer_date": 1528469253000, "content_id": "efc57dd23d06e02b2ad72717a69853490a9dba45", "detected_licenses": [ "MIT" ], "directory_id": "d6254d3a0996d7977816c167bc2af76677a52b87", "extension": "py", "fi...
2.5
stackv2
#! /usr/bin/env python from jinja2 import Environment, FileSystemLoader import begin env = Environment(loader=FileSystemLoader('.')) redis_conf = [] @begin.start def main(N): N = int(N) for i in range(N): redis = {} redis['i'] = i+1 redis['port'] = 7000+i redis['host'] = 'redis...
18
25.33
58
12
124
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_8b6fbfecffb3adbd_2369830e", "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." ]
[ 4 ]
[ null ]
[ 7 ]
[ 48 ]
2024-11-19T01:29:20.331023+00:00
1,633,024,898,000
798e8f3eeddba3513db11a42926f22e04938c853
3
{ "blob_id": "798e8f3eeddba3513db11a42926f22e04938c853", "branch_name": "refs/heads/main", "committer_date": 1633024898000, "content_id": "41524236577ffbc75fec842e96ad4fa6754afbb9", "detected_licenses": [ "MIT" ], "directory_id": "842cf2210f595edb6dd4af364a0be872130cdf75", "extension": "py", "file...
2.5625
stackv2
# ---------------------------------- # This sample shows how to connect to twitter Rest API using OAuth 1 # Python and Flask framework # Code by Fernando Matsuo Santos # Date: 2016/04/11 # ---------------------------------- import requests, json, unicodedata, re import logging from logging.handlers import RotatingFileH...
171
30.42
97
14
1,352
python
[{"finding_id": "codeql_py/flask-debug_edb3e897a7e0d932_144fe50f", "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-117" ]
[ "py/flask-debug", "py/partial-ssrf", "py/log-injection" ]
[ "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.", "Part of the URL of this request depends on a [user-provided value](1).", "This log entry depends on a [user-provided value](1)." ]
[ 171, 88, 148 ]
[ null, null, null ]
[ 5, 13, 42 ]
[ 35, 30, 54 ]
2024-11-19T01:29:21.134090+00:00
1,499,934,906,000
3fb099e7bce20b55e6f06e56b97929f984a1e013
2
{ "blob_id": "3fb099e7bce20b55e6f06e56b97929f984a1e013", "branch_name": "refs/heads/master", "committer_date": 1499934906000, "content_id": "777cb6fea93049c823b8a11221e27e2fddae0d7b", "detected_licenses": [ "MIT" ], "directory_id": "1544ecf835c15b28ad6f759a2412fbe9b8d4a4bf", "extension": "py", "fi...
2.328125
stackv2
file = open("oksp/settings/conf.py","w") comment = "\"\"\"\n"; file.write(comment) file.write("Configuration file for settings\n") file.write(comment) print ("\n---------------------------------------\n") print("We are by default going to allow all hosts to access the files, you can change this by updating the ALLOWED...
41
31.83
147
13
333
python
[{"finding_id": "codeql_py/clear-text-storage-sensitive-data_855e981da39f0c7c_5bc7b10d", "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 (password)](2) as clear text." ]
[ 37 ]
[ null ]
[ 12 ]
[ 18 ]
2024-11-19T01:29:22.325148+00:00
1,654,779,010,000
8783ea2708cb057ef69f4670b3e8348572b85faf
3
{ "blob_id": "8783ea2708cb057ef69f4670b3e8348572b85faf", "branch_name": "refs/heads/master", "committer_date": 1654779010000, "content_id": "02976008af6f635112e74275af7675a918701187", "detected_licenses": [ "Apache-2.0" ], "directory_id": "facfb720e1e98255e285524e135e62d6efbc9b35", "extension": "py"...
2.828125
stackv2
#!/usr/bin/python # GenerateEncryptedString method derived from https://github.com/jamfit/Encrypted-Script-Parameters # Python wrapper for 'openssl' to create an encrypted Base64 string for script parameters # Additional layer of security when passing account credentials from the JSS to a client import subprocess imp...
89
33.1
157
14
815
python
[{"finding_id": "codeql_py/clear-text-storage-sensitive-data_f8c82f75ba111d7e_399868a3", "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." ]
[ 33 ]
[ null ]
[ 26 ]
[ 36 ]
2024-11-19T01:29:28.900226+00:00
1,574,607,004,000
9c8e4d81f2f97d9b4c8d7c277841b163f8e22501
3
{ "blob_id": "9c8e4d81f2f97d9b4c8d7c277841b163f8e22501", "branch_name": "refs/heads/master", "committer_date": 1574607004000, "content_id": "998744046d6f9e3bcfe719bb54203fccd6223a86", "detected_licenses": [ "Apache-2.0" ], "directory_id": "676dfc66fb21524827373b44139b2563dcc1f583", "extension": "py"...
2.796875
stackv2
import socket import re import sys def connection(ip,user,passw): sock = socket.socket(socket.AF_INET,socket.SOCK_STREAM) print('Trying'+ ip+ ':' + user + ":" +passw) sock.connect(('192.168.1.25',111)) data = sock.recv(1024) sock.send('User' + user * '\r\n') data = sock.recv(1024) so...
32
19.16
88
13
213
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_e8d2c88987f31c5c_13dbeb67", "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." ]
[ 9 ]
[ null ]
[ 11 ]
[ 48 ]
2024-11-19T01:29:57.701341+00:00
1,565,640,876,000
1c5125f5cf3f26873713cba2199c280215ddcc16
3
{ "blob_id": "1c5125f5cf3f26873713cba2199c280215ddcc16", "branch_name": "refs/heads/master", "committer_date": 1565640876000, "content_id": "0f21d0925629d85b245816c2492a1a2c113f4722", "detected_licenses": [ "MIT" ], "directory_id": "7fe9402027c0b06b4fec862130f471ca0b3b0b36", "extension": "py", "fi...
2.546875
stackv2
import subprocess import os def gh_deploy(config): if not os.path.exists('.git'): print 'Cannot deploy - this directory does not appear to be a git repository' return print "Copying '%s' to `gh-pages` branch and pushing to GitHub." % config['site_dir'] try: subprocess.check_call(['...
27
32.78
89
14
233
python
[{"finding_id": "codeql_py/incomplete-url-substring-sanitization_6965e104ad3e7d2c_79ae834c", "tool_name": "codeql", "rule_id": "py/incomplete-url-substring-sanitization", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "The string [github.com/](1) may be at an arbitrary position in the...
1
true
[ "CWE-020" ]
[ "py/incomplete-url-substring-sanitization" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "The string [github.com/](1) may be at an arbitrary position in the sanitized URL." ]
[ 19 ]
[ null ]
[ 8 ]
[ 28 ]
2024-11-19T01:54:54.616313+00:00
1,691,319,694,000
156156046095845e7231e18dda94795d22986702
2
{ "blob_id": "156156046095845e7231e18dda94795d22986702", "branch_name": "refs/heads/master", "committer_date": 1691319694000, "content_id": "a230305f2f3d81a79c0e77adfa486fc2e3081727", "detected_licenses": [ "MIT" ], "directory_id": "689f2e1ba92e86252445fae375289af17ff14896", "extension": "py", "fi...
2.46875
stackv2
from strictyaml import load from git import Repo import jinja2 from collections import OrderedDict from templex import Templex from pathquery import pathquery from path import Path import difflib import mimetypes CHANGELOG_MD_TEMPLATE = """\ # Changelog {% for version, changes in version_changes.items() %} ### {% if ...
173
32.4
95
24
1,249
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_650d8aa599dba6f2_7120e1d6", "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." ]
[ 49 ]
[ null ]
[ 9 ]
[ 47 ]
2024-11-19T01:55:03.306428+00:00
1,538,387,806,000
0f0b3b406e67851dd42779fec2ed9b5ad4d59fdc
4
{ "blob_id": "0f0b3b406e67851dd42779fec2ed9b5ad4d59fdc", "branch_name": "refs/heads/master", "committer_date": 1538387806000, "content_id": "635309659b772c53e5837a65de9525910c2ca1ef", "detected_licenses": [ "MIT" ], "directory_id": "d8f6e7d4eefb237aa0b3817e44f66c7fd5da0d97", "extension": "py", "fi...
3.5
stackv2
"""Fetch weather information Usage: weather (-h | --help) weather [--country=COUNTRY] <city> Options: -h, --help Show a brief usage summary. --country=COUNTRY Restrict cities to an ISO 3166 country code. An OpenWeatherMap API key MUST be provided via the OPENWEATHERMAP_KEY environment variable. """ ...
50
27.14
119
15
371
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_9389c5542b904403_919f28a5", "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." ]
[ 50 ]
[ null ]
[ 11 ]
[ 119 ]
2024-11-19T01:55:07.154079+00:00
1,547,508,368,000
4872fab3694449ddd45ab576cd91b80784b7f6b6
2
{ "blob_id": "4872fab3694449ddd45ab576cd91b80784b7f6b6", "branch_name": "refs/heads/master", "committer_date": 1547508368000, "content_id": "d7d93a3ff407dc37e74f9aa6b45bbe74528e968b", "detected_licenses": [ "MIT" ], "directory_id": "6aa7c110fc8a15c38837cc4f2c8aa840b70546ec", "extension": "py", "fi...
2.46875
stackv2
# [START app] import logging import json import os from flask import Flask, request from sklearn.externals import joblib MODEL_EXT = None MODEL_NEU = None MODEL_AGR = None MODEL_CON = None MODEL_OPN = None app = Flask(__name__) @app.before_first_request def _load_model(): global MODEL_EXT, MODEL_NEU, MODEL_AGR...
90
29.99
114
15
763
python
[{"finding_id": "codeql_py/flask-debug_a3ea9582243d11e9_9398624d", "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-117" ]
[ "py/flask-debug", "py/log-injection" ]
[ "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 log entry depends on a [user-provided value](1)." ]
[ 89, 46 ]
[ null, null ]
[ 5, 21 ]
[ 53, 25 ]
2024-11-19T01:55:07.326313+00:00
1,613,960,928,000
952bc0456e845f59f41104436a3495f3636c3683
3
{ "blob_id": "952bc0456e845f59f41104436a3495f3636c3683", "branch_name": "refs/heads/main", "committer_date": 1613960928000, "content_id": "a3a7c1a6753d21a7f72eeb55163edfff545ea678", "detected_licenses": [ "Unlicense" ], "directory_id": "04779b1d2390faad5686ccc619995975b8525b92", "extension": "py", ...
3.078125
stackv2
import duolingo import logging from typing import Tuple def login(user: str, password: str) -> duolingo.Duolingo: lingo = duolingo.Duolingo(user, password) return lingo def creds() -> Tuple[str, str]: import os user: str = os.environ['USER'] password: str = os.environ['PASS'] return user,...
32
15.06
57
9
142
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_d156ca55b6942421_99c8cc81", "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." ]
[ 25 ]
[ null ]
[ 19 ]
[ 20 ]
2024-11-19T01:55:14.859294+00:00
1,565,669,307,000
9c084dc3daa78ad6af9bdcd1e6a804d8d3cc22b3
3
{ "blob_id": "9c084dc3daa78ad6af9bdcd1e6a804d8d3cc22b3", "branch_name": "refs/heads/master", "committer_date": 1565669307000, "content_id": "e733fea9977fc77c635e0db8dff6a2be5cb709cc", "detected_licenses": [ "MIT" ], "directory_id": "e93a758f31b4b2d39fcc2be59efd2e5980cb7477", "extension": "py", "fi...
3.421875
stackv2
# -------------- #Header files import pandas as pd import numpy as np import matplotlib.pyplot as plt #path of the data file- path data= pd.read_csv(path) data.Gender.replace('-','Agender',inplace=True) gender_count=data.Gender.value_counts() print(gender_count) gender_count.plot(kind='bar') #Code starts here ...
79
17.51
59
10
402
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_81f1561dc74b9611_c44d3c67", "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." ]
[ 12 ]
[ null ]
[ 7 ]
[ 19 ]
2024-11-19T01:55:23.722853+00:00
1,514,369,452,000
bcfad320c943ae3ecb200ce65aa45947771cf30a
4
{ "blob_id": "bcfad320c943ae3ecb200ce65aa45947771cf30a", "branch_name": "refs/heads/master", "committer_date": 1514369452000, "content_id": "a36607492e2b351614cb8d4cc7633bd6ccd58edd", "detected_licenses": [ "Apache-2.0" ], "directory_id": "f13a73ccd692620486c86e0c03db9a5a8a4673be", "extension": "py"...
4.125
stackv2
def greet_user(isim): print("merhaba "+str(isim)+"!") greet_user("ali") def greet_user_fullname(firstname,lastname): print("Hello "+firstname+" "+lastname) greet_user_fullname("cemal ","süreyya") def user_dob(day, month, year): return str(day)+':'+str(month)+":"+str(year) birthday = user_dob(day=12, yea...
34
29.79
118
13
271
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_5ac7d8063728607c_88f76463", "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." ]
[ 14 ]
[ null ]
[ 7 ]
[ 15 ]
2024-11-19T01:55:30.695667+00:00
1,563,158,549,000
02a5eb5f66a6ad12da09d0e4c65a5181910cc605
3
{ "blob_id": "02a5eb5f66a6ad12da09d0e4c65a5181910cc605", "branch_name": "refs/heads/master", "committer_date": 1563158549000, "content_id": "07e9cfc9ba557186a2103127f974388e69d6ce3d", "detected_licenses": [ "MIT" ], "directory_id": "15bdda6d371e9da24f7a905d2bac14d2b049d601", "extension": "py", "fi...
2.921875
stackv2
import nltk import string import numpy as np nltk.download('averaged_perceptron_tagger') nltk.download('punkt') nltk.download('universal_tagset') with open('volo.txt') as f: book = f.read() tokenizer = nltk.tokenize.TweetTokenizer() def get_line_breaks(text): # uphold line breaks lines = nltk.line_tokenize...
113
29.26
103
16
932
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_cbc2ea09b9530553_a99874e0", "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 (secret)](1) as clear text.", "r...
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 (secret)](1) as clear text.", "This expression logs [sensitive data (secret)](1) as clear text." ]
[ 69, 73 ]
[ null, null ]
[ 11, 11 ]
[ 18, 18 ]
2024-11-19T02:06:55.037245+00:00
1,520,185,350,000
582758adab7e126098f6eec9b72cf4ea77d48e72
3
{ "blob_id": "582758adab7e126098f6eec9b72cf4ea77d48e72", "branch_name": "refs/heads/master", "committer_date": 1520185350000, "content_id": "c497d343457b84b19d4c10bf1c9b6cb650eb6af6", "detected_licenses": [ "MIT" ], "directory_id": "ca28a7a8707386d3e1e3d3cc671fb775fa92a3c0", "extension": "py", "fi...
2.765625
stackv2
from flask import Flask, request from keras.models import load_model from urllib.request import urlopen import numpy as np import cv2 from keras.preprocessing.image import img_to_array app = Flask(__name__) model = load_model('cat_not_cat.h5') @app.route('/predict', methods=['GET']) def predict(): url = request.a...
38
26.53
67
16
305
python
[{"finding_id": "codeql_py/full-ssrf_fd380a01d3b8f17a_87be6514", "tool_name": "codeql", "rule_id": "py/full-ssrf", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "The full URL of this request depends on a [user-provided value](1).", "remediation": "", "location": {"file_path": "u...
2
true
[ "CWE-918", "CWE-079" ]
[ "py/full-ssrf", "py/reflective-xss" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "The full URL of this request depends on a [user-provided value](1).", "Cross-site scripting vulnerability due to a [user-provided value](1)." ]
[ 14, 35 ]
[ null, null ]
[ 11, 12 ]
[ 23, 32 ]
2024-11-19T02:07:13.624664+00:00
1,601,025,581,000
106265595f681a30925d7a77bae68857878e1af5
3
{ "blob_id": "106265595f681a30925d7a77bae68857878e1af5", "branch_name": "refs/heads/master", "committer_date": 1601025581000, "content_id": "87ae5851a6b0dbace2feeadd44320200f752276e", "detected_licenses": [ "MIT" ], "directory_id": "43093da92d0f887b4596461fb3d8c3d652c8698e", "extension": "py", "fi...
2.578125
stackv2
# -*- coding: utf-8 -*- """Public section, including homepage and signup.""" from flask import ( Blueprint, current_app, flash, redirect, render_template, request, url_for, ) from flask_login import login_required, login_user, logout_user from virtual_island.extensions import login_manager ...
98
32.06
110
18
670
python
[{"finding_id": "codeql_py/url-redirection_afe0e3ed164962e0_c9561886", "tool_name": "codeql", "rule_id": "py/url-redirection", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "Untrusted URL redirection depends on a [user-provided value](1).", "remediation": "", "location": {"file_...
1
true
[ "CWE-601" ]
[ "py/url-redirection" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "Untrusted URL redirection depends on a [user-provided value](1)." ]
[ 42 ]
[ null ]
[ 29 ]
[ 41 ]
2024-11-19T02:07:15.563911+00:00
1,524,627,659,000
50ac96ab80768609f1ec718a8974748b156d9c00
3
{ "blob_id": "50ac96ab80768609f1ec718a8974748b156d9c00", "branch_name": "refs/heads/master", "committer_date": 1524627659000, "content_id": "77111c52a27982579afa3e599e6c5ab882c2b9db", "detected_licenses": [ "MIT" ], "directory_id": "49201a80ee7cf00997861a45375de58e18e59a1c", "extension": "py", "fi...
3.140625
stackv2
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Fri Mar 23 00:38:05 2018 @author: Tadman Reis """ from nltk.classify import NaiveBayesClassifier import pandas as pd import re def _word_feats(words): return dict([(word, True) for word in words]) def _clean_sentence(sentence): sentence = sentenc...
60
26.05
95
14
418
python
[{"finding_id": "codeql_py/overly-large-range_33f1cd1141345ef8_590aa6bf", "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 overlaps with A-Z in ...
2
true
[ "CWE-020", "CWE-020" ]
[ "py/overly-large-range", "py/overly-large-range" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "Suspicious character range that overlaps with 0-9 in the same character class, and overlaps with A-Z in the same character class, and overlaps with a-z in the same character class, and is equivalent to \\[0-9:;<=>?@A-Z\\\\[\\\\\\\\]^_`a-z{{|}}~\\u007f\\u0080\\u0081\\u....", "Suspicious character range that overl...
[ 18, 18 ]
[ null, null ]
[ 47, 70 ]
[ 50, 73 ]
2024-11-19T02:31:41.652585+00:00
1,563,235,710,000
8b542a58de56cac4de97a80b1a0228c4609e37fb
2
{ "blob_id": "8b542a58de56cac4de97a80b1a0228c4609e37fb", "branch_name": "refs/heads/master", "committer_date": 1563235710000, "content_id": "4791dc2be98af7e9394a7a25b4b2693000a481da", "detected_licenses": [ "BSD-3-Clause" ], "directory_id": "b068da3b26c1359e6394dc96e88cbab142014120", "extension": "p...
2.4375
stackv2
""" Utility script to get data block placement of a hdfs file and plot it """ import os import random import paramiko from datetime import datetime import time import re from collections import Counter import matplotlib.pyplot as plt import run_experiments import socket import plot_one_experiment import numpy as np ...
141
35.36
132
18
1,282
python
[{"finding_id": "codeql_py/paramiko-missing-host-key-validation_0b616a6cae183229_df2f977d", "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." ]
[ 34 ]
[ null ]
[ 5 ]
[ 65 ]
2024-11-19T02:32:21.552311+00:00
1,418,817,142,000
fefd03a12f3190fce6484e62d64445c5aa2053fd
3
{ "blob_id": "fefd03a12f3190fce6484e62d64445c5aa2053fd", "branch_name": "refs/heads/master", "committer_date": 1418817142000, "content_id": "eb68b970fb0d7dc60d2d3c4980ee1c8f2fed5733", "detected_licenses": [ "MIT" ], "directory_id": "b6ed94e1cb209d33c60b4d9c5fc46e36c73b775e", "extension": "py", "fi...
2.5625
stackv2
''' Created on Jun 15, 2014 @author: sscepano ''' ########################################################################################################### ### computes how many people per home subpref & how many of them commute and saves to output files ##############################################################...
59
34.81
113
16
537
python
[{"finding_id": "codeql_py/clear-text-storage-sensitive-data_6ef6c3ffdb219927_04d85f9a", "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 (private)](1) as clear text.",...
2
true
[ "CWE-312", "CWE-312" ]
[ "py/clear-text-storage-sensitive-data", "py/clear-text-storage-sensitive-data" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "This expression stores [sensitive data (private)](1) as clear text.", "This expression stores [sensitive data (private)](1) as clear text.\nThis expression stores [sensitive data (private)](2) as clear text." ]
[ 34, 35 ]
[ null, null ]
[ 18, 18 ]
[ 68, 107 ]
2024-11-19T02:32:56.606887+00:00
1,622,625,078,000
5634e0ce95965f4e9e3ae21b8b39a4caab55e19f
4
{ "blob_id": "5634e0ce95965f4e9e3ae21b8b39a4caab55e19f", "branch_name": "refs/heads/master", "committer_date": 1622625078000, "content_id": "d2df13d81f6270f634568321353e7788fefc2d3d", "detected_licenses": [ "MIT" ], "directory_id": "f117d31ece12b25afe7182e0546f63f49a1a88d2", "extension": "py", "fi...
3.78125
stackv2
class Emp: leaves = 10 def __init__(self, new_args_name, new_args_salary, new_args_role): # Constructor function self.name = new_args_name self.salary = new_args_salary self.role = new_args_role def print_details(self): return f"\nName is {self.name}. \nSallary is {...
40
33.67
137
12
379
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_39e11eaa16c97852_b89533a4", "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." ]
[ 40 ]
[ null ]
[ 7 ]
[ 20 ]
2024-11-19T02:33:05.698542+00:00
1,638,921,811,000
20474e57cb8e913d9359439640ac9c08fd66bfaf
4
{ "blob_id": "20474e57cb8e913d9359439640ac9c08fd66bfaf", "branch_name": "refs/heads/main", "committer_date": 1638921811000, "content_id": "0d3d9e51185e834be8dbdeefdc76ed2edbad6b37", "detected_licenses": [ "MIT" ], "directory_id": "6eed04ffd48f5ea5ccb2c4052783710d35c277f2", "extension": "py", "file...
3.5
stackv2
def main() -> None: with open("day-4.in", "r") as input_file: min_password, max_password = (int(x) for x in input_file.readline().split("-")) valid_password_count = 0 for password in range(min_password, max_password): password = str(password) if password == ''.join(sorted(password))...
20
30.55
87
14
171
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_8f45a77c0f9e9f70_21ea0910", "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." ]
[ 11 ]
[ null ]
[ 11 ]
[ 31 ]
2024-11-19T02:43:29.593233+00:00
1,581,862,962,000
3c929cd162a1dd71952c0b8a74a38469e032d2ed
3
{ "blob_id": "3c929cd162a1dd71952c0b8a74a38469e032d2ed", "branch_name": "refs/heads/master", "committer_date": 1582389162000, "content_id": "1c6ab3b07300338021d75164214da54822f30cb0", "detected_licenses": [ "MIT" ], "directory_id": "76acbc606ac6412d7e5692c2a93d97eefbedea64", "extension": "py", "fi...
2.828125
stackv2
#!/usr/bin/env python import OpenSSL.crypto as crypto import click import socket import ssl from datetime import datetime from prettytable import PrettyTable pt = PrettyTable() pt.field_names = [ "Host", "Common Name", "NotBefore", "NotAfter", "Issuer", ] pt.align = "l" def expiration_check(ta...
65
18.72
68
14
322
python
[{"finding_id": "codeql_py/insecure-protocol_ff2b2ee9dfc5e2cd_47395569", "tool_name": "codeql", "rule_id": "py/insecure-protocol", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Insecure SSL/TLS protocol version TLSv1 allowed by [call to ssl.create_default_context](1).\nInsecure SSL/...
1
true
[ "CWE-327" ]
[ "py/insecure-protocol" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "Insecure SSL/TLS protocol version TLSv1 allowed by [call to ssl.create_default_context](1).\nInsecure SSL/TLS protocol version TLSv1_1 allowed by [call to ssl.create_default_context](1)." ]
[ 25 ]
[ null ]
[ 12 ]
[ 15 ]
2024-11-19T02:43:35.772906+00:00
1,536,262,558,000
88fd6db7d497940e3dd01c445387609985d7b90a
3
{ "blob_id": "88fd6db7d497940e3dd01c445387609985d7b90a", "branch_name": "refs/heads/master", "committer_date": 1536262558000, "content_id": "d1708186efdaf930249821aed0ed78e7ac34d224", "detected_licenses": [ "MIT" ], "directory_id": "bad9ed7d149372afb5020531297826ac2dcf6665", "extension": "py", "fi...
2.75
stackv2
# -*- coding: utf-8 -*- """ Created on Tue Oct 24 17:02:15 2017 abstract tumer info from file @author: Student """ import re import csv with open('bigwig_file.txt') as f: content = f.readlines() regexPattern = '[A-Z0-9]*_[A-Z0-9]*_[A-Z0-9]*_(?P<Gender>[fe]*male)_(?P<Tissue>[\w]*)(.)?(?P<SubTissue>[\w.]*).bw' p...
101
24.81
114
15
730
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_f42597c07608948d_97c3af68", "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." ]
[ 83 ]
[ null ]
[ 7 ]
[ 19 ]
2024-11-19T02:55:04.107476+00:00
1,631,600,641,000
2f74b49d38658ecc9e5e5c6336a68ba42ae6cbcb
3
{ "blob_id": "2f74b49d38658ecc9e5e5c6336a68ba42ae6cbcb", "branch_name": "refs/heads/main", "committer_date": 1631600641000, "content_id": "3e86c8919de62b7badcda95611637bde68694e12", "detected_licenses": [ "MIT" ], "directory_id": "b1d73720d2c5e412d8dbaf20fa28226d14c110c3", "extension": "py", "file...
2.578125
stackv2
""" Ref: - https://en.wikipedia.org/wiki/Basic_access_authentication - https://en.wikipedia.org/wiki/Digest_access_authentication - https://datatracker.ietf.org/doc/html/rfc2617 - https://datatracker.ietf.org/doc/html/rfc7616 - https://datatracker.ietf.org/doc/html/rfc7617 - https://developer.mozilla.org/zh-CN/docs/Web...
392
32.72
87
22
2,977
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_03f3f70dbd4f65c1_a6896735", "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...
2
true
[ "CWE-327", "CWE-327" ]
[ "py/weak-sensitive-data-hashing", "py/weak-sensitive-data-hashing" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "[Sensitive data (secret)](1) is used in a hashing algorithm (MD5) that is insecure.", "[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 algorit...
[ 177, 200 ]
[ null, null ]
[ 20, 20 ]
[ 75, 50 ]
2024-11-19T02:55:08.698761+00:00
1,612,592,571,000
15840ae626613daf2118a4926c2d7dfcf6503d49
2
{ "blob_id": "15840ae626613daf2118a4926c2d7dfcf6503d49", "branch_name": "refs/heads/main", "committer_date": 1612592571000, "content_id": "1ac066ac7fe2a2b36ec212672702b70fbaf86fe0", "detected_licenses": [ "MIT" ], "directory_id": "53fe4483b847aa2df3d531aab37cbbc9c9b1b55d", "extension": "py", "file...
2.421875
stackv2
from datetime import datetime from flask import Flask, request, render_template import flask import flask_login import hashlib import redis import toml config = toml.loads( open("config.toml", "r").read() ) auth_dict = toml.loads( open("auth.toml", "r").read() ) admins = auth_dict['admin'] admin_dict = {} for...
154
24.36
127
18
929
python
[{"finding_id": "codeql_py/flask-debug_0606353495aee610_7ed14f5c", "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-327" ]
[ "py/flask-debug", "py/weak-sensitive-data-hashing" ]
[ "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.", "[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 (passwor...
[ 150, 123 ]
[ 154, null ]
[ 5, 61 ]
[ 6, 78 ]
2024-11-19T02:55:20.086235+00:00
1,505,867,280,000
e43099acbf14a8a73a14a855844d2729d5df6884
2
{ "blob_id": "e43099acbf14a8a73a14a855844d2729d5df6884", "branch_name": "refs/heads/master", "committer_date": 1505867280000, "content_id": "4af83f31ab8f1f36b2f57915539d32d02554d0e0", "detected_licenses": [ "MIT" ], "directory_id": "3136a68b323caee95eace5426e2ed341ea9cc1a1", "extension": "py", "fi...
2.328125
stackv2
""" This pipeline populates fct_players_stats table, this is a daily process that grabs all the uploads that happened since the last run and aggregates on a daily, player, hero, map and gametype level. The metrics that are aggregated are coming from the generalstats table. """ from airflow import DAG from airflow.ope...
190
36.96
110
12
1,963
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_741709f044f60a47_94287f6d", "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...
2
true
[ "CWE-079", "CWE-079" ]
[ "py/jinja2/autoescape-false", "py/jinja2/autoescape-false" ]
[ "MEDIUM", "MEDIUM" ]
[ "MEDIUM", "MEDIUM" ]
[ "Using jinja2 templates with autoescape=False can potentially allow XSS attacks.", "Using jinja2 templates with autoescape=False can potentially allow XSS attacks." ]
[ 40, 72 ]
[ 63, 179 ]
[ 9, 9 ]
[ 9, 9 ]
2024-11-19T03:10:21.670353+00:00
1,444,380,700,000
b0e0f2a79bae2fba3930b9ead5413cd7f5f38a9a
2
{ "blob_id": "b0e0f2a79bae2fba3930b9ead5413cd7f5f38a9a", "branch_name": "refs/heads/master", "committer_date": 1444380700000, "content_id": "7265301ce1e82f36b4e370e06fc466a6a50a469b", "detected_licenses": [ "MIT" ], "directory_id": "ddf1f909d1d1b10b77f759079b230a5db10753e0", "extension": "py", "fi...
2.390625
stackv2
#!/usr/bin/env python import ConfigParser import logging import os import re import sys import argparse new_path = [ os.path.join( os.getcwd(), "lib" ) ] new_path.extend( sys.path[1:] ) sys.path = new_path from galaxy import eggs eggs.require( "SQLAlchemy >= 0.4" ) eggs.require( 'mercurial' ) import galaxy.config ...
209
31.54
111
16
1,490
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_ff482005a09f164f_0fc720c6", "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.\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 (p...
[ 78, 88 ]
[ null, 89 ]
[ 23, 19 ]
[ 38, 68 ]
2024-11-19T03:10:29.339824+00:00
1,604,544,015,000
6a19c85131965ab660fbfd78b477e68e36452088
2
{ "blob_id": "6a19c85131965ab660fbfd78b477e68e36452088", "branch_name": "refs/heads/main", "committer_date": 1604544015000, "content_id": "022fdee37af63ddbc03c2011b03eb4ccdb6d4005", "detected_licenses": [ "ISC" ], "directory_id": "a7b58053098040bcb8f7028422858503c17b1bd9", "extension": "py", "file...
2.390625
stackv2
import datetime import os from pathlib import Path import tomlkit import copy import sys import mistune import jinja2 from generators import csv, ics, json, html, stats import election os.makedirs("site", exist_ok=True) states = {} alternatives = [ {"extension": "ics", "name": "https", "generator": ics.generat...
143
33.08
100
16
1,137
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_70aa18919fccd39b_ef510943", "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." ]
[ 32 ]
[ null ]
[ 7 ]
[ 70 ]
2024-11-19T03:10:29.808035+00:00
1,549,675,860,000
a1f044fdad6f6a30913cb2a7b2078e114fbafaca
2
{ "blob_id": "a1f044fdad6f6a30913cb2a7b2078e114fbafaca", "branch_name": "refs/heads/master", "committer_date": 1549675860000, "content_id": "f442e6bf0380f154fa91346083837fe3d8635243", "detected_licenses": [ "MIT" ], "directory_id": "bf8e4d14fa082446a5f4581b91c1991c2d1bfb17", "extension": "py", "fi...
2.4375
stackv2
# -*- coding: utf-8 -*- import os from flask import Flask, request, flash, redirect, render_template, url_for, abort, jsonify try: from urllib.parse import urlparse, urljoin except ImportError: from urlparse import urlparse, urljoin from flask_login import LoginManager, login_user, logout_user, current_user, l...
134
31.51
159
14
1,053
python
[{"finding_id": "codeql_py/url-redirection_d23dbed605dd65ee_a1adde06", "tool_name": "codeql", "rule_id": "py/url-redirection", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "Untrusted URL redirection depends on a [user-provided value](1).", "remediation": "", "location": {"file_...
1
true
[ "CWE-601" ]
[ "py/url-redirection" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "Untrusted URL redirection depends on a [user-provided value](1)." ]
[ 57 ]
[ null ]
[ 25 ]
[ 52 ]
2024-11-19T03:10:37.009605+00:00
1,412,303,071,000
50af54cfbf47a9f839c11d0806f6c8e4759a688a
3
{ "blob_id": "50af54cfbf47a9f839c11d0806f6c8e4759a688a", "branch_name": "refs/heads/master", "committer_date": 1412303071000, "content_id": "73580cb5cf97cf28d29ce9e19021f9ff20191477", "detected_licenses": [ "MIT" ], "directory_id": "c3dd741fafc3a75363f8a4074afcf0e3226db61e", "extension": "py", "fi...
2.625
stackv2
import CommandHandler import FileObject import hashlib import time import json import datetime from google.appengine.ext import ndb # https://cloud.google.com/appengine/docs/python/ndb/ class User(ndb.Model): userid=ndb.StringProperty() password=ndb.StringProperty() token=ndb.StringProperty() ...
120
33.05
86
16
957
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_797ddfb94150b678_984506a2", "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 (id)](2) is used in a hashing algorithm (SHA1) that is insecure." ]
[ 43 ]
[ null ]
[ 28 ]
[ 51 ]
2024-11-19T03:10:52.471091+00:00
1,692,067,034,000
54d4768bf2658833631e171e0a5cc857cc5bb611
3
{ "blob_id": "54d4768bf2658833631e171e0a5cc857cc5bb611", "branch_name": "refs/heads/main", "committer_date": 1692067034000, "content_id": "1bc69c0f55e38a052827090d56a3cf118431e073", "detected_licenses": [ "BSD-2-Clause" ], "directory_id": "73db0789f8f4b6cbc111def56880bd79d03171e5", "extension": "py"...
2.703125
stackv2
import socket import paramiko import threading import logging class _HoneySSHServer(paramiko.ServerInterface): def check_auth_password(self, username, password): logging.info('Username: %s\tPassword: %s', username, password) return paramiko.AUTH_FAILED class HoneySSH(object): def __init__(self, port=220...
53
25.21
68
16
336
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_f5d35117e54f3842_ee47f6d4", "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-200" ]
[ "py/clear-text-logging-sensitive-data", "py/bind-socket-all-network-interfaces" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "This expression logs [sensitive data (password)](1) as clear text.", "'' binds a socket to all interfaces." ]
[ 9, 26 ]
[ null, null ]
[ 58, 5 ]
[ 66, 39 ]
2024-11-19T03:21:48.401904+00:00
1,567,921,109,000
5f9ec2e7ab53c53f593ca1bb9273be000c7332f3
3
{ "blob_id": "5f9ec2e7ab53c53f593ca1bb9273be000c7332f3", "branch_name": "refs/heads/master", "committer_date": 1567921109000, "content_id": "1f099a53b250b1dd94912afb0f05b4d0c6790e14", "detected_licenses": [ "MIT" ], "directory_id": "fb5f99d2b54ee9874909adfac935209e4c74f692", "extension": "py", "fi...
2.671875
stackv2
import os import requests import subprocess import json import re def correctFilename(filename): rep='\/:*?"<>|`' for i in rep: file=filename.replace(i,"") return file def downloadFileByUrl(url,path,filename=None): ''' 从形如http://i2.hdslb.com/bfs/archive/axx.jpg的链接下载文件 ''' if filena...
60
21.62
65
13
367
python
[{"finding_id": "codeql_py/overly-large-range_20557a283b10a2ca_1d29275f", "tool_name": "codeql", "rule_id": "py/overly-large-range", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Suspicious character range that overlaps with a-z in the same character class, and is equivalent to \\[A...
1
true
[ "CWE-020" ]
[ "py/overly-large-range" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "Suspicious character range that overlaps with a-z in the same character class, and is equivalent to \\[A-Z\\\\[\\\\\\\\]^_`a-z\\]." ]
[ 39 ]
[ null ]
[ 29 ]
[ 32 ]
2024-11-19T03:43:51.298331+00:00
1,491,055,761,000
11d83e36c97da390bfa7b61a18718bdec6a34e30
2
{ "blob_id": "11d83e36c97da390bfa7b61a18718bdec6a34e30", "branch_name": "refs/heads/master", "committer_date": 1491055761000, "content_id": "e4a2f107ae091c763d7abcb43a73f25a41794497", "detected_licenses": [ "MIT" ], "directory_id": "5a976deba50005dfd6596cebce447abb1b97f2b0", "extension": "py", "fi...
2.34375
stackv2
#!/usr/bin/env python3 from jinja2 import Environment, FileSystemLoader, meta import configparser import argparse import requests import sys import json parser = argparse.ArgumentParser(description='deploy digital ocean servers') parser.add_argument('-n','--name',help='Server name',type=str , required=True) parser.add_...
125
30.52
106
18
963
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_641ea02e0103e2be_1037b2d2", "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." ]
[ 27 ]
[ null ]
[ 7 ]
[ 77 ]