added
stringlengths
32
32
created
int64
1,236B
1,694B
id
stringlengths
40
40
int_score
int64
2
5
metadata
dict
score
float64
2.31
5.03
source
stringclasses
1 value
text
stringlengths
330
19.3k
num_lines
int64
16
648
avg_line_length
float64
15.5
59.3
max_line_length
int64
37
179
ast_depth
int64
8
38
length
int64
102
3.79k
lang
stringclasses
1 value
sast_codeql_findings
stringlengths
1.11k
276k
sast_codeql_findings_count
int64
1
33
sast_codeql_success
bool
1 class
sast_codeql_error
stringclasses
1 value
cwe_ids
listlengths
1
33
rule_ids
listlengths
1
33
confidences
listlengths
1
33
severities
listlengths
1
33
messages
listlengths
1
33
line_starts
listlengths
1
33
line_ends
listlengths
1
33
column_starts
listlengths
1
33
column_ends
listlengths
1
33
2024-11-18T21:33:33.894628+00:00
1,575,952,349,000
a335a334da80a163f3c7c8f1b065bc83c6d69854
3
{ "blob_id": "a335a334da80a163f3c7c8f1b065bc83c6d69854", "branch_name": "refs/heads/master", "committer_date": 1575952349000, "content_id": "300df7aef26377a9694da73268e25bc32a029de1", "detected_licenses": [ "MIT" ], "directory_id": "3856752238afb7e5ba13fba47b98a0993058e886", "extension": "py", "fi...
2.59375
stackv2
# from flask import import os import tensorflow as tf from flask import Flask, request, url_for, Response from keras.preprocessing.image import ImageDataGenerator, load_img, img_to_array import simplejson as json import numpy as np import argparse import imutils import cv2 import time import uuid import base64 IMG_SHA...
123
25.34
80
18
772
python
[{"finding_id": "codeql_py/path-injection_c1cb51132ee9e1d7_8e790ba1", "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)." ]
[ 99, 106, 106 ]
[ null, null, 107 ]
[ 23, 23, 34 ]
[ 32, 32, 39 ]
2024-11-18T23:15:48.193239+00:00
1,617,171,167,000
671ac8788b75938fbf23c991fbb1be302777f0f2
3
{ "blob_id": "671ac8788b75938fbf23c991fbb1be302777f0f2", "branch_name": "refs/heads/main", "committer_date": 1617171167000, "content_id": "a8a0f0220da0ef0a6f848a3a029a575c1c550064", "detected_licenses": [ "Apache-2.0" ], "directory_id": "9d54da912580023412507eaf049191455c1f83f1", "extension": "py", ...
2.734375
stackv2
#!/usr/bin/env python # -*- coding: utf-8 -*- # author: liwfeng # datetime: 2020/12/1 16:52 # ide: PyCharm import codecs import json import os import random import re import jieba import pandas as pd import numpy as np from configs.path_config import CORPUS_ROOT_PATH def json_data_process(path): index2label,ret...
239
27.47
126
23
1,875
python
[{"finding_id": "codeql_py/overly-large-range_a01748ffc0885e54_e4dd3488", "tool_name": "codeql", "rule_id": "py/overly-large-range", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Suspicious character range that is empty.", "remediation": "", "location": {"file_path": "unknown", "lin...
1
true
[ "CWE-020" ]
[ "py/overly-large-range" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "Suspicious character range that is empty." ]
[ 116 ]
[ null ]
[ 52 ]
[ 55 ]
2024-11-18T23:15:49.054037+00:00
1,458,105,986,000
6ed48da66f29bc554c830941c6cc75aa0a7940eb
3
{ "blob_id": "6ed48da66f29bc554c830941c6cc75aa0a7940eb", "branch_name": "refs/heads/master", "committer_date": 1458105986000, "content_id": "f1b0197803812c7677203baa166a8e972013f79d", "detected_licenses": [ "Apache-2.0" ], "directory_id": "51ad107664220f0b1d6a199b049b9d1227fb1b0c", "extension": "py"...
2.65625
stackv2
#!/usr/bin/env python # -*- coding: utf-8 -*- from flask import Flask, request from docker import Client from docker.utils import kwargs_from_env flask_app = Flask(__name__) # initialising the docker client assuming it's running on mac OS X kwargs = kwargs_from_env() kwargs['tls'].assert_hostname = False docker_clie...
60
31.97
77
11
453
python
[{"finding_id": "codeql_py/flask-debug_c13530e539f1938a_a327aaf9", "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)." ]
[ 60, 27 ]
[ null, 28 ]
[ 5, 16 ]
[ 57, 42 ]
2024-11-18T23:15:49.289639+00:00
1,602,772,452,000
847ba368cb5bc9417489e4bb40ad060075fb73f0
3
{ "blob_id": "847ba368cb5bc9417489e4bb40ad060075fb73f0", "branch_name": "refs/heads/main", "committer_date": 1602772452000, "content_id": "c61aa356fef947b3939ca88af2d6186d2d58b2b7", "detected_licenses": [ "Apache-2.0" ], "directory_id": "28dc453ce81cb939b0096e7379f82f9407ed720d", "extension": "py", ...
2.578125
stackv2
# -*- coding: utf-8 -*- import os import glob import shutil import yaml import click from jinja2 import Template from airflow_dag.__version__ import __version__ @click.group("airflow-dag") @click.version_option(version=__version__) @click.pass_context def cli(*args, **kwargs): """A tool to manage Airflow dags....
71
29.48
99
17
523
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_fe8e449b7fb2cd60_5b85495c", "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." ]
[ 59 ]
[ null ]
[ 20 ]
[ 38 ]
2024-11-18T23:15:54.587011+00:00
1,614,100,099,000
d1dbd7acd8c76f2d195dea456e62a1cc3c732898
3
{ "blob_id": "d1dbd7acd8c76f2d195dea456e62a1cc3c732898", "branch_name": "refs/heads/master", "committer_date": 1614100099000, "content_id": "a39977281a65d3052cdcf8fce283734d6385dbec", "detected_licenses": [ "BSD-3-Clause" ], "directory_id": "8e9c75acfe607524942449eb1e3cbae4679edf0f", "extension": "p...
2.53125
stackv2
import enum import json from target_voice import create_voice, gender_string import api.stt.util class Provider(enum.Enum): GCLOUD = 1 AWS = 2 class Client: def __init__( self, upload_filename, stt_provider=Provider.GCLOUD, translate_provider=Provider.GCLOUD, tts_...
209
31.82
92
15
1,479
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_ed2a3f8d883ab2b9_15aa8950", "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." ]
[ 111 ]
[ null ]
[ 15 ]
[ 64 ]
2024-11-18T22:30:11.675669+00:00
1,564,857,791,000
5fc300ee92d3f90ac216ffc2ad6daab03a25a551
3
{ "blob_id": "5fc300ee92d3f90ac216ffc2ad6daab03a25a551", "branch_name": "refs/heads/master", "committer_date": 1564857791000, "content_id": "281aad8c64921f3cec6fd999dd2a9711e770a603", "detected_licenses": [ "MIT", "Apache-2.0" ], "directory_id": "f4909fa9aa7ef4cf2e187d965d77bb80b5b00330", "exten...
2.515625
stackv2
from sqlalchemy import create_engine, Column, Integer, String, ForeignKey, Boolean from sqlalchemy.ext.declarative import declarative_base from sqlalchemy.orm import relationship, backref, sessionmaker Base = declarative_base() class User(Base): __tablename__ = 'users' id = Column('id', Integer, primary_key=...
119
30.08
103
17
849
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_69bc2f432b6086af_705cae8b", "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." ]
[ 106 ]
[ null ]
[ 26 ]
[ 34 ]
2024-11-18T22:30:14.231687+00:00
1,599,751,171,000
defc0b4cc23eef4739fa873750bcef570acb58a5
2
{ "blob_id": "defc0b4cc23eef4739fa873750bcef570acb58a5", "branch_name": "refs/heads/master", "committer_date": 1599751171000, "content_id": "1fcf1818020706ac411141f9a919e698b2ccca52", "detected_licenses": [ "Apache-2.0" ], "directory_id": "ccf8e9a4cfc6435f664059192ddccd744b2945e4", "extension": "py"...
2.421875
stackv2
from django.shortcuts import render from common.models import Users from datetime import datetime from django.core.paginator import Paginator def index(request, pIndex): ''' 浏览会员信息 ''' # 获取商品类别信息 list = Users.objects.all() # 获取商品信息查询对象 mod = Users.objects mywhere = [] # 定义一个用于存放搜索条件列表 ...
150
26.7
71
13
1,123
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_643777819181caf6_bba401b6", "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...
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 (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 algorithm (MD5) that is insecure for password hashing, since it is not a computationally exp...
[ 63, 143 ]
[ null, null ]
[ 18, 18 ]
[ 66, 66 ]
2024-11-18T22:30:17.443074+00:00
1,550,392,462,000
a12c6b0b17c6c07e763ef10423bac79ee98e1d28
3
{ "blob_id": "a12c6b0b17c6c07e763ef10423bac79ee98e1d28", "branch_name": "refs/heads/master", "committer_date": 1550392462000, "content_id": "061c6160eb73e63a252dfcca464ec4d7eb66944c", "detected_licenses": [ "MIT" ], "directory_id": "68d20f52a5936112c35a2ea23740dcdd892b97a8", "extension": "py", "fi...
2.859375
stackv2
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Simple member database access Connects to the database or emulate a connection Table 'users' expected Check the existence of a member If a member is found then check that he paid his due Manage the coding and decoding of QR Codes (various versions)...
315
44.82
145
21
3,625
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_f5e7241756b8e261_86767476", "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.", "...
3
true
[ "CWE-312", "CWE-327", "CWE-327" ]
[ "py/clear-text-logging-sensitive-data", "py/weak-cryptographic-algorithm", "py/weak-cryptographic-algorithm" ]
[ "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "This expression logs [sensitive data (private)](1) as clear text.", "[The block mode ECB](1) is broken or weak, and should not be used.\n[The cryptographic algorithm DES](2) is broken or weak, and should not be used.", "[The block mode ECB](1) is broken or weak, and should not be used.\n[The cryptographic algo...
[ 309, 172, 207 ]
[ null, null, null ]
[ 26, 37, 47 ]
[ 37, 55, 66 ]
2024-11-18T22:30:21.367617+00:00
1,604,672,991,000
7bc9907095561c1b342adf227280894127750633
3
{ "blob_id": "7bc9907095561c1b342adf227280894127750633", "branch_name": "refs/heads/master", "committer_date": 1604672991000, "content_id": "9f9aa6d3798f277d8792c41a6fca748749ffb398", "detected_licenses": [ "MIT" ], "directory_id": "c8213419b4b03df0a8a14293091d9a14c96fd15c", "extension": "py", "fi...
2.59375
stackv2
# -*- coding: UTF-8 -*- import os import re from requests import get from tqdm import tqdm from src.constants import MSG_ERROR_DOWNLOAD, PATTERN_TS, TMP_DOWNLOAD_PATH, URL_TS def get_ts_urls(content): urls = list() for line in content.split('\n')[::-1]: match = re.match(PATTERN_TS, line) if ...
66
29.79
89
16
478
python
[{"finding_id": "codeql_py/request-without-cert-validation_5178aa7c151ee828_34aa3c9d", "tool_name": "codeql", "rule_id": "py/request-without-cert-validation", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "This request may run without certificate validation because [it is disabled]...
1
true
[ "CWE-295" ]
[ "py/request-without-cert-validation" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "This request may run without certificate validation because [it is disabled](1)." ]
[ 26 ]
[ null ]
[ 24 ]
[ 74 ]
2024-11-18T21:14:10.435499+00:00
1,524,499,146,000
a9097b040b6183efaea5407056e74851cb7a9172
2
{ "blob_id": "a9097b040b6183efaea5407056e74851cb7a9172", "branch_name": "refs/heads/master", "committer_date": 1524499146000, "content_id": "c86d765e064d32cb12ca3e8dc7a8e9449108d251", "detected_licenses": [ "MIT" ], "directory_id": "2e5e87021c888f8f679d4bb0392395683b09b31b", "extension": "py", "fi...
2.40625
stackv2
import requests import logging from django.conf import settings from django.utils import timezone from django.core.management.base import BaseCommand, CommandError from django.contrib.auth.hashers import make_password, check_password logger = logging.getLogger('default') class Command(BaseCommand): help = 'Gener...
20
32.05
81
13
136
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_48bda9675de105ea_b5aa66a0", "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 ]
[ 21 ]
[ 63 ]
2024-11-18T21:14:12.432005+00:00
1,611,040,959,000
7290140593361f7235d7dc73a771b992e1a5102a
3
{ "blob_id": "7290140593361f7235d7dc73a771b992e1a5102a", "branch_name": "refs/heads/master", "committer_date": 1611040959000, "content_id": "17946ca23d438fcdd6b873d6ed7ea92389fcf21a", "detected_licenses": [ "MIT" ], "directory_id": "11af92a40e7943cccbf249ef3dd209889b25ff34", "extension": "py", "fi...
2.578125
stackv2
#!/usr/bin/env python3 # -*- coding: utf-8 -*- import logging import time import hashlib from db_models import UserAuth, UserInfo __author__ = 'Burnell Liu' async def user_cookie_parse(cookie_str, cookie_secret=''): """ 解析用户COOKIE字符串 :param cookie_str: COOKIE字符串 :param cookie_secret: 加密COOKIE的字符串 ...
68
24.63
81
15
473
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_b4d05d8f164f5d75_c8835cd7", "tool_name": "codeql", "rule_id": "py/weak-sensitive-data-hashing", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "[Sensitive data (secret)](1) is used in a hashing algorithm (SHA1) that is insecu...
3
true
[ "CWE-327", "CWE-327", "CWE-327" ]
[ "py/weak-sensitive-data-hashing", "py/weak-sensitive-data-hashing", "py/weak-sensitive-data-hashing" ]
[ "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "[Sensitive data (secret)](1) is used in a hashing algorithm (SHA1) that is insecure.\n[Sensitive data (secret)](2) is used in a hashing algorithm (SHA1) that is insecure.", "[Sensitive data (id)](1) is used in a hashing algorithm (SHA1) that is insecure.\n[Sensitive data (secret)](2) is used in a hashing algorit...
[ 34, 56, 68 ]
[ null, null, null ]
[ 33, 45, 25 ]
[ 50, 68, 48 ]
2024-11-18T21:14:41.068148+00:00
1,429,806,666,000
06c08e670e5a8aeaccb61a9a3cf1488c553a57df
2
{ "blob_id": "06c08e670e5a8aeaccb61a9a3cf1488c553a57df", "branch_name": "refs/heads/master", "committer_date": 1429806666000, "content_id": "aedbf6d0567ec23a82b662a9c6a6fa68c0c95aa6", "detected_licenses": [ "BSD-3-Clause", "MIT" ], "directory_id": "84428ffbc993fe9e4539d695688a63c8f4192afb", "ext...
2.390625
stackv2
import os, re, json import numpy from math import sqrt from .mri import MRI class Widget(object): def __init__(self, fname, categorized): from IPython.core.display import display, Javascript path = os.path.abspath(os.path.join(os.path.dirname(__file__), "template/init_widget.js")) js = open...
67
33.3
98
21
545
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_83e81b7215041272_78c0d104", "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." ]
[ 26 ]
[ null ]
[ 20 ]
[ 47 ]
2024-11-18T21:57:30.330996+00:00
1,530,581,516,000
eebb270e60742e17cbcc1629038d0caaf4e03659
3
{ "blob_id": "eebb270e60742e17cbcc1629038d0caaf4e03659", "branch_name": "refs/heads/master", "committer_date": 1530581516000, "content_id": "12f54d392a6a57f902a283dc3674dfb1c2a7ceee", "detected_licenses": [ "BSD-3-Clause" ], "directory_id": "49d8e4be4ed52cc657ce0ccfca7c97540a3de454", "extension": "p...
3
stackv2
#! /usr/bin/env python3 # # BSD 3-Clause License # Copyright (c) 2018, 'Layer 8, LLC'. All rights reserved. """Read a CSV file and hash the email addresses. This script reads a CSV file, hashes the email addresses using an HMAC (SHA3-256) and then outputs the hashes to another file. The script will output some execu...
161
35.16
79
19
1,316
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_884e2669548f3438_b3a50ac5", "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 (password)](2) as clear text.\nThis expression logs [sensitive data (secret)](3) as clear text.\nThis expression logs [sensitive data (secret)](4) as clear text." ]
[ 130 ]
[ 131 ]
[ 15 ]
[ 39 ]
2024-11-18T21:57:52.049387+00:00
1,635,354,168,000
0766b20c6657a1688b74d3c70587ddf7fdf9c8c2
3
{ "blob_id": "0766b20c6657a1688b74d3c70587ddf7fdf9c8c2", "branch_name": "refs/heads/main", "committer_date": 1635354168000, "content_id": "4c06a26840c8c7f0f9c8506ad02836f6bf3d314e", "detected_licenses": [ "MIT" ], "directory_id": "abbd09cd2487ba36567c423838a723ae342b1f4a", "extension": "py", "file...
2.921875
stackv2
# Importing functions from the class bottle from bottle import run, get, post, request import time import requests import threading def timer(): while True: result = requests.get("http://127.0.0.1:4444") print(result.text) time.sleep(1) @get("/") # Can use same method name because of th...
43
23.91
77
16
305
python
[{"finding_id": "codeql_py/reflective-xss_4e97be24c915ad45_18289783", "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)." ]
[ 37 ]
[ null ]
[ 12 ]
[ 47 ]
2024-11-18T21:58:01.603283+00:00
1,690,775,476,000
76d2b03eb5478af570590a2b61a81cffe9b0a959
3
{ "blob_id": "76d2b03eb5478af570590a2b61a81cffe9b0a959", "branch_name": "refs/heads/master", "committer_date": 1690775476000, "content_id": "90fcb5ed3afc3d2c536cd23161af7d48124838b6", "detected_licenses": [ "BSD-2-Clause" ], "directory_id": "49b861ac5ca3adfe8861a10839b18d9448eb8020", "extension": "p...
2.6875
stackv2
import requests import json # Given a Passport document, extract the passport holder face and convert/parse all Machine Readable Zone # to textual content ready to be consumed by your application. # # PixLab recommend that you connect your AWS S3 bucket via the dashboard at https://pixlab.io/dashboard # so that any ex...
37
47.11
110
12
460
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_e6520f4af91ab88f_91b0655d", "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.", "...
3
true
[ "CWE-312", "CWE-312", "CWE-312" ]
[ "py/clear-text-logging-sensitive-data", "py/clear-text-logging-sensitive-data", "py/clear-text-logging-sensitive-data" ]
[ "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "This expression logs [sensitive data (private)](1) as clear text.", "This expression logs [sensitive data (private)](1) as clear text.", "This expression logs [sensitive data (private)](1) as clear text." ]
[ 32, 33, 34 ]
[ null, null, null ]
[ 10, 10, 10 ]
[ 62, 62, 54 ]
2024-11-18T21:58:06.288327+00:00
1,523,272,952,000
1cebc8f7db7e75e680d599ee68853ecb96eee9b2
2
{ "blob_id": "1cebc8f7db7e75e680d599ee68853ecb96eee9b2", "branch_name": "refs/heads/master", "committer_date": 1523272952000, "content_id": "0564823c9e294186f86aee5daa972c4a2f49f3f0", "detected_licenses": [ "Apache-2.0" ], "directory_id": "1978c7e325dcdb362c8185d22414014d6deeca29", "extension": "py"...
2.375
stackv2
#!venv/bin/python import os, re, json from flask import Flask, request from flask_restful import Resource, Api from json import dumps from flask_jsonpify import jsonify from flask import render_template from boxes import * app = Flask(__name__) api = Api(app) def get_logs(date, severity, box): DATESTAMP_RE...
78
29.77
96
18
662
python
[{"finding_id": "codeql_py/path-injection_483291b1074c65bb_67e40973", "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", ...
2
true
[ "CWE-022", "CWE-022" ]
[ "py/path-injection", "py/path-injection" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "This path depends on a [user-provided value](1).", "This path depends on a [user-provided value](1)." ]
[ 46, 47 ]
[ null, null ]
[ 23, 12 ]
[ 31, 20 ]
2024-11-18T21:58:14.057248+00:00
1,502,948,319,000
669e7fc5c47bf226a4c8e9f0a4807586d04356b3
4
{ "blob_id": "669e7fc5c47bf226a4c8e9f0a4807586d04356b3", "branch_name": "refs/heads/master", "committer_date": 1502948319000, "content_id": "ac7eb084ffeffffa7d57ade34d3e5473bb04ff53", "detected_licenses": [ "MIT" ], "directory_id": "beb32a1b95e9f8959c8cfb103fb9b4f29977c25a", "extension": "py", "fi...
4
stackv2
# zip_crack.py # python 3.5 # Encrypted Zip-file cracker. # This is a memory-friendly version that doesn't load the whole file into RAM # Works 100% of the time, 80% of the time. Else shows false-positives. # Code is heavily based on implementation from Violent-Python: # https://github.com/igniteflow/vi...
140
22.94
90
17
760
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_af7c8d2e74945e54_fcb428e6", "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." ]
[ 134 ]
[ null ]
[ 19 ]
[ 48 ]
2024-11-18T21:58:22.008241+00:00
1,593,109,843,000
ffed5f7c164bfdff65aff514bbdd387baeb08071
4
{ "blob_id": "ffed5f7c164bfdff65aff514bbdd387baeb08071", "branch_name": "refs/heads/master", "committer_date": 1593109843000, "content_id": "68e69b600eba61b1fb999acaf1afd9f70f765d4e", "detected_licenses": [ "MIT" ], "directory_id": "6a163418c4b8a7b41fee4e247cbfbe7a5788e1cf", "extension": "py", "fi...
3.59375
stackv2
def cadastrar(): email = input("E-mail: ") name = input("Nome:") password = input("Senha: ") #adiciona user no arquivo de login f = open("logins.txt","r") content = f.readlines() content.append(email + ',' + name + ',' + password + '\n') f.close() f = open("logins.txt","w") f.wri...
32
25.25
62
13
217
python
[{"finding_id": "codeql_py/clear-text-storage-sensitive-data_0399fbbbbdb27424_641639a3", "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." ]
[ 11 ]
[ null ]
[ 18 ]
[ 25 ]
2024-11-18T21:58:29.388821+00:00
1,690,475,182,000
cd89410c408e3f5d1ef3bf7d21d4e69d5730fcb6
2
{ "blob_id": "cd89410c408e3f5d1ef3bf7d21d4e69d5730fcb6", "branch_name": "refs/heads/master", "committer_date": 1690475182000, "content_id": "051fd92c75491b9f58082a9dfcae72fe9f71ff58", "detected_licenses": [ "Apache-2.0" ], "directory_id": "76d0ca4876672cdfa3adfeb34303fe1e57ca7398", "extension": "py"...
2.4375
stackv2
import logging logger = logging.getLogger(__name__) from pyramid.httpexceptions import HTTPFound, HTTPForbidden from pyramid.security import remember, forget, unauthenticated_userid from pyramid.view import view_config from .cas import CASProvider def _get_next_url(request, default): """ Returns the next UR...
67
37.21
86
14
552
python
[{"finding_id": "codeql_py/url-redirection_bc47518c143dbc84_24cdd617", "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)." ]
[ 55 ]
[ null ]
[ 35 ]
[ 43 ]
2024-11-18T21:58:34.601141+00:00
1,576,690,829,000
6d9c8898f768665db73cc67297b9dd4d70dc287d
4
{ "blob_id": "6d9c8898f768665db73cc67297b9dd4d70dc287d", "branch_name": "refs/heads/master", "committer_date": 1576690829000, "content_id": "23615d54b5d581b5018d3bf6580abf791a9d986f", "detected_licenses": [ "MIT" ], "directory_id": "a93aa3a5b7c307691e6816326565d9572f8dda5d", "extension": "py", "fi...
3.515625
stackv2
# Author: Ben Wichser # Date: 12/03/2019 # Description: Calculate number of possible passwords with given rules. see www.adventofcode.com/2019 (day 4) for more information # Part 2 min = 245318 max = 765747 possible_passwords = 0 for number in range(min, max): passing_conditions = 0 doubles = 0 number...
39
29
138
14
329
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_1cfdf4be2e9bd017_a5c30d91", "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." ]
[ 39 ]
[ null ]
[ 7 ]
[ 25 ]
2024-11-18T23:10:54.509492+00:00
1,575,145,146,000
b0634b07b42b86aa5e522bc29bd281704fa6f0c1
4
{ "blob_id": "b0634b07b42b86aa5e522bc29bd281704fa6f0c1", "branch_name": "refs/heads/master", "committer_date": 1575145146000, "content_id": "f528ebb9588171f44d41c3d3b9238e06b46dd294", "detected_licenses": [ "MIT" ], "directory_id": "f061447df787bf575cbece358e952d861f9aaac9", "extension": "py", "fi...
3.671875
stackv2
#Read from the file ''' infile = open("C:\\Users\\tgeorge\\Documents\\Python Scripts\\input.txt","r") line = infile.readline() while line != "": #when it print it always add a new line and when it read it always add a new line so in effect two \n(new line) line = line.rstrip() print (line) line = infile.readline...
81
23.2
133
9
544
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_595ecaf6919eeaa8_e5948261", "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." ]
[ 55 ]
[ null ]
[ 19 ]
[ 22 ]
2024-11-18T23:10:56.546484+00:00
1,578,683,900,000
b6424f0407ef9450cb8cade286ebf61e53ecc03e
3
{ "blob_id": "b6424f0407ef9450cb8cade286ebf61e53ecc03e", "branch_name": "refs/heads/master", "committer_date": 1578683900000, "content_id": "30b7f4a205e864513fd8a95da315bc222aecebbf", "detected_licenses": [ "MIT" ], "directory_id": "d063203a4041ff648ed89b8afca2b8acbcbe61f7", "extension": "py", "fi...
2.65625
stackv2
from flask import Flask, render_template, request from joblib import load import pandas as pd import json import sqlite3 from .image_parser import radar_chart pipeline_scaler = load('Models/scaler.joblib') pipeline_NN = load('Models/NNmodel.joblib') sqldb = 'Database/Songsdb.sqlite3' def create_app(): """Create ...
81
41.59
77
16
706
python
[{"finding_id": "codeql_py/stack-trace-exposure_c287b56f4724f9c9_cd89510a", "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." ]
[ 79 ]
[ null ]
[ 20 ]
[ 33 ]
2024-11-18T23:11:00.507353+00:00
1,580,903,336,000
6e86cd168a00a85e50eccdcc8f3e862b77db9d45
3
{ "blob_id": "6e86cd168a00a85e50eccdcc8f3e862b77db9d45", "branch_name": "refs/heads/master", "committer_date": 1580903336000, "content_id": "037a7d26bd8b260a3747ac2530747684675d7e74", "detected_licenses": [ "Apache-2.0" ], "directory_id": "57ee5844c9ff85f6f833c902b1d32998dc578309", "extension": "py"...
2.671875
stackv2
#!/usr/bin/env python """standardise_chembl_compounds.py Processes ChEMBL compound files, and generates a 'standard' tab-separated output. Download ChEMBL from here: ftp://ftp.ebi.ac.uk/pub/databases/chembl/ChEMBLdb/latest/ Unlike most other sources of molecules where the structures are specified as SMILES with ChEM...
210
31.77
98
16
1,509
python
[{"finding_id": "codeql_py/overly-permissive-file_31a5246dfbae219f_d980e104", "tool_name": "codeql", "rule_id": "py/overly-permissive-file", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Overly permissive mask in chmod sets file to world writable.", "remediation": "", "location": ...
1
true
[ "CWE-732" ]
[ "py/overly-permissive-file" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "Overly permissive mask in chmod sets file to world writable." ]
[ 179 ]
[ null ]
[ 9 ]
[ 37 ]
2024-11-18T23:11:10.396218+00:00
1,659,365,313,000
8e09675de28049526733f6e533dedc40ce014183
3
{ "blob_id": "8e09675de28049526733f6e533dedc40ce014183", "branch_name": "refs/heads/master", "committer_date": 1659365313000, "content_id": "2d7477a25b5c1dafc01432644a021119e00a326b", "detected_licenses": [ "MIT" ], "directory_id": "61673ab9a42f7151de7337608c442fa6247f13bb", "extension": "py", "fi...
2.765625
stackv2
# date: 2019.04.14 # https://stackoverflow.com/questions/55672653/python-http-server-not-responding-on-post-and-get-requests/55672850#55672850 from flask import Flask, request app = Flask(__name__) @app.route('/', methods=['GET', 'POST']) def index(): if request.method == 'POST': print(request.form['nam...
17
25.47
123
12
137
python
[{"finding_id": "codeql_py/reflective-xss_c05cf85be582e4cc_408f4c6d", "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)." ]
[ 13 ]
[ null ]
[ 16 ]
[ 52 ]
2024-11-18T22:48:57.806318+00:00
1,532,276,792,000
b9544b48b54daecb79582ee64e86d80bd9e96ea7
3
{ "blob_id": "b9544b48b54daecb79582ee64e86d80bd9e96ea7", "branch_name": "refs/heads/master", "committer_date": 1532276792000, "content_id": "11eaad25e919eeeab1004adf388693b3bf24b113", "detected_licenses": [ "Unlicense" ], "directory_id": "e4b2e5963b24d94f2900553c36c1133aa9fb5888", "extension": "py",...
2.53125
stackv2
import os import re import random import common import argparse import sys def gen_lst(dir, clas, testc, trainc): dir = os.path.expanduser(dir) images = common.get_images(dir) c = 0 with open(os.path.join(dir, 'lst_train.lst'), 'w') as train: with open(os.path.join(dir, 'lst_test.lst'), 'w') as...
52
34.87
77
23
424
python
[{"finding_id": "codeql_py/clear-text-storage-sensitive-data_692f7302320e328e_398cba47", "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.\n...
1
true
[ "CWE-312" ]
[ "py/clear-text-storage-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression stores [sensitive data (private)](1) as clear text.\nThis expression stores [sensitive data (private)](2) as clear text." ]
[ 37 ]
[ null ]
[ 29 ]
[ 39 ]
2024-11-18T22:49:08.921216+00:00
1,433,774,271,000
4b19a3c020e115b86ec778207d2e9471c278539b
2
{ "blob_id": "4b19a3c020e115b86ec778207d2e9471c278539b", "branch_name": "refs/heads/master", "committer_date": 1433774271000, "content_id": "5d2958906b66a1420836f402ea201688bf54945a", "detected_licenses": [ "BSD-2-Clause" ], "directory_id": "3e42329443d9cb6a912bca4d0de25eb985271b4b", "extension": "p...
2.34375
stackv2
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*- import hashlib import uuid __author__ = 'rikkt0r' import random import base64 from hashlib import md5 from datetime import datetime from functools import wraps from flask import redirect, current_app, request class Utils: def __init__(self): pass @st...
104
26.35
93
21
641
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_4ede13699c090972_2262206f", "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...
3
true
[ "CWE-327", "CWE-327", "CWE-601" ]
[ "py/weak-sensitive-data-hashing", "py/weak-sensitive-data-hashing", "py/url-redirection" ]
[ "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "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...
[ 92, 97, 29 ]
[ null, null, null ]
[ 31, 43, 37 ]
[ 64, 81, 79 ]
2024-11-18T23:26:20.548357+00:00
1,627,966,867,000
5c943642b247bbd7a5d007d9e33afd16e0a99557
3
{ "blob_id": "5c943642b247bbd7a5d007d9e33afd16e0a99557", "branch_name": "refs/heads/master", "committer_date": 1627966867000, "content_id": "fb9ad870cce218c4aada72e159660a0347658ff3", "detected_licenses": [ "MIT" ], "directory_id": "4dd45b96e589f7185ee7f78c71222fed15ba45b6", "extension": "py", "fi...
2.875
stackv2
import paramiko import os.path import subprocess import time import sys import re # Function to check IP address file and content validity def ip_is_valid(): global ip_list # Check if user wants to configure manually while True: decision = raw_input("Do you want to configure manually or use auto-c...
187
29.97
108
18
1,253
python
[{"finding_id": "codeql_py/paramiko-missing-host-key-validation_0ac746f166065ef3_d46ee5b7", "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." ]
[ 142 ]
[ null ]
[ 9 ]
[ 70 ]
2024-11-18T22:27:34.984823+00:00
1,403,247,456,000
e27c4a5374e54da60e7389c6d20069d3fd0b4fd6
3
{ "blob_id": "e27c4a5374e54da60e7389c6d20069d3fd0b4fd6", "branch_name": "refs/heads/master", "committer_date": 1403247456000, "content_id": "bc5ece8a221b4416ae1fa82e6111717dee0dc31d", "detected_licenses": [ "BSD-2-Clause" ], "directory_id": "599d1e6269bcd0320217537521ccfb58a5c83cbd", "extension": "p...
2.53125
stackv2
"""Django support for Tranquil""" from django.http import HttpResponse, HttpResponseNotAllowed, HttpResponseBadRequest import json from tranquil.request import process_request def context_class_to_view(context_class): def view_function(request): if request.method != 'POST': return HttpRespons...
29
31.31
84
14
166
python
[{"finding_id": "codeql_py/stack-trace-exposure_bce664af49aaf15c_ec99c88c", "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." ]
[ 19 ]
[ null ]
[ 43 ]
[ 49 ]
2024-11-19T00:33:33.164133+00:00
1,693,519,269,000
81432674048116e78cd9919cbf7b0caad12da98f
2
{ "blob_id": "81432674048116e78cd9919cbf7b0caad12da98f", "branch_name": "refs/heads/main", "committer_date": 1693519269000, "content_id": "673fd85aedb993f5ad23c597bd2166b7c85334dc", "detected_licenses": [ "Apache-2.0" ], "directory_id": "d810a9223e286f2bbb401d94eba6e7e03bc8c531", "extension": "py", ...
2.390625
stackv2
#!/usr/local/autopkg/python # # Refactoring 2018 Michal Moravec # Copyright 2015 Greg Neagle # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0...
342
36.89
87
18
2,721
python
[{"finding_id": "codeql_py/overly-permissive-file_c07668cd48fa1169_4caff33c", "tool_name": "codeql", "rule_id": "py/overly-permissive-file", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Overly permissive mask in chmod sets file to world readable.", "remediation": "", "location": ...
1
true
[ "CWE-732" ]
[ "py/overly-permissive-file" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "Overly permissive mask in chmod sets file to world readable." ]
[ 181 ]
[ null ]
[ 9 ]
[ 44 ]
2024-11-19T00:45:03.694925+00:00
1,591,388,508,000
39041ba0109e49c1d69cb3735c6419c313c0c417
2
{ "blob_id": "39041ba0109e49c1d69cb3735c6419c313c0c417", "branch_name": "refs/heads/master", "committer_date": 1591388508000, "content_id": "db98636f799ac648169074067e2bdcc3509bffec", "detected_licenses": [ "BSD-2-Clause" ], "directory_id": "642214528d35b168c0f4c533fe5f84f5b45056f1", "extension": "p...
2.328125
stackv2
#!/usr/bin/python3 ''' a modified version of cvim_server.py orginially created by 1995eaton https://github.com/1995eaton/chromium-vim/blob/master/cvim_server.py USAGE: ./cvim_server.py If you want to use native Vim to edit text boxes you must be running this script. To begin editing, first map the editWithVim (e.g. ...
133
23.04
79
15
865
python
[{"finding_id": "codeql_py/command-line-injection_c3e557b3c55c85d2_a6a11198", "tool_name": "codeql", "rule_id": "py/command-line-injection", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This command line depends on a [user-provided value](1).", "remediation": "", "location": {...
1
true
[ "CWE-078" ]
[ "py/command-line-injection" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This command line depends on a [user-provided value](1)." ]
[ 116 ]
[ null ]
[ 30 ]
[ 41 ]
2024-11-18T23:28:27.905214+00:00
1,551,674,050,000
08206a4b479a6a16b8d1f1ae3b638cd1822b84ac
2
{ "blob_id": "08206a4b479a6a16b8d1f1ae3b638cd1822b84ac", "branch_name": "refs/heads/master", "committer_date": 1551674050000, "content_id": "0baf6cd18fddbddea728e12d119bede8958b6ad1", "detected_licenses": [ "MIT" ], "directory_id": "130d2d88b685a5959772fe6c52b398d98ce34656", "extension": "py", "fi...
2.359375
stackv2
#!/usr/bin/python import datetime import requests import json import base64 import os no_cert_warnings = True rubrik_clusters = { 'cluster-1':{ 'ip':'10.100.1.10', 'user':'admin', 'pass':'pass123!' }, 'cluster-2':{ 'ip':'10.100.2.10', 'user':'admin', 'pass':'...
61
37.51
102
12
639
python
[{"finding_id": "codeql_py/request-without-cert-validation_e0731d1d8e770eb6_632b9f79", "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)." ]
[ 35, 51 ]
[ null, null ]
[ 16, 16 ]
[ 83, 83 ]
2024-11-18T23:28:38.898730+00:00
1,674,814,538,000
77c9e5dac7f0a0bc88b9a46967fac12ce262cb97
3
{ "blob_id": "77c9e5dac7f0a0bc88b9a46967fac12ce262cb97", "branch_name": "refs/heads/master", "committer_date": 1674814538000, "content_id": "f73dd91dae692685a8d5574fd14c87edf10952a1", "detected_licenses": [ "MIT" ], "directory_id": "d3c71c23e595264c4949d4d76c4dd61b9ba87fe8", "extension": "py", "fi...
2.84375
stackv2
# -*- coding: utf-8 -*- import os import csv from datetime import datetime try: from collections.abc import Mapping, Sequence except: from collections import Mapping, Sequence from pkg_resources import resource_filename from dwca.read import DwCAReader from cerberus import SchemaError from jinja2 import ...
507
35.75
109
29
3,484
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_a4639a72a9b7aa22_8c1493e1", "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." ]
[ 502 ]
[ 503 ]
[ 15 ]
[ 50 ]
2024-11-18T23:39:39.277361+00:00
1,652,399,951,000
af9fc0d697ecf761acf480fe7ae9ae108ab579bb
3
{ "blob_id": "af9fc0d697ecf761acf480fe7ae9ae108ab579bb", "branch_name": "refs/heads/main", "committer_date": 1652399951000, "content_id": "a778b544f502ccebf8526a2181646c2acb79cb34", "detected_licenses": [ "MIT" ], "directory_id": "e8e86c1667f138a6342318664c3cd23075be3a8d", "extension": "py", "file...
2.609375
stackv2
import argparse import json import shlex import subprocess import tarfile import time from pathlib import Path import GPUtil # noqa from loguru import logger from numpy import mean, median def get_avail_gpus(): avail_gpus = GPUtil.getAvailable(order='load', limit=1, ...
86
29.41
75
14
636
python
[{"finding_id": "codeql_py/tarslip_533c710dd91bb272_906e8d63", "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)." ]
[ 55 ]
[ null ]
[ 9 ]
[ 12 ]
2024-11-18T23:39:46.791710+00:00
1,459,337,892,000
93ebc0b1c5df120079623aaf2a0a41f8dcd7727f
3
{ "blob_id": "93ebc0b1c5df120079623aaf2a0a41f8dcd7727f", "branch_name": "refs/heads/master", "committer_date": 1459337892000, "content_id": "a40fc54fc7ee56336abf74e1bb4b849a7dc34f3d", "detected_licenses": [ "MIT" ], "directory_id": "86339d23ff23e6a9a235f5b890c79f5d8d477c6b", "extension": "py", "fi...
2.625
stackv2
import json from flask import Flask, render_template, request from flask_sqlalchemy import SQLAlchemy app = Flask(__name__) app.config['SQLALCHEMY_DATABASE_URI'] = 'postgresql://vagrant:123@localhost:5432/catalog' db = SQLAlchemy(app) # User model class User(db.Model): __tablename__ = "users" user_id = db...
119
28.67
89
14
789
python
[{"finding_id": "codeql_py/reflective-xss_7f28bbe22f0c23c3_fbe58f83", "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)." ]
[ 84 ]
[ null ]
[ 12 ]
[ 29 ]
2024-11-18T23:40:03.496262+00:00
1,620,409,773,000
b38fe1d0096f97df04156f9a6521672a78d5673b
2
{ "blob_id": "b38fe1d0096f97df04156f9a6521672a78d5673b", "branch_name": "refs/heads/master", "committer_date": 1620409773000, "content_id": "ec1d3b55ee15907cffbdc4b033b57ebfb9a002e6", "detected_licenses": [ "BSD-2-Clause-Views" ], "directory_id": "aab5a0958969db1a6cb6bcada6a14bab48f73a4f", "extensio...
2.46875
stackv2
#!/usr/bin/env python # Final Orientation Calculation File import stdb import pickle import os.path import numpy as np from orientpy import utils, arguments, plotting from pathlib import Path def main(): # Run the Input Parser args = arguments.get_bng_average_arguments() # Load Database db, stkeys...
129
28.22
83
16
917
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_3982c3b2b057686e_560a1541", "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." ]
[ 50 ]
[ 51 ]
[ 19 ]
[ 45 ]
2024-11-19T00:05:01.191508+00:00
1,643,110,780,000
3513c399877852d2b68054d474a187e373787f47
3
{ "blob_id": "3513c399877852d2b68054d474a187e373787f47", "branch_name": "refs/heads/master", "committer_date": 1643110780000, "content_id": "c06e053bad901ac22724019c413dbb60356201cf", "detected_licenses": [ "MIT" ], "directory_id": "f10506a518f3f1b383e0d74771b7a841464ad5f7", "extension": "py", "fi...
3.015625
stackv2
import requests IMAGE_FORMATS = ("image/png", "image/jpeg", "image/jpg", "image/webp") class UrlUtils: """ Helper class for URLs """ @staticmethod def is_imgur_url(url): """ Returns true, if an image url is an IMGUR image or album """ return "imgur.com" in url @staticmethod def ...
23
27.48
72
14
146
python
[{"finding_id": "codeql_py/incomplete-url-substring-sanitization_f4ef3d2aa45428bc_8069cb9a", "tool_name": "codeql", "rule_id": "py/incomplete-url-substring-sanitization", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "The string [imgur.com](1) may be at an arbitrary position in the s...
1
true
[ "CWE-020" ]
[ "py/incomplete-url-substring-sanitization" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "The string [imgur.com](1) may be at an arbitrary position in the sanitized URL." ]
[ 12 ]
[ null ]
[ 16 ]
[ 34 ]
2024-11-19T00:06:18.854109+00:00
1,324,844,671,000
3890a0838119586023945fabae2427275a74bdca
2
{ "blob_id": "3890a0838119586023945fabae2427275a74bdca", "branch_name": "refs/heads/master", "committer_date": 1324844671000, "content_id": "e6a9be47f45d888b850fe49a66a70bf865c542ac", "detected_licenses": [ "BSD-3-Clause" ], "directory_id": "a84e5f2743a22792d4439a99c93985b73e1c2d71", "extension": "p...
2.34375
stackv2
import os, re, hashlib, subprocess, threading from .. import httpRequest from ..lib import BeautifulSoup, cssmin from ..lib._StringIO import StringIO from ..log import * from ..lib.utils import * from .. import client class _style(object): _removeHtmlComments = re.compile(u'^\\s*/*\\s*<!--[^\\r\\n]*|/*\\s*-->\\s*$') ...
108
29.82
142
20
875
python
[{"finding_id": "codeql_py/bad-tag-filter_5998627c98e0ef34_839f716e", "tool_name": "codeql", "rule_id": "py/bad-tag-filter", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "This regular expression only parses --> and not --!> as a HTML comment end tag.", "remediation": "", "location":...
1
true
[ "CWE-116" ]
[ "py/bad-tag-filter" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This regular expression only parses --> and not --!> as a HTML comment end tag." ]
[ 10 ]
[ null ]
[ 37 ]
[ 71 ]
2024-11-19T01:11:18.138667+00:00
1,519,197,124,000
8ec694e5e86c180b70af37d6d97fbe8f3a25ce3d
3
{ "blob_id": "8ec694e5e86c180b70af37d6d97fbe8f3a25ce3d", "branch_name": "refs/heads/master", "committer_date": 1519197124000, "content_id": "8d3d6b15e52f09a9b69876f7fe0be01b684691eb", "detected_licenses": [ "MIT" ], "directory_id": "f5f6d36a1fce403d783c4334fe554d62aecb3b77", "extension": "py", "fi...
3.03125
stackv2
import pandas as pd import numpy as np import requests as rq import pandas_datareader as pdr from pandas_datareader.google.daily import GoogleDailyReader from io import StringIO # hack until pandas_datareader is fixed to a new google API @property def url(self): return 'http://finance.google.com/finance/historica...
98
33.94
79
18
851
python
[{"finding_id": "codeql_py/request-without-cert-validation_b34fee1d302dc06f_2caa1bb1", "tool_name": "codeql", "rule_id": "py/request-without-cert-validation", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "This request may run without certificate validation because [it is disabled]...
1
true
[ "CWE-295" ]
[ "py/request-without-cert-validation" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "This request may run without certificate validation because [it is disabled](1)." ]
[ 35 ]
[ null ]
[ 19 ]
[ 48 ]
2024-11-19T01:11:41.749718+00:00
1,457,182,510,000
b64341d9b0c77ab6e3e9d241c5a9d43cdfc587a4
4
{ "blob_id": "b64341d9b0c77ab6e3e9d241c5a9d43cdfc587a4", "branch_name": "refs/heads/master", "committer_date": 1457182510000, "content_id": "688126cea1e9dcaa1d1c37b73e853d9769eb9e4c", "detected_licenses": [ "MIT" ], "directory_id": "e6d8634878f118976a1adc954fbb69356ef44384", "extension": "py", "fi...
4.09375
stackv2
# The purpose of this class is to generate a uniformly distributed series of # lat/long coordinates given max/min latitude, max/min longitude, latitude # resolution, and longitude resolution, where resolution is the desired number # of degrees between output coordinates # Outputs a pandas dataframe of lat/long coord...
84
42.05
79
15
750
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_f403ca6e971264d4_6686ef21", "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.", "...
3
true
[ "CWE-312", "CWE-312", "CWE-312" ]
[ "py/clear-text-logging-sensitive-data", "py/clear-text-logging-sensitive-data", "py/clear-text-logging-sensitive-data" ]
[ "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "This expression logs [sensitive data (private)](1) as clear text.", "This expression logs [sensitive data (private)](1) as clear text.", "This expression logs [sensitive data (private)](1) as clear text." ]
[ 31, 32, 33 ]
[ null, null, null ]
[ 19, 19, 19 ]
[ 60, 62, 69 ]
2024-11-18T23:48:06.328198+00:00
1,532,980,334,000
ec5d5e00bc1d8f987336b3623329fca55a150302
2
{ "blob_id": "ec5d5e00bc1d8f987336b3623329fca55a150302", "branch_name": "refs/heads/master", "committer_date": 1532980334000, "content_id": "07e6e2f4c5595523697f948ed493b9042f486777", "detected_licenses": [ "BSD-2-Clause" ], "directory_id": "d5b3c5e1a990f6079ffa38f48b31f8e396c0fd22", "extension": "p...
2.421875
stackv2
import sys import logging from flask import Flask, request, abort, jsonify, Response, make_response from flask_compress import Compress from indra.db.client import get_statements_by_gene_role_type, \ get_statements_by_paper, get_evidence from indra.statements import make_statement_camel from indra.databases impor...
276
36.4
80
18
2,336
python
[{"finding_id": "codeql_py/stack-trace-exposure_d92e2702839f1053_3cb526b5", "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.", "...
7
true
[ "CWE-209", "CWE-079", "CWE-079", "CWE-079", "CWE-117", "CWE-117", "CWE-117" ]
[ "py/stack-trace-exposure", "py/reflective-xss", "py/reflective-xss", "py/reflective-xss", "py/log-injection", "py/log-injection", "py/log-injection" ]
[ "HIGH", "HIGH", "HIGH", "HIGH", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "[Stack trace information](1) flows to this location and may be exposed to an external user.", "Cross-site scripting vulnerability due to a [user-provided value](1).", "Cross-site scripting vulnerability due to a [user-provided value](1).", "Cross-site scripting vulnerability due to a [user-provided value](1)...
[ 166, 151, 181, 267, 93, 262, 266 ]
[ null, null, 182, null, null, null, null ]
[ 24, 24, 24, 24, 18, 17, 22 ]
[ 73, 78, 47, 27, 68, 70, 25 ]
2024-11-18T23:48:19.425997+00:00
1,619,018,139,000
468ee174ab41adf769acae68374f52bffecfec9b
3
{ "blob_id": "468ee174ab41adf769acae68374f52bffecfec9b", "branch_name": "refs/heads/main", "committer_date": 1619018139000, "content_id": "acde41d57e1c53bf754557820e8fb2717261c189", "detected_licenses": [ "Apache-2.0" ], "directory_id": "7a99c4de4e509c324593058606740ab02d8fa3cb", "extension": "py", ...
2.5625
stackv2
from flask import Flask, request, render_template, redirect, url_for import requests API_KEY = 'YOUR TRANSPORT API API_KEY HERE' APP_ID = 'YOUR TRANSPORT API APP_ID HERE' app = Flask(__name__) @app.route("/hello",methods=["GET"]) def hello(): return "hello from us" @app.route("/",methods=["GET"]) def home(): ...
42
37.31
134
16
392
python
[{"finding_id": "codeql_py/flask-debug_ecd5d926519083fa_1e3d2bd1", "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)." ]
[ 42, 17 ]
[ null, null ]
[ 5, 23 ]
[ 24, 85 ]
2024-11-18T23:48:22.865926+00:00
1,618,250,952,000
6b538563cac3215dc4d7ebef184bf14a249f1e9a
2
{ "blob_id": "6b538563cac3215dc4d7ebef184bf14a249f1e9a", "branch_name": "refs/heads/main", "committer_date": 1618250952000, "content_id": "e6289400e07715f281e7dda5d272b63a24fe75a0", "detected_licenses": [ "MIT" ], "directory_id": "cf580e7bd3cbcb4b27176d86e46496e98fc4e9ee", "extension": "py", "file...
2.375
stackv2
try: import simplejson as json except ImportError: import json from flask import Flask,request,Response,render_template import psycopg2 import time app = Flask(__name__) stacked_data_cache = {} leader_position_cache = {} height_data_cache = {} year_to_index = {} ###### HELPERS ###### def getCursor(): con...
325
31.86
165
19
2,956
python
[{"finding_id": "codeql_py/flask-debug_4824a9ddde93a75b_d9c174bb", "tool_name": "codeql", "rule_id": "py/flask-debug", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", ...
6
true
[ "CWE-215", "CWE-089", "CWE-089", "CWE-089", "CWE-089", "CWE-089" ]
[ "py/flask-debug", "py/sql-injection", "py/sql-injection", "py/sql-injection", "py/sql-injection", "py/sql-injection" ]
[ "HIGH", "HIGH", "HIGH", "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", "This SQL query depends on a [user-provided value](1).", "This SQL query depends on a [user-provided value](1).", "This SQL query depends on a [user-provided value](1).", "This SQL query de...
[ 325, 40, 81, 100, 148, 187 ]
[ null, null, 83, null, null, null ]
[ 3, 18, 18, 18, 20, 20 ]
[ 32, 122, 48, 148, 119, 66 ]
2024-11-18T23:23:30.557955+00:00
1,582,574,577,000
d16444a63f79d188009676bb7938ce8f5634d463
3
{ "blob_id": "d16444a63f79d188009676bb7938ce8f5634d463", "branch_name": "refs/heads/master", "committer_date": 1582574577000, "content_id": "662f6b0a942a85abae6895dc8e30f669cfb29a32", "detected_licenses": [ "MIT" ], "directory_id": "0ae7dc1c1b796faad57a3cde343ad0c72c1213d9", "extension": "py", "fi...
2.59375
stackv2
import os import shutil from flask import Flask, request, jsonify from flask_sqlalchemy import SQLAlchemy from flask_marshmallow import Marshmallow # Init app app = Flask(__name__) basedir = os.path.abspath(os.path.dirname(__file__)) # Database app.config['SQLALCHEMY_DATABASE_URI'] = 'sqlite:///' + os.path.join(base...
250
24.46
105
14
1,398
python
[{"finding_id": "codeql_py/flask-debug_496949193af385ff_52b98d9e", "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.", ...
8
true
[ "CWE-215", "CWE-022", "CWE-022", "CWE-022", "CWE-022", "CWE-022", "CWE-022", "CWE-022" ]
[ "py/flask-debug", "py/path-injection", "py/path-injection", "py/path-injection", "py/path-injection", "py/path-injection", "py/path-injection", "py/path-injection" ]
[ "HIGH", "HIGH", "HIGH", "HIGH", "HIGH", "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", "This path depends on a [user-provided value](1).", "This path depends on a [user-provided value](1).", "This path depends on a [user-provided value](1).", "This path depends on a [user-pro...
[ 250, 91, 92, 93, 94, 176, 177, 178 ]
[ null, null, null, null, null, null, null, null ]
[ 5, 27, 18, 18, 18, 27, 18, 18 ]
[ 35, 44, 35, 48, 52, 47, 38, 49 ]
2024-11-19T00:44:07.754265+00:00
1,616,113,676,000
4b8c9470aec96e2141a3c27a0c03c5b262396c5a
2
{ "blob_id": "4b8c9470aec96e2141a3c27a0c03c5b262396c5a", "branch_name": "refs/heads/main", "committer_date": 1616113676000, "content_id": "5f09c528fb98c5253442a6236f7a92880227d3ee", "detected_licenses": [ "MIT" ], "directory_id": "c69eb1681c25b996c3eba16e6a58af5a92cf1c54", "extension": "py", "file...
2.4375
stackv2
#!/usr/bin/env python # -*- coding:utf-8 -*- # FileName: CS_chatbot_flask.py # Development starting date: 2019.07.13 # Developer: Peter. w (peter.w@droidtown.co), Wilbert (wilbert.phen@gmail.com) import json import re from ArticutAPI.ArticutAPI import Articut with open("config.json") as f: configDICT = json.loa...
106
33.35
151
21
1,051
python
[{"finding_id": "codeql_py/reflective-xss_e8979b4b6ce8cf47_bad11175", "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)." ]
[ 45 ]
[ null ]
[ 16 ]
[ 61 ]
2024-11-19T00:44:11.186294+00:00
1,542,220,784,000
92c92e7079d3d4fb1819648f637eb0a6e2ec431e
2
{ "blob_id": "92c92e7079d3d4fb1819648f637eb0a6e2ec431e", "branch_name": "refs/heads/master", "committer_date": 1542220784000, "content_id": "30b31fb92a094faa5765b09bcd89fa022d0056eb", "detected_licenses": [ "MIT" ], "directory_id": "c3338e3883499987d3e08a1917c6fc333437f502", "extension": "py", "fi...
2.359375
stackv2
# -*- coding: utf-8 -*- from __future__ import unicode_literals import os.path import pkg_resources import mimetypes import datetime import stat import webbrowser from tornado import gen import tornado.web import tornado.websocket import tornado.iostream import tornado.ioloop from httpwatcher.filesystem import File...
377
35.55
116
18
2,792
python
[{"finding_id": "codeql_py/url-redirection_3bbff9228d401b75_2a6b0f05", "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).\nUntrusted URL redirection depends on a ...
2
true
[ "CWE-601", "CWE-117" ]
[ "py/url-redirection", "py/log-injection" ]
[ "HIGH", "MEDIUM" ]
[ "MEDIUM", "MEDIUM" ]
[ "Untrusted URL redirection depends on a [user-provided value](1).\nUntrusted URL redirection depends on a [user-provided value](2).", "This log entry depends on a [user-provided value](1)." ]
[ 252, 377 ]
[ null, null ]
[ 21, 68 ]
[ 75, 75 ]
2024-11-19T00:44:32.282524+00:00
1,631,256,458,000
8972ecb1c6efe5c8f668f8b0a2268264ffac3171
2
{ "blob_id": "8972ecb1c6efe5c8f668f8b0a2268264ffac3171", "branch_name": "refs/heads/master", "committer_date": 1631256458000, "content_id": "55be9261019dca6c14cab14053cb0db3cf180630", "detected_licenses": [ "MIT" ], "directory_id": "df4dcc2b9cdd5fd1d700b98b94b73ac28baa9b44", "extension": "py", "fi...
2.359375
stackv2
import os,json,sys,getopt,logging from flask import Flask,request,abort,session,url_for,render_template,flash app = Flask(__name__) BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) DATABASE = os.path.join(BASE_DIR, 'database')+os.path.sep LOGS = os.path.join(BASE_DIR, 'logs')+os.path.sep if no...
222
37.98
126
21
2,407
python
[{"finding_id": "codeql_py/path-injection_b4cb6cb51b66daf9_040bb996", "tool_name": "codeql", "rule_id": "py/path-injection", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This path depends on a [user-provided value](1).", "remediation": "", "location": {"file_path": "unknown", ...
4
true
[ "CWE-022", "CWE-022", "CWE-117", "CWE-117" ]
[ "py/path-injection", "py/path-injection", "py/log-injection", "py/log-injection" ]
[ "HIGH", "HIGH", "MEDIUM", "MEDIUM" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "This path depends on a [user-provided value](1).", "This path depends on a [user-provided value](1).", "This log entry depends on a [user-provided value](1).", "This log entry depends on a [user-provided value](1)." ]
[ 81, 105, 80, 104 ]
[ null, null, null, null ]
[ 19, 19, 21, 21 ]
[ 84, 84, 114, 118 ]
2024-11-18T23:05:31.686971+00:00
1,555,343,064,000
fbd6b353ec00b532d7b75d09145f858108718ca3
3
{ "blob_id": "fbd6b353ec00b532d7b75d09145f858108718ca3", "branch_name": "refs/heads/master", "committer_date": 1555343064000, "content_id": "b48e1e54d8e9e73f56283c13ea21679d94997139", "detected_licenses": [ "Apache-2.0" ], "directory_id": "0eb82823cdeb915a7222d25c00af8ee9128be76a", "extension": "py"...
2.515625
stackv2
import os from flask import Flask, request, jsonify import requests import json import hmac LGTM_URL = os.getenv("LGTM_WEBHOOK_URL") assert LGTM_URL != None GITHUB_URL = os.getenv("GIT_REPO_URL") assert GITHUB_URL != None GITHUB_BOT_USERNAME = os.getenv("GIT_BOT_USERNAME") assert GITHUB_BOT_USERNAME != None GITHUB...
209
32.12
98
19
1,805
python
[{"finding_id": "codeql_py/full-ssrf_f515183ebb6e1788_d7c3e518", "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...
5
true
[ "CWE-918", "CWE-918", "CWE-918", "CWE-918", "CWE-918" ]
[ "py/full-ssrf", "py/partial-ssrf", "py/partial-ssrf", "py/partial-ssrf", "py/partial-ssrf" ]
[ "HIGH", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "The full URL of this request depends on a [user-provided value](1).", "Part of the URL of this request depends on a [user-provided value](1).", "Part of the URL of this request depends on a [user-provided value](1).", "Part of the URL of this request depends on a [user-provided value](1).", "Part of the UR...
[ 139, 99, 112, 125, 148 ]
[ 141, 101, 114, 128, 150 ]
[ 13, 13, 13, 13, 17 ]
[ 10, 10, 10, 10, 14 ]
2024-11-18T23:05:49.998360+00:00
1,568,154,374,000
a81079a1b14f0f90d2c3ab81322603d8f0a73dfe
3
{ "blob_id": "a81079a1b14f0f90d2c3ab81322603d8f0a73dfe", "branch_name": "refs/heads/master", "committer_date": 1568154374000, "content_id": "f048acd2f94ee52c62698db61f9ba98c6731feeb", "detected_licenses": [ "BSD-3-Clause" ], "directory_id": "273b7de5f153011b67fd492fecfccb33817b0a47", "extension": "p...
2.6875
stackv2
from pathlib import Path from zipfile import ZipFile from urllib.parse import urlparse from http.client import HTTPResponse import tarfile def extract_zip(doc_location: Path, file: Path): ZipFile(file).extractall(path=doc_location) file.unlink() def extract_tars(doc_location: Path, file: Path): tar = tarf...
49
32.96
118
15
371
python
[{"finding_id": "codeql_py/tarslip_0edb3df39712f8e5_5a4ecd67", "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)." ]
[ 13 ]
[ null ]
[ 5 ]
[ 8 ]
2024-11-18T23:20:02.595964+00:00
1,546,292,692,000
9d40e47b0608a2603651f4a82fbc15644d9df1ae
2
{ "blob_id": "9d40e47b0608a2603651f4a82fbc15644d9df1ae", "branch_name": "refs/heads/master", "committer_date": 1546292692000, "content_id": "913a854d7ad431f3240d64210390d4a00a50656f", "detected_licenses": [ "MIT" ], "directory_id": "a540b24af7d25f505210beaa47b7cbc9d8149a66", "extension": "py", "fi...
2.421875
stackv2
from queue import Queue from time import sleep from threading import Thread import paramiko from mp.utils import interactive as _interactive class Packet: def __init__(self, name: str, msg: list): self.name = name self.msg = msg def __repr__(self): return '@ %s' % '\n'.join([self.na...
117
28.71
113
24
817
python
[{"finding_id": "codeql_py/paramiko-missing-host-key-validation_cb828953d8ac50e2_d4308493", "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." ]
[ 31 ]
[ null ]
[ 9 ]
[ 71 ]
2024-11-18T23:11:08.708217+00:00
1,585,268,962,000
990deee21f729e33c19568bfe6cadfd260edcee9
3
{ "blob_id": "990deee21f729e33c19568bfe6cadfd260edcee9", "branch_name": "refs/heads/master", "committer_date": 1585268962000, "content_id": "85ea5064502c545a5abaa4e5b74536de9ddb9e80", "detected_licenses": [ "MIT" ], "directory_id": "6e567903319cc63cf7512206f57839f84674ab2c", "extension": "py", "fi...
2.6875
stackv2
from ftplib import FTP_TLS from ftplib import FTP from infrastructure.sftp import SftpClient from os import path import paramiko class FtpCommon: @staticmethod def get_ftp(host, username, password): ftp = FTP(host) resp = ftp.login(username, password) return ftp @staticmethod ...
77
30.42
96
14
534
python
[{"finding_id": "codeql_py/paramiko-missing-host-key-validation_5972b9448c1ae14c_fa8dfe35", "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." ]
[ 27 ]
[ null ]
[ 9 ]
[ 69 ]
2024-11-18T23:11:12.145439+00:00
1,561,182,784,000
f48398e8c3c86632d1730a0a82db18f0857ce916
3
{ "blob_id": "f48398e8c3c86632d1730a0a82db18f0857ce916", "branch_name": "refs/heads/master", "committer_date": 1561182784000, "content_id": "bfb489eaa7c8dd152a8044288e1e9f072d3f3aa8", "detected_licenses": [ "MIT" ], "directory_id": "7f3ece2b53e3d05d24bd3dbcc78a2f48d9cb5f94", "extension": "py", "fi...
2.515625
stackv2
from rest_framework.views import APIView from rest_framework.response import Response from release_note.models import ReleaseNote from release_note.serializers import ReleaseNoteSerializer from datetime import datetime, timedelta, timezone from community_metrics.constants import URL_API, HTTP_OK, NINETY_DAYS import req...
85
30.49
79
13
553
python
[{"finding_id": "codeql_py/partial-ssrf_035dbdbe608710b8_4c196eea", "tool_name": "codeql", "rule_id": "py/partial-ssrf", "finding_type": "path-problem", "severity": "medium", "confidence": "medium", "message": "Part of the URL of this request depends on a [user-provided value](1).\nPart of the URL of this request depen...
1
true
[ "CWE-918" ]
[ "py/partial-ssrf" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "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).\nPart of the URL of this request depends on a [user-provided value](3).\nPart of the URL of this request depends on a [user-provided value](4)." ]
[ 66 ]
[ 67 ]
[ 22 ]
[ 47 ]
2024-11-19T01:21:39.087802+00:00
1,621,714,405,000
2870d0fe22f5e9ffb50637d8d9c6a41cea199eea
3
{ "blob_id": "2870d0fe22f5e9ffb50637d8d9c6a41cea199eea", "branch_name": "refs/heads/master", "committer_date": 1621714405000, "content_id": "d33f048a7b4559c3ce7b2b1d5d10112d7069a611", "detected_licenses": [ "MIT" ], "directory_id": "9df6a23c63157a6897622658e73e322ad6572b71", "extension": "py", "fi...
2.53125
stackv2
### ### Implementation from https://github.com/exelban/tensorflow-cifar-10 ### AlexNet on Cifar-10 dataset, dataset from https://www.cs.toronto.edu/~kriz/cifar.html ### import numpy as np import tensorflow as tf from time import time import math import pickle import numpy as np import os from six.moves.urllib.request...
416
31.15
120
18
3,574
python
[{"finding_id": "codeql_py/tarslip_63c13482186e580e_bd14c986", "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)." ]
[ 107 ]
[ null ]
[ 13 ]
[ 54 ]
2024-11-19T01:21:47.825545+00:00
1,693,678,202,000
a088fd5185f55eace7fcf513a6da73c35d7c311d
3
{ "blob_id": "a088fd5185f55eace7fcf513a6da73c35d7c311d", "branch_name": "refs/heads/master", "committer_date": 1693678202000, "content_id": "343ddc3772b51df77788a669e04bfb9591c22327", "detected_licenses": [ "BSD-3-Clause" ], "directory_id": "f46081e54cbba5fcaf6c5414efa21e331a1fbc8b", "extension": "p...
2.59375
stackv2
import argparse import pandas as pd from pprint import pprint import subprocess import os def run_City_Graph_app(cityGraph_location, API_KEY, COUNTRY_CODE, POPULATION_LIMIT, CITIES_LIMIT): subprocess.call(['java', '-jar',...
87
36.24
109
12
694
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_15d22b30d6123f08_098b3def", "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." ]
[ 38 ]
[ null ]
[ 11 ]
[ 44 ]
2024-11-19T01:21:50.759655+00:00
1,556,444,464,000
e899316b45268c864da26de393cac51b034a77af
2
{ "blob_id": "e899316b45268c864da26de393cac51b034a77af", "branch_name": "refs/heads/master", "committer_date": 1556444464000, "content_id": "097c069683694af3dc75d719a938e54b354902a9", "detected_licenses": [ "Apache-2.0" ], "directory_id": "ab3b4614f903b0e87edc8c0dad37728472fc2067", "extension": "py"...
2.46875
stackv2
# Copyright 2011 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, ...
97
28.99
77
15
700
python
[{"finding_id": "codeql_py/incomplete-url-substring-sanitization_220422d7fc410bed_e8c18ade", "tool_name": "codeql", "rule_id": "py/incomplete-url-substring-sanitization", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "The string [sourceforge.net](1) may be at an arbitrary position in...
1
true
[ "CWE-020" ]
[ "py/incomplete-url-substring-sanitization" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "The string [sourceforge.net](1) may be at an arbitrary position in the sanitized URL." ]
[ 46 ]
[ null ]
[ 8 ]
[ 42 ]
2024-11-19T00:24:54.753463+00:00
1,682,135,118,000
4a6257304508ce3e8388306e7a27503cb2099c0e
2
{ "blob_id": "4a6257304508ce3e8388306e7a27503cb2099c0e", "branch_name": "refs/heads/master", "committer_date": 1682135118000, "content_id": "a6795f389230786e55ef01e950387ceb36e085b1", "detected_licenses": [ "MIT" ], "directory_id": "cfaf255efd70d91cf84ae2f33e37d52240bd4fe4", "extension": "py", "fi...
2.46875
stackv2
import typing as tp from copy import deepcopy from pathlib import Path from jinja2 import Environment from schema import Schema, Use, Optional from yaml import safe_load from flag_slurper.autolib import models from flag_slurper.conf.config import Config project_schema_v1_0 = Schema({ '_version': Use(str, error='...
173
28.36
84
17
1,084
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_7d82b8789d6c2afe_a3e89fbb", "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." ]
[ 127 ]
[ null ]
[ 16 ]
[ 29 ]
2024-11-19T00:51:24.650459+00:00
1,417,629,753,000
3e812e4d1aad33beecb3174a40425eff064dd76e
2
{ "blob_id": "3e812e4d1aad33beecb3174a40425eff064dd76e", "branch_name": "refs/heads/master", "committer_date": 1417629753000, "content_id": "430665f7ba13c0e56647af3e84f1bac888e36d8f", "detected_licenses": [ "Apache-2.0" ], "directory_id": "6cfacc683f68a9e9748058335c36e8ee2fa7f83d", "extension": "py"...
2.4375
stackv2
# -*- coding: utf-8 -*- # Copyright 2014 OpenMarket Ltd # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable la...
240
31.46
79
22
1,662
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_6dd06bf24732c917_cf821416", "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."...
1
true
[ "CWE-327" ]
[ "py/weak-sensitive-data-hashing" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "[Sensitive data (id)](1) is used in a hashing algorithm (SHA1) that is insecure." ]
[ 237 ]
[ null ]
[ 21 ]
[ 64 ]
2024-11-19T01:02:27.285079+00:00
1,692,022,900,000
01d6e0497ca44fe70dcdc653d26eb1d21114bc7c
3
{ "blob_id": "01d6e0497ca44fe70dcdc653d26eb1d21114bc7c", "branch_name": "refs/heads/master", "committer_date": 1692022900000, "content_id": "595c2758139b30a0275e51424cc3f05a8cc2b70a", "detected_licenses": [ "BSD-3-Clause" ], "directory_id": "c20767783916f856ae359c13e5e0850113bc47f0", "extension": "p...
2.65625
stackv2
# Copyright (C) 2019 Intel Corporation # SPDX-License-Identifier: BSD-3-Clause """ Contains utility functions for common operations, including: - Checking file extensions - Opening files for writing - Checking paths """ from os.path import splitext import os import collections from collections.abc import Iterable impo...
159
26.03
87
18
1,003
python
[{"finding_id": "codeql_py/overly-permissive-file_848473e53a0b6cff_ab778a06", "tool_name": "codeql", "rule_id": "py/overly-permissive-file", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Overly permissive mask in open sets file to world writable.", "remediation": "", "location": {...
1
true
[ "CWE-732" ]
[ "py/overly-permissive-file" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "Overly permissive mask in open sets file to world writable." ]
[ 99 ]
[ null ]
[ 12 ]
[ 88 ]
2024-11-18T23:48:38.743764+00:00
1,595,169,000,000
0e286d41abc06ea890207f8bd45c3aa6b358901a
4
{ "blob_id": "0e286d41abc06ea890207f8bd45c3aa6b358901a", "branch_name": "refs/heads/master", "committer_date": 1595169000000, "content_id": "7065109c8979f2ec000f65f49ea75c94e129755c", "detected_licenses": [ "MIT" ], "directory_id": "5c1cb65c0d9b56b15b60e97d7707efaef5ba390f", "extension": "py", "fi...
3.59375
stackv2
# -------------- #Code starts here #Function to read file def read_file(path): #Opening of the file located in the path in 'read' mode file=open(path,'r') #Reading of the first line of the file and storing it in a variable sentence=file.readline() #Closing of the file file.close() retu...
133
21.65
76
11
738
python
[{"finding_id": "codeql_py/clear-text-storage-sensitive-data_48369bbf9a7d0b07_32176e46", "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...
6
true
[ "CWE-312", "CWE-312", "CWE-312", "CWE-312", "CWE-312", "CWE-312" ]
[ "py/clear-text-storage-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", "py/clear-text-logging-sensitive-data" ]
[ "HIGH", "HIGH", "HIGH", "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "This expression stores [sensitive data (secret)](1) as clear text.\nThis expression stores [sensitive data (secret)](2) as clear text.", "This expression logs [sensitive data (secret)](1) as clear text.", "This expression logs [sensitive data (secret)](1) as clear text.", "This expression logs [sensitive dat...
[ 117, 40, 65, 100, 112, 122 ]
[ null, null, null, null, null, null ]
[ 16, 7, 7, 7, 7, 7 ]
[ 26, 19, 19, 19, 19, 17 ]
2024-11-18T23:48:44.224360+00:00
1,402,071,340,000
025d0af63bdf07abc68b696ada98538fb45ae90e
3
{ "blob_id": "025d0af63bdf07abc68b696ada98538fb45ae90e", "branch_name": "refs/heads/master", "committer_date": 1402071340000, "content_id": "ee4552b655c9899e2ade923f4bae5c5baf555396", "detected_licenses": [ "MIT" ], "directory_id": "ba51455ac10ac6d14f40c57859959c3f7c5fcba1", "extension": "py", "fi...
2.546875
stackv2
import os import json import datetime import re import urlparse import urllib import requests from flask import Flask, Response, render_template, request, abort from flask.ext.cache import Cache # Get environement variables debug_app = 'DEBUG_APP' in os.environ # Domain regex domain_regex = '.*s3\.amazonaws\.com$' if...
144
24.93
100
14
984
python
[{"finding_id": "codeql_py/full-ssrf_8f68bf64a48508e8_2a641666", "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)." ]
[ 104, 95 ]
[ null, null ]
[ 7, 19 ]
[ 24, 40 ]
2024-11-19T01:51:59.596547+00:00
1,542,728,967,000
90d31a9341e8d0e9e7d4d2f487bdffcae6e9a0cb
3
{ "blob_id": "90d31a9341e8d0e9e7d4d2f487bdffcae6e9a0cb", "branch_name": "refs/heads/master", "committer_date": 1542728967000, "content_id": "bab3b84c50c4395fed710d30816795dc12245918", "detected_licenses": [ "BSD-3-Clause" ], "directory_id": "d57148c74b79954ff762ce3a02c1b0ef3e79d6a1", "extension": "p...
2.578125
stackv2
import os import threading import socket import ssl from SmartMeshSDK.ApiConnector import ApiConnector from SmartMeshSDK.ApiException import ConnectionError AUTHTIMEOUT = 10.0 # max number of seconds to wait for response during connection TCPRXBUFSIZE = 4096 # size of the TCP reception buffer import logging cla...
415
36.18
128
21
3,170
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_d1f200ce44883496_b13f05ce", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (password)](1) as clear text.", ...
2
true
[ "CWE-312", "CWE-327" ]
[ "py/clear-text-logging-sensitive-data", "py/insecure-default-protocol" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "This expression logs [sensitive data (password)](1) as clear text.", "Call to deprecated method ssl.wrap_socket does not specify a protocol, which may result in an insecure default being used." ]
[ 377, 209 ]
[ null, 214 ]
[ 19, 31 ]
[ 41, 65 ]
2024-11-19T01:52:00.275914+00:00
1,656,585,542,000
95f65149609290857fac362791a8d3b9db87961b
2
{ "blob_id": "95f65149609290857fac362791a8d3b9db87961b", "branch_name": "refs/heads/master", "committer_date": 1656585542000, "content_id": "8e4e5a96b1542f26a28fa0cb9a26ef58c6a7c1be", "detected_licenses": [ "Apache-2.0" ], "directory_id": "90fddf90b54d586991db4b74be5895c16e04fcee", "extension": "py"...
2.40625
stackv2
#!/usr/bin/python # coding: utf-8 -*- # # GNU General Public License v3.0+ # # Copyright 2020 TiTom73 # # 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/...
93
28.82
142
12
660
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_2dc7665b6636987d_99d4d3c2", "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." ]
[ 83 ]
[ null ]
[ 11 ]
[ 57 ]
2024-11-19T00:55:23.542350+00:00
1,497,220,011,000
708c62c4a3d9b96811e1c47c960c7077ff1b67bb
3
{ "blob_id": "708c62c4a3d9b96811e1c47c960c7077ff1b67bb", "branch_name": "refs/heads/master", "committer_date": 1497220011000, "content_id": "72870e1c9bdba1776d6b14ce0f8550510015f7af", "detected_licenses": [ "MIT" ], "directory_id": "7de0b9e2c11e3dd1fc627f31fde04d0574d32e13", "extension": "py", "fi...
2.546875
stackv2
'''''' from flask import request, redirect, render_template, url_for, flash from flask_login import login_user, logout_user, login_required from . import auth from .forms import SigninForm, SignupForm from ..models import User @auth.route('/signin', methods=['GET', 'POST']) def signin(): '''Sign in page''' f...
47
28.94
77
16
305
python
[{"finding_id": "codeql_py/url-redirection_15a218dc92a302ce_995e4ac6", "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)." ]
[ 18 ]
[ null ]
[ 29 ]
[ 77 ]
2024-11-19T00:32:58.501614+00:00
1,389,808,134,000
f8f4c39c5eeecdacb04e329371052db48bf0b12f
3
{ "blob_id": "f8f4c39c5eeecdacb04e329371052db48bf0b12f", "branch_name": "refs/heads/master", "committer_date": 1389808134000, "content_id": "dc0661fb494ef10be9bd2a1742e9aca78694ab64", "detected_licenses": [ "MIT" ], "directory_id": "72f859518d9571934fe1ffde833afc0b239c15cd", "extension": "py", "fi...
2.640625
stackv2
# -*- coding: utf-8 -*- """ Coinkit ~~~~~ :copyright: (c) 2013 by Halfmoon Labs :license: MIT, see LICENSE for more details. """ import os import json import ecdsa import hashlib import binascii from .entropy import random_secret_exponent from .passphrase import random_256bit_passphrase, random_1...
192
29.88
101
18
1,587
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_7dd5dd1c0e9d8469_befddf93", "tool_name": "codeql", "rule_id": "py/weak-sensitive-data-hashing", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "[Sensitive data (password)](1) is used in a hashing algorithm (SHA256) that is in...
1
true
[ "CWE-327" ]
[ "py/weak-sensitive-data-hashing" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "[Sensitive data (password)](1) is used in a hashing algorithm (SHA256) that is insecure for password hashing, since it is not a computationally expensive hash function.\n[Sensitive data (password)](2) is used in a hashing algorithm (SHA256) that is insecure for password hashing, since it is not a computationally e...
[ 66 ]
[ null ]
[ 42 ]
[ 52 ]
2024-11-19T01:18:06.199162+00:00
1,607,336,304,000
63faa0bae9797e22c65fab8bbb75cfbf80ed96ab
3
{ "blob_id": "63faa0bae9797e22c65fab8bbb75cfbf80ed96ab", "branch_name": "refs/heads/main", "committer_date": 1607336304000, "content_id": "176a5cfada4bb31b1fe5e197469850848eb0c71e", "detected_licenses": [ "Apache-2.0" ], "directory_id": "d9a47afcc1b4873d6f76f9a5c917bda05c5e8069", "extension": "py", ...
2.671875
stackv2
# -*- coding: utf-8 -*- import csv import json import requests from spiders.common.objects import Kline from spiders.spider import Spider class NasdaqSpider(Spider): def __init__(self): self.base_url = 'https://api.nasdaq.com/api/quote/{0}/chart?assetclass=stocks&fromdate={1}&todate={2}' """ g...
68
40.57
133
18
700
python
[{"finding_id": "codeql_py/request-without-cert-validation_a2749d9642f9dc84_8642a566", "tool_name": "codeql", "rule_id": "py/request-without-cert-validation", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "This request may run without certificate validation because [it is disabled]...
1
true
[ "CWE-295" ]
[ "py/request-without-cert-validation" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "This request may run without certificate validation because [it is disabled](1)." ]
[ 34 ]
[ null ]
[ 16 ]
[ 64 ]
2024-11-19T00:15:31.967028+00:00
1,572,019,441,000
0af85328b5c247280833bc410e414d989a279a67
3
{ "blob_id": "0af85328b5c247280833bc410e414d989a279a67", "branch_name": "refs/heads/master", "committer_date": 1572019441000, "content_id": "e56d1a910397d8c2349ed3b0bf06bce6de4c60f0", "detected_licenses": [ "MIT" ], "directory_id": "4a95f58c74c3655188e4d935f07d34bce9fff57b", "extension": "py", "fi...
2.515625
stackv2
from datetime import datetime from flask_jwt_extended.view_decorators import jwt_required from flask_restful import Resource, reqparse from flask import request from app.models.user import UserModel from schemas.user import UserSchema parser = reqparse.RequestParser() parser.add_argument("username", type=str, require...
77
38.66
90
16
657
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_98970c3a9b3b84ef_33178b31", "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." ]
[ 58 ]
[ null ]
[ 19 ]
[ 29 ]
2024-11-19T01:02:36.981228+00:00
1,558,286,582,000
4e784ae48bbc11eb1f20c7c894d32ca4763b03ae
3
{ "blob_id": "4e784ae48bbc11eb1f20c7c894d32ca4763b03ae", "branch_name": "refs/heads/master", "committer_date": 1558286582000, "content_id": "b908e93c84c7c194fd10d0a213dbfd13215c8ef6", "detected_licenses": [ "BSD-3-Clause" ], "directory_id": "0d9f63b99643b45d771bc1bcaae47fa2227a38bc", "extension": "p...
2.9375
stackv2
import pycurl from io import BytesIO class Curl: def __init__(self): self.curl = pycurl.Curl() self.curl.setopt(pycurl.SSL_VERIFYPEER, 0) self.curl.setopt(pycurl.SSL_VERIFYHOST, 0) def perform(self, url): storage = BytesIO() self.curl.setopt(self.curl.WRITEFUNCTION,...
21
25.48
64
12
147
python
[{"finding_id": "codeql_py/request-without-cert-validation_316b4c37f1f7d4f1_be4fec5c", "tool_name": "codeql", "rule_id": "py/request-without-cert-validation", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "This request may run without certificate validation because [it is disabled]...
1
true
[ "CWE-295" ]
[ "py/request-without-cert-validation" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "This request may run without certificate validation because [it is disabled](1) by [this value](2)." ]
[ 7 ]
[ null ]
[ 9 ]
[ 51 ]
2024-11-19T00:28:37.352514+00:00
1,409,813,306,000
5fb471b4ac5afcd45c9f546a0e70de1fbe54e94e
2
{ "blob_id": "5fb471b4ac5afcd45c9f546a0e70de1fbe54e94e", "branch_name": "refs/heads/master", "committer_date": 1409813306000, "content_id": "b7e52ec2c53d905a22e81ca2a18514e5783a5841", "detected_licenses": [ "MIT" ], "directory_id": "0ee9d9bb2237e1452b40dad6babcbaf1b4ea866e", "extension": "py", "fi...
2.3125
stackv2
from SocketServer import ThreadingMixIn import json import logging import os import SimpleHTTPServer import BaseHTTPServer import threading from time import sleep import baseservice import time import config basepath = os.path.dirname(__file__) formatter = logging.Formatter('%(asctime)s %(levelname)s %(message)s') lo...
129
30.47
100
18
882
python
[{"finding_id": "codeql_py/path-injection_c0a4f0359a2475a1_184f8a04", "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", ...
2
true
[ "CWE-022", "CWE-117" ]
[ "py/path-injection", "py/log-injection" ]
[ "HIGH", "MEDIUM" ]
[ "MEDIUM", "MEDIUM" ]
[ "This path depends on a [user-provided value](1).", "This log entry depends on a [user-provided value](1)." ]
[ 63, 28 ]
[ null, null ]
[ 27, 17 ]
[ 38, 21 ]
2024-11-19T00:28:40.784426+00:00
1,454,546,977,000
c0c6df8c59e89ee20a0f4bd156f06686a7c47532
3
{ "blob_id": "c0c6df8c59e89ee20a0f4bd156f06686a7c47532", "branch_name": "refs/heads/master", "committer_date": 1454546977000, "content_id": "d6270fff79d1d3ee6dff64a08d5e3cc40cb0d48c", "detected_licenses": [ "BSD-2-Clause" ], "directory_id": "0ac09deb9aed1b39dd5781b1964c99b09360b703", "extension": "p...
2.53125
stackv2
""" manage.py Manage the kernels available to remote_ikernel. Run ``remote_ikernel manage`` to see a list of commands. """ from __future__ import print_function import argparse import getpass import json import os import re import sys from os import path from subprocess import list2cmdline # How we identify kernel...
286
37.13
84
17
2,381
python
[{"finding_id": "codeql_py/overly-permissive-file_36fc14cad4c02499_7aa068e2", "tool_name": "codeql", "rule_id": "py/overly-permissive-file", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Overly permissive mask in chmod sets file to world readable.", "remediation": "", "location": ...
1
true
[ "CWE-732" ]
[ "py/overly-permissive-file" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "Overly permissive mask in chmod sets file to world readable." ]
[ 181 ]
[ null ]
[ 9 ]
[ 34 ]
2024-11-19T00:28:41.082422+00:00
1,629,132,026,000
3c02db23e1bbfed50a8d4a0efa3742e27f6a4a72
2
{ "blob_id": "3c02db23e1bbfed50a8d4a0efa3742e27f6a4a72", "branch_name": "refs/heads/main", "committer_date": 1629132026000, "content_id": "6cf3a2e456a4727840f11f084d2d142eca58f377", "detected_licenses": [ "MIT" ], "directory_id": "9e10a4f01f34bba9fbefc5940da7dd31b1f6fa8f", "extension": "py", "file...
2.359375
stackv2
import os from Utils import __version__ from jinja2 import Template import yaml import json from worlds.AutoWorld import AutoWorldRegister target_folder = os.path.join("WebHostLib", "static", "generated") def create(): for game_name, world in AutoWorldRegister.world_types.items(): res = Template(open(os...
64
39.27
110
19
500
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_23d2b9f82ea5689a_8618964f", "tool_name": "codeql", "rule_id": "py/jinja2/autoescape-false", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Using jinja2 templates with autoescape=False can potentially allow XSS attacks.", "remediati...
1
true
[ "CWE-079" ]
[ "py/jinja2/autoescape-false" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "Using jinja2 templates with autoescape=False can potentially allow XSS attacks." ]
[ 14 ]
[ null ]
[ 15 ]
[ 93 ]
2024-11-19T00:50:17.350685+00:00
1,602,290,620,000
0db912b827bf76232b968496eec2f76048fb43e1
2
{ "blob_id": "0db912b827bf76232b968496eec2f76048fb43e1", "branch_name": "refs/heads/main", "committer_date": 1602290620000, "content_id": "f6f2d2b0c42f9622b743feeb636ba456a09b2081", "detected_licenses": [ "MIT" ], "directory_id": "5435ab5bc7a2b506b6a4fb1e8eb249d84c1c9d5c", "extension": "py", "file...
2.421875
stackv2
# -*- coding: utf8 -*- import requests import hashlib import json import time import random def md5(code): res=hashlib.md5() res.update(code.encode("utf8")) return res.hexdigest() def get_information(mobile,password): header = { 'Content-Type': 'application/json; charset=utf-8', "User-...
122
28.7
139
18
1,030
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_b6423a2a8bf7aa56_8a5a79dc", "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...
[ 10 ]
[ null ]
[ 16 ]
[ 35 ]
2024-11-19T00:51:29.162436+00:00
1,692,453,874,000
96ec108cb0ac2c756220ac07685f16e393ef7706
3
{ "blob_id": "96ec108cb0ac2c756220ac07685f16e393ef7706", "branch_name": "refs/heads/master", "committer_date": 1692453874000, "content_id": "877bc76292073bb1eca458d25cfb13eac87e5fe7", "detected_licenses": [ "MIT" ], "directory_id": "d05c946e345baa67e7894ee33ca21e24b8d26028", "extension": "py", "fi...
3
stackv2
import requests import sys # replace your API key api_key = "64d1303e4ba02f1ebba4699bc871413f0510a" # the URL you want to shorten url = sys.argv[1] # preferred name in the URL api_url = f"https://cutt.ly/api/api.php?key={api_key}&short={url}" # or # api_url = f"https://cutt.ly/api/api.php?key={api_key}&short={url}&...
23
24.65
90
9
189
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_c68b6d8285ef96f7_7ab26ad8", "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." ]
[ 21, 23 ]
[ null, null ]
[ 29, 40 ]
[ 42, 44 ]
2024-11-19T00:51:35.665617+00:00
1,519,402,669,000
2178d017fa5743ea4a158f728348a9df0ace31a0
3
{ "blob_id": "2178d017fa5743ea4a158f728348a9df0ace31a0", "branch_name": "refs/heads/master", "committer_date": 1519402669000, "content_id": "871ed1f06380e3c5ee6710f25a98127ee1125be5", "detected_licenses": [ "Apache-2.0" ], "directory_id": "4b2dc147becbd9a319097fbfd0f8aea846519163", "extension": "py"...
2.8125
stackv2
import requests import json from getpass import getpass from datetime import datetime, timedelta """ Make sure to set a valid nodeID in line 50 before using! """ class SwisClient: def __init__(self, hostname, username, password): self.url = "https://%s:17778/SolarWinds/InformationService/v3/Json/" % (hostname) s...
93
29.11
97
14
733
python
[{"finding_id": "codeql_py/request-without-cert-validation_c60809c0d9ee16bf_f439fa14", "tool_name": "codeql", "rule_id": "py/request-without-cert-validation", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "This request may run without certificate validation because [it is disabled]...
1
true
[ "CWE-295" ]
[ "py/request-without-cert-validation" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "This request may run without certificate validation because [it is disabled](1)." ]
[ 41 ]
[ 45 ]
[ 10 ]
[ 49 ]
2024-11-19T00:51:41.511622+00:00
1,600,246,242,000
85056a8ada90205fcf4b67dc7fb36ed514ba33ff
2
{ "blob_id": "85056a8ada90205fcf4b67dc7fb36ed514ba33ff", "branch_name": "refs/heads/master", "committer_date": 1600246242000, "content_id": "44d6fa7ca8f01f753495d3d709c47c64bcc00cb7", "detected_licenses": [ "MIT" ], "directory_id": "e00486e8d77d81a3e0b7dae4944d746cfbab2063", "extension": "py", "fi...
2.421875
stackv2
import tarfile import rarfile import zipfile import os import json from datetime import datetime from pictor.models import Analysis from pictor.utils.applog_helpers import api_logger import requests from pictor.utils.manage_helpers import get_task_interface from django.utils import timezone def extract_file(source_fi...
271
41.23
123
16
2,752
python
[{"finding_id": "codeql_py/tarslip_374225af8b3fef10_b1340271", "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)." ]
[ 19 ]
[ null ]
[ 13 ]
[ 16 ]
2024-11-19T01:54:58.516579+00:00
1,559,786,947,000
e5d7f9d11d7ee7e794c693476195fd86235170a0
3
{ "blob_id": "e5d7f9d11d7ee7e794c693476195fd86235170a0", "branch_name": "refs/heads/master", "committer_date": 1559786947000, "content_id": "8bb60c0adee74f66f05657c3abe3f36bb3998684", "detected_licenses": [ "MIT" ], "directory_id": "b64c79a9462b75e748b93ed2c655569f1f5320ad", "extension": "py", "fi...
2.671875
stackv2
# -*- coding: utf-8 -*- ''' # refer: # * https://python-guide-kr.readthedocs.io/ko/latest/scenarios/web.html#jinja2 # * https://bibhasdn.com/blog/using-jinja2-as-the-template-engine-for-tornado-web-framework/ ''' from jinja2 import Environment, FileSystemLoader, TemplateNotFound class TemplateRender(object): ""...
34
31.38
93
13
235
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_9e502a2db5a95358_4db74d28", "tool_name": "codeql", "rule_id": "py/jinja2/autoescape-false", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Using jinja2 templates with autoescape=False can potentially allow XSS attacks.", "remediati...
1
true
[ "CWE-079" ]
[ "py/jinja2/autoescape-false" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "Using jinja2 templates with autoescape=False can potentially allow XSS attacks." ]
[ 21 ]
[ null ]
[ 27 ]
[ 78 ]
2024-11-19T02:05:07.613879+00:00
1,686,308,997,000
754a69e600834c8efd6a4d892879e548550275e2
2
{ "blob_id": "754a69e600834c8efd6a4d892879e548550275e2", "branch_name": "refs/heads/master", "committer_date": 1686308997000, "content_id": "7e5e3b06b37a6ce352101594e7b4d6b2d093ffc3", "detected_licenses": [ "Apache-2.0" ], "directory_id": "a9ba4f79697e519b291d40d51a525ee7b54715c7", "extension": "py"...
2.3125
stackv2
from websocket import create_connection, WebSocketTimeoutException, WebSocketConnectionClosedException from threading import RLock import requests import json import _thread import time import zlib import re import random import hashlib __Threads = [] # 全部存活线程id AllData = [] # 未解析的data数据 AllMessage = [] # 可以自行调整所有的...
190
29.71
120
20
1,698
python
[{"finding_id": "codeql_py/request-without-cert-validation_85a1774662607a41_ffe9228e", "tool_name": "codeql", "rule_id": "py/request-without-cert-validation", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "This request may run without certificate validation because [it is disabled]...
1
true
[ "CWE-295" ]
[ "py/request-without-cert-validation" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "This request may run without certificate validation because [it is disabled](1)." ]
[ 97 ]
[ 100 ]
[ 12 ]
[ 33 ]
2024-11-19T00:53:46.718715+00:00
1,556,135,485,000
98a59fe461bdf16b1812b6fc6189b4d34a612ead
3
{ "blob_id": "98a59fe461bdf16b1812b6fc6189b4d34a612ead", "branch_name": "refs/heads/master", "committer_date": 1556135485000, "content_id": "d9fbcec98b86bdfbe91da5ab8947b5b5d75e17bb", "detected_licenses": [ "MIT" ], "directory_id": "4487952253d0148117bc25d76ed7d19d21d3a08e", "extension": "py", "fi...
2.96875
stackv2
import sys import os import numpy import pandas as pd import pydicom import scipy.ndimage import SimpleITK as sitk import matplotlib.pyplot as plt from skimage import measure, morphology from mpl_toolkits.mplot3d.art3d import Poly3DCollection # This code is used to do all of the preprocessing of extracting patches for...
200
34.51
122
14
1,798
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_df5286e1cccd6765_da10f669", "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." ]
[ 166 ]
[ null ]
[ 36 ]
[ 53 ]
2024-11-19T00:04:25.651345+00:00
1,561,944,735,000
0119074700cccb72b5c69033cb0b8dd95f47624c
3
{ "blob_id": "0119074700cccb72b5c69033cb0b8dd95f47624c", "branch_name": "refs/heads/master", "committer_date": 1561944735000, "content_id": "6947932f618c0fbaa7d9798053ce16580b1e7c87", "detected_licenses": [ "Apache-2.0" ], "directory_id": "ce06506af2fc33ccba6ef8aa4fc8ae9afb8b3d9b", "extension": "py"...
2.78125
stackv2
""" Script to upload secrets to AWS SSM Parameter Store and tag them appropriately This script will read your secret value from the clipboard automagically """ import click import pyperclip from colorama import init, Fore from upside.enforcer.upload.util import upload_secret, secret_key_pattern from upside.enforcer.u...
62
39.47
154
14
552
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_c599800b819da3ed_021e5c3a", "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.\nThis expression logs [sensitive data (secret)](2) as clear text." ]
[ 51, 54 ]
[ null, null ]
[ 11, 11 ]
[ 54, 43 ]
2024-11-19T00:04:32.212383+00:00
1,610,585,220,000
080cb6a861a39fb7830594e928594fa71d86668e
2
{ "blob_id": "080cb6a861a39fb7830594e928594fa71d86668e", "branch_name": "refs/heads/master", "committer_date": 1610585220000, "content_id": "19daf55dfddd3348a7f40eabc7138e1e6c0a7dab", "detected_licenses": [ "MIT" ], "directory_id": "0c67a8b451ff00726c62f65cfa58d018fc66eef0", "extension": "py", "fi...
2.3125
stackv2
import flask, sys, os import requests app = flask.Flask(__name__) counter = 12345672 @app.route('/<path:page>') def custom_page(page): if page == 'favicon.ico': return '' global counter counter += 1 try: template = open(page).read() except Exception as e: template = str(e) tem...
32
23.97
80
13
225
python
[{"finding_id": "codeql_py/stack-trace-exposure_c9567b721e45df40_fb5af202", "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.", "...
4
true
[ "CWE-209", "CWE-074", "CWE-079", "CWE-022" ]
[ "py/stack-trace-exposure", "py/template-injection", "py/reflective-xss", "py/path-injection" ]
[ "HIGH", "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "[Stack trace information](1) flows to this location and may be exposed to an external user.", "This template construction depends on a [user-provided value](1).", "Cross-site scripting vulnerability due to a [user-provided value](1).", "This path depends on a [user-provided value](1)." ]
[ 18, 18, 18, 14 ]
[ null, null, null, null ]
[ 12, 41, 12, 25 ]
[ 80, 49, 80, 29 ]
2024-11-19T00:04:38.658816+00:00
1,588,223,880,000
df6e89a08559fedaf307d87680a658377308558e
2
{ "blob_id": "df6e89a08559fedaf307d87680a658377308558e", "branch_name": "refs/heads/master", "committer_date": 1588223880000, "content_id": "fbd51701f75f76a604d3dce53028c2ff4197f1ce", "detected_licenses": [ "MIT" ], "directory_id": "a01d4236d17aa3e0f65f346c036cab74b06948b5", "extension": "py", "fi...
2.5
stackv2
import os,glob,shutil def generate_hash(s,times=1): assert times>=1 import hashlib m = hashlib.md5() def gen(): m.update(s.encode('utf-8')) return m.hexdigest()[:10] for i in range(times): data=gen() return data def makedirs_ifneeded(d): import os os.makedirs(d) i...
58
30.24
122
14
494
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_777f95853df1266d_3180c3e9", "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." ]
[ 29 ]
[ null ]
[ 11 ]
[ 24 ]
2024-11-19T00:27:14.310126+00:00
1,632,762,869,000
9d9fb354262750d64f05b65f4760f40f7c866d53
3
{ "blob_id": "9d9fb354262750d64f05b65f4760f40f7c866d53", "branch_name": "refs/heads/main", "committer_date": 1632762869000, "content_id": "fa6276f71cc503a73ebcfaf78d2e67371eb4d24f", "detected_licenses": [ "MIT" ], "directory_id": "25c3c0f01731717c44cd5660090189c6ec9c93de", "extension": "py", "file...
2.875
stackv2
import asyncio import discord from discord.ext import commands, tasks from api import Coin class CryptoBot(commands.Cog): def __init__(self, bot): self.bot = bot self.coins_id = ['plant-vs-undead-token', 'smooth-love-potion', ] self.main_coin = 'slp' self.__temp_index = None ...
116
31.72
92
18
853
python
[{"finding_id": "codeql_py/incomplete-url-substring-sanitization_732eef07613a9dc2_3bcc7763", "tool_name": "codeql", "rule_id": "py/incomplete-url-substring-sanitization", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "The string [coingecko.com](1) may be at an arbitrary position in t...
1
true
[ "CWE-020" ]
[ "py/incomplete-url-substring-sanitization" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "The string [coingecko.com](1) may be at an arbitrary position in the sanitized URL." ]
[ 63 ]
[ null ]
[ 28 ]
[ 50 ]
2024-11-19T00:27:24.151077+00:00
1,486,228,193,000
0ebfc53c0338960a699e357a7a16884ee10d32b1
3
{ "blob_id": "0ebfc53c0338960a699e357a7a16884ee10d32b1", "branch_name": "refs/heads/master", "committer_date": 1486228193000, "content_id": "f5b6ef459cf477a017c21899cb32afa1acb51fb0", "detected_licenses": [ "MIT" ], "directory_id": "d3a8d80b74b33046118b58d4db0c86847dca6c04", "extension": "py", "fi...
2.921875
stackv2
import requests import datetime import sqlite3 from config import APIURL, APIKEY, HEADERS, DATABASE def fetch_genres(): genre_url = '{url}genre/movie/list?api_key={key}'.format(url=APIURL, key=APIKEY) try: genre_res = requests.get(genre_url, headers=HEADERS, verify=False) genre_json = genre_r...
105
28.07
103
18
706
python
[{"finding_id": "codeql_py/request-without-cert-validation_9de5119eaf04a67e_3a58b8e0", "tool_name": "codeql", "rule_id": "py/request-without-cert-validation", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "This request may run without certificate validation because [it is disabled]...
1
true
[ "CWE-295" ]
[ "py/request-without-cert-validation" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "This request may run without certificate validation because [it is disabled](1)." ]
[ 11 ]
[ null ]
[ 21 ]
[ 75 ]
2024-11-19T01:06:17.618673+00:00
1,583,352,965,000
4627415d99348c90ee16e96e80555465c0cfc1a8
3
{ "blob_id": "4627415d99348c90ee16e96e80555465c0cfc1a8", "branch_name": "refs/heads/master", "committer_date": 1583352965000, "content_id": "f104f3c53c3c114cf1d13741cb4f6a18ddf4a5ff", "detected_licenses": [ "MIT" ], "directory_id": "5c5e118e4c2e649c367cc5f289eaa596a411778a", "extension": "py", "fi...
2.546875
stackv2
# Sebastian Raschka 2016-2017 # # Supporting code for the book # "Introduction to Artificial Neural Networks and Deep Learning: # A Practical Guide with Applications in Python" # # Source: https://github.com/rasbt/deep-learning-book # Author: Sebastian Raschka <sebastianraschka.com> # License: MIT from urllib.reques...
233
33.67
81
19
2,013
python
[{"finding_id": "codeql_py/tarslip_fa5de33d89db03bf_ab036598", "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)." ]
[ 55 ]
[ null ]
[ 9 ]
[ 10 ]
2024-11-19T01:17:09.976646+00:00
1,664,895,636,000
856585987e650a59c120ca0e4b9ce028b62581b4
3
{ "blob_id": "856585987e650a59c120ca0e4b9ce028b62581b4", "branch_name": "refs/heads/master", "committer_date": 1664895636000, "content_id": "7ae5bfe0c8fb971e1e8ec38a3553aaaa1a86de18", "detected_licenses": [ "MIT" ], "directory_id": "be3f475d391f5b3288b82bb4c42f82825e302aa0", "extension": "py", "fi...
3.28125
stackv2
# -------------- ##File path for the file file_path #Code starts here def read_file(path): file = open(file_path, 'r') sentence = file.readline() file.close() return sentence sample_message = read_file(file_path) print(sample_message) # -------------- #Code starts here def read_file_1(path_1): ...
136
19.84
70
11
801
python
[{"finding_id": "codeql_py/clear-text-storage-sensitive-data_ae045d13498b3cc8_d5c148e2", "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...
6
true
[ "CWE-312", "CWE-312", "CWE-312", "CWE-312", "CWE-312", "CWE-312" ]
[ "py/clear-text-storage-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", "py/clear-text-logging-sensitive-data" ]
[ "HIGH", "HIGH", "HIGH", "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "This expression stores [sensitive data (secret)](1) as clear text.\nThis expression stores [sensitive data (secret)](2) as clear text.\nThis expression stores [sensitive data (secret)](3) as clear text.\nThis expression stores [sensitive data (secret)](4) as clear text.\nThis expression stores [sensitive data (sec...
[ 130, 49, 75, 98, 114, 134 ]
[ null, null, null, null, null, null ]
[ 16, 7, 7, 7, 7, 7 ]
[ 26, 19, 19, 19, 19, 17 ]
2024-11-19T01:17:15.160261+00:00
1,636,379,146,000
f49ffb3ba14f59ab93089d9fe7093e43e189f1d9
2
{ "blob_id": "f49ffb3ba14f59ab93089d9fe7093e43e189f1d9", "branch_name": "refs/heads/master", "committer_date": 1636379146000, "content_id": "759d0f55e9017bd311aab08033b4ffe3604c9bb4", "detected_licenses": [ "Apache-2.0" ], "directory_id": "45e46c8e850c98cd0ff7ec4cb7f040ead42355ae", "extension": "py"...
2.328125
stackv2
# Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # http://www.apache.org/licenses/LICENSE-2.0 # # Authors: # - Alexey Anisenkov, anisyonk@cern.ch, 2018 # - Paul Nilsson, paul.nilsson@cern.ch, 20...
160
39.98
130
19
1,457
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_53285cad211d8293_486cc6dd", "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...
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.\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." ]
[ 113, 121 ]
[ null, null ]
[ 25, 26 ]
[ 54, 120 ]
2024-11-19T01:17:26.349337+00:00
1,691,037,619,000
8e583bbfed801f13529b6979cb59f04264b0cbe3
3
{ "blob_id": "8e583bbfed801f13529b6979cb59f04264b0cbe3", "branch_name": "refs/heads/master", "committer_date": 1691037619000, "content_id": "691344fbcffb0f1402200b5c131ff99825e9f325", "detected_licenses": [ "Apache-2.0" ], "directory_id": "7dfc958846a98c9dc90829ace237adb0f4e79057", "extension": "py"...
2.59375
stackv2
"""Efficiently upload/download data """ import urllib.request from concurrent.futures import ThreadPoolExecutor, as_completed from pathlib import Path, PurePosixPath import click import requests try: import boto3 except ModuleNotFoundError: boto3 = None def yield_index(file_size, max_size): parts = int(...
176
27.73
86
18
1,248
python
[{"finding_id": "codeql_py/incomplete-url-substring-sanitization_ca3afbebf617a7b1_3b0f5495", "tool_name": "codeql", "rule_id": "py/incomplete-url-substring-sanitization", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "The string [https://github.com](1) may be at an arbitrary position...
1
true
[ "CWE-020" ]
[ "py/incomplete-url-substring-sanitization" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "The string [https://github.com](1) may be at an arbitrary position in the sanitized URL." ]
[ 162 ]
[ null ]
[ 12 ]
[ 53 ]
2024-11-19T01:17:26.731927+00:00
1,525,951,271,000
bed43fb91b275c375076e4318e6fd2dc3788b974
3
{ "blob_id": "bed43fb91b275c375076e4318e6fd2dc3788b974", "branch_name": "refs/heads/master", "committer_date": 1525951271000, "content_id": "348bc403c23e030bdf731425c44628e4fe4016ae", "detected_licenses": [ "MIT" ], "directory_id": "21ac32f09d3b665c437c4665126930447a38a2fc", "extension": "py", "fi...
2.59375
stackv2
import threading from platform import system as system_name from uuid import getnode as get_mac import random import os import requests import datetime from datetime import timedelta import subprocess import json server_up = None device_up = True start_time = None end_time = None data = None HOST_NAME = 's4907869.buc...
148
23.49
126
18
881
python
[{"finding_id": "codeql_py/clear-text-storage-sensitive-data_0b7f59099f20f78d_06a80066", "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-295", "CWE-295" ]
[ "py/clear-text-storage-sensitive-data", "py/clear-text-logging-sensitive-data", "py/request-without-cert-validation", "py/request-without-cert-validation" ]
[ "HIGH", "HIGH", "MEDIUM", "MEDIUM" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "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.", "This expression logs [sensitive data (password)](1) as clear text.\nThis expression logs [sensitive d...
[ 120, 102, 101, 138 ]
[ null, null, null, null ]
[ 13, 19, 17, 17 ]
[ 18, 109, 127, 125 ]
2024-11-19T01:17:27.114678+00:00
1,514,272,562,000
28b65ba71447b6eb2ec8f341dd4715d9b348383d
2
{ "blob_id": "28b65ba71447b6eb2ec8f341dd4715d9b348383d", "branch_name": "refs/heads/master", "committer_date": 1514272562000, "content_id": "8b668fbe8921256196fe3d6c5de4f19fddc4f381", "detected_licenses": [ "MIT" ], "directory_id": "86a343d90e8c4b79255c8fc4f75c822e2eca982a", "extension": "py", "fi...
2.453125
stackv2
""" This is the main program which contains GET and POST methods """ import os from flask import Flask, request, render_template from modules import Bot from basic import log, user, message APP = Flask(__name__) @APP.route('/', methods=['GET']) def verify(): """ This verifies Tokens and renders webpage ...
74
25.8
88
18
430
python
[{"finding_id": "codeql_py/flask-debug_033160165233319e_210ec7ed", "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)." ]
[ 74, 22 ]
[ null, null ]
[ 5, 16 ]
[ 24, 50 ]
2024-11-19T01:17:35.961321+00:00
1,628,401,355,000
479e496b00a6ccb9e551a1a42501a1fe43ad03f0
3
{ "blob_id": "479e496b00a6ccb9e551a1a42501a1fe43ad03f0", "branch_name": "refs/heads/main", "committer_date": 1628401355000, "content_id": "63ee0877b4c45ccbe9467016b5aaab7ca9954d97", "detected_licenses": [ "MIT" ], "directory_id": "904de3a9e562e31d20ff87d3b84c3be651387e7e", "extension": "py", "file...
2.53125
stackv2
from flask import * from werkzeug.utils import secure_filename from werkzeug.datastructures import FileStorage from tensorflow.keras.models import load_model from keras.preprocessing import image import numpy as np import os model = load_model('model.h5') UPLOAD_FOLDER = './static' def load_image(img_path): im...
58
21.76
71
11
333
python
[{"finding_id": "codeql_py/flask-debug_ac1685e30f991c7c_0305d56b", "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)." ]
[ 58, 50 ]
[ null, null ]
[ 4, 9 ]
[ 25, 13 ]
2024-11-19T01:14:57.965763+00:00
1,576,132,275,000
fa8b9498b5c1fae4aaa0990a3306a52b8468631a
2
{ "blob_id": "fa8b9498b5c1fae4aaa0990a3306a52b8468631a", "branch_name": "refs/heads/master", "committer_date": 1576132275000, "content_id": "d433f7efb8bff5a688ee6df6d1e9bd45390ef7d3", "detected_licenses": [ "MIT" ], "directory_id": "f390b4fcd716f0b16223d9d8363d250262ff73b0", "extension": "py", "fi...
2.453125
stackv2
#!/usr/bin/env python3 """ SSH Utils Helper module Created on May 5, 2015 @author: samuels """ import os import socket import pexpect import sys import warnings import argparse import logging import time import errno from socket import error as socket_error with warnings.catch_warnings(): warnings.simplefilter("...
237
36.84
118
18
2,091
python
[{"finding_id": "codeql_py/paramiko-missing-host-key-validation_0c1e316f1377f061_cdd89f46", "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." ]
[ 67 ]
[ null ]
[ 9 ]
[ 66 ]
2024-11-19T01:15:01.180632+00:00
1,541,773,228,000
48586a4fbf5c97b2beb87e1c076152680c9a1b06
3
{ "blob_id": "48586a4fbf5c97b2beb87e1c076152680c9a1b06", "branch_name": "refs/heads/master", "committer_date": 1541773228000, "content_id": "63873ef52fa5ab48148d584a947365f04365f5af", "detected_licenses": [ "MIT" ], "directory_id": "a68b81ade0a70be17bfe824655b38533ae6724ad", "extension": "py", "fi...
2.515625
stackv2
"""Mailer script.""" import hashlib import sys import os import smtplib import urllib2 from urlparse import urlparse from optparse import OptionParser from flask import Flask, request, redirect, url_for, render_template, session from email.MIMEMultipart import MIMEMultipart from email.MIMEBase import MIMEBase from ema...
107
29.32
118
16
829
python
[{"finding_id": "codeql_py/flask-debug_6e4af1d0edb78618_e6c0a1e5", "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/full-ssrf" ]
[ "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.", "The full URL of this request depends on a [user-provided value](1)." ]
[ 107, 64 ]
[ null, 69 ]
[ 5, 15 ]
[ 64, 11 ]
2024-11-19T00:43:51.469819+00:00
1,577,070,466,000
6a1c209edf4081a080840ac24f1a7fe2c87dedc3
2
{ "blob_id": "6a1c209edf4081a080840ac24f1a7fe2c87dedc3", "branch_name": "refs/heads/master", "committer_date": 1577070466000, "content_id": "017fa4986ac10fd54fc0e0c9ec0125f78cd34b78", "detected_licenses": [ "MIT" ], "directory_id": "fa0c31b319a268e1de551d835e62f0697997613f", "extension": "py", "fi...
2.34375
stackv2
# -*- coding: utf-8 -*- from __future__ import unicode_literals import logging import time import json from jinja2 import Template import requests from django.core.mail import send_mail from natrix.common import exception as natrix_exceptions from infrastructure.configurations import messenger as conf from .template...
166
29.3
92
21
946
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_57150b7ecd7fd865_5cd43486", "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." ]
[ 101 ]
[ null ]
[ 29 ]
[ 52 ]
2024-11-19T00:43:56.007357+00:00
1,588,659,094,000
c52a2bb2dbcf03ee89dc89dbe5edbbc2536a176c
3
{ "blob_id": "c52a2bb2dbcf03ee89dc89dbe5edbbc2536a176c", "branch_name": "refs/heads/master", "committer_date": 1588659094000, "content_id": "ac03bbe228ac3b2173aa9a8e83fe86907dfacbc4", "detected_licenses": [ "MIT" ], "directory_id": "6a0922dc5960cd669f3987f229ff093bcbd0af47", "extension": "py", "fi...
2.515625
stackv2
#imports import csv import json import requests import requests.utils import requests.sessions import urllib3 import sys import traceback import configparser import logging from urllib3.exceptions import InsecureRequestWarning urllib3.disable_warnings(InsecureRequestWarning) logging.basicConfig(format='%(levelname)s...
86
34.71
171
17
692
python
[{"finding_id": "codeql_py/request-without-cert-validation_2c9afd09a3f0b45c_1f253e2d", "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]...
4
true
[ "CWE-295", "CWE-295", "CWE-295", "CWE-295" ]
[ "py/request-without-cert-validation", "py/request-without-cert-validation", "py/request-without-cert-validation", "py/request-without-cert-validation" ]
[ "MEDIUM", "MEDIUM", "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).", "This request may run without certificate validation becau...
[ 46, 58, 69, 78 ]
[ null, null, null, null ]
[ 13, 13, 13, 13 ]
[ 78, 73, 43, 43 ]
2024-11-19T01:32:00.069004+00:00
1,633,093,229,000
0a72c73b9938284df287b218688e34d3a5089a9f
2
{ "blob_id": "0a72c73b9938284df287b218688e34d3a5089a9f", "branch_name": "refs/heads/main", "committer_date": 1633093229000, "content_id": "e5e544317cc496950b8f2dc128042db56a90bbdd", "detected_licenses": [ "MIT" ], "directory_id": "05d873c8b98d31e3ad2b44edd3b5c4eac6cb8593", "extension": "py", "file...
2.390625
stackv2
from nfmd.schemata import FirewallOnboardRequestSchema from marshmallow.exceptions import ValidationError from .BaseResource import BaseResource from flask import request from ipaddress import ip_address import requests import os from requests.exceptions import ConnectionError from netifaces import interfaces, ifaddres...
129
31.77
144
19
885
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_3c8ddda339cdb028_85a6137e", "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." ]
[ 111 ]
[ null ]
[ 15 ]
[ 33 ]
2024-11-19T01:32:01.557591+00:00
1,645,973,291,000
9b4d632dab5891ad9c2e71ac818a136a2c107a63
3
{ "blob_id": "9b4d632dab5891ad9c2e71ac818a136a2c107a63", "branch_name": "refs/heads/master", "committer_date": 1645973291000, "content_id": "53de2ccd5997112c0f6d27376a7824c4c181a977", "detected_licenses": [], "directory_id": "82bdcb8ae01103447b0e4a5697246be840aae229", "extension": "py", "filename": "mak...
3.015625
stackv2
#!/usr/bin/env python3 import random, string, sys def main(lenght=16): counter = 0 passwd = "" proto_passwd = "" while lenght != counter: proto_passwd += random.choice(string.ascii_letters) counter += 1 pass2list = list(proto_passwd) for i in range(lenght//4): pass2list[...
24
21.08
78
13
139
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_4ba79354fdf836f3_60611cdc", "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." ]
[ 22 ]
[ null ]
[ 11 ]
[ 33 ]
2024-11-19T01:32:05.936837+00:00
1,520,010,427,000
8f7e96d4aa54dc97fc3b116c59c848402f3aae67
3
{ "blob_id": "8f7e96d4aa54dc97fc3b116c59c848402f3aae67", "branch_name": "refs/heads/master", "committer_date": 1520010427000, "content_id": "8ee626e1e50aef8983db047dddcd634abe992652", "detected_licenses": [ "MIT" ], "directory_id": "2995562afe5d7417c2996be096c94b20188bfb59", "extension": "py", "fi...
2.5625
stackv2
import json import traceback import time from requests import Session from requests import Request from requests.exceptions import Timeout from requests.exceptions import ConnectionError #import nest_py.flask.app2.API_PREFIX as API_PREFIX #TODO move to a (jobs?) config file API_PREFIX = '/api/v2/' VERBOSE = False #lo...
301
34.07
107
20
2,125
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_2d460638f32c02dc_d90260f1", "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." ]
[ 300 ]
[ null ]
[ 11 ]
[ 30 ]
2024-11-19T01:32:40.962471+00:00
1,533,210,140,000
ba94f18279ee8d260cbc03f429ffea9d2d94af79
3
{ "blob_id": "ba94f18279ee8d260cbc03f429ffea9d2d94af79", "branch_name": "refs/heads/master", "committer_date": 1533210140000, "content_id": "d2a7fb13201480f6050d1e371099d369938bc05d", "detected_licenses": [ "Apache-2.0" ], "directory_id": "d3349e1b7b86ebcf0072586d25e5131068fecf95", "extension": "py"...
2.8125
stackv2
# # Marco Panato # 2016-03-11 # Authenticator for frontend # # Each user has a role # 1 -> min privileges # 5 -> max privileges from hashlib import md5 import logging from database.DataManager import DataManager class Authenticator(object): def authenticate(self, user, password): """ Re...
31
24.74
76
17
204
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_abab66104a6ff928_933440a3", "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." ]
[ 24 ]
[ null ]
[ 40 ]
[ 57 ]
2024-11-19T01:43:45.082022+00:00
1,608,659,423,000
c0b10ba206bc37b12462a45ca69fc6372e63e753
3
{ "blob_id": "c0b10ba206bc37b12462a45ca69fc6372e63e753", "branch_name": "refs/heads/main", "committer_date": 1608659423000, "content_id": "95094baaa20bd1656146356aedd9626bedcdb1c6", "detected_licenses": [ "MIT" ], "directory_id": "7c6b3cd0d68000fb08c90482e9924658ae12a016", "extension": "py", "file...
3.421875
stackv2
def passwordAccepted(ranged, char, string): total = 0 for x in string: if x == char: total += 1 return int(ranged[0]) <= total and total <= int(ranged[1]) f = f = open('input.txt', 'r') lines = f.readlines() passwordCount = 0 for line in lines: tokens = line.split() ranged = to...
20
22.35
62
10
133
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_17b1b7c4500bafe5_25e65d0a", "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." ]
[ 20 ]
[ null ]
[ 7 ]
[ 20 ]
2024-11-19T01:43:49.696862+00:00
1,573,569,542,000
1a38f30a559c8e64ae7320a3e31421c861f681ef
4
{ "blob_id": "1a38f30a559c8e64ae7320a3e31421c861f681ef", "branch_name": "refs/heads/master", "committer_date": 1573569542000, "content_id": "b9524c1d6e0d87712622e677191cc13728cd1647", "detected_licenses": [ "MIT" ], "directory_id": "0d56a36196bba73ec930c69f8415613a380a292b", "extension": "py", "fi...
3.5625
stackv2
#!/usr/bin/python3 from Crypto.Protocol.KDF import PBKDF2 from Crypto.Hash import SHA256, HMAC from Crypto.Cipher import AES from Crypto import Random import binascii class AES_CBC_PBKDF2(): def __init__(self, text, key=str, salt=bytes): self.text = text self.salt = salt self.key = key ...
85
30.72
95
16
802
python
[{"finding_id": "codeql_py/weak-cryptographic-algorithm_57370c4cb7d96242_18c42dfe", "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": ...
2
true
[ "CWE-327", "CWE-327" ]
[ "py/weak-cryptographic-algorithm", "py/weak-cryptographic-algorithm" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "[The block mode ECB](1) is broken or weak, and should not be used.", "[The block mode ECB](1) is broken or weak, and should not be used." ]
[ 23, 27 ]
[ null, null ]
[ 16, 16 ]
[ 34, 34 ]
2024-11-19T01:44:00.282871+00:00
1,587,997,898,000
3e4199cafbce3166bf92a670c8d79c5e43215a3e
3
{ "blob_id": "3e4199cafbce3166bf92a670c8d79c5e43215a3e", "branch_name": "refs/heads/master", "committer_date": 1587997898000, "content_id": "7afd252ee8a32d405fbdd777b6d262ffeda98bca", "detected_licenses": [ "MIT" ], "directory_id": "d9349305bccb46ec2f00e016be4a2be3fba8a993", "extension": "py", "fi...
2.8125
stackv2
from flask import Blueprint, request, jsonify, render_template import os import random import json import datetime comics = Blueprint('comics', __name__) @comics.route('/random') def random_comic(): is_json = request.args.get('json') all_comics = os.listdir('apis/data/comics/') r = random.randint(0, len(...
62
29.6
92
17
456
python
[{"finding_id": "codeql_py/stack-trace-exposure_1c59f324632bb1b5_e8fc97f7", "tool_name": "codeql", "rule_id": "py/stack-trace-exposure", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "[Stack trace information](1) flows to this location and may be exposed to an external user.", "...
2
true
[ "CWE-209", "CWE-022" ]
[ "py/stack-trace-exposure", "py/path-injection" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "[Stack trace information](1) flows to this location and may be exposed to an external user.", "This path depends on a [user-provided value](1)." ]
[ 36, 32 ]
[ null, null ]
[ 24, 19 ]
[ 77, 58 ]
2024-11-19T01:44:02.395378+00:00
1,462,508,032,000
bcb7dfb9447b5884c2546e81a2482e07b96285c9
3
{ "blob_id": "bcb7dfb9447b5884c2546e81a2482e07b96285c9", "branch_name": "refs/heads/master", "committer_date": 1462508032000, "content_id": "13f44a995b6784a37da7d960fa4877d0aa7344e7", "detected_licenses": [ "MIT" ], "directory_id": "ae8bfda28bc401e1b51f6da79187bd03c42a79f3", "extension": "py", "fi...
2.65625
stackv2
__author__ = 'Jeff' import re import os import zipfile import smtplib import getpass from email import encoders from email.mime.base import MIMEBase from email.mime.text import MIMEText from email.mime.multipart import MIMEMultipart userEmail = '' toEmail = '' while 1: userEmail = input("Please enter your email ...
238
29.59
108
22
1,850
python
[{"finding_id": "codeql_py/overly-large-range_bfe12192e55360b0_2d5ffd6d", "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\\]." ]
[ 212 ]
[ null ]
[ 31 ]
[ 34 ]