added
stringlengths
32
32
created
int64
1,244B
1,694B
id
stringlengths
40
40
int_score
int64
2
5
metadata
dict
score
float64
2.31
5.25
source
stringclasses
1 value
text
stringlengths
324
20.1k
num_lines
int64
16
598
avg_line_length
float64
15.1
58.3
max_line_length
int64
33
179
ast_depth
int64
8
39
length
int64
101
3.8k
lang
stringclasses
1 value
sast_codeql_findings
stringlengths
1.1k
265k
sast_codeql_findings_count
int64
1
45
sast_codeql_success
bool
1 class
sast_codeql_error
stringclasses
1 value
cwe_ids
listlengths
1
45
rule_ids
listlengths
1
45
confidences
listlengths
1
45
severities
listlengths
1
45
messages
listlengths
1
45
line_starts
listlengths
1
45
line_ends
listlengths
1
45
column_starts
listlengths
1
45
column_ends
listlengths
1
45
2024-11-18T21:55:49.533398+00:00
1,588,078,514,000
eace1d7813f46e032a8c4397428086d8bc500fc7
3
{ "blob_id": "eace1d7813f46e032a8c4397428086d8bc500fc7", "branch_name": "refs/heads/master", "committer_date": 1588078514000, "content_id": "cce071f2a8ef26942ddc2c32b75cb1e4e27495bf", "detected_licenses": [ "BSD-3-Clause-Clear", "MIT", "BSD-3-Clause" ], "directory_id": "ca2ebf85d457a4693305107...
2.921875
stackv2
""" Description: The script we use to prepare the directory/files needed to export a model to the Kipoi model zoo. Output: Saves model.yaml, class names, and model state dictionary weights to a user-specified output directory. Usage: kipoi_export.py <saved-model-pth> <class-names> <config-yaml> <o...
118
31.86
78
12
913
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_141615deaef7a1f5_401f08d5", "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." ]
[ 85 ]
[ null ]
[ 20 ]
[ 48 ]
2024-11-18T21:55:54.266577+00:00
1,617,814,526,000
37a2bafe1988b60b3d403e7195c507686d225c89
2
{ "blob_id": "37a2bafe1988b60b3d403e7195c507686d225c89", "branch_name": "refs/heads/master", "committer_date": 1617814526000, "content_id": "606edc3070bd5e542a9a768c731f9e95ef340f46", "detected_licenses": [ "MIT" ], "directory_id": "056c9cf8df69748c4ac6f1ae1e25795d2b4c2e0b", "extension": "py", "fi...
2.3125
stackv2
from http.server import BaseHTTPRequestHandler import http import argparse from urllib.parse import urlparse from urllib.parse import urlencode from urllib.parse import parse_qs from urllib.parse import unquote import socket, ssl, pprint from io import BytesIO XSS = "'\"><img src=\"\" onerror=alert(\"\")>" FILE_PATH =...
133
34.11
144
20
1,022
python
[{"finding_id": "codeql_py/insecure-default-protocol_3d13245b90d4b0f8_c0b22ade", "tool_name": "codeql", "rule_id": "py/insecure-default-protocol", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Call to deprecated method ssl.wrap_socket does not specify a protocol, which may result in...
1
true
[ "CWE-327" ]
[ "py/insecure-default-protocol" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "Call to deprecated method ssl.wrap_socket does not specify a protocol, which may result in an insecure default being used." ]
[ 18 ]
[ null ]
[ 20 ]
[ 38 ]
2024-11-18T21:55:57.263707+00:00
1,552,533,124,000
7cc280998580390432f642b1eb03fc5ca50b3269
2
{ "blob_id": "7cc280998580390432f642b1eb03fc5ca50b3269", "branch_name": "refs/heads/master", "committer_date": 1552533124000, "content_id": "7563adf171ce3249e99857f9a73fe976f77cb277", "detected_licenses": [ "MIT" ], "directory_id": "4949c2059b4e9e6a5be4626dcc928dc08f371dcb", "extension": "py", "fi...
2.34375
stackv2
# -*- coding:utf8 -*- # !/usr/bin/env python # Copyright 2017 Google Inc. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2...
313
34.54
81
14
2,425
python
[{"finding_id": "codeql_py/stack-trace-exposure_65cd9c0c82531609_eb3514df", "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.\n[S...
2
true
[ "CWE-209", "CWE-215" ]
[ "py/stack-trace-exposure", "py/flask-debug" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "[Stack trace information](1) flows to this location and may be exposed to an external user.\n[Stack trace information](2) flows to this location and may be exposed to an external user.\n[Stack trace information](3) flows to this location and may be exposed to an external user.\n[Stack trace information](4) flows t...
[ 60, 313 ]
[ null, null ]
[ 34, 5 ]
[ 62, 40 ]
2024-11-18T21:55:58.033824+00:00
1,626,230,416,000
889abb0848e0fd4d542d0462e9a933b6d0686597
3
{ "blob_id": "889abb0848e0fd4d542d0462e9a933b6d0686597", "branch_name": "refs/heads/master", "committer_date": 1626230416000, "content_id": "1c33247d1ebd76b37c331b06ae4b8b207ceb0b05", "detected_licenses": [ "MIT" ], "directory_id": "ffd1694d89e2b43db95de3fdc5729564ec267428", "extension": "py", "fi...
2.65625
stackv2
import json import logging from typing import Any, Sequence, Optional, Tuple, Iterable, MutableMapping, Union import requests import time from .models.metabase import MetabaseModel, MetabaseColumn class MetabaseClient: """Metabase API client.""" _SYNC_PERIOD_SECS = 5 def __init__( self, ...
479
34.19
149
22
3,329
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_8a753aa1c76cf3fb_9545e38f", "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." ]
[ 467 ]
[ null ]
[ 25 ]
[ 39 ]
2024-11-18T21:56:04.967874+00:00
1,609,517,342,000
1581a68f26bcc4fb73b2ed9edaea491e4e9d3383
3
{ "blob_id": "1581a68f26bcc4fb73b2ed9edaea491e4e9d3383", "branch_name": "refs/heads/main", "committer_date": 1609517342000, "content_id": "0951251504201918967251cb47e0d6a752221335", "detected_licenses": [ "MIT" ], "directory_id": "b18b6628e156bfba80468a7da6e9cf12eae5a960", "extension": "py", "file...
2.53125
stackv2
import secrets import os from PIL import Image from flask import render_template, flash, redirect, request, url_for, abort from flaskblog.forms import RegistrationForm, LoginForm, UpdateAccountForm, PostForm from flaskblog.models import User,Posts from flaskblog import app, db, bcrypt from flask_login import login_use...
157
34.8
116
18
1,248
python
[{"finding_id": "codeql_py/url-redirection_5de031f7364b7200_23328eb0", "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)." ]
[ 54 ]
[ null ]
[ 33 ]
[ 42 ]
2024-11-18T23:06:12.801702+00:00
1,474,752,296,000
581a0b37e53f62b991a33ab5ddc94ef75dc4d212
2
{ "blob_id": "581a0b37e53f62b991a33ab5ddc94ef75dc4d212", "branch_name": "refs/heads/master", "committer_date": 1474752302000, "content_id": "6c6fb234f5d138bd2f4dc0d40050ca16e240db3b", "detected_licenses": [ "MIT" ], "directory_id": "79b1d6d9f9f5f074c13d935a1a4b4409e0b6ccc8", "extension": "py", "fi...
2.390625
stackv2
from flask import Flask import pandas as pd import json from sqlalchemy import create_engine from sqlalchemy import text from sqlalchemy import inspect def object_as_dict(obj): return {c.key: getattr(obj, c.key) for c in inspect(obj).mapper.column_attrs} engine = create_engine('sqlite:///nba.db') def ru...
38
19.47
52
11
186
python
[{"finding_id": "codeql_py/sql-injection_2a4db3349e384495_c912cb52", "tool_name": "codeql", "rule_id": "py/sql-injection", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This SQL query depends on a [user-provided value](1).", "remediation": "", "location": {"file_path": "unknown...
1
true
[ "CWE-089" ]
[ "py/sql-injection" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This SQL query depends on a [user-provided value](1)." ]
[ 16 ]
[ null ]
[ 14 ]
[ 19 ]
2024-11-18T23:06:16.818276+00:00
1,587,974,576,000
14e77e5facb84e57b72e06e799a4182451b73408
3
{ "blob_id": "14e77e5facb84e57b72e06e799a4182451b73408", "branch_name": "refs/heads/master", "committer_date": 1587974576000, "content_id": "5273fc3a2ab6a29b586b033542fde4fc59703bdb", "detected_licenses": [ "Apache-2.0" ], "directory_id": "7e4b6e6aa20557091f112673b936a20ed9bce0db", "extension": "py"...
2.703125
stackv2
#!/usr/bin/python3 import netmiko # multi vendor library from getpass import getpass sec=getpass("plz enter password for device : ") # accept password without showing in screen device1={ 'username' : 'root', 'password' : sec, 'device_type' : 'cisco_ios', 'host' : '172.16.6.12' } sec1=getpass("plz enter pass...
47
30.77
88
12
401
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_012601cabb44cef2_ddaf564e", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (password)](1) as clear text.\nT...
5
true
[ "CWE-312", "CWE-312", "CWE-312", "CWE-312", "CWE-312" ]
[ "py/clear-text-logging-sensitive-data", "py/clear-text-logging-sensitive-data", "py/clear-text-logging-sensitive-data", "py/clear-text-logging-sensitive-data", "py/clear-text-logging-sensitive-data" ]
[ "HIGH", "HIGH", "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "This expression logs [sensitive data (password)](1) as clear text.\nThis expression logs [sensitive data (password)](2) as clear text.", "This expression logs [sensitive data (password)](1) as clear text.\nThis expression logs [sensitive data (password)](2) as clear text.", "This expression logs [sensitive dat...
[ 31, 31, 43, 45, 47 ]
[ null, null, null, null, null ]
[ 48, 79, 52, 66, 52 ]
[ 64, 88, 61, 75, 61 ]
2024-11-18T23:06:17.519485+00:00
1,608,236,106,000
8ce04ef36e9c2f87f4e2c4e2e17213d7ef091f78
3
{ "blob_id": "8ce04ef36e9c2f87f4e2c4e2e17213d7ef091f78", "branch_name": "refs/heads/master", "committer_date": 1608236106000, "content_id": "f633d026ec007ea3ba2a8e5421338cf2046e77b5", "detected_licenses": [ "MIT" ], "directory_id": "26f6bcbf436c6bc39b959daf31c9291c50a5c904", "extension": "py", "fi...
2.640625
stackv2
import postgres from flask import Flask, jsonify from flask_cors import CORS from flask import request import Parsers app = Flask(__name__) CORS(app) api_url = '/api/v1.0' dota = Parsers.Dota() overwatch = Parsers.Overwatch() pg = postgres.Postgress() @app.route('/') def hello_world(): return 'Hello World!' # ...
78
26.85
76
18
557
python
[{"finding_id": "codeql_py/stack-trace-exposure_f2d202d2cc58135d_5be5905b", "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-079" ]
[ "py/stack-trace-exposure", "py/reflective-xss" ]
[ "HIGH", "HIGH" ]
[ "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)." ]
[ 48, 55 ]
[ null, null ]
[ 16, 16 ]
[ 17, 77 ]
2024-11-18T23:06:19.083308+00:00
1,563,316,685,000
0287638b659590f6c8c5e6e78ba940db7e3e922c
3
{ "blob_id": "0287638b659590f6c8c5e6e78ba940db7e3e922c", "branch_name": "refs/heads/master", "committer_date": 1563316685000, "content_id": "ef00dc1187200bd7be3c2ad5bb335f1ea0004b8d", "detected_licenses": [ "BSD-2-Clause", "BSD-3-Clause" ], "directory_id": "0bf5f81cf4689c7dcb2c8136b24ed637c149c39f...
2.96875
stackv2
from os.path import join import requests # PATRIC service endpoint patric_url = 'https://www.patricbrc.org/api/' def get_genome_summary(genome_id): """ Get the summary data for a genome in PATRIC. Parameters ---------- genome_id : str Genome ID of genome available in PATRIC Returns ...
154
32.19
103
17
1,146
python
[{"finding_id": "codeql_py/request-without-cert-validation_0641f1c3c4b755b3_37e359cb", "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)." ]
[ 24 ]
[ null ]
[ 16 ]
[ 71 ]
2024-11-18T22:43:25.227154+00:00
1,624,540,493,000
98b705b8745ea9f539f4e9a08af27bd40be13a13
3
{ "blob_id": "98b705b8745ea9f539f4e9a08af27bd40be13a13", "branch_name": "refs/heads/main", "committer_date": 1624540493000, "content_id": "1a891d8ea3705ca18a97f115591efe155c8c6d24", "detected_licenses": [ "MIT" ], "directory_id": "65f856bb3c782fe2fec794192260d5b7aa997ef3", "extension": "py", "file...
2.75
stackv2
"""项目要用到的一些类和函数""" import datetime import re import random import requests from django_redis import get_redis_connection from rest_framework import serializers from settings import BAIDU_APIKEY, BAIDU_SECRETKEY from wsc_django.utils.region_file import REGION ORDER_SHOP_TYPE_PREFIX = "60" # 微商城系统店铺类型固定订单前缀 class ...
198
29.05
125
20
1,506
python
[{"finding_id": "codeql_py/request-without-cert-validation_0da9f31ed33f777a_afc1bfc6", "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)." ]
[ 188 ]
[ 192 ]
[ 16 ]
[ 10 ]
2024-11-18T22:43:25.856644+00:00
1,692,197,318,000
d48d47bd8065373c8b18b532764544637b966bb7
2
{ "blob_id": "d48d47bd8065373c8b18b532764544637b966bb7", "branch_name": "refs/heads/master", "committer_date": 1692197318000, "content_id": "204b1bb058ff6d75428d7ba7cb250c296dc8fefb", "detected_licenses": [ "Apache-2.0" ], "directory_id": "5d9997b08860f592e3967d1f437f85b4faf8999c", "extension": "py"...
2.375
stackv2
# # worker.py - Thread that shepherds a job through it execution sequence # import threading import time import logging import tempfile import requests from requests.packages.urllib3.util.retry import Retry from requests.adapters import HTTPAdapter import os import shutil from datetime import datetime from config impo...
374
38.13
88
21
3,217
python
[{"finding_id": "codeql_py/insecure-temporary-file_7008357400de9286_a38362c0", "tool_name": "codeql", "rule_id": "py/insecure-temporary-file", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Call to deprecated function tempfile.mktemp may be insecure.", "remediation": "", "location": ...
2
true
[ "CWE-377", "CWE-295" ]
[ "py/insecure-temporary-file", "py/request-without-cert-validation" ]
[ "HIGH", "MEDIUM" ]
[ "MEDIUM", "MEDIUM" ]
[ "Call to deprecated function tempfile.mktemp may be insecure.", "This request may run without certificate validation because [it is disabled](1)." ]
[ 172, 144 ]
[ null, 146 ]
[ 23, 32 ]
[ 40, 22 ]
2024-11-18T22:44:14.451606+00:00
1,532,506,172,000
3f56c7f0fe6d249d2b735e4ec42fb2df17faceea
2
{ "blob_id": "3f56c7f0fe6d249d2b735e4ec42fb2df17faceea", "branch_name": "refs/heads/master", "committer_date": 1532506172000, "content_id": "9e7d9c2e85221ca8488c8264a7c2a133405b4eb9", "detected_licenses": [ "Apache-2.0" ], "directory_id": "6425ae8784553066283f4c8f17bcf407655dfd1b", "extension": "py"...
2.40625
stackv2
import os import json import tarfile from catalyst.constants import SUPPORTED_WALLETS from catalyst.utils.deprecate import deprecated from catalyst.utils.paths import data_root, ensure_directory from catalyst.marketplace.marketplace_errors import MarketplaceJSONError def get_marketplace_folder(environ=None): """...
212
22.92
79
20
1,062
python
[{"finding_id": "codeql_py/tarslip_cf8e9081d205ece8_d7a46bbf", "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)." ]
[ 105 ]
[ null ]
[ 9 ]
[ 12 ]
2024-11-18T23:10:40.036369+00:00
1,499,484,132,000
492e8b273eecd0265f022839e97daa9eac081f1f
3
{ "blob_id": "492e8b273eecd0265f022839e97daa9eac081f1f", "branch_name": "refs/heads/master", "committer_date": 1499484132000, "content_id": "47344cc4a3aa3e8b3479bd22ec04e0aa3e7ddb11", "detected_licenses": [ "MIT" ], "directory_id": "9b77193e9b46a39d649c2be73e35f7f047dc4c18", "extension": "py", "fi...
2.78125
stackv2
#! /usr/bin/env python2 """This script serves as a client example of registering a backend. Your credentials are encrypted prior to transport and your api gateway key is used to encrypt and validate you as a user on the other end. """ from os import environ as env, path import sys sys.path.append(path.dirname(path.dirn...
63
33.22
79
14
460
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_b874f57e1f24816b_47981576", "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." ]
[ 34 ]
[ 40 ]
[ 15 ]
[ 47 ]
2024-11-18T23:10:12.153287+00:00
1,687,848,724,000
80ea976a5bfff180cef2ed60aa3b4b788556b968
2
{ "blob_id": "80ea976a5bfff180cef2ed60aa3b4b788556b968", "branch_name": "refs/heads/master", "committer_date": 1687848724000, "content_id": "1a43b09b60330f744ce2fb1768157b5192eff5be", "detected_licenses": [ "MIT" ], "directory_id": "538f4f93f30536626360e88597171895e3f377a4", "extension": "py", "fi...
2.375
stackv2
import os import boto3 import uuid from flask import request, jsonify from flask_lambda import FlaskLambda from flask_cors import CORS from rook.serverless import rookout_serverless REGION = os.environ['REGION_NAME'] TABLE_NAME = os.environ['TABLE_NAME'] app = FlaskLambda(__name__) cors = CORS(app) # add dynamo DB i...
131
31.18
105
18
986
python
[{"finding_id": "codeql_py/stack-trace-exposure_e5255d02adf4fca9_cf1473a1", "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-209", "CWE-209", "CWE-209" ]
[ "py/stack-trace-exposure", "py/stack-trace-exposure", "py/stack-trace-exposure", "py/stack-trace-exposure" ]
[ "HIGH", "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "[Stack trace information](1) flows to this location and may be exposed to an external user.", "[Stack trace information](1) flows to this location and may be exposed to an external user.", "[Stack trace information](1) flows to this location and may be exposed to an external user.\n[Stack trace information](1)...
[ 55, 76, 116, 124 ]
[ null, null, null, null ]
[ 24, 24, 24, 24 ]
[ 64, 64, 78, 74 ]
2024-11-18T23:15:54.484135+00:00
1,691,103,980,000
b886b0df454015d789dd242776298a890fcd5f72
3
{ "blob_id": "b886b0df454015d789dd242776298a890fcd5f72", "branch_name": "refs/heads/master", "committer_date": 1691103980000, "content_id": "1599107dff265d6b9062323f9c0a39cc19dc7dea", "detected_licenses": [ "Apache-2.0" ], "directory_id": "0d7b8255b18046b5fde9c5870b9c34b4c2353e72", "extension": "py"...
2.78125
stackv2
import os import re import requests from urllib.parse import urlparse, parse_qs from ftplib import FTP from bs4 import BeautifulSoup import zipfile from config import DATA_ARCHIVE_ROOT from biothings.hub.dataload.dumper import HTTPDumper, DumperException from biothings.utils.common import unzipall class DBNSFPDumper...
187
42.86
151
17
1,901
python
[{"finding_id": "codeql_py/incomplete-url-substring-sanitization_2cfb245ed2e0b216_b0f4a905", "tool_name": "codeql", "rule_id": "py/incomplete-url-substring-sanitization", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "The string [box.com](1) may be at an arbitrary position in the san...
1
true
[ "CWE-020" ]
[ "py/incomplete-url-substring-sanitization" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "The string [box.com](1) may be at an arbitrary position in the sanitized URL." ]
[ 133 ]
[ null ]
[ 14 ]
[ 61 ]
2024-11-18T23:15:56.249919+00:00
1,599,053,689,000
e0ccf24cc36487f7846d3828808b48e81524864e
3
{ "blob_id": "e0ccf24cc36487f7846d3828808b48e81524864e", "branch_name": "refs/heads/master", "committer_date": 1599053689000, "content_id": "f6acc131dd7fcd6f310d2c0f0decfad5101d303d", "detected_licenses": [ "Apache-2.0" ], "directory_id": "5fe72bb13baf3649058ebe11aa86ad4fc56c69ed", "extension": "py"...
2.515625
stackv2
#!/usr/bin/python from urlgrab import Cache from BeautifulSoup import MinimalSoup as BeautifulSoup from re import compile from os.path import exists, getsize, dirname, join from urllib import urlretrieve, urlencode, quote from sys import argv import demjson import zlib folder = dirname(argv[0]) cache = Cache(debug=F...
102
34.85
142
19
836
python
[{"finding_id": "codeql_py/incomplete-hostname-regexp_0450164cb17e95d4_dc0c3c42", "tool_name": "codeql", "rule_id": "py/incomplete-hostname-regexp", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "This regular expression has an unescaped '.' before '(?:themis-media|escapistmagazine).c...
1
true
[ "CWE-020" ]
[ "py/incomplete-hostname-regexp" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This regular expression has an unescaped '.' before '(?:themis-media|escapistmagazine).com/', so it might match more hosts than expected." ]
[ 41 ]
[ null ]
[ 24 ]
[ 139 ]
2024-11-18T22:30:27.047327+00:00
1,596,648,258,000
be2fc34a766f11ae5c1d3688ab8817a9b3d9d841
3
{ "blob_id": "be2fc34a766f11ae5c1d3688ab8817a9b3d9d841", "branch_name": "refs/heads/master", "committer_date": 1596648258000, "content_id": "308e45742573b3e7dbda7846eeccebd524e6ff41", "detected_licenses": [ "MIT" ], "directory_id": "f1d3a4d7bca73c70c423dd8f32949b500206520a", "extension": "py", "fi...
3.015625
stackv2
import os import tarfile import requests def download_mnist(): url = 'https://github.com/myleott/mnist_png/raw/master/mnist_png.tar.gz' base_path = './data' file_name = 'mnist.tar.gz' # Check if file has been extracted if os.path.isdir(os.path.join(base_path, 'mnist')): print('MNIST i...
34
28.44
85
14
246
python
[{"finding_id": "codeql_py/tarslip_fb83df8f7e5929ca_01078cf8", "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)." ]
[ 30 ]
[ null ]
[ 5 ]
[ 8 ]
2024-11-18T22:44:41.983340+00:00
1,593,818,654,000
82e9e4e75118f7916176f4eeab082ee61eb978cd
3
{ "blob_id": "82e9e4e75118f7916176f4eeab082ee61eb978cd", "branch_name": "refs/heads/master", "committer_date": 1593818654000, "content_id": "1ecb06812005b1da508a26b80735ba33bac361f2", "detected_licenses": [ "BSD-3-Clause" ], "directory_id": "8ff68383de2788b621a3f64c3548c6fb71810bc1", "extension": "p...
2.671875
stackv2
# -*- coding: utf-8 -*- ''' Requirement: This code uses Stanford Log-linear Part-Of-Speech Tagger from https://nlp.stanford.edu/software/tagger.shtml Please download it and change the directory in tagger_pos accordingly ''' import os import re from shutil import rmtree from nltk.corpus import stopwords as sw from nl...
244
39.62
95
23
2,619
python
[{"finding_id": "codeql_py/overly-large-range_8750fa89b8e98acb_c1bf299d", "tool_name": "codeql", "rule_id": "py/overly-large-range", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Suspicious character range that is equivalent to \\[A-Z\\\\[\\\\\\\\]^_`a-z\\].", "remediation": "", "lo...
1
true
[ "CWE-020" ]
[ "py/overly-large-range" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "Suspicious character range that is equivalent to \\[A-Z\\\\[\\\\\\\\]^_`a-z\\]." ]
[ 93 ]
[ null ]
[ 48 ]
[ 51 ]
2024-11-18T22:44:45.859176+00:00
1,562,910,710,000
d167c49790e8a6128a8db8a87d0649ec2d118d86
3
{ "blob_id": "d167c49790e8a6128a8db8a87d0649ec2d118d86", "branch_name": "refs/heads/master", "committer_date": 1562910710000, "content_id": "d05e801d84783b6202c87a13095af64fe21da0d1", "detected_licenses": [ "MIT" ], "directory_id": "69576566fc4c2b32d6e64bfef14013cf3c9e3475", "extension": "py", "fi...
2.890625
stackv2
"""取引所(バイナンス)から通貨情報を取得する""" # coding: UTF-8 文字コード指定 import time import ccxt # 取引所ライブラリをインポート import os # パスを操作するモジュール import sys # パスを読み込むモジュール sys.path.append(os.path.abspath(os.path.join('..'))) # 自作モジュールのパス指定 # sqlite3 標準モジュールをインポート from sqlalchemy import exc from app.module.exchangess.setting import session fr...
99
31.65
102
16
913
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_eace6da10f64cca2_b4acef5a", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (secret)](1) as clear text.", "r...
1
true
[ "CWE-312" ]
[ "py/clear-text-logging-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression logs [sensitive data (secret)](1) as clear text." ]
[ 99 ]
[ null ]
[ 18 ]
[ 36 ]
2024-11-18T22:44:50.253314+00:00
1,621,737,801,000
ed42abee0a4496e597f4c36b4c4e04c6ea227749
3
{ "blob_id": "ed42abee0a4496e597f4c36b4c4e04c6ea227749", "branch_name": "refs/heads/master", "committer_date": 1621737801000, "content_id": "25bd36f15b98cd28f7b0ab4634f0d46a0d52906d", "detected_licenses": [ "MIT" ], "directory_id": "18a6b272d4c55b24d9c179ae1e58959674e53afe", "extension": "py", "fi...
2.609375
stackv2
# original code: https://github.com/joeybose/FloRL/blob/master/pytorch-soft-actor-critic/plots/plot_comet.py import argparse import csv import json import os from statistics import mean # from comet_ml import API import matplotlib import numpy as np matplotlib.use('Agg') import matplotlib.pyplot as plt import seabor...
167
32.49
119
17
1,353
python
[{"finding_id": "codeql_py/clear-text-storage-sensitive-data_360cec7c93cbe5f1_16e730b1", "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."...
3
true
[ "CWE-312", "CWE-312", "CWE-312" ]
[ "py/clear-text-storage-sensitive-data", "py/clear-text-storage-sensitive-data", "py/clear-text-logging-sensitive-data" ]
[ "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "This expression stores [sensitive data (password)](1) as clear text.", "This expression stores [sensitive data (password)](1) as clear text.", "This expression logs [sensitive data (password)](1) as clear text." ]
[ 52, 53, 50 ]
[ null, null, null ]
[ 22, 22, 11 ]
[ 58, 67, 54 ]
2024-11-18T23:36:54.777458+00:00
1,675,884,890,000
89d9801503e8d60fede77f06f9049c4ebf639813
3
{ "blob_id": "89d9801503e8d60fede77f06f9049c4ebf639813", "branch_name": "refs/heads/master", "committer_date": 1675884890000, "content_id": "117f7f01cd516101422f0cbdb9bbfbfca0e2a8b0", "detected_licenses": [ "Apache-2.0" ], "directory_id": "30b06187f8c6f30de84b8a93f24bce5562afa947", "extension": "py"...
3
stackv2
import logging import requests from src import common from tools import ExcelOps def monitor_poe(baseurl, cookie_header): """ Write POE details to an excel sheet - MonitorPOE.xlsx in the same folder :param baseurl: imported baseurl variable :param cookie_header: Parse cookie resulting from successful ...
100
42.43
116
16
1,013
python
[{"finding_id": "codeql_py/request-without-cert-validation_0e709f6a7f357366_21490ebd", "tool_name": "codeql", "rule_id": "py/request-without-cert-validation", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "This request may run without certificate validation because [it is disabled]...
3
true
[ "CWE-295", "CWE-295", "CWE-295" ]
[ "py/request-without-cert-validation", "py/request-without-cert-validation", "py/request-without-cert-validation" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "This request may run without certificate validation because [it is disabled](1).", "This request may run without certificate validation because [it is disabled](1).", "This request may run without certificate validation because [it is disabled](1)." ]
[ 38, 44, 73 ]
[ null, null, null ]
[ 20, 20, 16 ]
[ 68, 68, 64 ]
2024-11-18T23:37:11.318485+00:00
1,555,256,369,000
34eef154c87dd309e6b6ed45f78b355b6b4207f8
3
{ "blob_id": "34eef154c87dd309e6b6ed45f78b355b6b4207f8", "branch_name": "refs/heads/master", "committer_date": 1555256369000, "content_id": "807c13ad929b848a89d5d0cec028c8d137638afa", "detected_licenses": [ "Apache-2.0" ], "directory_id": "e7d197774f5123ee14e00bfe6134fb07efd6626b", "extension": "py"...
2.921875
stackv2
import spacy from Appointments import Appointments from NLPEngine import NLP from Response import ResponseType from ResponseGenerator import ResponseGenerator from parser import NameInqParser, Request class Robot: def __init__(self, robot_name, save_path): self.robot_name = robot_name self.save_p...
54
34.31
114
18
394
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_c42e8012f4fe85fc_dfaff6a4", "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." ]
[ 23 ]
[ null ]
[ 15 ]
[ 21 ]
2024-11-18T21:14:04.388672+00:00
1,597,639,749,000
1a3028266c638a8da63bb40ec3f21449c16f5d50
3
{ "blob_id": "1a3028266c638a8da63bb40ec3f21449c16f5d50", "branch_name": "refs/heads/master", "committer_date": 1597639749000, "content_id": "cefbc460ecc6af99f88b6b54466731e3b1b87f2a", "detected_licenses": [ "MIT" ], "directory_id": "4e78a042f555ee1f65316353363d6cd59011f3ac", "extension": "py", "fi...
2.84375
stackv2
from sqlalchemy import ( Column, String, ) from models import Model from models.base_model import ( SQLMixin, db, ) from utils import log class User(SQLMixin, db.Model): """ User is a model storing user data, including two properties now """ username = Column(String(50), nullable=...
62
25.84
88
17
387
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_d6ffdce1ce80adab_3e3ccf69", "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...
[ 26 ]
[ null ]
[ 35 ]
[ 60 ]
2024-11-18T21:57:25.151640+00:00
1,596,704,908,000
b4bab02ddae8e846ee00ac7b65928cd762fdaf03
3
{ "blob_id": "b4bab02ddae8e846ee00ac7b65928cd762fdaf03", "branch_name": "refs/heads/master", "committer_date": 1596704908000, "content_id": "c1bd9f08b6e5015cd6eabeca9023a151769a447a", "detected_licenses": [ "BSD-3-Clause" ], "directory_id": "b42102a215a0e149a632b98878a93b821a1aad57", "extension": "p...
2.71875
stackv2
import numpy as np from sklearn.model_selection import StratifiedKFold, train_test_split, GroupShuffleSplit, ShuffleSplit from sklearn.metrics import accuracy_score, f1_score, roc_auc_score, roc_curve from sklearn.ensemble import RandomForestClassifier, GradientBoostingClassifier from sklearn.preprocessing import MinMa...
159
35.71
123
19
1,521
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_b13af6015711433d_9a86bf46", "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." ]
[ 37 ]
[ null ]
[ 31 ]
[ 41 ]
2024-11-18T21:57:35.273219+00:00
1,582,841,178,000
cd1cdb7e12f3633a4c737e6d0bf5891dee5b77e6
3
{ "blob_id": "cd1cdb7e12f3633a4c737e6d0bf5891dee5b77e6", "branch_name": "refs/heads/master", "committer_date": 1582841178000, "content_id": "128dfb4a84bfb1a90dca208bffa20b29f1466a9b", "detected_licenses": [ "MIT" ], "directory_id": "d0ff7ab12e5caa14da5f795a25aa6a55f3c5aa0b", "extension": "py", "fi...
2.84375
stackv2
#!/usr/bin/env python3 from __future__ import print_function # http://python-future.org/compatible_idioms.html ######################################### # print_cert.py # Extract information from SSL Certificates, Private Keys and PKCS12 archives # Certificates can be retrieved from either files or from a HTTP server ...
196
31.97
118
20
1,591
python
[{"finding_id": "codeql_py/insecure-protocol_e8e3ecc54efb8bda_8454dbbd", "tool_name": "codeql", "rule_id": "py/insecure-protocol", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Insecure SSL/TLS protocol version TLSv1 specified by [call to Context](1).", "remediation": "", "location"...
1
true
[ "CWE-327" ]
[ "py/insecure-protocol" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "Insecure SSL/TLS protocol version TLSv1 specified by [call to Context](1)." ]
[ 81 ]
[ null ]
[ 33 ]
[ 54 ]
2024-11-18T21:58:12.991017+00:00
1,665,610,246,000
f203aab9a32845f053a8d9085b108a5dd055ebc8
2
{ "blob_id": "f203aab9a32845f053a8d9085b108a5dd055ebc8", "branch_name": "refs/heads/master", "committer_date": 1665610246000, "content_id": "1047d092ecca81c1d600df7bb47eb4d5a9eebba0", "detected_licenses": [ "Apache-2.0" ], "directory_id": "c1c63610a860508d77377b562659f59facb52528", "extension": "py"...
2.4375
stackv2
# -*- coding: utf8 -*- import json import hashlib import csv import logging import sys from urllib.request import urlopen from urllib.parse import urljoin, quote, urlsplit, urlunsplit import requests import lxml.html import lxml.etree from .consts import * try: from bmemcached import Client from zlib import com...
73
30
104
15
583
python
[{"finding_id": "codeql_py/request-without-cert-validation_1db36cf173fc32ba_5c35bfd5", "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, 59 ]
[ null, null ]
[ 9, 13 ]
[ 83, 76 ]
2024-11-18T21:58:38.708217+00:00
1,428,076,296,000
ab43a4be885ff54a9fed4cbc433f0174481a8d7b
2
{ "blob_id": "ab43a4be885ff54a9fed4cbc433f0174481a8d7b", "branch_name": "refs/heads/master", "committer_date": 1428076296000, "content_id": "03044198a804945cf592aa3a53b643c121c0c5f3", "detected_licenses": [ "Apache-2.0" ], "directory_id": "71f6c23bf0d20ec398affc25816caad96721d7d8", "extension": "py"...
2.453125
stackv2
"""Provides functions useful for background services.""" """Copyright and License. Copyright 2012-2014 Gregory Holt 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/license...
427
36.07
79
22
3,672
python
[{"finding_id": "codeql_py/insecure-default-protocol_8404f4c6b827d729_80755a15", "tool_name": "codeql", "rule_id": "py/insecure-default-protocol", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Call to deprecated method ssl.wrap_socket does not specify a protocol, which may result in...
3
true
[ "CWE-327", "CWE-200", "CWE-200" ]
[ "py/insecure-default-protocol", "py/bind-socket-all-network-interfaces", "py/bind-socket-all-network-interfaces" ]
[ "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "Call to deprecated method ssl.wrap_socket does not specify a protocol, which may result in an insecure default being used.", "'0.0.0.0' binds a socket to all interfaces.", "'0.0.0.0' binds a socket to all interfaces." ]
[ 229, 226, 291 ]
[ null, null, null ]
[ 24, 13, 13 ]
[ 77, 34, 34 ]
2024-11-18T22:47:26.251152+00:00
1,627,855,994,000
91a83f5fd32a87cfe7fddcdfdd7df12d0664f336
4
{ "blob_id": "91a83f5fd32a87cfe7fddcdfdd7df12d0664f336", "branch_name": "refs/heads/main", "committer_date": 1627855994000, "content_id": "992d2caa699033246d6b8afab69f10daecde8447", "detected_licenses": [ "MIT" ], "directory_id": "fdf64807c4872b69e44b895d12b3134a2787168f", "extension": "py", "file...
3.859375
stackv2
import random import string # int number generate between 10 and 20 # int_number = random.randint(10, 20) # random int using the function range() int_number = random.randrange(900, 1000, 10) # float number generate between 10 and 20 # float_number = random.uniform(10, 20) # float number generate between 0 and 1 floa...
39
22.95
71
9
263
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_3ca4401d1fe01ee2_f94de643", "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." ]
[ 36 ]
[ null ]
[ 7 ]
[ 20 ]
2024-11-18T22:35:53.839738+00:00
1,638,534,670,000
93616e75969a2fa3a6acd4ad8c25c16ee72caac0
2
{ "blob_id": "93616e75969a2fa3a6acd4ad8c25c16ee72caac0", "branch_name": "refs/heads/master", "committer_date": 1638534670000, "content_id": "3a5081b077d4e85b6be1e3a2d473212f58b72f09", "detected_licenses": [ "MIT" ], "directory_id": "67de29ccf51cd68f3e14569dc30282902dc5c8c4", "extension": "py", "fi...
2.46875
stackv2
import multiprocessing import sys import re import requests import urllib3 from urllib.parse import urlparse # 1. Use this to scrape a resource from a list of given URLs # 2. In Burp start a new scan and them as "URLs to Scan" # 3. Selectively disable other extensions adding active scanner checks and run a "Audit chec...
127
26.02
119
20
834
python
[{"finding_id": "codeql_py/request-without-cert-validation_4dc9b65539c86526_ed60efff", "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)." ]
[ 44 ]
[ null ]
[ 20 ]
[ 62 ]
2024-11-18T22:48:23.484171+00:00
1,676,139,610,000
0c8a317d2bd4ec5e9ebd205ee8440a3b963aaac7
3
{ "blob_id": "0c8a317d2bd4ec5e9ebd205ee8440a3b963aaac7", "branch_name": "refs/heads/master", "committer_date": 1676139610000, "content_id": "75f999fa33ba4b031a2a16862c5066935525620d", "detected_licenses": [ "MIT" ], "directory_id": "255e19ddc1bcde0d3d4fe70e01cec9bb724979c9", "extension": "py", "fi...
2.78125
stackv2
import string import sys import logging import json from flask import Flask from flask import Response, request logger = logging.getLogger(__name__) logger.info("Stackdriver webhook-sample starting up on %s" % (string.replace(sys.version, '\n', ' '))) app = Flask("webhook-sample") @app.route('/simple', methods=['P...
63
34.57
116
14
502
python
[{"finding_id": "codeql_py/log-injection_ba73ed385805bf1b_94a60307", "tool_name": "codeql", "rule_id": "py/log-injection", "finding_type": "path-problem", "severity": "medium", "confidence": "medium", "message": "This log entry depends on a [user-provided value](1).", "remediation": "", "location": {"file_path": "unkno...
3
true
[ "CWE-117", "CWE-117", "CWE-117" ]
[ "py/log-injection", "py/log-injection", "py/log-injection" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "This log entry depends on a [user-provided value](1).", "This log entry depends on a [user-provided value](1).", "This log entry depends on a [user-provided value](1)." ]
[ 19, 36, 52 ]
[ null, null, null ]
[ 17, 21, 21 ]
[ 48, 52, 52 ]
2024-11-18T22:49:09.062852+00:00
1,515,280,281,000
7b79e3143ef06a4523c1373ca3604164b90074f9
3
{ "blob_id": "7b79e3143ef06a4523c1373ca3604164b90074f9", "branch_name": "refs/heads/master", "committer_date": 1515280281000, "content_id": "73f61fc837759b1190ae152c2a3955cfdaa0283f", "detected_licenses": [ "MIT" ], "directory_id": "88b66aeb055127a340da2c21f102e954e2896823", "extension": "py", "fi...
3.1875
stackv2
with open("resources/day4", "rt") as f: valid_passphrases = 0 for line in f: split_phrase = line.split() phrase_set = set() for word in split_phrase: word_as_list = sorted(list(word)) word_sorted = ''.join(word_as_list) phrase_set.add(word_sorted) ...
16
27.25
53
14
107
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_ed6ad14531a47a34_c585e42c", "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." ]
[ 15 ]
[ null ]
[ 11 ]
[ 28 ]
2024-11-18T22:49:13.154851+00:00
1,620,762,019,000
7db96247d04f9f98c26d79ec3d59c827f11238b6
3
{ "blob_id": "7db96247d04f9f98c26d79ec3d59c827f11238b6", "branch_name": "refs/heads/master", "committer_date": 1620762019000, "content_id": "ea92a0580228b0df9077a2531507a7bcaf3be712", "detected_licenses": [ "MIT" ], "directory_id": "7c5437e93be4890583c7994f54cc1564d8fa0a7b", "extension": "py", "fi...
2.546875
stackv2
from django.db import models from django.core.validators import MaxLengthValidator from django.utils import timezone from datetime import datetime, timedelta from webtools import settings from django.utils.translation import gettext_lazy as _ import hashlib import uuid EXPIRE_CHOICES = ( (0, _("Never expire")), ...
137
30.08
87
18
960
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_63b816b0eaa98257_619f386e", "tool_name": "codeql", "rule_id": "py/weak-sensitive-data-hashing", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "[Sensitive data (password)](1) is used in a hashing algorithm (SHA512) that is in...
1
true
[ "CWE-327" ]
[ "py/weak-sensitive-data-hashing" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "[Sensitive data (password)](1) is used in a hashing algorithm (SHA512) that is insecure for password hashing, since it is not a computationally expensive hash function." ]
[ 119 ]
[ null ]
[ 31 ]
[ 57 ]
2024-11-18T23:25:55.788947+00:00
1,502,952,834,000
aeb94ff44de3ba5925aa460e4b85d1ad526a8fcd
3
{ "blob_id": "aeb94ff44de3ba5925aa460e4b85d1ad526a8fcd", "branch_name": "refs/heads/master", "committer_date": 1502952834000, "content_id": "669e1789c8c7d284feff7c17679bf2b6e1acc7db", "detected_licenses": [ "Apache-2.0" ], "directory_id": "d9e3091f57403180b20e71d4cbcae8455138d000", "extension": "py"...
2.546875
stackv2
from flask import Flask, Response, request import json import os import redis import logging app = Flask(__name__) host = os.environ.get("HOST", "localhost") port = os.environ.get("PORT", 6379) db = os.environ.get("DB", 0) r = redis.StrictRedis(host=host, decode_responses=True, port=port, db=db) @app.route('/', met...
75
30.32
78
18
546
python
[{"finding_id": "codeql_py/flask-debug_d2aa3a5659e38f3b_f93a77b6", "tool_name": "codeql", "rule_id": "py/flask-debug", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", ...
2
true
[ "CWE-215", "CWE-117" ]
[ "py/flask-debug", "py/log-injection" ]
[ "HIGH", "MEDIUM" ]
[ "MEDIUM", "MEDIUM" ]
[ "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", "This log entry depends on a [user-provided value](1)." ]
[ 75, 56 ]
[ null, null ]
[ 5, 25 ]
[ 55, 70 ]
2024-11-18T23:26:13.583924+00:00
1,595,171,255,000
5594aa5280add188c96abba87d070dbb3c3f159b
4
{ "blob_id": "5594aa5280add188c96abba87d070dbb3c3f159b", "branch_name": "refs/heads/master", "committer_date": 1595171255000, "content_id": "b0b4b8c5dbcabe272738d15880aaf8ef557a6d12", "detected_licenses": [ "MIT" ], "directory_id": "7ff9de453f53b658d13896bb0c376d67489145a7", "extension": "py", "fi...
3.609375
stackv2
# *args -> allows multiple func arguments # **kwargs -> allows multiple func keyword arguments # **kwargs -> gives a dictionary def add(*args): return sum(args) def salary_accumulator(**kwargs): total = 0 for item in kwargs.values(): total += item return total print(salary_accumulator(num=...
23
18.04
52
8
117
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_73886132fdecddbc_0083e5e7", "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." ]
[ 17 ]
[ null ]
[ 7 ]
[ 42 ]
2024-11-18T22:27:24.411638+00:00
1,689,978,225,000
eaf3a43eac75ddf5fac064029094a21500c59f0b
3
{ "blob_id": "eaf3a43eac75ddf5fac064029094a21500c59f0b", "branch_name": "refs/heads/master", "committer_date": 1689978225000, "content_id": "508e500c8ff540b10d83ebc6a8eb5d0c8cd596e3", "detected_licenses": [ "MIT" ], "directory_id": "dba967b747ea343ac9c733568e6aec2154e8cf29", "extension": "py", "fi...
2.546875
stackv2
import os try: from weasyprint import HTML, CSS except (ImportError, OSError) as err: message = ( "[PDF Reports] ERROR: The Weasyprint library did not load" "properly! You will not be able to generate PDF reports until" "you fix this issue.\n" ) if "pango" in str(err): ...
220
30.01
87
14
1,612
python
[{"finding_id": "codeql_py/insecure-temporary-file_65d8df8f71183572_7425c36f", "tool_name": "codeql", "rule_id": "py/insecure-temporary-file", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Call to deprecated function tempfile.mktemp may be insecure.", "remediation": "", "location": ...
2
true
[ "CWE-377", "CWE-079" ]
[ "py/insecure-temporary-file", "py/jinja2/autoescape-false" ]
[ "HIGH", "MEDIUM" ]
[ "MEDIUM", "MEDIUM" ]
[ "Call to deprecated function tempfile.mktemp may be insecure.", "Using jinja2 templates with autoescape=False can potentially allow XSS attacks." ]
[ 94, 102 ]
[ null, 105 ]
[ 25, 11 ]
[ 55, 6 ]
2024-11-18T22:27:27.238667+00:00
1,543,489,682,000
587c1f29f8355cbe92148c2699eab70b0e53db9f
3
{ "blob_id": "587c1f29f8355cbe92148c2699eab70b0e53db9f", "branch_name": "refs/heads/master", "committer_date": 1543489682000, "content_id": "0d5a4f35cca7f923fd1681dac4913bb32efe8fbe", "detected_licenses": [ "Unlicense" ], "directory_id": "e71ebb598138f8d76291ca59c9304907e099cfe6", "extension": "py",...
3.140625
stackv2
# Sentiment Analysis of tweets in context to GOP debates in 2016 # Link used as reference: https://www.kaggle.com/ngyptr/lstm-sentiment-analysis-keras/notebook # import statements import numpy as np # linear algebra import pandas as pd # data processing, CSV file I/O (e.g. pd.read_csv) from sklearn.feature_extracti...
177
33.17
175
13
1,879
python
[{"finding_id": "codeql_py/overly-large-range_8f11bc8309694aea_604e3a7d", "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\\]." ]
[ 29 ]
[ null ]
[ 59 ]
[ 62 ]
2024-11-18T22:27:33.159205+00:00
1,593,560,652,000
46bfe9cc6ce9c158d16d986fbd0a3bc7cca158ca
3
{ "blob_id": "46bfe9cc6ce9c158d16d986fbd0a3bc7cca158ca", "branch_name": "refs/heads/master", "committer_date": 1593560652000, "content_id": "8e79aafa2c639d62cdc530593ca0fe584ab46613", "detected_licenses": [ "MIT" ], "directory_id": "16ff1b0128506cc5cd5a5f85d5539ec486824f77", "extension": "py", "fi...
2.625
stackv2
import logging import humps from enum import Enum from collections.abc import Mapping, Iterable from flask import request, json, current_app from meltano.core.utils import compose class KeyFrozenDict(dict): pass def freeze_keys(d: dict): """ Mark the dictionary as frozen, no automatic conversion wi...
111
25.78
83
15
658
python
[{"finding_id": "codeql_py/log-injection_e9074d5dedfeb8e9_f6d1e5ad", "tool_name": "codeql", "rule_id": "py/log-injection", "finding_type": "path-problem", "severity": "medium", "confidence": "medium", "message": "This log entry depends on a [user-provided value](1).", "remediation": "", "location": {"file_path": "unkno...
1
true
[ "CWE-117" ]
[ "py/log-injection" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "This log entry depends on a [user-provided value](1)." ]
[ 93 ]
[ null ]
[ 27 ]
[ 57 ]
2024-11-18T22:14:58.609098+00:00
1,561,054,809,000
e2657608e46334ea9de057b4bb1cfe35dc08f4e6
2
{ "blob_id": "e2657608e46334ea9de057b4bb1cfe35dc08f4e6", "branch_name": "refs/heads/master", "committer_date": 1561054809000, "content_id": "b6f515d5c65e7d842ff1dfc17ae7791b8e1f9afb", "detected_licenses": [ "MIT" ], "directory_id": "81da85f6d3f363676784df704285f9060cf598b5", "extension": "py", "fi...
2.46875
stackv2
import ssl import urlparse import socket import deproxy import tornado from tornado import httpclient import threading # Example socket based responder class CustomResponder: def send_response(self, wfile, response): """ Send the given Response over the socket. Add Server and Date headers i...
253
31.98
113
16
1,889
python
[{"finding_id": "codeql_py/insecure-default-protocol_12d6018872602392_71313267", "tool_name": "codeql", "rule_id": "py/insecure-default-protocol", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Call to deprecated method ssl.wrap_socket does not specify a protocol, which may result in...
1
true
[ "CWE-327" ]
[ "py/insecure-default-protocol" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "Call to deprecated method ssl.wrap_socket does not specify a protocol, which may result in an insecure default being used." ]
[ 96 ]
[ null ]
[ 24 ]
[ 45 ]
2024-11-18T22:54:58.240910+00:00
1,601,049,659,000
889bc99c49f2449ab568048f9e9f439b2805ffb0
3
{ "blob_id": "889bc99c49f2449ab568048f9e9f439b2805ffb0", "branch_name": "refs/heads/master", "committer_date": 1601049659000, "content_id": "e54e211f0a8da8f0eb90e9361853540bd5426083", "detected_licenses": [ "MIT" ], "directory_id": "e86a6eb512905d7dfdaf644d1dd60020bb6d97d1", "extension": "py", "fi...
3.125
stackv2
import time import hashlib from mysql_conn import * mail = str(input("Mail adresinizi veya kullanıcı adınızı giriniz")).strip() username = mail sql = "SELECT * FROM myusers WHERE (mail=%s or username=%s) and status=%s " adr = (str(mail), str(username), 1) cursor.execute(sql, adr) result = cursor.fetchall() if resu...
42
27.24
75
14
308
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_24c0d5c7a47b2767_60dde1e1", "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." ]
[ 26 ]
[ null ]
[ 27 ]
[ 44 ]
2024-11-18T23:55:48.651237+00:00
1,563,494,641,000
a4f27f6a12d49bd1ae3d47110e28f82b919e5534
3
{ "blob_id": "a4f27f6a12d49bd1ae3d47110e28f82b919e5534", "branch_name": "refs/heads/master", "committer_date": 1563494641000, "content_id": "8c822030ab5d5854fe67c4c96c2004d171d901f9", "detected_licenses": [ "MIT" ], "directory_id": "0543034747009e59a991d5197715a7516cada884", "extension": "py", "fi...
2.9375
stackv2
import os, re, sys import glob from jinja2 import Environment, FileSystemLoader, select_autoescape """ Apply Default Values to Captain Hook Jinja Templates This script applies default values to templates in this folder. The templates are used by Ansible, but this script uses the same template engine as Ansible to...
89
26.34
83
16
580
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_de2987c550a16489_d6e3014a", "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." ]
[ 61 ]
[ null ]
[ 11 ]
[ 52 ]
2024-11-19T00:07:21.737855+00:00
1,692,602,558,000
98fa761c61bb84aff66aed460b5e715ba1a6ac3f
3
{ "blob_id": "98fa761c61bb84aff66aed460b5e715ba1a6ac3f", "branch_name": "refs/heads/master", "committer_date": 1692602558000, "content_id": "b577da15ed9cfa17cdb4a0b9aa62adf39a40f1aa", "detected_licenses": [ "MIT" ], "directory_id": "4a48593a04284ef997f377abee8db61d6332c322", "extension": "py", "fi...
2.828125
stackv2
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # Copyright (c) 2015 Jérémie DECOCK (http://www.jdhp.org) # Warning: # The urllib2 (from Python 2.x) module has been split across several modules in # Python 3 named "urllib.request" and "urllib.error". # Urllib (and thus urllib2) is part of the Python3 standard library ...
43
30.14
79
8
346
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_df2e9f535fdd9350_146a09dc", "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." ]
[ 37 ]
[ null ]
[ 23 ]
[ 42 ]
2024-11-19T00:07:27.412868+00:00
1,572,496,259,000
97a15c330942593032178ed10e426f0948f5bbf6
3
{ "blob_id": "97a15c330942593032178ed10e426f0948f5bbf6", "branch_name": "refs/heads/master", "committer_date": 1572496259000, "content_id": "fb0f721e9ef51dcf2782edf92eec992ac572766e", "detected_licenses": [ "MIT" ], "directory_id": "89163fe15a36cb2b4e387be34688c4d6359a7e99", "extension": "py", "fi...
2.9375
stackv2
""" Common functionality for sqlalchemy schemas. """ import hashlib import uuid from datetime import datetime from sqlalchemy.ext.declarative import declarative_base from sqlalchemy import ( Column, DateTime, Unicode, ) DeclarativeBase = declarative_base() def eid_gen(): """ Generates an uniq...
83
24.3
82
17
449
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_d709cea6ad08a601_2cb661c8", "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." ]
[ 27 ]
[ null ]
[ 24 ]
[ 58 ]
2024-11-18T23:28:31.605368+00:00
1,541,523,908,000
dfffb66186c95cd097262c19997ed4e229d52a46
3
{ "blob_id": "dfffb66186c95cd097262c19997ed4e229d52a46", "branch_name": "refs/heads/master", "committer_date": 1541523908000, "content_id": "289f883bfa6bc05dcb942b4eeaebed32776f8d40", "detected_licenses": [ "Apache-2.0" ], "directory_id": "73297a722d6bfc1d495786f28e8e5f1593c3f68b", "extension": "py"...
2.578125
stackv2
import os from flask import Flask from flask import render_template from flask import request from flask import redirect from flask import url_for from flask import send_from_directory from werkzeug import secure_filename UPLOAD_FOLDER = '/home/shiyanlou/Code/shiyanlou_cs29/myproject/static' ALLOWED_EXTENSIONS = set([...
86
27.76
81
16
594
python
[{"finding_id": "codeql_py/flask-debug_660339778bad9106_0c91699c", "tool_name": "codeql", "rule_id": "py/flask-debug", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", ...
4
true
[ "CWE-215", "CWE-079", "CWE-079", "CWE-079" ]
[ "py/flask-debug", "py/reflective-xss", "py/reflective-xss", "py/reflective-xss" ]
[ "HIGH", "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", "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 ...
[ 86, 27, 31, 43 ]
[ null, null, null, null ]
[ 5, 12, 12, 12 ]
[ 24, 32, 31, 33 ]
2024-11-18T23:28:36.294331+00:00
1,637,412,210,000
ec8bf55de7698e7107543d8d05da2de1a26aa8d1
3
{ "blob_id": "ec8bf55de7698e7107543d8d05da2de1a26aa8d1", "branch_name": "refs/heads/main", "committer_date": 1637412210000, "content_id": "9109a8d5f810c5bfa1f52b96ba5fd6be18890d29", "detected_licenses": [ "MIT" ], "directory_id": "5b3fcd4ba7034315a42c64bdcf84ffe4342facdd", "extension": "py", "file...
3.171875
stackv2
from flask import Flask, request, jsonify # Imports the flask library modules from flask.wrappers import Response from marshmallow import ValidationError #Framework to echo Validation Error. import requests as req #Framework to pass requests to the server import encode #Program to shorten the URLs import decode #Progr...
62
44.79
125
16
643
python
[{"finding_id": "codeql_py/full-ssrf_2eb3493209bed108_134afe4b", "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-918" ]
[ "py/full-ssrf", "py/full-ssrf" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "The full URL of this request depends on a [user-provided value](1).", "The full URL of this request depends on a [user-provided value](1)." ]
[ 20, 45 ]
[ null, null ]
[ 16, 16 ]
[ 28, 32 ]
2024-11-18T23:28:37.150990+00:00
1,608,705,254,000
b8647112fca8f3c02cbd6c5bb6e111a037a2e7e5
2
{ "blob_id": "b8647112fca8f3c02cbd6c5bb6e111a037a2e7e5", "branch_name": "refs/heads/main", "committer_date": 1608705254000, "content_id": "7c1d13cc2c00c9bdd0e8789e3f5ae9db0bc5494f", "detected_licenses": [ "MIT" ], "directory_id": "c32d92582a05498d0cec97dcb5307942959bf70a", "extension": "py", "file...
2.328125
stackv2
import os from pathlib import Path import json from jinja2 import Environment, FileSystemLoader def single_quotes(d): return d.replace('"', "'") def to_nice_json(d): return json.dumps(d, indent=2) def is_flat(d): for val in d.values(): if isinstance(val, (dict, list)): return Fals...
139
24.58
85
14
843
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_342e8318e276a617_163ce4f6", "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." ]
[ 24 ]
[ 27 ]
[ 7 ]
[ 2 ]
2024-11-18T23:40:03.345871+00:00
1,609,095,449,000
8c06b15ab5cc475778d5e0c924235522758b46cd
4
{ "blob_id": "8c06b15ab5cc475778d5e0c924235522758b46cd", "branch_name": "refs/heads/main", "committer_date": 1609095449000, "content_id": "21adccaa619ba9e9755af726fcf418feafb2425b", "detected_licenses": [ "MIT" ], "directory_id": "8bd968a4232445f67348fe7c69e9c970b09691d0", "extension": "py", "file...
3.703125
stackv2
''' Advent of Code: Day 2 - Puzzle 1 & 2 ''' data = 'Day-02-input.txt' passwords = [] with open(data, 'r') as infile: passwords = infile.read().splitlines() def valid_passwords(password_list): number_of_valid_passwords = 0 low_number = 0 high_number = 0 letter = None password = None for line in pass...
87
27.74
172
14
667
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_4ff0e26b069cb060_71edc8e0", "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...
4
true
[ "CWE-312", "CWE-312", "CWE-312", "CWE-312" ]
[ "py/clear-text-logging-sensitive-data", "py/clear-text-logging-sensitive-data", "py/clear-text-logging-sensitive-data", "py/clear-text-logging-sensitive-data" ]
[ "HIGH", "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "This expression logs [sensitive data (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.", "This expression logs [sensitive data (password)](1) as clear text.\nThis expression logs [sensitive data (p...
[ 42, 70, 80, 86 ]
[ null, null, null, null ]
[ 7, 7, 9, 9 ]
[ 66, 84, 78, 78 ]
2024-11-19T00:05:00.545422+00:00
1,482,207,496,000
61994dfd410548b9cb9c9090463eb311dbd47f75
3
{ "blob_id": "61994dfd410548b9cb9c9090463eb311dbd47f75", "branch_name": "refs/heads/master", "committer_date": 1482207496000, "content_id": "54ee4aeb479e13ca5957b2cee3ba93f6f8c9f40a", "detected_licenses": [ "MIT" ], "directory_id": "5076988b691203789c9cac75a6e9c6860c29485e", "extension": "py", "fi...
3.140625
stackv2
#!/bin/python # -*- coding: ascii -*- # Advent of Code 2016 # Day 5 # 2016-12-05 # Python implementation # # In Python 2.7.10 (32-bit) # Part 1 takes ~23.54s # Part 2 takes ~63.59s # # In Python 2.7.12 (64-bit) # Part 1 takes ~20.71s # Part 2 takes ~57.06s # # In Python 3.5.2 (64-bit) # Part 1 takes ~28.07s # Part 2 ...
105
21.7
94
19
775
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_23681ed5bb9d8207_3e8d2bcc", "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...
4
true
[ "CWE-312", "CWE-312", "CWE-312", "CWE-312" ]
[ "py/clear-text-logging-sensitive-data", "py/clear-text-logging-sensitive-data", "py/clear-text-logging-sensitive-data", "py/clear-text-logging-sensitive-data" ]
[ "HIGH", "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "This expression logs [sensitive data (password)](1) as clear text.\nThis expression logs [sensitive data (password)](2) as clear text.", "This expression logs [sensitive data (password)](1) as clear text.\nThis expression logs [sensitive data (password)](2) as clear text.", "This expression logs [sensitive dat...
[ 64, 71, 96, 103 ]
[ null, null, null, null ]
[ 15, 7, 27, 7 ]
[ 30, 89, 42, 89 ]
2024-11-19T00:44:13.574271+00:00
1,620,716,424,000
aa41e09a68ba77f70a7d328df13dd6183406be24
3
{ "blob_id": "aa41e09a68ba77f70a7d328df13dd6183406be24", "branch_name": "refs/heads/main", "committer_date": 1620716424000, "content_id": "678185e342256419802c19f0f7b6088ac075cc1f", "detected_licenses": [ "MIT" ], "directory_id": "78eb581a7bd4dcd150ebe58c9c25c654ead6bb56", "extension": "py", "file...
2.53125
stackv2
#!/usr/bin/python3 import sys import os.path from subprocess import Popen, PIPE valid_commands = ["--name", "--namespace", "--from-file"] file_list = [] namespace = "" secret_name = "" create_secrets_cmd_a = ["kubectl", "--namespace", "default", "create", "secret", "generic", "sealegs-secrets"] create_secrets...
99
25.37
131
16
693
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_18008499b5a8e17a_9ef3f78b", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (secret)](1) as clear text.\nThi...
1
true
[ "CWE-312" ]
[ "py/clear-text-logging-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression logs [sensitive data (secret)](1) as clear text.\nThis expression logs [sensitive data (secret)](2) as clear text." ]
[ 84 ]
[ null ]
[ 8 ]
[ 37 ]
2024-11-19T00:44:30.850521+00:00
1,532,766,875,000
ea27b99b8dacb8eafa0e586139d7139789b49a63
2
{ "blob_id": "ea27b99b8dacb8eafa0e586139d7139789b49a63", "branch_name": "refs/heads/master", "committer_date": 1532766875000, "content_id": "c0c886a469ee91dadce9f47f5f9a15bf5e29cb6a", "detected_licenses": [ "Apache-2.0" ], "directory_id": "f01c31a661dec8f1f4a6f885a11c97c686dac927", "extension": "py"...
2.453125
stackv2
import random import string import uuid from core import output def generate_token(size=32): return ''.join(random.SystemRandom().choice( string.ascii_lowercase + string.ascii_uppercase + string.digits ) for _ in range(size) ) def store_creds( module, user, password, two_fact...
88
27.17
73
18
496
python
[{"finding_id": "codeql_py/clear-text-storage-sensitive-data_be5a7047af1cb81b_954c1a7f", "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."...
2
true
[ "CWE-312", "CWE-312" ]
[ "py/clear-text-storage-sensitive-data", "py/clear-text-storage-sensitive-data" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "This expression stores [sensitive data (password)](1) as clear text.", "This expression stores [sensitive data (password)](1) as clear text." ]
[ 28, 48 ]
[ 39, null ]
[ 22, 26 ]
[ 14, 73 ]
2024-11-18T23:05:32.436891+00:00
1,292,994,288,000
19224fd2b97e07d893ceef092bb81708b223da97
3
{ "blob_id": "19224fd2b97e07d893ceef092bb81708b223da97", "branch_name": "refs/heads/master", "committer_date": 1292994288000, "content_id": "ef1144e231684f645149c8455859eb16ac84b30e", "detected_licenses": [ "MIT" ], "directory_id": "6079a74be33e5e18cc75108a0ec7715028917757", "extension": "py", "fi...
2.6875
stackv2
import logging import traceback from django.http import HttpResponse log = logging.getLogger("hiicart") def call_func(name, *args, **kwargs): """Call a function when all you have is the [str] name and arguments.""" parts = name.split('.') module = __import__(".".join(parts[:-1]), fromlist=[parts[-1]]) ...
32
30.72
76
13
214
python
[{"finding_id": "codeql_py/stack-trace-exposure_0f317a36a66f8592_053af052", "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." ]
[ 29 ]
[ null ]
[ 37 ]
[ 40 ]
2024-11-18T23:05:37.663391+00:00
1,513,307,714,000
6afde90b1ddc9cd86f5f5403c67bb976c2239eb7
4
{ "blob_id": "6afde90b1ddc9cd86f5f5403c67bb976c2239eb7", "branch_name": "refs/heads/master", "committer_date": 1513307714000, "content_id": "65f5e07ef0b36d58f6b93a64bd47de0d0f24da25", "detected_licenses": [ "Apache-2.0" ], "directory_id": "49860bba126919dbd13311d8724ee32b7edbd02e", "extension": "py"...
4.15625
stackv2
#!/usr/bin/python3 # 文件名:class_method3.py ''' 类私有方法:两个下划线开头,声明该方法为私有方法,只能在类内部调用,不能在类外部调用 self.__private_methods. ''' # 类定义 class JustCounter: __secretCount = 0 # 私有变量 publicCount = 0 # 公开变量 def count(self): self.__secretCount += 1 self.publicCount += 1 print(self.__secretCount) # 实例化类 counter = Just...
24
17.08
44
10
157
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_d7594aee6a55f9f6_4a583f8d", "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." ]
[ 16, 24 ]
[ null, null ]
[ 9, 7 ]
[ 27, 28 ]
2024-11-18T23:05:42.738304+00:00
1,588,876,504,000
0220afb933ce8ec61bcbead755727d52b73e6a57
3
{ "blob_id": "0220afb933ce8ec61bcbead755727d52b73e6a57", "branch_name": "refs/heads/master", "committer_date": 1588876504000, "content_id": "0f3ff1e8d7b2e722730235dac49eca7eaf6aee1e", "detected_licenses": [ "MIT" ], "directory_id": "7b3b16d23e0927004e1b75803a050e60a492d084", "extension": "py", "fi...
2.59375
stackv2
from flask import Flask, render_template,request from pathlib import Path import os import flask_monitoringdashboard as dashboard app = Flask(__name__, static_folder="static") dashboard.bind(app) @app.route("/upload", methods=["POST"]) def upload(): try: file = request.files["inputFile"] if not f...
34
27.47
63
16
218
python
[{"finding_id": "codeql_py/stack-trace-exposure_97f5eb6a48110143_f215fd93", "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-079", "CWE-022", "CWE-022" ]
[ "py/stack-trace-exposure", "py/reflective-xss", "py/path-injection", "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.", "Cross-site scripting vulnerability due to a [user-provided value](1).", "This path depends on a [user-provided value](1).", "This path depends on a [user-provided value](1)." ]
[ 22, 20, 16, 19 ]
[ null, null, null, null ]
[ 16, 16, 14, 19 ]
[ 47, 50, 51, 50 ]
2024-11-18T23:18:42.214740+00:00
1,592,182,770,000
e7034850317876e0b40cf287126abc08f774e60f
3
{ "blob_id": "e7034850317876e0b40cf287126abc08f774e60f", "branch_name": "refs/heads/master", "committer_date": 1592182770000, "content_id": "9df6388fccdfa058489200b36622fc94b7b08d2a", "detected_licenses": [ "MIT" ], "directory_id": "b1d3876aafc8730e8f3ec709561d83ff622cb63a", "extension": "py", "fi...
3.21875
stackv2
import hashlib example = { "a": ["abc", "18f47a30"], "b": ["abc", "05ace8e3"] } def find_hex(txt, num, day, l=5): m = hashlib.md5((txt + str(num)).encode("utf-8")) if m.hexdigest()[0:l] == "0" * l: if day == "a": return m.hexdigest()[5:6] else: if m.hexdigest()[5:6] in ["0", "1", "2", "3", "4", "5", "6"...
58
20.78
69
19
429
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_b0a13fd209a9fece_db75d313", "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)](1) as clear text." ]
[ 53 ]
[ null ]
[ 8 ]
[ 25 ]
2024-11-18T23:20:02.661651+00:00
1,635,333,893,000
6d7a6e2474a0d1dc9bfed74e8622ac218cabe6fc
2
{ "blob_id": "6d7a6e2474a0d1dc9bfed74e8622ac218cabe6fc", "branch_name": "refs/heads/master", "committer_date": 1635333893000, "content_id": "e923e7da6e9f4834b9c2dff89723571f4bfd997e", "detected_licenses": [ "MIT" ], "directory_id": "3425eac6e03cf0fc7c722891d2584591623b8508", "extension": "py", "fi...
2.46875
stackv2
""" Simple app to upload an image via a web form and view the inference results on the image in the browser. """ import argparse from io import BytesIO import os from PIL import Image import boto3 from botocore.exceptions import ClientError import urllib import torch from flask import Flask, render_template, jsonify,...
84
36.29
98
18
766
python
[{"finding_id": "codeql_py/full-ssrf_24c474812ef87bfa_a53ee54e", "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...
1
true
[ "CWE-918" ]
[ "py/full-ssrf" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "The full URL of this request depends on a [user-provided value](1)." ]
[ 28 ]
[ null ]
[ 23 ]
[ 61 ]
2024-11-19T00:11:31.802028+00:00
1,664,972,455,000
271d56bff0aa3453b2c1dfa3a18ef10bea8625a2
3
{ "blob_id": "271d56bff0aa3453b2c1dfa3a18ef10bea8625a2", "branch_name": "refs/heads/master", "committer_date": 1664972455000, "content_id": "2326c2e9d5234989d413f94a9631311e17cab1f6", "detected_licenses": [ "MIT" ], "directory_id": "d335907600cc518f16907b1275665a8c88fa22f5", "extension": "py", "fi...
2.859375
stackv2
#!/usr/bin/env python import requests import time import math try: import simplejson as json except ImportError: import json from pprint import pprint import base64 class GitlabAPI(object): """Basic wrapper for the Gitlab api. For further information on the API itself see: http://developer.gitlab.co...
351
32.36
87
18
2,754
python
[{"finding_id": "codeql_py/request-without-cert-validation_d28749537d4e4a70_e3340c8b", "tool_name": "codeql", "rule_id": "py/request-without-cert-validation", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "This request may run without certificate validation because [it is disabled]...
3
true
[ "CWE-295", "CWE-295", "CWE-295" ]
[ "py/request-without-cert-validation", "py/request-without-cert-validation", "py/request-without-cert-validation" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "This request may run without certificate validation because [it is disabled](1).", "This request may run without certificate validation because [it is disabled](1).", "This request may run without certificate validation because [it is disabled](1)." ]
[ 45, 69, 92 ]
[ null, null, null ]
[ 13, 13, 13 ]
[ 71, 83, 82 ]
2024-11-19T00:11:34.707135+00:00
1,693,357,105,000
35d6dc90ab113a904ba72b330901d9f00f769e2c
2
{ "blob_id": "35d6dc90ab113a904ba72b330901d9f00f769e2c", "branch_name": "refs/heads/master", "committer_date": 1693357105000, "content_id": "b7315a48df4e5596670f0441ed097d4196c2c352", "detected_licenses": [ "MIT" ], "directory_id": "11e114eff5abae40032dc720c7f7f6b08e9d4446", "extension": "py", "fi...
2.484375
stackv2
import sys from jinja2 import Template import spotipy if __name__ == "__main__": clientid, secret, refresh = sys.argv[1:4] sa = spotipy.oauth2.SpotifyOAuth( client_id=clientid, client_secret=secret, redirect_uri="http://example.com/callback/") token = sa.refresh_access_token(refresh...
20
39.15
85
12
210
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_0af23ef4ced16a8f_98c5c6d7", "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." ]
[ 18 ]
[ null ]
[ 20 ]
[ 38 ]
2024-11-19T00:11:44.300002+00:00
1,596,087,927,000
ddae39b75b09cbd47679403e287c049d5a38a9fd
2
{ "blob_id": "ddae39b75b09cbd47679403e287c049d5a38a9fd", "branch_name": "refs/heads/master", "committer_date": 1596087927000, "content_id": "ae2315eb6eef6c72fcc4286bf99e4950a44ac8f2", "detected_licenses": [ "MIT" ], "directory_id": "e026672d9e6bd81429c2bf48841233639dccdb08", "extension": "py", "fi...
2.46875
stackv2
#! /usr/bin/env python #-*- coding=utf-8 -*- import sys, requests, time import urllib, urllib2, re from bs4 import BeautifulSoup def getPokemonHead(): homeUrl = 'https://www.pkparaiso.com' targetUrl = 'https://www.pkparaiso.com/xy/artworks_pokemon_global_link.php' targetPage = requests.get(targetUrl, veri...
22
32.86
79
16
196
python
[{"finding_id": "codeql_py/request-without-cert-validation_2c46f4216467656a_ff9bb3e9", "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 ]
[ 18 ]
[ 55 ]
2024-11-19T00:36:49.262815+00:00
1,492,246,061,000
4dd6cf5983609ebabee71f56509bf70083c2eb7a
3
{ "blob_id": "4dd6cf5983609ebabee71f56509bf70083c2eb7a", "branch_name": "refs/heads/master", "committer_date": 1492246061000, "content_id": "335ee89f611133d2dddacafc11935c0aa432e082", "detected_licenses": [ "MIT" ], "directory_id": "787a1feeb83b8a00e5f61ff7a6784316b00200fe", "extension": "py", "fi...
2.890625
stackv2
import os import sys from jinja2 import Template def manage_country(country): """Create country layout :param country: country name :type country: str or unicode """ country_path = 'inventories/{}'.format(country) environments = '{{ cookiecutter.environments }}'.split(',') if not os.p...
117
25.1
79
13
594
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_ed45fd152d7eca9f_fc5499ac", "tool_name": "codeql", "rule_id": "py/jinja2/autoescape-false", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Using jinja2 templates with autoescape=False can potentially allow XSS attacks.", "remediati...
2
true
[ "CWE-079", "CWE-079" ]
[ "py/jinja2/autoescape-false", "py/jinja2/autoescape-false" ]
[ "MEDIUM", "MEDIUM" ]
[ "MEDIUM", "MEDIUM" ]
[ "Using jinja2 templates with autoescape=False can potentially allow XSS attacks.", "Using jinja2 templates with autoescape=False can potentially allow XSS attacks." ]
[ 74, 101 ]
[ null, null ]
[ 16, 16 ]
[ 33, 33 ]
2024-11-19T00:36:55.543739+00:00
1,633,526,560,000
7ba4d213ab83bea3d4c2665d564759acf3f56fc3
3
{ "blob_id": "7ba4d213ab83bea3d4c2665d564759acf3f56fc3", "branch_name": "refs/heads/master", "committer_date": 1633526560000, "content_id": "1bb26621b8b10a72c659ba957fe62d27700718db", "detected_licenses": [ "MIT" ], "directory_id": "b2bba0d9903bf37d07623bdb0a16f6c611022ace", "extension": "py", "fi...
2.921875
stackv2
from flask import Flask, request from flask_httpauth import HTTPBasicAuth from flask_cors import CORS from werkzeug.security import generate_password_hash, check_password_hash import os # where data will be stored OUTPUT_DIR = 'example_output' # generate username/passwords users = { "susan": generate_password_has...
66
23.03
78
14
358
python
[{"finding_id": "codeql_py/path-injection_e1d8767bbb53a8eb_492a322e", "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)." ]
[ 37, 40 ]
[ null, null ]
[ 17, 19 ]
[ 26, 27 ]
2024-11-19T00:36:57.328044+00:00
1,600,086,611,000
39ed2a894565fee07f81d5e8ab7926c2bfbc5f98
2
{ "blob_id": "39ed2a894565fee07f81d5e8ab7926c2bfbc5f98", "branch_name": "refs/heads/master", "committer_date": 1600086611000, "content_id": "00d4def55a04e3200c6d7bc5dbfd48c3a3f5a1c1", "detected_licenses": [ "Apache-2.0" ], "directory_id": "45e7a4a426053b360cae2d93354e44244563d0b8", "extension": "py"...
2.46875
stackv2
import logging from seventweets.config import g from flask import Blueprint, request, jsonify from seventweets.exceptions import except_handler register_blueprint = Blueprint('register', __name__) logger = logging.getLogger(__name__) @register_blueprint.route('/register', methods=['POST']) @except_handler def regi...
37
28.22
77
13
222
python
[{"finding_id": "codeql_py/log-injection_4c802293b279d3c5_d7fc739e", "tool_name": "codeql", "rule_id": "py/log-injection", "finding_type": "path-problem", "severity": "medium", "confidence": "medium", "message": "This log entry depends on a [user-provided value](1).", "remediation": "", "location": {"file_path": "unkno...
1
true
[ "CWE-117" ]
[ "py/log-injection" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "This log entry depends on a [user-provided value](1)." ]
[ 36 ]
[ null ]
[ 17 ]
[ 48 ]
2024-11-19T00:37:02.591578+00:00
1,408,144,221,000
af1528b019e97ec4c29d302a9f94b6df9c709f42
2
{ "blob_id": "af1528b019e97ec4c29d302a9f94b6df9c709f42", "branch_name": "refs/heads/master", "committer_date": 1408144221000, "content_id": "f57e4b354350a25ccbd11d34817693170f994493", "detected_licenses": [ "MIT" ], "directory_id": "2141685c14753a684ad6eba92080060519c00564", "extension": "py", "fi...
2.40625
stackv2
import os import boto from datetime import datetime from functools import wraps from markdown import markdown as md from mimetypes import guess_type from flask import * from flask.ext.sqlalchemy import SQLAlchemy from flask.ext.login import LoginManager, login_required, current_user, login_user, logout_user from flask....
359
29.97
127
16
2,837
python
[{"finding_id": "codeql_py/url-redirection_d44afa18e826e186_f3484587", "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 ...
10
true
[ "CWE-601", "CWE-601", "CWE-601", "CWE-601", "CWE-601", "CWE-601", "CWE-601", "CWE-601", "CWE-601", "CWE-601" ]
[ "py/url-redirection", "py/url-redirection", "py/url-redirection", "py/url-redirection", "py/url-redirection", "py/url-redirection", "py/url-redirection", "py/url-redirection", "py/url-redirection", "py/url-redirection" ]
[ "HIGH", "HIGH", "HIGH", "HIGH", "HIGH", "HIGH", "HIGH", "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "Untrusted URL redirection depends on a [user-provided value](1).\nUntrusted URL redirection depends on a [user-provided value](2).\nUntrusted URL redirection depends on a [user-provided value](3).", "Untrusted URL redirection depends on a [user-provided value](1).\nUntrusted URL redirection depends on a [user-pr...
[ 125, 144, 155, 177, 190, 206, 221, 240, 257, 270 ]
[ null, null, null, null, null, null, null, null, null, null ]
[ 23, 23, 19, 19, 19, 21, 21, 19, 19, 19 ]
[ 93, 73, 95, 61, 61, 31, 31, 61, 49, 49 ]
2024-11-19T00:37:04.545566+00:00
1,689,606,054,000
1f3d41b1ef77fad842ae97ddf0f824ddb7e1a299
2
{ "blob_id": "1f3d41b1ef77fad842ae97ddf0f824ddb7e1a299", "branch_name": "refs/heads/main", "committer_date": 1689606054000, "content_id": "29b326c1724b3ed63fe4f63651e96138a6871f43", "detected_licenses": [ "Apache-2.0" ], "directory_id": "d668e775bfefaa2a1204994803bf7cd990cf3b8b", "extension": "py", ...
2.4375
stackv2
#!/usr/bin/env python # Item catalog service. from flask import Flask, abort, jsonify, request import os import random import requests from signalfx_tracing import auto_instrument from signalfx_tracing.libraries import requests_config import time from . import utils import uuid tracer = utils.get_tracer() requests_...
112
24.78
108
21
934
python
[{"finding_id": "codeql_py/partial-ssrf_837567ccd2034f63_631e0c76", "tool_name": "codeql", "rule_id": "py/partial-ssrf", "finding_type": "path-problem", "severity": "medium", "confidence": "medium", "message": "Part of the URL of this request depends on a [user-provided value](1).", "remediation": "", "location": {"fil...
1
true
[ "CWE-918" ]
[ "py/partial-ssrf" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "Part of the URL of this request depends on a [user-provided value](1)." ]
[ 56 ]
[ null ]
[ 9 ]
[ 83 ]
2024-11-19T01:02:09.569624+00:00
1,619,068,128,000
8423806cc8db55206afd111fa7458b84f8a6dbda
2
{ "blob_id": "8423806cc8db55206afd111fa7458b84f8a6dbda", "branch_name": "refs/heads/main", "committer_date": 1619068128000, "content_id": "6bea27a2a9fe13fe539c3cddfa8adb8ed3c73ed7", "detected_licenses": [ "MIT" ], "directory_id": "327e3b0565133f461fc27d4e10d6bcc4f769e586", "extension": "py", "file...
2.421875
stackv2
from flask import render_template, url_for, flash, redirect, request, Response from dMask import app, db, bcrypt from dMask.forms import LoginForm, UpdateForm, RecoverForm, ResetForm from dMask.models import User, Status from flask_login import login_user, login_required, current_user import cv2 import json # Тестово...
100
32.51
95
17
707
python
[{"finding_id": "codeql_py/url-redirection_7eb5a6ce654a9b67_b9a1a7c9", "tool_name": "codeql", "rule_id": "py/url-redirection", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "Untrusted URL redirection depends on a [user-provided value](1).", "remediation": "", "location": {"file_...
1
true
[ "CWE-601" ]
[ "py/url-redirection" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "Untrusted URL redirection depends on a [user-provided value](1)." ]
[ 60 ]
[ null ]
[ 29 ]
[ 33 ]
2024-11-19T01:02:16.758548+00:00
1,515,983,394,000
83b1f1129cb78303952bb44411078e2de8fbb3ec
3
{ "blob_id": "83b1f1129cb78303952bb44411078e2de8fbb3ec", "branch_name": "refs/heads/master", "committer_date": 1515983394000, "content_id": "ddeba402a14a485cc8c05e1a3c430ce55145cdac", "detected_licenses": [ "MIT" ], "directory_id": "6d4c81dbbb56e662661e05ab8c17b7e4aae7dd0c", "extension": "py", "fi...
2.546875
stackv2
import os from flask import Flask, request, redirect, url_for, send_from_directory, render_template, send_file, abort from werkzeug.utils import secure_filename UPLOAD_FOLDER = '/Users/adam/mister-web/' ALLOWED_EXTENSIONS = set(['txt', 'pdf', 'png', 'jpg', 'jpeg', 'gif']) app = Flask(__name__) app.config['UPLOAD_FOLD...
64
32.02
107
15
484
python
[{"finding_id": "codeql_py/url-redirection_f9be2e8424d5b1d8_75ef23f8", "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_...
7
true
[ "CWE-601", "CWE-601", "CWE-022", "CWE-022", "CWE-022", "CWE-022", "CWE-022" ]
[ "py/url-redirection", "py/url-redirection", "py/path-injection", "py/path-injection", "py/path-injection", "py/path-injection", "py/path-injection" ]
[ "HIGH", "HIGH", "HIGH", "HIGH", "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "Untrusted URL redirection depends on a [user-provided value](1).", "Untrusted URL redirection depends on a [user-provided value](1).", "This path depends on a [user-provided value](1).", "This path depends on a [user-provided value](1).", "This path depends on a [user-provided value](1).", "This path dep...
[ 21, 27, 31, 49, 53, 54, 62 ]
[ null, null, null, null, null, null, null ]
[ 18, 18, 12, 27, 23, 26, 24 ]
[ 29, 29, 74, 35, 31, 34, 32 ]
2024-11-19T01:02:18.962329+00:00
1,674,483,685,000
ca563b8da872bc05612601097f87d0f107f222c8
3
{ "blob_id": "ca563b8da872bc05612601097f87d0f107f222c8", "branch_name": "refs/heads/master", "committer_date": 1674483685000, "content_id": "9220ce6dff37a47d3ab8770b819c03688b14dfc6", "detected_licenses": [ "MIT" ], "directory_id": "aa2ab863bf256c0b81ef6e2ae494548bb7c56744", "extension": "py", "fi...
2.640625
stackv2
# from gsm import SmsListener, RawSMS import os import logging import subprocess _log = logging.getLogger("WIFI-Handler") def _write_to_wpa_suuplicant(ssid: str, password: str): wifiConfig = '\nnetwork={{\n ssid="{}"\n psk="{}"\n}}\n'.format( ssid, password) with open("/wpa_supplicant/wpa_supp...
41
27.95
82
11
314
python
[{"finding_id": "codeql_py/clear-text-storage-sensitive-data_df087d90b2afd8f5_81079bfc", "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.\...
2
true
[ "CWE-312", "CWE-312" ]
[ "py/clear-text-storage-sensitive-data", "py/clear-text-logging-sensitive-data" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "This expression stores [sensitive data (password)](1) as clear text.\nThis expression stores [sensitive data (password)](2) as clear text.", "This expression logs [sensitive data (password)](1) as clear text." ]
[ 14, 19 ]
[ null, null ]
[ 19, 16 ]
[ 29, 80 ]
2024-11-19T01:02:22.386421+00:00
1,616,613,737,000
169ec2fc5c843929ec0e84f40ce183bc6707d686
2
{ "blob_id": "169ec2fc5c843929ec0e84f40ce183bc6707d686", "branch_name": "refs/heads/master", "committer_date": 1616613737000, "content_id": "39b2f9dff7d4728e02f125829a6215bd665548cc", "detected_licenses": [ "Apache-2.0" ], "directory_id": "ae03e6ed3579a871c6737f39e3a7cf7e6bb7a5c2", "extension": "py"...
2.46875
stackv2
#!/usr/bin/env python # -*- coding: utf-8 -*- """ Crawls a website, sticking to just the given domain and not following external links. Reports non-200 response codes to the emails provided if any. Emails can be omitted if you're just interested in warming the cache. by Phillip Stromberg on 2015-01-27 """ import boto...
276
32.51
119
18
2,181
python
[{"finding_id": "codeql_py/request-without-cert-validation_9333791dad867af3_337cc83b", "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)." ]
[ 144 ]
[ null ]
[ 10 ]
[ 58 ]
2024-11-19T01:02:25.942327+00:00
1,528,331,834,000
7cd2c0006cb5d5edcb40f02581c1533dde3bbd77
3
{ "blob_id": "7cd2c0006cb5d5edcb40f02581c1533dde3bbd77", "branch_name": "refs/heads/master", "committer_date": 1528331834000, "content_id": "28793d6f897561392aca4368ed7d621057951809", "detected_licenses": [ "Apache-2.0" ], "directory_id": "13abaa0e28ba12dbb32fbfb90ba6506e0ce8ae7a", "extension": "py"...
2.625
stackv2
# # Copyright 2017 Import.io # # 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, ...
141
30.05
102
15
958
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_fa42c8b34f348e2a_898905bf", "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." ]
[ 108 ]
[ 110 ]
[ 22 ]
[ 10 ]
2024-11-19T00:13:42.106865+00:00
1,534,011,658,000
6f05790b175a18159547d84e37d476398cb5b1f4
2
{ "blob_id": "6f05790b175a18159547d84e37d476398cb5b1f4", "branch_name": "refs/heads/master", "committer_date": 1534011658000, "content_id": "9d500f5e403ded4937b622af8aaaa44e6d861c5c", "detected_licenses": [ "MIT" ], "directory_id": "f70f0c9ee47689dbb2b8cc3d17cd723658198d9e", "extension": "py", "fi...
2.359375
stackv2
from flask import Flask, request, jsonify from flask_cors import CORS # from db.import_cards import import_cards from db.operations.operations_factory import OperationsFactory from errors.errors import Error DB_NAME = "deckbuilder_db" app = Flask(__name__) CORS(app) operations_factory = OperationsFactory(DB_NAME) ca...
153
26.39
106
11
981
python
[{"finding_id": "codeql_py/reflective-xss_e4870e6f46a8bdb8_9a19266a", "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...
4
true
[ "CWE-079", "CWE-079", "CWE-079", "CWE-079" ]
[ "py/reflective-xss", "py/reflective-xss", "py/reflective-xss", "py/reflective-xss" ]
[ "HIGH", "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "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).", "Cross-site scripting vulnerability due to a [user-provided value](1)." ]
[ 73, 82, 92, 102 ]
[ null, null, null, null ]
[ 12, 12, 12, 12 ]
[ 19, 19, 19, 19 ]
2024-11-19T01:26:10.159358+00:00
1,403,884,936,000
841ad918df0ec1acc596ad273769158bc1f207e5
3
{ "blob_id": "841ad918df0ec1acc596ad273769158bc1f207e5", "branch_name": "refs/heads/master", "committer_date": 1403884936000, "content_id": "54b7ded53548ed3061ab2fc9c3fbc73ef4995888", "detected_licenses": [ "MIT" ], "directory_id": "dfd07eda52d2a61fbcc87bbff0950c5a8b67629a", "extension": "py", "fi...
3.0625
stackv2
''' Created on 03/02/2014 @author: Marc Lopez Roca @version: 0.8 Conversio d'interficie a py: pyuic4 -x Multipass.ui -o Multipass.py ''' # -*- coding: utf-8 -*- import sys, hashlib, base64 from PyQt4 import QtGui from Multipass import Ui_Multipass class StartQT4(QtGui.QMainWindow): def __init__(self, parent=Non...
97
32.65
119
16
915
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_07dd090650fcabd6_5f80c7cc", "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." ]
[ 33 ]
[ null ]
[ 34 ]
[ 38 ]
2024-11-18T23:43:10.162565+00:00
1,625,562,011,000
97ed910efeabe5e1ae845bee15c4d04ed69a694c
3
{ "blob_id": "97ed910efeabe5e1ae845bee15c4d04ed69a694c", "branch_name": "refs/heads/master", "committer_date": 1625562011000, "content_id": "28d753af018ec965d3f72cb150fc1f27a5e537d9", "detected_licenses": [ "BSD-3-Clause" ], "directory_id": "a18e4cb831e9dbc524d67ef4aab38df81b9c7727", "extension": "p...
2.625
stackv2
import os, sys from os.path import join import tarfile import xml.etree.ElementTree as ET from sklearn.datasets import get_data_home import pickle import rdflib from rdflib.namespace import RDF, SKOS from rdflib import URIRef import zipfile from collections import Counter from tqdm import tqdm from random import shuffl...
263
39.21
145
18
2,596
python
[{"finding_id": "codeql_py/tarslip_23e5dafb4867172b_dc1fce53", "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)." ]
[ 125 ]
[ null ]
[ 9 ]
[ 43 ]
2024-11-19T01:18:01.392366+00:00
1,487,756,787,000
0a7a57bf3db268d78d7485026a2c0a7059750329
2
{ "blob_id": "0a7a57bf3db268d78d7485026a2c0a7059750329", "branch_name": "refs/heads/master", "committer_date": 1487756787000, "content_id": "24dc5345cc9749eb8fa57f3f6cc5cea6a450313e", "detected_licenses": [ "BSD-3-Clause", "MIT", "Apache-2.0" ], "directory_id": "94f5bae62a2ed5bf5bd69995d9604c1...
2.390625
stackv2
#! /usr/bin/env python2.5 # -*- coding: utf-8 -*- # # Copyright (c) 2008 Ryan Kanno (ryankanno@localkinegrinds.com) # License: GNU GPLv3 import urllib2 import smtplib from email.MIMEMultipart import MIMEMultipart from email.MIMEBase import MIMEBase from email.MIMEText import MIMEText from email.Utils import COMMASP...
174
37.44
137
15
1,629
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_66176d96afaffb16_21fe89c5", "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.\nThis expression logs [sensitive data (password)](4) as clear text." ]
[ 96 ]
[ null ]
[ 23 ]
[ 137 ]
2024-11-19T01:18:02.669103+00:00
1,599,839,441,000
11669ac4854af1b27d18a2c9c2d3be89516ffbfe
3
{ "blob_id": "11669ac4854af1b27d18a2c9c2d3be89516ffbfe", "branch_name": "refs/heads/master", "committer_date": 1599839441000, "content_id": "d68a5122ce0548cae4812bf13d6ffd5912929802", "detected_licenses": [ "MIT" ], "directory_id": "3baad6a8ab52eb2274dc83d26cc9fe66c202a989", "extension": "py", "fi...
3.03125
stackv2
import tarfile import numpy as np import h5py import scipy.io as sio import os import re from shutil import copyfile # Path to the downloaded file is saved TAR_FILE_PATH = '/content/drive/My Drive/Colab Notebooks/FlowerClassification/102flowers.tgz' # Path where you want to extract the images EXTRACT_TO_PATH = '/co...
65
26.94
109
15
454
python
[{"finding_id": "codeql_py/tarslip_de1bb99bbc0e1e1e_73611e5e", "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)." ]
[ 29 ]
[ null ]
[ 5 ]
[ 8 ]
2024-11-19T00:15:29.823931+00:00
1,607,389,416,000
18f59e23d93e216140797511ae65c549bb7eb272
2
{ "blob_id": "18f59e23d93e216140797511ae65c549bb7eb272", "branch_name": "refs/heads/master", "committer_date": 1607389416000, "content_id": "a7fa619006dd2926e2599a7546f50cbd17cd8201", "detected_licenses": [ "MIT" ], "directory_id": "4011012058d784872fb8176584505b8263d36108", "extension": "py", "fi...
2.5
stackv2
# The MIT License (MIT) # # Copyright (c) 2019 Gregory M Paris # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, m...
116
39.36
80
17
1,055
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_f8ccd855754dad78_4ea3e354", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (secret)](1) as clear text.\nThi...
1
true
[ "CWE-312" ]
[ "py/clear-text-logging-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression logs [sensitive data (secret)](1) as clear text.\nThis expression logs [sensitive data (secret)](2) as clear text.\nThis expression logs [sensitive data (secret)](3) as clear text." ]
[ 105 ]
[ null ]
[ 23 ]
[ 65 ]
2024-11-19T00:25:32.428901+00:00
1,391,231,372,000
08e4cfe059b977fc4c738bd857a67ac051e1bf75
3
{ "blob_id": "08e4cfe059b977fc4c738bd857a67ac051e1bf75", "branch_name": "refs/heads/master", "committer_date": 1391231372000, "content_id": "3cd0a40d7536408702ccae322b2c8deaad1e6766", "detected_licenses": [ "MIT" ], "directory_id": "f1b30b834adf9b02b8288ce38d5fce663aba6478", "extension": "py", "fi...
2.546875
stackv2
""" Box creation helper script """ import os import stat import importlib import inspect import json from pkg_resources import resource_string, iter_entry_points from . import __version__ from .hook import check_output from .unbox import CONF_FILE class StaticResource(object): """ Wrapper for static resource l...
313
33.77
78
20
2,387
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_199dd55ab13da4fc_9865376f", "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." ]
[ 111 ]
[ null ]
[ 20 ]
[ 34 ]
2024-11-19T01:02:42.547096+00:00
1,593,170,191,000
30538c85fa29a459962792f3c9a64573634c9b13
2
{ "blob_id": "30538c85fa29a459962792f3c9a64573634c9b13", "branch_name": "refs/heads/master", "committer_date": 1593170191000, "content_id": "29413f39deca1f51034bbfd54abad7dc47095999", "detected_licenses": [ "Apache-2.0" ], "directory_id": "b76a6768ded04b3d63b33f555bbe4e51fd00210b", "extension": "py"...
2.359375
stackv2
# -*- coding: utf-8 -*- """ Usage of RichMenu Manager """ from richmenu import RichMenu, RichMenuManager from google.cloud import storage # import python library from flask import Flask, request import random, json, requests import pandas as pd # line libray from linebot import ( LineBotApi, WebhookHandler ) fr...
294
27.13
83
17
2,310
python
[{"finding_id": "codeql_py/flask-debug_72da9d3d88e21e28_addd9e18", "tool_name": "codeql", "rule_id": "py/flask-debug", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", ...
2
true
[ "CWE-215", "CWE-117" ]
[ "py/flask-debug", "py/log-injection" ]
[ "HIGH", "MEDIUM" ]
[ "MEDIUM", "MEDIUM" ]
[ "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", "This log entry depends on a [user-provided value](1)." ]
[ 289, 183 ]
[ 293, null ]
[ 5, 21 ]
[ 6, 44 ]
2024-11-19T00:16:08.327766+00:00
1,382,780,953,000
28c2b945f48398921e63f14715f7e426eb7522d5
2
{ "blob_id": "28c2b945f48398921e63f14715f7e426eb7522d5", "branch_name": "refs/heads/master", "committer_date": 1382780953000, "content_id": "9b557c495e54f68a01ceb755119d3f5c2a1b06e0", "detected_licenses": [ "BSD-2-Clause", "BSD-3-Clause" ], "directory_id": "85045953314a1cf340a6e954bd0763864f6ec78b...
2.40625
stackv2
#!/usr/bin/python import sn import sys,string import numpy as np import math import csv import os.path from collections import namedtuple import os import vcf import fnmatch from optparse import OptionParser import time class MapAndPed: """ This classe allow create and parse .map and .ped files to be used i...
363
35.01
166
25
3,269
python
[{"finding_id": "codeql_py/clear-text-storage-sensitive-data_eea951b04a7fa02f_e712374f", "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.\nThis expression stores [sensitive data (private)](3) as clear text." ]
[ 168 ]
[ null ]
[ 31 ]
[ 111 ]
2024-11-19T00:50:19.139979+00:00
1,571,736,687,000
680af6dc59d03fad50069ad83e58918b2ac554ec
3
{ "blob_id": "680af6dc59d03fad50069ad83e58918b2ac554ec", "branch_name": "refs/heads/master", "committer_date": 1571736687000, "content_id": "1a19b6c98df85e22fb6cdb37da468efa13fc90e0", "detected_licenses": [ "MIT" ], "directory_id": "3ab0be01080b9a49404a25c249d4b97c15e1eb3c", "extension": "py", "fi...
2.9375
stackv2
import mysql.connector import base64 import json import os product_table = 'products' product_key = 'product_id' product_rows_to_fetch = ['product_id', 'name', 'liter', 'min_age'] order_table = 'orders' class ThekenSQL: def __init__(self, id): self.db = None self.host:str = '' self.user:s...
137
32.45
143
20
882
python
[{"finding_id": "codeql_py/clear-text-storage-sensitive-data_ba893a97b3c9a89e_14820a2d", "tool_name": "codeql", "rule_id": "py/clear-text-storage-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression stores [sensitive data (password)](1) as clear text.\...
1
true
[ "CWE-312" ]
[ "py/clear-text-storage-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression stores [sensitive data (password)](1) as clear text.\nThis expression stores [sensitive data (password)](2) as clear text." ]
[ 33 ]
[ null ]
[ 21 ]
[ 44 ]
2024-11-19T01:30:48.831277+00:00
1,562,743,263,000
3c9bcedb7fa8ba3a87ef30c6bb973b9fbdb09f95
2
{ "blob_id": "3c9bcedb7fa8ba3a87ef30c6bb973b9fbdb09f95", "branch_name": "refs/heads/master", "committer_date": 1562743263000, "content_id": "b4b77bd039d2e5d7dfdada5c4630e075ea233909", "detected_licenses": [ "MIT" ], "directory_id": "6e77beef5d9b08fd7fcbe628bed4e46c0c291673", "extension": "py", "fi...
2.375
stackv2
import logging import os from collections import defaultdict from datetime import datetime from pathlib import Path from time import time from jinja2 import FileSystemLoader, Environment from sqlalchemy import or_ from binancedex.api import get_trades from binancedex.models import Session, engine, Address, Trade fro...
206
28.17
77
15
1,491
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_de28d89085c66c98_d09f097a", "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." ]
[ 37 ]
[ null ]
[ 19 ]
[ 45 ]
2024-11-19T01:31:00.507075+00:00
1,631,769,090,000
f2af1f94e9ea83ec9f4ff196637f405c4a44652f
2
{ "blob_id": "f2af1f94e9ea83ec9f4ff196637f405c4a44652f", "branch_name": "refs/heads/master", "committer_date": 1631769090000, "content_id": "5fe824da71c33823fadce519fc990bbb415bda6e", "detected_licenses": [ "MIT" ], "directory_id": "552bce065326b2f1068a61f3c11d7f42db45fea1", "extension": "py", "fi...
2.359375
stackv2
# -*- coding: utf-8 -*- # from http.server import HTTPServer, BaseHTTPRequestHandler import json import mimetypes import os import pstats import string import threading import webbrowser try: from html import escape except ImportError: from cgi import escape from .__about__ import __version__ from .module_gro...
219
30.95
88
18
1,715
python
[{"finding_id": "codeql_py/http-response-splitting_2154ba57aa842e04_11da2768", "tool_name": "codeql", "rule_id": "py/http-response-splitting", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This HTTP header is constructed from a [user-provided value](1).", "remediation": "", "lo...
2
true
[ "CWE-113", "CWE-022" ]
[ "py/http-response-splitting", "py/path-injection" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "This HTTP header is constructed from a [user-provided value](1).", "This path depends on a [user-provided value](1)." ]
[ 202, 205 ]
[ null, null ]
[ 50, 27 ]
[ 58, 35 ]
2024-11-19T02:05:01.493162+00:00
1,441,985,544,000
b6ed05b43216ac520ffe826083c82118cf6676e1
3
{ "blob_id": "b6ed05b43216ac520ffe826083c82118cf6676e1", "branch_name": "refs/heads/master", "committer_date": 1441985544000, "content_id": "56649598f0c3d479c782b96b7b572594fb85004a", "detected_licenses": [ "Apache-2.0" ], "directory_id": "7f2cfdef10d26debf31d56b9d12cb43a4dcad52a", "extension": "py"...
2.75
stackv2
import time from flask import Flask, request app = Flask(__name__) @app.route('/favicon.ico') def favicon(): return '' @app.route('/<code>', methods=['GET', 'POST']) def wait_request(code): wait_time_param = request.args.get('wait', '0') try: wait_time = int(wait_time_param) except ValueErro...
22
25.18
109
12
137
python
[{"finding_id": "codeql_py/flask-debug_9e7f6a0e4fa90914_1ddba04d", "tool_name": "codeql", "rule_id": "py/flask-debug", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", ...
3
true
[ "CWE-215", "CWE-079", "CWE-079" ]
[ "py/flask-debug", "py/reflective-xss", "py/reflective-xss" ]
[ "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", "Cross-site scripting vulnerability due to a [user-provided value](1).", "Cross-site scripting vulnerability due to a [user-provided value](1)." ]
[ 22, 17, 19 ]
[ null, null, null ]
[ 5, 16, 12 ]
[ 24, 65, 110 ]
2024-11-19T02:00:44.023972+00:00
1,561,517,545,000
565cafdee31673fbf4d64d61ec11d374d78ffc94
3
{ "blob_id": "565cafdee31673fbf4d64d61ec11d374d78ffc94", "branch_name": "refs/heads/master", "committer_date": 1561517545000, "content_id": "8bfed288be65480847603ea08a936105ee6a58d2", "detected_licenses": [ "MIT" ], "directory_id": "54d58e2dd19c52dd430947bea4f9efb3eb331281", "extension": "py", "fi...
3.359375
stackv2
# -*- coding: utf-8 -*- """ ------------------------------------------------- Author: Sz WeChat: itlke-sz ------------------------------------------------- """ __author__ = 'Sz' def get_body_fat(name, sex, age, height, weight): try: if sex in ("男", "女"): sex = 1 if sex == "男"...
53
25.96
116
13
441
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_f7f843b0afaa48e9_93108917", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (private)](1) as clear text.\nTh...
1
true
[ "CWE-312" ]
[ "py/clear-text-logging-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression logs [sensitive data (private)](1) as clear text.\nThis expression logs [sensitive data (private)](2) as clear text.\nThis expression logs [sensitive data (private)](3) as clear text." ]
[ 53 ]
[ null ]
[ 7 ]
[ 13 ]
2024-11-19T02:00:56.743354+00:00
1,569,315,423,000
66ac2dcefc64fd2f510b48ed649e66ace7e99f02
3
{ "blob_id": "66ac2dcefc64fd2f510b48ed649e66ace7e99f02", "branch_name": "refs/heads/master", "committer_date": 1569315423000, "content_id": "65c4a128ee2ea802a424b0869998f9250f3546ad", "detected_licenses": [ "MIT" ], "directory_id": "343b18a50270822591766004e223a3d584059b8e", "extension": "py", "fi...
2.53125
stackv2
from . import auth from flask import render_template,jsonify,redirect,url_for,request from werkzeug.security import check_password_hash from app.models import User from flask_login import login_user,logout_user @auth.route('/signup', methods=['POST','GET']) def signup(): if request.method == "POST": form = ...
52
39.85
95
18
415
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_19459de8d53e04eb_77242fac", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (password)](1) as clear text.", ...
1
true
[ "CWE-312" ]
[ "py/clear-text-logging-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression logs [sensitive data (password)](1) as clear text." ]
[ 14 ]
[ null ]
[ 15 ]
[ 23 ]
2024-11-19T02:00:59.495734+00:00
1,633,296,772,000
74a22f1c33f5a4103319fd58df280822bc2aef1a
3
{ "blob_id": "74a22f1c33f5a4103319fd58df280822bc2aef1a", "branch_name": "refs/heads/master", "committer_date": 1633296772000, "content_id": "dbc55b45cd38ac5bab05bf7270fb9ded42d7fc6d", "detected_licenses": [ "MIT" ], "directory_id": "7198a1915c085e0d10484bfdc351d2ed562f5cb8", "extension": "py", "fi...
2.75
stackv2
"""Handles user (un)subscription.""" import logging from flask import abort, jsonify, render_template, request from truestory import app, auth from truestory.models.mail import SubscriberModel def _subscribe_mail(mail): """Adds a new subscriber to our platform. Returns: SubscriberModel: The newly...
84
31.98
85
14
570
python
[{"finding_id": "codeql_py/log-injection_54a2446cc7fdc075_36253d98", "tool_name": "codeql", "rule_id": "py/log-injection", "finding_type": "path-problem", "severity": "medium", "confidence": "medium", "message": "This log entry depends on a [user-provided value](1).", "remediation": "", "location": {"file_path": "unkno...
3
true
[ "CWE-117", "CWE-117", "CWE-117" ]
[ "py/log-injection", "py/log-injection", "py/log-injection" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "This log entry depends on a [user-provided value](1).", "This log entry depends on a [user-provided value](1).", "This log entry depends on a [user-provided value](1)." ]
[ 26, 31, 36 ]
[ null, null, null ]
[ 55, 43, 58 ]
[ 59, 47, 62 ]
2024-11-19T00:04:21.854718+00:00
1,629,545,458,000
4287dd3d39b22899be68c6c98a3fbe94b26bb2e4
3
{ "blob_id": "4287dd3d39b22899be68c6c98a3fbe94b26bb2e4", "branch_name": "refs/heads/master", "committer_date": 1629545458000, "content_id": "1aa0e9d10d54e74864f9c354ee7f3cfc2a9ae689", "detected_licenses": [ "MIT" ], "directory_id": "f4c4de0097423ddf63c45a9730f9c382747ad1a4", "extension": "py", "fi...
2.671875
stackv2
from flask import render_template, url_for, request, redirect from flask_login import login_user, logout_user from app.auth import auth from app.models import User @auth.route('/login', methods=['GET', 'POST']) def login(): if request.method=='POST': form=request.form username=form.get('username') ...
68
35.87
93
17
491
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_fef95985999c5eb9_08d79768", "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." ]
[ 18 ]
[ null ]
[ 15 ]
[ 31 ]
2024-11-19T00:04:33.977839+00:00
1,554,682,618,000
ef7d7790b63dacd01b4da341548f42b6ecde036e
4
{ "blob_id": "ef7d7790b63dacd01b4da341548f42b6ecde036e", "branch_name": "refs/heads/master", "committer_date": 1554682618000, "content_id": "fa8dd1eee4e7e3d89fb299b48d139837c1cacd21", "detected_licenses": [ "MIT" ], "directory_id": "fc6df4504924bf7a1d176e8f74332d82b80a16b9", "extension": "py", "fi...
3.890625
stackv2
import string import random from user import User def print_message_head(message): ''' print welcome message function ''' print("*"*50) print(message.upper()) print("*"*50+"\n") def login(): ''' Logs in a new user ''' username=input("Username: ") password= input("Password: ...
113
23.19
108
15
646
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_9e87cb7a49f2c211_ee1715ed", "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." ]
[ 84 ]
[ null ]
[ 13 ]
[ 106 ]
2024-11-19T00:40:27.472332+00:00
1,693,638,988,000
2754c868ee6c3921caa1d608213a1a144dc67bf4
3
{ "blob_id": "2754c868ee6c3921caa1d608213a1a144dc67bf4", "branch_name": "refs/heads/main", "committer_date": 1693638988000, "content_id": "4f763ad84426db3800acf23298b4a3e2f9e8519b", "detected_licenses": [ "MIT" ], "directory_id": "0f2b08b31fab269c77d4b14240b8746a3ba17d5e", "extension": "py", "file...
2.8125
stackv2
import json import os import tarfile import wget def get_tar_file(link): file_name = link.split("/")[-1] return file_name def create_model_folder(model): os.mkdir(model) def extract_and_get_files(file_name): model_folder = file_name.replace(".tar.gz", "") + "/" create_model_folder(model_folde...
83
23.55
85
12
478
python
[{"finding_id": "codeql_py/tarslip_776c95ae6d8864bd_dfdd5d2f", "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)." ]
[ 21 ]
[ null ]
[ 5 ]
[ 14 ]
2024-11-19T00:40:30.339800+00:00
1,469,182,328,000
79c4ce23b1f75351d0824e7f2ba200b2fca89625
3
{ "blob_id": "79c4ce23b1f75351d0824e7f2ba200b2fca89625", "branch_name": "refs/heads/master", "committer_date": 1469182328000, "content_id": "ac75638c1febfd99eece7ffdcfad6aadeadc4e83", "detected_licenses": [ "MIT" ], "directory_id": "afba034302b419f819611b9217cee546ea5ace14", "extension": "py", "fi...
2.59375
stackv2
import argparse import json import os import logging from flask import Flask, request, render_template from Pokescanner import Pokescanner from datetime import datetime log = logging.getLogger('werkzeug') #log.setLevel(logging.ERROR) log.disabled = True app = Flask(__name__, template_folder="templates") scan_thread_l...
205
38.7
134
21
1,936
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_c9f6f62bd79f903e_afa9d668", "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...
4
true
[ "CWE-312", "CWE-215", "CWE-079", "CWE-079" ]
[ "py/clear-text-logging-sensitive-data", "py/flask-debug", "py/reflective-xss", "py/reflective-xss" ]
[ "HIGH", "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "This expression logs [sensitive data (private)](1) as clear text.\nThis expression logs [sensitive data (private)](2) as clear text.", "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-provid...
[ 92, 205, 78, 95 ]
[ null, null, 79, 100 ]
[ 15, 5, 16, 16 ]
[ 113, 66, 77, 91 ]
2024-11-19T01:17:55.488399+00:00
1,607,555,783,000
e634570d63220266aa551deedea5cfa6e5385971
2
{ "blob_id": "e634570d63220266aa551deedea5cfa6e5385971", "branch_name": "refs/heads/main", "committer_date": 1607555783000, "content_id": "f477f19d0c38733d5dcca09a170ad273b69bddb3", "detected_licenses": [ "Apache-2.0" ], "directory_id": "cfff28955ff3147aedd47dffd0a4b9412ad35fef", "extension": "py", ...
2.46875
stackv2
from flask import Flask from flask import Response from flask_cors import CORS import urllib.request import urllib.parse app = Flask(__name__) CORS(app) @app.route("/<id>") def home(id): url = 'https://world.openfoodfacts.org/api/v0/product/'+str(id)+'.json' f = urllib.request.urlopen(url) data = f.read(...
19
22.11
75
11
114
python
[{"finding_id": "codeql_py/flask-debug_7b270d7732c44f02_dd52105a", "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)." ]
[ 19, 14 ]
[ null, null ]
[ 5, 9 ]
[ 34, 36 ]
2024-11-19T01:18:11.761316+00:00
1,615,728,067,000
c0fd1f7c12d2220a15e14adf6044131c3691fcb3
3
{ "blob_id": "c0fd1f7c12d2220a15e14adf6044131c3691fcb3", "branch_name": "refs/heads/master", "committer_date": 1615728067000, "content_id": "37dd829f81b5c7bc698036d74279d9e9f9f95ad0", "detected_licenses": [ "Apache-2.0" ], "directory_id": "931ff90b0e1ba4a71a6892032e8e928b274d70bc", "extension": "py"...
2.625
stackv2
import hmac import time import hashlib class BtcturkAuth: def __init__(self, api_key: str, secret_key: str): self.api_key = api_key self.secret_key = secret_key def generate_auth_dict(self) -> dict: """ Returns headers for authenticated api request. """ nonce =...
33
28.24
79
14
238
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_ffd07ca76c82acc2_4531f1cd", "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." ]
[ 31 ]
[ null ]
[ 50 ]
[ 54 ]
2024-11-19T01:03:40.827779+00:00
1,561,577,885,000
9d6ef4a530b3e8d8bc70fcd38fbdc8ffecb79820
2
{ "blob_id": "9d6ef4a530b3e8d8bc70fcd38fbdc8ffecb79820", "branch_name": "refs/heads/master", "committer_date": 1561577885000, "content_id": "3ad4eda0f6b4d3244bf34ad0f28863de8ab84dcf", "detected_licenses": [ "Apache-2.0" ], "directory_id": "5f5f408dca091ad207cc674ae4fa59cc54bd31ef", "extension": "py"...
2.390625
stackv2
import logging from core.exceptions import AuthorizationException import hashlib def hash_password(password): h = hashlib.sha256(password.encode()) return h.hexdigest() def _check_rules(token_payload, roles: list=None): min_permission = min(roles) if token_payload.get('role', 0) <= min_permission: ...
57
26.91
74
21
279
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_25b3e01a82c665c6_8df0a77c", "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." ]
[ 7 ]
[ null ]
[ 24 ]
[ 41 ]
2024-11-19T01:15:10.484612+00:00
1,528,108,912,000
137237b603812b8f69de9d04f1458febbd36f282
2
{ "blob_id": "137237b603812b8f69de9d04f1458febbd36f282", "branch_name": "refs/heads/master", "committer_date": 1528108912000, "content_id": "e151f60cd61999737c680cc232242f55dff7af29", "detected_licenses": [ "MIT" ], "directory_id": "3e3f0c127ab5750d6bf37e2e6a922f69cb3e0114", "extension": "py", "fi...
2.40625
stackv2
from flask import Blueprint, render_template, redirect, flash, request, url_for from flask_login import login_user, logout_user, login_required from ..utils import require_unauthed, ts, send_email from ..forms import LoginForm, EmailForm, PasswordForm from ..models import User from .. import db login = Blueprint("log...
74
32.31
84
16
552
python
[{"finding_id": "codeql_py/url-redirection_32a3abd5d82007ba_48fddcaf", "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)." ]
[ 24 ]
[ null ]
[ 25 ]
[ 54 ]
2024-11-19T01:15:10.634467+00:00
1,520,458,362,000
6b675671215501a1e0f330febac4fb54e1fbd817
3
{ "blob_id": "6b675671215501a1e0f330febac4fb54e1fbd817", "branch_name": "refs/heads/master", "committer_date": 1520458362000, "content_id": "5edffdcb709288410265b614c85e55d014b17f7a", "detected_licenses": [ "BSD-3-Clause" ], "directory_id": "6ab233f0e97010d0c2151a618a48eea2a326160f", "extension": "p...
2.671875
stackv2
# -*- coding: utf-8 -*- import hmac import json import hashlib import time import base64 import requests from cryptotik.common import headers, ExchangeWrapper from cryptotik.exceptions import APIError from decimal import Decimal class Cryptopia(ExchangeWrapper): url = 'https://www.cryptopia.co.nz/' name = '...
247
32.97
108
17
1,797
python
[{"finding_id": "codeql_py/weak-sensitive-data-hashing_febb03dbe87f2e60_a31a4d92", "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." ]
[ 76 ]
[ null ]
[ 25 ]
[ 50 ]
2024-11-19T00:43:51.613998+00:00
1,489,246,362,000
d3c59c35b85208d4fb55d248780495ea4594bc90
3
{ "blob_id": "d3c59c35b85208d4fb55d248780495ea4594bc90", "branch_name": "refs/heads/master", "committer_date": 1489246362000, "content_id": "7450cf809803126e22c82f5e5c5f93afe859cbf6", "detected_licenses": [ "Apache-2.0" ], "directory_id": "1717fbb0786312220d5a182e19b3201381da796c", "extension": "py"...
2.578125
stackv2
import os from webdriver_manager import archive from webdriver_manager import utils from webdriver_manager.binary import Binary from webdriver_manager.driver import PhantomJsDriver from webdriver_manager.manager import DriverManager from shutil import copyfile class PhantomJsDriverManager(DriverManager): def __i...
40
34.08
92
13
303
python
[{"finding_id": "codeql_py/overly-permissive-file_b77c72b4997f97d9_1ab7abb1", "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." ]
[ 23 ]
[ null ]
[ 9 ]
[ 39 ]
2024-11-19T00:43:52.887994+00:00
1,623,954,958,000
1f954e449430336038cdadadbf115be05a59e5d2
2
{ "blob_id": "1f954e449430336038cdadadbf115be05a59e5d2", "branch_name": "refs/heads/master", "committer_date": 1623954958000, "content_id": "320e2ae4e3fa1a2293adbec9816edc7e9e589579", "detected_licenses": [ "MIT" ], "directory_id": "d2896b89005dfcbcf679a7488f3d94ffd266d1c7", "extension": "py", "fi...
2.34375
stackv2
from jinja2 import Template from starlette.applications import Starlette from starlette.responses import PlainTextResponse, HTMLResponse from starlette_wtf import StarletteForm from wtforms import StringField from wtforms.validators import DataRequired class MyForm(StarletteForm): name = StringField('name', valid...
41
22.44
63
12
224
python
[{"finding_id": "codeql_py/jinja2/autoescape-false_fabb1f75ed1bc11b_c98f0e0c", "tool_name": "codeql", "rule_id": "py/jinja2/autoescape-false", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Using jinja2 templates with autoescape=False can potentially allow XSS attacks.", "remediati...
1
true
[ "CWE-079" ]
[ "py/jinja2/autoescape-false" ]
[ "MEDIUM" ]
[ "MEDIUM" ]
[ "Using jinja2 templates with autoescape=False can potentially allow XSS attacks." ]
[ 13 ]
[ 27 ]
[ 12 ]
[ 5 ]
2024-11-19T01:32:16.177379+00:00
1,693,195,417,000
558f2c841fbdebf98e5bbfc56d587eda4cfc6834
3
{ "blob_id": "558f2c841fbdebf98e5bbfc56d587eda4cfc6834", "branch_name": "refs/heads/master", "committer_date": 1693195417000, "content_id": "05a9c64b450644c9a71c3f630aa4f5ad86a8f780", "detected_licenses": [ "MIT" ], "directory_id": "deda1742a61225a8c7ecd1833ec388f72d8bcc4f", "extension": "py", "fi...
2.625
stackv2
from flask import request, jsonify, make_response from flask.views import MethodView from ..database_setup import ( Feed, FeedTag, basicInformationAndFeed ) from .. import db from . import feed from .feed_services import FeedServices import json from datetime import datetime, timedelta import logging logger = logg...
75
32.81
78
16
544
python
[{"finding_id": "codeql_py/stack-trace-exposure_d78cf792c81df6dd_a9e9ef23", "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." ]
[ 59 ]
[ null ]
[ 34 ]
[ 53 ]
2024-11-19T01:32:19.617724+00:00
1,683,133,481,000
c14f1ebf20514437c173cdb7af99f060983c644a
3
{ "blob_id": "c14f1ebf20514437c173cdb7af99f060983c644a", "branch_name": "refs/heads/main", "committer_date": 1683133481000, "content_id": "66d9efb9d93bf691c993b8a6e780ce6b032a5e78", "detected_licenses": [ "BSD-2-Clause" ], "directory_id": "14d22442499bb52ae9d831d129a27904a95b2e30", "extension": "py"...
2.734375
stackv2
# Copyright 2016 the HERA Collaboration # Licensed under the BSD License. """This module contains various utilities that help with the Flask-y, web interface end of things. """ __all__ = str( """ AuthFailedError ServerError json_api login_required login logout """ ).split() import json import os import sys fro...
372
28.45
98
23
2,416
python
[{"finding_id": "codeql_py/stack-trace-exposure_92e36cf7650b1dc6_71882c76", "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.\n[S...
3
true
[ "CWE-209", "CWE-209", "CWE-601" ]
[ "py/stack-trace-exposure", "py/stack-trace-exposure", "py/url-redirection" ]
[ "HIGH", "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "[Stack trace information](1) flows to this location and may be exposed to an external user.\n[Stack trace information](2) flows to this location and may be exposed to an external user.", "[Stack trace information](1) flows to this location and may be exposed to an external user.", "Untrusted URL redirection de...
[ 175, 370, 280 ]
[ null, null, null ]
[ 25, 24, 21 ]
[ 32, 30, 24 ]
2024-11-19T01:44:11.565707+00:00
1,622,536,401,000
aa78ed10041144852dc5a2ca9169e8a114d09340
3
{ "blob_id": "aa78ed10041144852dc5a2ca9169e8a114d09340", "branch_name": "refs/heads/main", "committer_date": 1622536401000, "content_id": "1a834453f5ee599c7c36b2fa9800a46f83348f6d", "detected_licenses": [ "MIT" ], "directory_id": "bc4564b52ef9bd356f9922c9c555db27a63573f3", "extension": "py", "file...
2.515625
stackv2
""" Plist Service - handles parsing and formatting plist content """ from .exceptions import MuxError from ..util import logging import plistlib import re import ssl import struct from socket import socket from typing import Optional, Dict, Any from .usbmux import USBMux, MuxDevice __all__ = ['PlistService'] log = lo...
104
30.09
93
18
757
python
[{"finding_id": "codeql_py/overly-large-range_b5bcbdfc1e3bb27d_7168a8e4", "tool_name": "codeql", "rule_id": "py/overly-large-range", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Suspicious character range that overlaps with \\w in the same character class.", "remediation": "", "loc...
2
true
[ "CWE-020", "CWE-327" ]
[ "py/overly-large-range", "py/insecure-default-protocol" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "Suspicious character range that overlaps with \\w in the same character class.", "Call to deprecated method ssl.wrap_socket does not specify a protocol, which may result in an insecure default being used." ]
[ 17, 40 ]
[ null, null ]
[ 49, 21 ]
[ 52, 66 ]
2024-11-19T02:19:56.165806+00:00
1,573,547,121,000
ebcd03c06b559ad579307d84de999aeb74330cf5
3
{ "blob_id": "ebcd03c06b559ad579307d84de999aeb74330cf5", "branch_name": "refs/heads/master", "committer_date": 1573547121000, "content_id": "ef9b4f5f6e5b97b605d758e819d7a5251c7b6897", "detected_licenses": [ "MIT" ], "directory_id": "23f07a9909107e5050fb389b803948a25e16f856", "extension": "py", "fi...
3.28125
stackv2
""" # The Great Hypothesis Idea Generator print("___________________________") title = "The Great Hypothesis Idea Generator" intro = "This program assists in the generation of hypotheses and ideas" intro + " and uses different listing combinations to compile old ideas into new!" def introduction(): print(title + ...
175
23.22
122
15
1,215
python
[{"finding_id": "codeql_py/clear-text-logging-sensitive-data_45f2b36a166aee6b_d424b592", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (private)](1) as clear text.", "...
1
true
[ "CWE-312" ]
[ "py/clear-text-logging-sensitive-data" ]
[ "HIGH" ]
[ "MEDIUM" ]
[ "This expression logs [sensitive data (private)](1) as clear text." ]
[ 83 ]
[ null ]
[ 16 ]
[ 22 ]
2024-11-19T00:59:41.362244+00:00
1,610,083,679,000
7c16a9b32779f074719d14c82f03d3ae0ac52e65
3
{ "blob_id": "7c16a9b32779f074719d14c82f03d3ae0ac52e65", "branch_name": "refs/heads/main", "committer_date": 1610083679000, "content_id": "9318d30cd93715ad98f89eca939c666a26a139aa", "detected_licenses": [ "MIT" ], "directory_id": "65f7a73771bc213f87fbc58e089d1361ced83578", "extension": "py", "file...
2.875
stackv2
import flask import os import json from flask import jsonify, render_template class Student: def __init__(self,jsonIn): self.studentId = jsonIn['studentId'] self.studentName = jsonIn['name'] self.courses= jsonIn['courses'] self.quizzes = jsonIn['quizzes'] def addCourse(self...
192
30.41
124
15
1,409
python
[{"finding_id": "codeql_py/stack-trace-exposure_f83d7f00143bacb2_20c0e22b", "tool_name": "codeql", "rule_id": "py/stack-trace-exposure", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "[Stack trace information](1) flows to this location and may be exposed to an external user.", "...
2
true
[ "CWE-209", "CWE-209" ]
[ "py/stack-trace-exposure", "py/stack-trace-exposure" ]
[ "HIGH", "HIGH" ]
[ "MEDIUM", "MEDIUM" ]
[ "[Stack trace information](1) flows to this location and may be exposed to an external user.", "[Stack trace information](1) flows to this location and may be exposed to an external user." ]
[ 110, 157 ]
[ null, null ]
[ 16, 16 ]
[ 38, 38 ]
2024-11-19T00:59:47.216639+00:00
1,515,441,692,000
16235eb9555ab1833087ca6d9798d2f0cca5f3ef
3
{ "blob_id": "16235eb9555ab1833087ca6d9798d2f0cca5f3ef", "branch_name": "refs/heads/master", "committer_date": 1515441692000, "content_id": "fd521d7d19987e07043a71a61597e5f5fb9bb338", "detected_licenses": [ "MIT" ], "directory_id": "f45ecf5bee4befdf73e6cb79dff45d73af7365d3", "extension": "py", "fi...
2.578125
stackv2
import threading import queue import logging import os import time from flask.views import MethodView from flask import request from flask_restplus import Api, Resource, fields, reqparse """ This is the web service class that runs a REST. The REST can be used to direct control the mainboards functions on STM32 over S...
219
31.57
125
17
1,929
python
[{"finding_id": "codeql_py/log-injection_7fe1bff67e39d6f9_310a39d5", "tool_name": "codeql", "rule_id": "py/log-injection", "finding_type": "path-problem", "severity": "medium", "confidence": "medium", "message": "This log entry depends on a [user-provided value](1).", "remediation": "", "location": {"file_path": "unkno...
8
true
[ "CWE-117", "CWE-117", "CWE-117", "CWE-117", "CWE-117", "CWE-117", "CWE-117", "CWE-117" ]
[ "py/log-injection", "py/log-injection", "py/log-injection", "py/log-injection", "py/log-injection", "py/log-injection", "py/log-injection", "py/log-injection" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM", "MEDIUM" ]
[ "This log entry depends on a [user-provided value](1).", "This log entry depends on a [user-provided value](1).", "This log entry depends on a [user-provided value](1).", "This log entry depends on a [user-provided value](1).", "This log entry depends on a [user-provided value](1).", "This log entry depen...
[ 40, 45, 60, 61, 65, 73, 100, 116 ]
[ null, null, null, null, null, null, null, null ]
[ 22, 45, 22, 23, 27, 45, 23, 26 ]
[ 24, 47, 24, 55, 71, 47, 42, 60 ]