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-19T00:04:38.454361+00:00 | 1,532,071,222,000 | c95faa0fb6c87232587dc253692202d48512be4a | 2 | {
"blob_id": "c95faa0fb6c87232587dc253692202d48512be4a",
"branch_name": "refs/heads/master",
"committer_date": 1532071222000,
"content_id": "cec4474e720a1651078c6993e2a24722e55bd85c",
"detected_licenses": [
"BSD-3-Clause"
],
"directory_id": "bb747f5eb1e610983a441be933506111b40d239c",
"extension": "p... | 2.453125 | stackv2 | """
DOCSTRING
"""
import os
import sys
import json
import socket
import platform
import requests
import urllib3
from pathlib import Path
import re
from xml.etree.ElementTree import XML
# Disable Self-Signed SSL Warning
urllib3.disable_warnings(urllib3.exceptions.InsecureRequestWarning)
UCSD_ADDR = ""
CLOUPIA_KEY = "... | 357 | 22.46 | 108 | 22 | 1,974 | python | [{"finding_id": "codeql_py/request-without-cert-validation_1c5308fcec5d9a89_c7ab056c", "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)."
] | [
339,
341,
352
] | [
null,
null,
null
] | [
24,
24,
20
] | [
108,
109,
107
] | |
2024-11-19T00:40:28.498067+00:00 | 1,568,943,458,000 | dddebc1ad13e577a362c41446419a4c7825619e1 | 3 | {
"blob_id": "dddebc1ad13e577a362c41446419a4c7825619e1",
"branch_name": "refs/heads/master",
"committer_date": 1568943458000,
"content_id": "e0a5d54e87614761b0b58cf838dc13d57eba0876",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "926348f4a2bb2b0b079f41ed70a44b26d6d54604",
"extension": "py"... | 2.640625 | stackv2 | #!/usr/bin/env python
import json
import os
import stat
import sys
import time
import zipfile
def copy_files(zf, files_json):
utc_now_parts = time.gmtime(time.time())
for file_json in files_json:
src = file_json['src']
dst = file_json['dst']
with open(src, 'rb') as in_f:
d... | 60 | 28.57 | 111 | 13 | 442 | python | [{"finding_id": "codeql_py/overly-permissive-file_84e8f81018d95edd_b6eefa12", "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."
] | [
44
] | [
null
] | [
5
] | [
32
] | |
2024-11-19T01:17:27.174081+00:00 | 1,631,650,515,000 | 4472580f436a5474ff829176c03cf3ad0d2e3940 | 3 | {
"blob_id": "4472580f436a5474ff829176c03cf3ad0d2e3940",
"branch_name": "refs/heads/master",
"committer_date": 1631650515000,
"content_id": "37167894d419a1c549fe4364743eb7ae9cb9aed5",
"detected_licenses": [
"MIT"
],
"directory_id": "e76618bb68ee2544efa410326241878fd5752c51",
"extension": "py",
"fi... | 2.90625 | stackv2 | import urllib.request
import json
from .models import Source, Article
# Getting api key
api_key = 'b5a552ecd1014284b4bf5cbc587790c4'
# Getting source url,article url
News_Source_url = None
article_url = None
def configure_request(app):
global api_key, News_Source_url, article_url
News_Source_url = app.confi... | 101 | 31.12 | 122 | 12 | 715 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_be436ef557f7b3e2_42fd1e8c", "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."
] | [
66
] | [
null
] | [
11
] | [
26
] | |
2024-11-19T01:17:32.248940+00:00 | 1,593,463,153,000 | 3eab9623a969db73983e571c9395676c16d7f743 | 3 | {
"blob_id": "3eab9623a969db73983e571c9395676c16d7f743",
"branch_name": "refs/heads/master",
"committer_date": 1593463153000,
"content_id": "ef54f8d32e9d6368d7518c0a638d12df99e362d7",
"detected_licenses": [
"MIT"
],
"directory_id": "c53dfff517d233855b5d70c5d5af46723e2c6dd4",
"extension": "py",
"fi... | 2.6875 | stackv2 | import enum
import os
import sys
from pyjob.cexec import is_exe
from pyjob.exception import PyJobError
from pyjob.pool import Pool
@enum.unique
class ScriptProperty(enum.Enum):
"""Enumeration for :obj:`~pyjob.script.Script`-specific properties"""
# Tried to extend Enum but operation not allowed in Python3.7... | 352 | 27.75 | 103 | 15 | 2,263 | python | [{"finding_id": "codeql_py/overly-permissive-file_587312a58c28e295_8c0607ea", "tool_name": "codeql", "rule_id": "py/overly-permissive-file", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Overly permissive mask in chmod sets file to world writable.", "remediation": "", "location": ... | 1 | true | [
"CWE-732"
] | [
"py/overly-permissive-file"
] | [
"MEDIUM"
] | [
"MEDIUM"
] | [
"Overly permissive mask in chmod sets file to world writable."
] | [
252
] | [
null
] | [
9
] | [
31
] | |
2024-11-19T01:17:57.904839+00:00 | 1,615,898,972,000 | c217b39a0a241c50c26f31c74b1c20a30a944f50 | 3 | {
"blob_id": "c217b39a0a241c50c26f31c74b1c20a30a944f50",
"branch_name": "refs/heads/main",
"committer_date": 1615898972000,
"content_id": "b9aad428dd5ffce2d047f39daf1f6cac3889effe",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "d5ab8a200203bd65322dafef30cd7c0c08330c6d",
"extension": "py",
... | 2.84375 | stackv2 | # -*-coding:utf-8 -*-
"""
提供两个requests请求会话池
"""
import asyncio
import aiohttp
import requests
from requests.adapters import HTTPAdapter
from urllib3 import Retry
# from functools import lru_cache
DEFAULT_TIMEOUT = 30
ASYNC_TIMEOUT = aiohttp.ClientTimeout(total=5, connect=None, sock_connect=None, sock_read=None)
SESS... | 85 | 27.76 | 108 | 16 | 682 | python | [{"finding_id": "codeql_py/request-without-cert-validation_e6ac697fc9a9966b_bb18116f", "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)."
] | [
54,
61
] | [
null,
null
] | [
24,
24
] | [
91,
103
] | |
2024-11-19T01:15:21.154244+00:00 | 1,612,876,763,000 | 44510e7866f5cf286d28c7541fb34e8645c90c48 | 3 | {
"blob_id": "44510e7866f5cf286d28c7541fb34e8645c90c48",
"branch_name": "refs/heads/master",
"committer_date": 1612876763000,
"content_id": "0f7130c7c17c635d80c728fbed6627db4adaead3",
"detected_licenses": [
"MIT"
],
"directory_id": "b5e64dbb7b4c0c24675f48dcbfe5069d04e21ce1",
"extension": "py",
"fi... | 2.65625 | stackv2 | #!/usr/bin/env python3
'''
Original solution is available here: https://bart.degoe.de/use-google-cloud-text-to-speech-to-create-an-audio-version-of-your-blog-posts/
'''
import argparse
import functools
import logging
import os
import re
import sys
from glob import glob
from os import listdir
from pathlib import Path
fr... | 133 | 33.66 | 137 | 14 | 1,148 | python | [{"finding_id": "codeql_py/bad-tag-filter_3f07e9f55244f082_3317090d", "tool_name": "codeql", "rule_id": "py/bad-tag-filter", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "This regular expression does not match upper case <SCRIPT> tags.", "remediation": "", "location": {"file_path": ... | 1 | true | [
"CWE-116"
] | [
"py/bad-tag-filter"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"This regular expression does not match upper case <SCRIPT> tags."
] | [
34
] | [
null
] | [
21
] | [
42
] | |
2024-11-19T00:43:57.901282+00:00 | 1,613,132,525,000 | bbf0607892432f39252a6af3b3405219c3c3315a | 3 | {
"blob_id": "bbf0607892432f39252a6af3b3405219c3c3315a",
"branch_name": "refs/heads/main",
"committer_date": 1613132525000,
"content_id": "57da4862597756885b9cfd6b23d8b1bc5e7b77f9",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "ddee22198c3ac1ad9f0c0108385ab9967c0b12b4",
"extension": "py",
... | 2.703125 | stackv2 | """
Set of utility functions to use with this Resource Provider
"""
import logging
import tarfile
from typing import Optional, Mapping
import boto3
import os
import sys
import urllib
import hashlib
import subprocess
from botocore.exceptions import ClientError
from cloudformation_cli_python_lib import SessionProxy
#... | 364 | 35.81 | 125 | 16 | 3,280 | python | [{"finding_id": "codeql_py/clear-text-storage-sensitive-data_f385921e01a3cc13_b79c901d", "tool_name": "codeql", "rule_id": "py/clear-text-storage-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression stores [sensitive data (secret)](1) as clear text.", ... | 3 | true | [
"CWE-312",
"CWE-312",
"CWE-022"
] | [
"py/clear-text-storage-sensitive-data",
"py/clear-text-logging-sensitive-data",
"py/tarslip"
] | [
"HIGH",
"HIGH",
"MEDIUM"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"This expression stores [sensitive data (secret)](1) as clear text.",
"This expression logs [sensitive data (secret)](1) as clear text.",
"This file extraction depends on a [potentially untrusted source](1)."
] | [
37,
60,
333
] | [
null,
null,
null
] | [
17,
34,
9
] | [
43,
57,
12
] | |
2024-11-19T00:43:58.842017+00:00 | 1,454,770,937,000 | aa21af491f358384b4fa14aa24611c54f2d0ae73 | 2 | {
"blob_id": "aa21af491f358384b4fa14aa24611c54f2d0ae73",
"branch_name": "refs/heads/master",
"committer_date": 1454770937000,
"content_id": "0957ec31224653aff027149488f686f16d0f87f5",
"detected_licenses": [
"MIT"
],
"directory_id": "b1ea933d68ccb3382a1a1fb2fe9e26912f013487",
"extension": "py",
"fi... | 2.5 | stackv2 | # -*- coding:utf-8 -*-
import os
import codecs
from jinja2 import Environment, FileSystemLoader
def look(path='.', deep_limit=3, ignore=[]):
env = Environment(loader=FileSystemLoader(os.path.join(os.path.dirname(__file__))))
template = env.get_template('template.html')
link = []
for name in os.li... | 24 | 38.62 | 87 | 16 | 235 | python | [{"finding_id": "codeql_py/jinja2/autoescape-false_c8896c72bbb8809a_6bcef46e", "tool_name": "codeql", "rule_id": "py/jinja2/autoescape-false", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Using jinja2 templates with autoescape=False can potentially allow XSS attacks.", "remediati... | 1 | true | [
"CWE-079"
] | [
"py/jinja2/autoescape-false"
] | [
"MEDIUM"
] | [
"MEDIUM"
] | [
"Using jinja2 templates with autoescape=False can potentially allow XSS attacks."
] | [
8
] | [
null
] | [
11
] | [
88
] | |
2024-11-19T01:31:58.618832+00:00 | 1,636,456,473,000 | 498a5ccaab12d38f027f5b551cddb1f983d1efc2 | 4 | {
"blob_id": "498a5ccaab12d38f027f5b551cddb1f983d1efc2",
"branch_name": "refs/heads/main",
"committer_date": 1636456473000,
"content_id": "0ac11e9dc596ba985cd5d7ef2d2b24bd24e3adca",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "a9a7c436c6a6d312f1020b5c738017cf12caf4eb",
"extension": "py",
... | 3.515625 | stackv2 | # programme to create a employee class call a class from another module
# # helen oshea
# 20210430
from timesheetentry import *
class Employee:
timesheets=[]
def __init__(self,first,last):
self.first=first
self.last=last
def __str__(self):
return self.first + ' ' + self.last
def logminutes(self,p... | 34 | 24.09 | 71 | 11 | 242 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_a2fc0e1aec6bc1b0_f2f50578", "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."
] | [
25
] | [
null
] | [
9
] | [
13
] | |
2024-11-19T01:43:50.268228+00:00 | 1,584,427,146,000 | d866cfddb708e99e54273ddd9cf4eb0e24958742 | 3 | {
"blob_id": "d866cfddb708e99e54273ddd9cf4eb0e24958742",
"branch_name": "refs/heads/master",
"committer_date": 1584427146000,
"content_id": "0b6ed38623448a9dfbb21f241894c4c17f17f4b7",
"detected_licenses": [
"MIT"
],
"directory_id": "b16440e1a6ad52d7bb7c88fb2a90df376be63f0b",
"extension": "py",
"fi... | 2.640625 | stackv2 | from scipy import stats
import os
import pandas as pd
"""
Preprocess PubMed abstracts or MIMIC-III reports
"""
import re
import json
from nltk import sent_tokenize, word_tokenize
SECTION_TITLES = re.compile(
r'('
r'ABDOMEN AND PELVIS|CLINICAL HISTORY|CLINICAL INDICATION|COMPARISON|COMPARISON STUDY DATE'
r... | 216 | 27.97 | 137 | 20 | 1,863 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_f9de7e04c810bfc3_f5feba1e", "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."
] | [
176
] | [
null
] | [
19
] | [
68
] | |
2024-11-19T01:44:00.316893+00:00 | 1,635,424,568,000 | f29b5100163cd2c7150bd79cabba71aa2f5142c1 | 4 | {
"blob_id": "f29b5100163cd2c7150bd79cabba71aa2f5142c1",
"branch_name": "refs/heads/main",
"committer_date": 1635424568000,
"content_id": "aa24b2ee7c69d24a11bfcaf022a560e285ab1bdf",
"detected_licenses": [
"MIT"
],
"directory_id": "609662164f20054e61fa4f200220a7e15e76533d",
"extension": "py",
"file... | 3.921875 | stackv2 | #!/usr/bin/env python
# -*- encoding: utf-8 -*-
'''
@文件 :day21_classes_objects.py
@说明 :
@时间 :2021/09/22 11:58:50
@作者 :liangcheng
@版本 :1.0
'''
num = 10
print(type(num))
string = 'string'
print(type(string))
boolean = True
print(type(boolean))
# create class
class Person:
pass
print(Person) # <cl... | 142 | 25.77 | 125 | 11 | 1,179 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_43e01de5af359b34_011a3f07", "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... | 2 | true | [
"CWE-312",
"CWE-312"
] | [
"py/clear-text-logging-sensitive-data",
"py/clear-text-logging-sensitive-data"
] | [
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM"
] | [
"This expression logs [sensitive data (private)](1) as clear text.\nThis expression logs [sensitive data (private)](2) as clear text.\nThis expression logs [sensitive data (private)](3) as clear text.",
"This expression logs [sensitive data (private)](1) as clear text.\nThis expression logs [sensitive data (priva... | [
132,
138
] | [
null,
null
] | [
7,
7
] | [
23,
23
] | |
2024-11-19T01:44:12.346359+00:00 | 1,421,336,147,000 | 8d227887bac271d53c1a3e1e2564a1f239eb8f90 | 3 | {
"blob_id": "8d227887bac271d53c1a3e1e2564a1f239eb8f90",
"branch_name": "refs/heads/master",
"committer_date": 1421336147000,
"content_id": "a210fb8eed5193e84fdacff35ccfbbbc1a8ef4d5",
"detected_licenses": [
"MIT"
],
"directory_id": "ad184944cbfff1a1362995ee3bbc527b48816fda",
"extension": "py",
"fi... | 2.703125 | stackv2 | #!/usr/bin/env python
from flask import Flask, render_template, Response
import servo
import motor
import time
# emulated camera
#from camera import Camera
# Raspberry Pi camera module (requires picamera package)
from camera_pi import Camera
app = Flask(__name__)
pan =servo.ServoController(25)
pan.setAngle(0)
tilt... | 89 | 20.31 | 77 | 14 | 552 | python | [{"finding_id": "codeql_py/reflective-xss_8b7c99a9c722db67_50938f15", "tool_name": "codeql", "rule_id": "py/reflective-xss", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "Cross-site scripting vulnerability due to a [user-provided value](1).", "remediation": "", "location": {"fi... | 1 | true | [
"CWE-079"
] | [
"py/reflective-xss"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"Cross-site scripting vulnerability due to a [user-provided value](1)."
] | [
86
] | [
null
] | [
9
] | [
18
] | |
2024-11-19T00:59:35.029905+00:00 | 1,426,565,471,000 | 2099e9eebe028b32663e2297c2f95269e3e0f14c | 3 | {
"blob_id": "2099e9eebe028b32663e2297c2f95269e3e0f14c",
"branch_name": "refs/heads/master",
"committer_date": 1426565471000,
"content_id": "5f3dc66ff09a3ea5f641215119630d7d57844e62",
"detected_licenses": [
"MIT"
],
"directory_id": "701abeb3f989f277691f0ad16fba58b9e3a5241c",
"extension": "py",
"fi... | 3.234375 | stackv2 | """
@fileoverview Python Blowfish encryption.
@author David Parlevliet
@version 20130305
@preserve Copyright 2013 David Parlevliet.
Encryption
==========
Blowfish encryption. Tested Decypherable between PHP<->Node.JS<->Python
"""
from Crypto.Cipher import Blowfish
from base64 import b64encode, b64decode
from random im... | 34 | 23.97 | 71 | 13 | 241 | python | [{"finding_id": "codeql_py/weak-cryptographic-algorithm_41850da8d291afc6_c35ed9b4", "tool_name": "codeql", "rule_id": "py/weak-cryptographic-algorithm", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "[The block mode ECB](1) is broken or weak, and should not be used.", "remediation": ... | 2 | true | [
"CWE-327",
"CWE-327"
] | [
"py/weak-cryptographic-algorithm",
"py/weak-cryptographic-algorithm"
] | [
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM"
] | [
"[The block mode ECB](1) is broken or weak, and should not be used.",
"[The block mode ECB](1) is broken or weak, and should not be used."
] | [
22,
28
] | [
null,
null
] | [
14,
14
] | [
34,
48
] | |
2024-11-19T01:00:06.873289+00:00 | 1,409,345,716,000 | 46b5fa1af2240420a4501e1c785fa0f34d7f29af | 2 | {
"blob_id": "46b5fa1af2240420a4501e1c785fa0f34d7f29af",
"branch_name": "refs/heads/master",
"committer_date": 1409345716000,
"content_id": "c2968558e5f93ff063f090d3bb9663e03c13c2c4",
"detected_licenses": [
"CC0-1.0"
],
"directory_id": "7573bbdcff55b7f956c0d5f6eec2530b48dd7d2e",
"extension": "py",
... | 2.40625 | stackv2 | # Refactored consumer for VTechWorks
import requests
from datetime import date, timedelta
import time
from lxml import etree
from scrapi_tools import lint
from scrapi_tools.document import RawDocument, NormalizedDocument
NAME = 'vtechworks'
TODAY = date.today()
NAMESPACES = {'dc': 'http://purl.org/dc/elements/1.1/',... | 147 | 32.15 | 102 | 25 | 1,184 | python | [{"finding_id": "codeql_py/incomplete-url-substring-sanitization_2e17940a4f90e934_36b1c8cf", "tool_name": "codeql", "rule_id": "py/incomplete-url-substring-sanitization", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "The string [hdl.handle.net](1) may be at an arbitrary position in ... | 2 | true | [
"CWE-020",
"CWE-020"
] | [
"py/incomplete-url-substring-sanitization",
"py/incomplete-url-substring-sanitization"
] | [
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM"
] | [
"The string [hdl.handle.net](1) may be at an arbitrary position in the sanitized URL.",
"The string [dx.doi.org](1) may be at an arbitrary position in the sanitized URL."
] | [
76,
78
] | [
null,
null
] | [
12,
12
] | [
36,
32
] | |
2024-11-19T01:00:09.472901+00:00 | 1,608,195,719,000 | a7907cb024a398b4323cda8dd98c170428877309 | 2 | {
"blob_id": "a7907cb024a398b4323cda8dd98c170428877309",
"branch_name": "refs/heads/master",
"committer_date": 1608195719000,
"content_id": "93f733a89088982ed2c1dee97c7b08a143d039e5",
"detected_licenses": [
"MIT"
],
"directory_id": "c14e98581bf306ba5d1a9cbae930ba611ff15026",
"extension": "py",
"fi... | 2.375 | stackv2 | from bs4 import BeautifulSoup
import re
import dbmanager as dbm
from reppy.robots import Robots
import requests
import threading
import random
import sys
import stopit
import time
from datetime import datetime
url_pattern = re.compile("http[s]?://(?:[a-zA-Z]|[0-9]|[$-_@.&+]|[!*(),]|(?:%[0-9a-fA-F][0-9a-fA-F]))+")
sub_... | 369 | 26.49 | 120 | 23 | 2,341 | python | [{"finding_id": "codeql_py/overly-large-range_eb9153a969c37bb7_d2bded60", "tool_name": "codeql", "rule_id": "py/overly-large-range", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Suspicious character range that is equivalent to \\[$%&'()*+,\\-.\\/0-9:;<=>?@A-Z\\\\[\\\\\\\\]^_\\].", ... | 2 | true | [
"CWE-020",
"CWE-020"
] | [
"py/overly-large-range",
"py/overly-large-range"
] | [
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM"
] | [
"Suspicious character range that is equivalent to \\[$%&'()*+,\\-.\\/0-9:;<=>?@A-Z\\\\[\\\\\\\\]^_\\].",
"Suspicious character range that overlaps with \\w in the same character class."
] | [
13,
14
] | [
null,
null
] | [
57,
36
] | [
60,
39
] | |
2024-11-19T01:00:10.990668+00:00 | 1,560,501,738,000 | 478988d20086dc9c09e86d18cfd12458909262b5 | 2 | {
"blob_id": "478988d20086dc9c09e86d18cfd12458909262b5",
"branch_name": "refs/heads/master",
"committer_date": 1560501738000,
"content_id": "a8365564c3bf4701e7eae5cd5c634b257e6036c7",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "d5e83460d5e9719f5fe1ba0f2ef75fb0cf86e7b6",
"extension": "py"... | 2.484375 | stackv2 | """"my project"""
from flask import jsonify,json,Flask,request,session,redirect,url_for
app = Flask(__name__)
app.config["SECRET_KEY"] = 'silasomurunga'
user_details = dict()
user_order ={1:{"order":"chips","username":"paul"},
2:{"order":"snacks","username":"silas"},
3:{"order":"coffee","username":"joshua"}}
@app.ro... | 152 | 35.42 | 87 | 17 | 1,264 | python | [{"finding_id": "codeql_py/flask-debug_fde43848577d8e6f_8558dafe", "tool_name": "codeql", "rule_id": "py/flask-debug", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", ... | 2 | true | [
"CWE-215",
"CWE-079"
] | [
"py/flask-debug",
"py/reflective-xss"
] | [
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM"
] | [
"A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.",
"Cross-site scripting vulnerability due to a [user-provided value](1)."
] | [
152,
87
] | [
null,
null
] | [
5,
12
] | [
24,
39
] | |
2024-11-19T01:11:40.007611+00:00 | 1,632,357,880,000 | fc2ff3ed4251acd8debd867abcbfb7b483daac6b | 2 | {
"blob_id": "fc2ff3ed4251acd8debd867abcbfb7b483daac6b",
"branch_name": "refs/heads/main",
"committer_date": 1632357880000,
"content_id": "8af9f4a74187431f11b14aedbeacd99777201d27",
"detected_licenses": [
"MIT"
],
"directory_id": "2c46ea469e015eadf04555ba8449ff74e356b2ef",
"extension": "py",
"file... | 2.421875 | stackv2 | import os
import sys
import json
import base64
import subprocess
secret_dir = '/run/secrets'
# import secrets
if len(sys.argv) > 1:
secrets = json.loads(base64.b64decode(sys.argv[1]))
if not os.path.isdir(secret_dir):
os.mkdir(secret_dir)
for secret in secrets.keys():
file = os.path.jo... | 45 | 22.64 | 74 | 14 | 270 | python | [{"finding_id": "codeql_py/clear-text-storage-sensitive-data_c2561db3b29d5629_3447cc03", "tool_name": "codeql", "rule_id": "py/clear-text-storage-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression stores [sensitive data (secret)](1) as clear text.", ... | 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 (secret)](1) as clear text.",
"This expression logs [sensitive data (secret)](1) as clear text."
] | [
21,
45
] | [
null,
null
] | [
21,
7
] | [
54,
74
] | |
2024-11-19T01:11:47.523147+00:00 | 1,489,206,864,000 | 5888af0faaba3d9d0fc55b457a0f1f7dc8b24ac4 | 2 | {
"blob_id": "5888af0faaba3d9d0fc55b457a0f1f7dc8b24ac4",
"branch_name": "refs/heads/master",
"committer_date": 1489206864000,
"content_id": "576c2ed5a84b98e7aaff128a5dc2df582e39f2ed",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "c62ceb2ee3d9f43590269c6a7fa304c61182ea1a",
"extension": "py"... | 2.453125 | stackv2 |
from flask import Flask
from redis import Redis
from flask import request, redirect
import tempfile
import os
from blob_api import blob_api
import base64
app = Flask(__name__)
redis = Redis(host='redis', port=6379)
base_url = "http://192.168.15.198:8080"
@app.route('/blob/v1/count')
def hello():
redis.incr('h... | 85 | 28.18 | 105 | 15 | 683 | python | [{"finding_id": "codeql_py/flask-debug_d99bbc2dba42cd93_620d7f88", "tool_name": "codeql", "rule_id": "py/flask-debug", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", ... | 8 | true | [
"CWE-215",
"CWE-601",
"CWE-732",
"CWE-117",
"CWE-117",
"CWE-117",
"CWE-117",
"CWE-117"
] | [
"py/flask-debug",
"py/url-redirection",
"py/overly-permissive-file",
"py/log-injection",
"py/log-injection",
"py/log-injection",
"py/log-injection",
"py/log-injection"
] | [
"HIGH",
"HIGH",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.",
"Untrusted URL redirection depends on a [user-provided value](1).",
"Overly permissive mask in chmod sets file to world writable.",
"This log entry depends on a [user-provided value](1).",
... | [
85,
47,
80,
41,
44,
60,
63,
66
] | [
null,
null,
null,
null,
null,
null,
null,
null
] | [
5,
29,
9,
22,
26,
22,
26,
26
] | [
40,
34,
35,
56,
41,
43,
41,
63
] | |
2024-11-19T01:21:26.203391+00:00 | 1,573,771,163,000 | 60838c0ad84c4a6f18a0d51d0f1bd9acf6ba6a8c | 3 | {
"blob_id": "60838c0ad84c4a6f18a0d51d0f1bd9acf6ba6a8c",
"branch_name": "refs/heads/master",
"committer_date": 1573771163000,
"content_id": "e2274585056d6a5e4abc6801ec9d1ae72fd4a98b",
"detected_licenses": [
"MIT"
],
"directory_id": "34192b1bd60addcf0e166158859af8984678692f",
"extension": "py",
"fi... | 3.1875 | stackv2 | """ download.py
Download utils.
"""
import math
import pathlib
import os
import requests
from tqdm import tqdm
def download(url, dst_dir, filename, proto='http', extract=None):
"""Downloads a file from a server.
Parameters
----------
url : str
File URL to download.
dst_dir : str
Destination d... | 118 | 25.42 | 88 | 17 | 791 | python | [{"finding_id": "codeql_py/tarslip_81c0e42c1d33a0af_d90bc345", "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)."
] | [
112
] | [
null
] | [
7
] | [
9
] | |
2024-11-19T01:21:37.215923+00:00 | 1,605,691,391,000 | 74c49b4a4d1a0b95389fdc9c66146738633ada3f | 3 | {
"blob_id": "74c49b4a4d1a0b95389fdc9c66146738633ada3f",
"branch_name": "refs/heads/master",
"committer_date": 1605691391000,
"content_id": "d712e5376ef5a22840e8d3d7e669e1682d64b336",
"detected_licenses": [
"MIT"
],
"directory_id": "190f6854422fbf9ca0b2cabfc34ec6a78fd3d00a",
"extension": "py",
"fi... | 3.296875 | stackv2 | #!/usr/bin/env python3.6
from user import User
from user import Credentials
def create_new_user(username,password):
'''
function to create new user
'''
new_user = User(username,password)
return new_user
def save_users(user):
'''
function to save users in user list
'''
user.save_use... | 171 | 29.42 | 175 | 19 | 1,075 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_0567952382dfef8b_97f8d22d", "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."
] | [
90
] | [
null
] | [
19
] | [
115
] | |
2024-11-19T01:21:40.714815+00:00 | 1,584,943,898,000 | 4f0650f4c811bb3b6209e969fbbe897f28695238 | 2 | {
"blob_id": "4f0650f4c811bb3b6209e969fbbe897f28695238",
"branch_name": "refs/heads/master",
"committer_date": 1584943898000,
"content_id": "0627f9c2741567ed3dd04e68bc70aafe91e2d344",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "8da62bbba2c34701952760df53d87e71e5da2466",
"extension": "py"... | 2.375 | stackv2 | # !/usr/bin/python3
# -*- coding: utf-8 -*-
# @Time : 2019/8/13 16:37
# @Author : Hubery
# @File : crawler_sina.py
# @Software: PyCharm
import re
import json
from datetime import datetime
from dateutil.parser import parse
import os
from helper import get_text, url_to_mid
BASE_DIR = os.path.dirname(os.path.absp... | 146 | 31.86 | 120 | 18 | 1,229 | python | [{"finding_id": "codeql_py/bad-tag-filter_0f70bbc258cbbd11_e9495d36", "tool_name": "codeql", "rule_id": "py/bad-tag-filter", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "This regular expression does not match upper case <SCRIPT> tags.", "remediation": "", "location": {"file_path": ... | 1 | true | [
"CWE-116"
] | [
"py/bad-tag-filter"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"This regular expression does not match upper case <SCRIPT> tags."
] | [
31
] | [
null
] | [
20
] | [
40
] | |
2024-11-19T01:33:49.832783+00:00 | 1,575,599,483,000 | b8a75fc4c6ff875a873744c43cd0006f76b066fc | 3 | {
"blob_id": "b8a75fc4c6ff875a873744c43cd0006f76b066fc",
"branch_name": "refs/heads/master",
"committer_date": 1575599483000,
"content_id": "975c28cda1c29d94a001b4981f4698376d638c1c",
"detected_licenses": [
"MIT"
],
"directory_id": "04b7df24deea6db4dbc66183e94f11e848fc071a",
"extension": "py",
"fi... | 2.734375 | stackv2 | from azure.keyvault.secrets import SecretClient
from azure.identity import DefaultAzureCredential
import os
from flask import Flask
app = Flask(__name__)
def run_example():
"""Azure Managed Identities Authentication example."""
# Get credentials
credentials = DefaultAzureCredential()
key_vault_uri... | 43 | 20.07 | 123 | 11 | 198 | python | [{"finding_id": "codeql_py/stack-trace-exposure_79d4898156731179_5820dc2c", "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."
] | [
34
] | [
null
] | [
16
] | [
24
] | |
2024-11-19T01:56:43.879858+00:00 | 1,597,873,382,000 | 855196dab09a0074a50a207d81f8abb0edd3b89f | 3 | {
"blob_id": "855196dab09a0074a50a207d81f8abb0edd3b89f",
"branch_name": "refs/heads/master",
"committer_date": 1597873382000,
"content_id": "bd22e9cb7d854367ec6f663cf463a791256cccd8",
"detected_licenses": [
"MIT"
],
"directory_id": "5bd9f57169ba7132cf2dd7733f9ba53517051764",
"extension": "py",
"fi... | 2.546875 | stackv2 | import asyncio
import json
import logging
import math
import random
import re
import requests
import serial
import string
import sys
import time
import websockets
deviceSettings = {
'port': 'COM4',
'interval': 1 / 60,
'range': {
'L0': [0.0, 1.0],
'L1': [0.0, 1.0],
'L2': [0.0, 1.0],
... | 324 | 32.12 | 141 | 21 | 2,694 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_91156ed4ed2aee49_091888e2", "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."
] | [
294
] | [
null
] | [
37
] | [
44
] | |
2024-11-19T01:56:47.596418+00:00 | 1,590,334,371,000 | 111f5967798790fa181d00878c74c939fe875297 | 2 | {
"blob_id": "111f5967798790fa181d00878c74c939fe875297",
"branch_name": "refs/heads/master",
"committer_date": 1590334371000,
"content_id": "c30bbc2219b8b398889de8f7499aeb457900dda5",
"detected_licenses": [
"MIT"
],
"directory_id": "4183f43d7f9ab6a32b154d5e7eaab7e855c56485",
"extension": "py",
"fi... | 2.3125 | stackv2 | # /usr/bin/python
# -*- coding: utf-8 -*-
from __future__ import absolute_import
from __future__ import print_function
import numpy as np
import argparse
import cv2
from cv2 import *
import threading
from threading import Thread
import os
import sys
import traceback
import time
import CameraLED
from six.moves import ra... | 455 | 32.82 | 111 | 29 | 3,354 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_287edfe4638bf1e2_08a09082", "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."
] | [
62
] | [
null
] | [
7
] | [
73
] | |
2024-11-19T02:10:45.957134+00:00 | 1,613,594,349,000 | bfcc95fc702c32459c43f858483798bf7d7e86f2 | 3 | {
"blob_id": "bfcc95fc702c32459c43f858483798bf7d7e86f2",
"branch_name": "refs/heads/master",
"committer_date": 1613594349000,
"content_id": "fafc0c29a5c90dfecde72ead680c9de3acd604fb",
"detected_licenses": [
"Unlicense"
],
"directory_id": "4449237cb1edf479d0410d2ca0906c1f39d1f1a3",
"extension": "py",... | 2.796875 | stackv2 | from flask import request, jsonify, Flask
from flask_sqlalchemy import SQLAlchemy
from flask_migrate import Migrate
db_string = "postgres://postgres:example@db:5432/postgres"
app = Flask(__name__)
app.config['SQLALCHEMY_DATABASE_URI'] = db_string
db = SQLAlchemy(app)
migrate = Migrate(app, db)
class ListModel(db.Mo... | 67 | 28.39 | 78 | 13 | 464 | python | [{"finding_id": "codeql_py/reflective-xss_351957945ab69978_115d32ef", "tool_name": "codeql", "rule_id": "py/reflective-xss", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "Cross-site scripting vulnerability due to a [user-provided value](1).", "remediation": "", "location": {"fi... | 1 | true | [
"CWE-079"
] | [
"py/reflective-xss"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"Cross-site scripting vulnerability due to a [user-provided value](1)."
] | [
51
] | [
null
] | [
16
] | [
79
] | |
2024-11-19T02:45:50.511047+00:00 | 1,596,864,832,000 | 91ad5dd7a2505cef9e6697c4886e1bc85391b926 | 2 | {
"blob_id": "91ad5dd7a2505cef9e6697c4886e1bc85391b926",
"branch_name": "refs/heads/master",
"committer_date": 1596864832000,
"content_id": "7105d3e8bfb1cfd5515b03767d215d70dcd6d0b1",
"detected_licenses": [
"MIT"
],
"directory_id": "039c09f5a3c567e9a4dd64babccb6bfd34ff3d74",
"extension": "py",
"fi... | 2.5 | stackv2 | from cy.Box import Box, AESBox
import argparse
import PyInstaller.__main__
import os
import pickle
from chardet import detect
__pdoc__ = {}
def get_encoding_type(file):
with open(file, 'rb') as f:
rawdata = f.read()
return detect(rawdata)['encoding']
def encrypt(args):
if args.input is None:
... | 92 | 36.71 | 134 | 17 | 809 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_1704e91fec40c1f9_3813a6ed", "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... | 2 | true | [
"CWE-312",
"CWE-312"
] | [
"py/clear-text-logging-sensitive-data",
"py/clear-text-logging-sensitive-data"
] | [
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM"
] | [
"This expression logs [sensitive data (password)](1) as clear text.\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... | [
82,
90
] | [
null,
null
] | [
15,
15
] | [
55,
55
] | |
2024-11-19T02:45:52.095042+00:00 | 1,449,377,171,000 | 1c7ffc7d5b86cabad58c5005ffdedb7756d74ad8 | 2 | {
"blob_id": "1c7ffc7d5b86cabad58c5005ffdedb7756d74ad8",
"branch_name": "refs/heads/master",
"committer_date": 1449377171000,
"content_id": "9e6a03e05eb505ffccb762d1f49c699624e51dc7",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "8e5d4ff13462948a5d7a6ad14760a525d4ec7971",
"extension": "py"... | 2.4375 | stackv2 | '''
Created on Oct 29, 2015
@author: Kagiu
'''
import sys
from PySide import QtGui, QtCore
from signin import TimeLogger
def boxToWidget(layout):
widget = QtGui.QWidget()
widget.setLayout(layout)
return widget
class SignGUI(QtGui.QMainWindow):
def __init__(self):
super(SignGUI, self).__init_... | 129 | 34.48 | 122 | 19 | 951 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_4ff98c6fc5426e0d_55e16e66", "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."
] | [
82
] | [
null
] | [
19
] | [
25
] | |
2024-11-19T02:57:14.324514+00:00 | 1,642,698,959,000 | f330971c853249410513c9cc023a93d504da9404 | 2 | {
"blob_id": "f330971c853249410513c9cc023a93d504da9404",
"branch_name": "refs/heads/master",
"committer_date": 1642698959000,
"content_id": "51cf539b3205c99c62cb067b332bf03d65e2850e",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "f00747d1406b3211983f1255855fce0b5346c13d",
"extension": "py"... | 2.40625 | stackv2 |
#!/usr/bin/python3.4
# encoding: utf-8
from flask import Flask, make_response, request
from functools import wraps
import os
# Import Needed modules
from flask import send_from_directory
import logging
from modules.mp_module import MpModule
from common.utils import getHostIp
webapp = Flask(__name__)
pendingRes... | 123 | 27.09 | 163 | 15 | 813 | python | [{"finding_id": "codeql_py/path-injection_07947602e74c86b4_afa7d94c", "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", ... | 5 | true | [
"CWE-022",
"CWE-117",
"CWE-117",
"CWE-117",
"CWE-117"
] | [
"py/path-injection",
"py/log-injection",
"py/log-injection",
"py/log-injection",
"py/log-injection"
] | [
"HIGH",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"This path depends on a [user-provided value](1).",
"This log entry depends on a [user-provided value](1).",
"This log entry depends on a [user-provided value](1).",
"This log entry depends on a [user-provided value](1).",
"This log entry depends on a [user-provided value](1)."
] | [
86,
59,
70,
85,
95
] | [
null,
null,
null,
null,
null
] | [
19,
18,
18,
22,
18
] | [
73,
67,
41,
51,
78
] | |
2024-11-19T03:12:12.260154+00:00 | 1,648,537,793,000 | f532fed25d1122b313cfaf35929a8f438464e457 | 3 | {
"blob_id": "f532fed25d1122b313cfaf35929a8f438464e457",
"branch_name": "refs/heads/master",
"committer_date": 1648537793000,
"content_id": "fdab29277ed2c66a05daedd78901930359442ce0",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "5512e3ded45018c24d507514817300cdd7bb192d",
"extension": "py"... | 2.53125 | stackv2 | #!/usr/bin/python
# -*- coding: UTF-8 -*-
import numpy as np
import pandas as pd
import re
from collections import defaultdict
def file_reader(file_path):
utterance = list()
label = list()
goal_type = list()
goal_entity = list()
bot_flag = list()
with open(file_path, "r") as f:
utt = l... | 318 | 39.95 | 154 | 21 | 3,255 | python | [{"finding_id": "codeql_py/overly-large-range_f6bcccea5de8c528_10d8c162", "tool_name": "codeql", "rule_id": "py/overly-large-range", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Suspicious character range that overlaps with +-= in the same character class, and is equivalent to \\[+... | 6 | true | [
"CWE-020",
"CWE-020",
"CWE-020",
"CWE-020",
"CWE-020",
"CWE-020"
] | [
"py/overly-large-range",
"py/overly-large-range",
"py/overly-large-range",
"py/overly-large-range",
"py/overly-large-range",
"py/overly-large-range"
] | [
"HIGH",
"HIGH",
"HIGH",
"HIGH",
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"Suspicious character range that overlaps with +-= in the same character class, and is equivalent to \\[+,\\-.\\/0-9:;<=\\].",
"Suspicious character range that is equivalent to \\[+,\\-.\\/0-9:;<=\\].",
"Suspicious character range that overlaps with +-= in the same character class, and is equivalent to \\[+,\\-... | [
167,
167,
186,
186,
215,
215
] | [
null,
null,
null,
null,
null,
null
] | [
39,
69,
42,
72,
47,
77
] | [
42,
72,
45,
75,
50,
80
] | |
2024-11-19T03:12:26.388123+00:00 | 1,517,866,927,000 | 4e867e45b82cdfa892ae850adc0ff63b771cdad0 | 2 | {
"blob_id": "4e867e45b82cdfa892ae850adc0ff63b771cdad0",
"branch_name": "refs/heads/master",
"committer_date": 1517867104000,
"content_id": "6705825b0303b41e37af0251b5f2ba204e4df37d",
"detected_licenses": [
"MIT"
],
"directory_id": "07ea92536d5e1beb0cf916278ed9f6db06d383ad",
"extension": "py",
"fi... | 2.359375 | stackv2 | #!/usr/bin/env python
#-*-coding:utf-8-*-
try:
import android
__android__ = True
except ImportError:
__android__ = False
if __name__ == '__main__':
import os
import os.path
os.chdir(os.path.dirname(os.path.abspath(__file__)))
from request import webkv_query
import time
if __android... | 48 | 26.52 | 77 | 18 | 344 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_03ae62595ccac970_7f9961ca", "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... | 2 | true | [
"CWE-312",
"CWE-312"
] | [
"py/clear-text-logging-sensitive-data",
"py/clear-text-logging-sensitive-data"
] | [
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM"
] | [
"This expression logs [sensitive data (private)](1) as clear text.\nThis expression logs [sensitive data (private)](2) as clear text.",
"This expression logs [sensitive data (private)](1) as clear text.\nThis expression logs [sensitive data (private)](2) as clear text."
] | [
43,
43
] | [
null,
null
] | [
19,
23
] | [
22,
26
] | |
2024-11-19T01:33:49.530888+00:00 | 1,595,012,881,000 | 0679d471f2a26c400ea9ff57fd99e5d5222fdeb7 | 3 | {
"blob_id": "0679d471f2a26c400ea9ff57fd99e5d5222fdeb7",
"branch_name": "refs/heads/master",
"committer_date": 1595012881000,
"content_id": "b1d1fdbc20b2c2470ade518cc9cc4760fecce839",
"detected_licenses": [
"MIT"
],
"directory_id": "d99195e909338c8b5248acc8488ff82d7a0d5321",
"extension": "py",
"fi... | 2.609375 | stackv2 | """Get system information using the redfish API"""
import os
from multiprocessing import Pool
import requests
REDFISH_URI = "https://{}/redfish/v1/Systems/System.Embedded.1"
idrac_username = os.environ.get("IDRAC_USERNAME", "root")
idrac_password = os.environ.get("IDRAC_PASSWORD", "calvin")
class RedfishError(Excep... | 167 | 32.16 | 109 | 22 | 1,347 | python | [{"finding_id": "codeql_py/request-without-cert-validation_5131ac6b628f5b25_f29b6f37", "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)."
] | [
19
] | [
null
] | [
16
] | [
86
] | |
2024-11-19T01:57:28.077114+00:00 | 1,619,538,544,000 | 73c0602a73b9ef7c150bea7cdc7bed6960f56e77 | 2 | {
"blob_id": "73c0602a73b9ef7c150bea7cdc7bed6960f56e77",
"branch_name": "refs/heads/main",
"committer_date": 1619538544000,
"content_id": "55610107f32c9ae51af76d5636ca62cecedd60b0",
"detected_licenses": [
"MIT"
],
"directory_id": "0e302ea09b488b76662c37fbd7b7ab6bc237242b",
"extension": "py",
"file... | 2.5 | stackv2 | #!/usr/bin/env python
# -*- coding: utf-8 -*
import logging
from http.server import BaseHTTPRequestHandler, HTTPServer
from json import loads
from os import getenv
from sys import argv
from requests import session
from matrix_client.client import MatrixClient
from matrix_client.errors import MatrixHttpLibError
from s... | 130 | 28.52 | 90 | 15 | 905 | python | [{"finding_id": "codeql_py/log-injection_88845f69bdae3729_8b50d317", "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)."
] | [
95
] | [
98
] | [
13
] | [
30
] | |
2024-11-19T02:11:24.969665+00:00 | 1,554,634,850,000 | f629f322fa31279537d393e5e88063e650a4db3c | 2 | {
"blob_id": "f629f322fa31279537d393e5e88063e650a4db3c",
"branch_name": "refs/heads/master",
"committer_date": 1554634850000,
"content_id": "5869d211bab9a20a642f3956f1b05f71e924c567",
"detected_licenses": [
"MIT"
],
"directory_id": "31660a3a33d0deaebc66ecba54b705d801e8f73b",
"extension": "py",
"fi... | 2.3125 | stackv2 | import datetime
import logging
from flask import request
from app import db
from app.api_v1 import bp
from app.models import User, Sensor, FlowerMetric
from app.api_v1.errors import bad_request, unauthorized, server_error
from app.utils import create_response_from_data_with_code, authorize, parse_authorization_header... | 86 | 29.33 | 96 | 15 | 604 | python | [{"finding_id": "codeql_py/log-injection_d394d5aa5d6cf754_7ae82f18", "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)."
] | [
50
] | [
null
] | [
18
] | [
44
] | |
2024-11-19T02:11:29.028235+00:00 | 1,546,564,553,000 | 2e9fd916db87f9b42f36cf7d72ad35685436c0dc | 3 | {
"blob_id": "2e9fd916db87f9b42f36cf7d72ad35685436c0dc",
"branch_name": "refs/heads/master",
"committer_date": 1546564553000,
"content_id": "04bdbec2772d4c52922108d6eff328438982bbd1",
"detected_licenses": [
"MIT"
],
"directory_id": "c43501c1d3006187f00756b57e4a29a483791046",
"extension": "py",
"fi... | 3.03125 | stackv2 | import os
from struct import unpack
def generate(length=50):
sample = '1234567890-=!@#$%^&*()_+qwertyuiopasdfghjklzxcvbnm'
return ''.join([sample[unpack('>I', os.urandom(4))[0] % len(sample)] for i in range(length)])
def from_file(path):
""" Load secret key value from file
If file does not exist, ma... | 53 | 43.87 | 97 | 16 | 560 | python | [{"finding_id": "codeql_py/clear-text-storage-sensitive-data_28612591622fa26e_d1dc2455", "tool_name": "codeql", "rule_id": "py/clear-text-storage-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression stores [sensitive data (secret)](1) as clear text.", ... | 3 | true | [
"CWE-312",
"CWE-312",
"CWE-312"
] | [
"py/clear-text-storage-sensitive-data",
"py/clear-text-logging-sensitive-data",
"py/clear-text-logging-sensitive-data"
] | [
"HIGH",
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"This expression stores [sensitive data (secret)](1) as clear text.",
"This expression logs [sensitive data (secret)](1) as clear text.",
"This expression logs [sensitive data (secret)](1) as clear text."
] | [
31,
40,
46
] | [
null,
null,
null
] | [
21,
15,
15
] | [
31,
84,
60
] | |
2024-11-19T02:32:58.843758+00:00 | 1,643,244,122,000 | a111f5cc3778370ea55d1ed843222d32199e0498 | 3 | {
"blob_id": "a111f5cc3778370ea55d1ed843222d32199e0498",
"branch_name": "refs/heads/main",
"committer_date": 1643244122000,
"content_id": "290426a4162da4a58fd1685ef1884c374b26c7f5",
"detected_licenses": [
"MIT"
],
"directory_id": "5c9dd8aa0bd7a7feec1a3e8800d4c21b05efb90f",
"extension": "py",
"file... | 3.390625 | stackv2 | """A command-line tool for generating passwords using the Diceware method.
MIT License
Copyright (c) 2018 John Eastman
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, includ... | 95 | 35.41 | 118 | 15 | 771 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_8488da6514d03271_de54d86c", "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."
] | [
95
] | [
null
] | [
15
] | [
25
] | |
2024-11-19T02:33:30.722512+00:00 | 1,606,119,103,000 | b66915d727dcd585d8a257404a6f6e228d0699c0 | 3 | {
"blob_id": "b66915d727dcd585d8a257404a6f6e228d0699c0",
"branch_name": "refs/heads/main",
"committer_date": 1606119103000,
"content_id": "c8186e789bf6e296dce1891d80318db0eacd8403",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "8bfcb36df590df7070a2669511826fb9d59d2f79",
"extension": "py",
... | 2.6875 | stackv2 | import json
import jinja2
TEMPLATE = "cluster.yml.j2"
CONFIG = "config.json"
if __name__ == "__main__":
# Load configuration
with open(CONFIG) as cfg:
config = json.loads(cfg.read())
user = config["vm"]["user"]
# Create nodes to be used by template
names = []
for i in range(config["v... | 74 | 28.66 | 83 | 16 | 544 | python | [{"finding_id": "codeql_py/jinja2/autoescape-false_9043cbb473286947_6fccb809", "tool_name": "codeql", "rule_id": "py/jinja2/autoescape-false", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Using jinja2 templates with autoescape=False can potentially allow XSS attacks.", "remediati... | 1 | true | [
"CWE-079"
] | [
"py/jinja2/autoescape-false"
] | [
"MEDIUM"
] | [
"MEDIUM"
] | [
"Using jinja2 templates with autoescape=False can potentially allow XSS attacks."
] | [
69
] | [
null
] | [
11
] | [
84
] | |
2024-11-19T02:33:32.956217+00:00 | 1,590,071,284,000 | b839979eebfc232045f05176907249c3876e5a6d | 3 | {
"blob_id": "b839979eebfc232045f05176907249c3876e5a6d",
"branch_name": "refs/heads/master",
"committer_date": 1590071284000,
"content_id": "8609314225c9b3e64bffc96c1d62236b0b0dfa7a",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "470836ada9dd1909899d06fbc4a02498227dbf83",
"extension": "py"... | 2.640625 | stackv2 | # -*- coding: utf-8 -*-
"""
Created on Fri May 8 14:43:45 2020
@author: sefa
"""
from PIL import Image
import os
from flask import Flask, request, send_file
from werkzeug.utils import secure_filename
import cv2
import numpy as np
UPLOAD_FOLDER = './images/'
ALLOWED_EXTENSIONS = set(['jpeg'])
face_cascade = cv2.C... | 60 | 26.23 | 75 | 16 | 408 | python | [{"finding_id": "codeql_py/flask-debug_cb470834cbf68487_1078db82", "tool_name": "codeql", "rule_id": "py/flask-debug", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", ... | 2 | true | [
"CWE-215",
"CWE-022"
] | [
"py/flask-debug",
"py/path-injection"
] | [
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM"
] | [
"A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.",
"This path depends on a [user-provided value](1)."
] | [
58,
43
] | [
null,
null
] | [
5,
30
] | [
34,
34
] | |
2024-11-19T02:33:37.309591+00:00 | 1,690,799,061,000 | e6c26b1e952023c460c0ad5fea8ea71461bbd555 | 2 | {
"blob_id": "e6c26b1e952023c460c0ad5fea8ea71461bbd555",
"branch_name": "refs/heads/main",
"committer_date": 1690799061000,
"content_id": "f75771a69502ea49aa6947dae911bbdde82a24a9",
"detected_licenses": [
"BSD-2-Clause"
],
"directory_id": "9af86b835f74d2fdf6ee3dc5e7927fc74cfef76b",
"extension": "py"... | 2.34375 | stackv2 | #!/usr/bin/env python
# file: setup.py
# vim:fileencoding=utf-8:fdm=marker:ft=python
#
# Copyright © 2020 R.F. Smith <rsmith@xs4all.nl>
# SPDX-License-Identifier: MIT
# Created: 2020-10-25T12:18:04+0100
# Last modified: 2022-01-23T18:07:08+0100
"""Install self-contained scripts for the local user."""
import os
import ... | 154 | 28.56 | 81 | 17 | 1,256 | python | [{"finding_id": "codeql_py/overly-permissive-file_e73b648dbcb1e8c7_d4400b59", "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."
] | [
134
] | [
null
] | [
5
] | [
26
] | |
2024-11-19T02:59:18.866170+00:00 | 1,626,711,340,000 | ef5dafce853834057edde7e5ee8bed2275b8dbcc | 3 | {
"blob_id": "ef5dafce853834057edde7e5ee8bed2275b8dbcc",
"branch_name": "refs/heads/main",
"committer_date": 1626711340000,
"content_id": "cd926578ca3c1578b9b2148b2adbe2767bc76be4",
"detected_licenses": [
"MIT"
],
"directory_id": "ff29df788ddf9573636d718fcf24cb378d7e3357",
"extension": "py",
"file... | 2.703125 | stackv2 | import art, time, os, platform
from colorama import init, Fore
from termcolor import colored
import pandas as pd
import datetime
from selenium import webdriver
from selenium.webdriver.support import expected_conditions as EC
from selenium.webdriver.common.by import By
from selenium.webdriver.support.ui import WebDriver... | 114 | 36.71 | 138 | 22 | 1,113 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_fcfc5127f1239540_146c46af", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (private)](1) as clear text.", "... | 3 | true | [
"CWE-312",
"CWE-312",
"CWE-312"
] | [
"py/clear-text-logging-sensitive-data",
"py/clear-text-logging-sensitive-data",
"py/clear-text-logging-sensitive-data"
] | [
"HIGH",
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"This expression logs [sensitive data (private)](1) as clear text.",
"This expression logs [sensitive data (private)](1) as clear text.",
"This expression logs [sensitive data (private)](1) as clear text."
] | [
33,
35,
37
] | [
null,
null,
null
] | [
15,
15,
15
] | [
134,
138,
133
] | |
2024-11-19T02:59:21.571388+00:00 | 1,597,555,140,000 | f9b156334efe802cafa2cfc83b7e3b76c06e1f1e | 3 | {
"blob_id": "f9b156334efe802cafa2cfc83b7e3b76c06e1f1e",
"branch_name": "refs/heads/master",
"committer_date": 1597555140000,
"content_id": "1941ae90cc80fc1fe69f1f7a4dbbf324161476c1",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "815f0d5ac233c79065dbfea6c1cc9eeaf3d12b5d",
"extension": "py"... | 2.515625 | stackv2 | # encoding: utf-8
import tkinter.messagebox
import webbrowser
from tkinter import *
import jieba
import pandas as pd
import pymongo
from pyecharts import options as opts
from pyecharts.charts import Bar, Page, Pie, WordCloud, Line, Map
class App:
def __init__(self, master):
self.master = master
... | 347 | 36.51 | 119 | 23 | 3,411 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_bbefc0236cccb279_c4fb4f2b", "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."
] | [
201
] | [
null
] | [
19
] | [
27
] | |
2024-11-19T02:59:26.334068+00:00 | 1,614,673,145,000 | 7225620cb06e8b7a1f2f99b6ad6b9f0140b2b710 | 2 | {
"blob_id": "7225620cb06e8b7a1f2f99b6ad6b9f0140b2b710",
"branch_name": "refs/heads/main",
"committer_date": 1614673145000,
"content_id": "998563dd191c20c5b68501d54ed9339139388f75",
"detected_licenses": [
"BSD-3-Clause"
],
"directory_id": "2f81460ad3dee32ac1d035d69af472f09a6ff52a",
"extension": "py"... | 2.359375 | stackv2 | from gluon import *
import re, hashlib, base64
import rsa
import json
import random
import pickle
from uuid import uuid4
try:
import ast
have_ast=True
except:
have_ast=False
regex_field = re.compile('{{(\w+)(\:\w+)?\!?}}')
regex_email = re.compile('[^\s<>"\',;]+\@[^\s<>"\',;]+',re.IGNORECASE)
def uuid():... | 101 | 35.65 | 101 | 19 | 890 | python | [{"finding_id": "codeql_py/weak-crypto-key_513f6619f91751d7_a8fce68b", "tool_name": "codeql", "rule_id": "py/weak-crypto-key", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Creation of an RSA key uses [1024](1) bits, which is below 2048 and considered breakable.", "remediation": "",... | 1 | true | [
"CWE-326"
] | [
"py/weak-crypto-key"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"Creation of an RSA key uses [1024](1) bits, which is below 2048 and considered breakable."
] | [
22
] | [
null
] | [
24
] | [
41
] | |
2024-11-19T02:59:48.894489+00:00 | 1,593,618,541,000 | d678dbe281088c19f872b7e51308812825683ea3 | 3 | {
"blob_id": "d678dbe281088c19f872b7e51308812825683ea3",
"branch_name": "refs/heads/master",
"committer_date": 1593618541000,
"content_id": "68052220640fb999aa20e7cb49ec0eab9d6166f1",
"detected_licenses": [
"MIT"
],
"directory_id": "ffcfe0dbee140e4ed15e49c8e7feaac020055f36",
"extension": "py",
"fi... | 2.609375 | stackv2 | import requests
import re
import execjs
def process_cookies():
'''
生成请求使用的cookie
测试时间 : 2019-08-01
:return:
'''
url_ = 'http://www.66ip.cn/areaindex_35/index.html'
base_url = 'http://www.66ip.cn/'
headers = {
"User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/... | 45 | 28.76 | 154 | 10 | 431 | python | [{"finding_id": "codeql_py/bad-tag-filter_4a1e362c16e53ec3_62e7486f", "tool_name": "codeql", "rule_id": "py/bad-tag-filter", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "This regular expression does not match upper case <SCRIPT> tags.", "remediation": "", "location": {"file_path": ... | 1 | true | [
"CWE-116"
] | [
"py/bad-tag-filter"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"This regular expression does not match upper case <SCRIPT> tags."
] | [
20
] | [
null
] | [
23
] | [
44
] | |
2024-11-19T03:12:04.963976+00:00 | 1,611,578,268,000 | 3262588807689e8c3d0fecbe4a44ac7b948f27b3 | 3 | {
"blob_id": "3262588807689e8c3d0fecbe4a44ac7b948f27b3",
"branch_name": "refs/heads/main",
"committer_date": 1611578268000,
"content_id": "ac3894533af7e66885eb099380714202590fc29f",
"detected_licenses": [
"MIT"
],
"directory_id": "d122c916523afd4f37f2d06f407069d1ed9b9c19",
"extension": "py",
"file... | 2.546875 | stackv2 | import numpy as np
import os
import pickle
from pathlib import Path
import requests
import tarfile
def download(url, filename):
with open(filename, 'wb') as f:
response = requests.get(url, stream=True)
total = response.headers.get('content-length')
if total is None:
f.write(r... | 113 | 33.11 | 97 | 21 | 944 | python | [{"finding_id": "codeql_py/tarslip_b2f7ac48c68c1924_29d7da75", "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)."
] | [
38
] | [
null
] | [
5
] | [
9
] | |
2024-11-19T03:12:07.385919+00:00 | 1,608,188,983,000 | a34bf9e6aff001ae414eb81b6c7c3ca5b3d9bcb7 | 3 | {
"blob_id": "a34bf9e6aff001ae414eb81b6c7c3ca5b3d9bcb7",
"branch_name": "refs/heads/master",
"committer_date": 1608188983000,
"content_id": "b2907fcb42d3d57521331e4bcf545f03238f11a5",
"detected_licenses": [
"MIT"
],
"directory_id": "619f1eaf6da65eb6ecd321be2f623f3d971d98e8",
"extension": "py",
"fi... | 2.609375 | stackv2 | #!/usr/bin/env python3
# -*- coding: UTF-8 -*-
import sys
import getopt
import configparser
from gateAPI import GateIO
import datetime
import pandas as pd
import json
import matplotlib.pyplot as plt
from pandas.plotting import register_matplotlib_converters
register_matplotlib_converters()
API_QUERY_URL = 'data.gate... | 130 | 26.07 | 79 | 13 | 984 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_9b81d3930ca3ee2e_592413e5", "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."
] | [
27
] | [
null
] | [
11
] | [
52
] | |
2024-11-19T03:24:43.983231+00:00 | 1,616,185,066,000 | 6ff7cda158e085e5e1002cb616ab4d1bf3bca89e | 3 | {
"blob_id": "6ff7cda158e085e5e1002cb616ab4d1bf3bca89e",
"branch_name": "refs/heads/main",
"committer_date": 1616185066000,
"content_id": "f428e051586d59060dd4c9d66fed3272e18f82c5",
"detected_licenses": [
"MIT"
],
"directory_id": "fd7a01a2d83f1d9b0c899860ba3ac261f7101a0a",
"extension": "py",
"file... | 2.609375 | stackv2 |
from collections import Counter
from itertools import chain
from django.shortcuts import get_object_or_404
from django.conf import settings
from rest_framework.decorators import api_view, permission_classes
from rest_framework.permissions import IsAuthenticated
from rest_framework.response import Response
from rest_f... | 123 | 33.46 | 114 | 17 | 939 | python | [{"finding_id": "codeql_py/stack-trace-exposure_2551eaadc672b049_dde03a05", "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."
] | [
47
] | [
null
] | [
25
] | [
41
] | |
2024-11-19T01:26:48.399543+00:00 | 1,607,039,559,000 | ac58a8c192a7f09075112e6364025b438807b77d | 3 | {
"blob_id": "ac58a8c192a7f09075112e6364025b438807b77d",
"branch_name": "refs/heads/master",
"committer_date": 1607039559000,
"content_id": "75f788c2fe15a123ec6bf61c11432f465498775b",
"detected_licenses": [
"MIT"
],
"directory_id": "66ddfc5652ea24af3b395bf54158e45ef5058bd6",
"extension": "py",
"fi... | 2.515625 | stackv2 | # core
import hashlib
import hmac
import itertools
import pprint
import time
# 3rd party
from libsaas import http, parsers
from libsaas.services import base
# local
import user
def parse_text(body, code, headers):
print "TEXT: {0}".format(body)
def nonce():
return int(time.time())
def signature():
n =... | 77 | 20.42 | 70 | 14 | 412 | python | [{"finding_id": "codeql_py/weak-sensitive-data-hashing_2f9c57b551d60a98_cf6019ee", "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."
] | [
26
] | [
null
] | [
30
] | [
37
] | |
2024-11-19T01:27:02.169367+00:00 | 1,623,767,191,000 | 6730a896c23870f5d6471dae2a23ee43adb661d0 | 3 | {
"blob_id": "6730a896c23870f5d6471dae2a23ee43adb661d0",
"branch_name": "refs/heads/main",
"committer_date": 1623767191000,
"content_id": "0f0d163a7c374a4fd81e2217f5c2bc36307e3715",
"detected_licenses": [
"MIT"
],
"directory_id": "142e8cafb8c668314c12e2a0de30d2569a7c0160",
"extension": "py",
"file... | 2.5625 | stackv2 | from fastapi import APIRouter, Depends, HTTPException, Response
from schemas import py_models as pm
from typing import List
import app_services.services as serv
import sqlalchemy.orm as orm
from models import sql_models as sql
app = APIRouter()
@app.get('/members', response_model = List[pm.Members])
async def get_me... | 101 | 35.84 | 106 | 14 | 863 | python | [{"finding_id": "codeql_py/stack-trace-exposure_0db03dad2d126a61_3067b2f9", "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."
] | [
21
] | [
null
] | [
33
] | [
39
] | |
2024-11-19T01:38:00.961809+00:00 | 1,617,133,517,000 | a44a788804547bb63120fcb385b68e0a0bae752b | 4 | {
"blob_id": "a44a788804547bb63120fcb385b68e0a0bae752b",
"branch_name": "refs/heads/main",
"committer_date": 1617133517000,
"content_id": "8dd53dd8370820b9732720c793e88c18d6c0ece2",
"detected_licenses": [
"MIT"
],
"directory_id": "d1a5468271179ddf701a37a56e5ec39a87241416",
"extension": "py",
"file... | 3.90625 | stackv2 | import random
def jogar():
mensagem_inicial()
palavra_secreta = carregar_palavra_secreta()
letra_acerto = ["_" for letra in palavra_secreta]
print(letra_acerto)
print("")
enforcou = False
acertou = False
erros = 0
while(not enforcou and not acertou): #enquanto nao enforcou ou ... | 169 | 28.69 | 90 | 13 | 1,359 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_8e66ce5b497dba88_61c779d1", "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."
] | [
137
] | [
null
] | [
11
] | [
55
] | |
2024-11-19T01:38:05.232510+00:00 | 1,486,447,109,000 | 995ae4e93b4303113a92511a9f6e4edf3141dce7 | 2 | {
"blob_id": "995ae4e93b4303113a92511a9f6e4edf3141dce7",
"branch_name": "refs/heads/master",
"committer_date": 1486447109000,
"content_id": "350b224b54e3682544697cfc99d32c04f4a9d7f9",
"detected_licenses": [
"MIT"
],
"directory_id": "b64926b053b9d58e4ad8caca65338429d2d90bdb",
"extension": "py",
"fi... | 2.359375 | stackv2 | from pubnub.pnconfiguration import PNConfiguration
from pubnub.pubnub import PubNub
from pubnub.callbacks import SubscribeCallback
from Cryptodome.Cipher import AES
import base64
from threading import Timer
class Subscription(object):
def __init__(self, rest_client, events, message_callback, status_callback = None... | 65 | 39.35 | 117 | 21 | 565 | python | [{"finding_id": "codeql_py/weak-cryptographic-algorithm_fa1cc92071f15bde_61e9bbdd", "tool_name": "codeql", "rule_id": "py/weak-cryptographic-algorithm", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "[The block mode ECB](1) is broken or weak, and should not be used.", "remediation": ... | 1 | true | [
"CWE-327"
] | [
"py/weak-cryptographic-algorithm"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"[The block mode ECB](1) is broken or weak, and should not be used."
] | [
21
] | [
null
] | [
24
] | [
70
] | |
2024-11-19T01:38:26.974422+00:00 | 1,649,828,816,000 | 88f4f49873d709a378d5a44ba301d1cfecfd7de6 | 2 | {
"blob_id": "88f4f49873d709a378d5a44ba301d1cfecfd7de6",
"branch_name": "refs/heads/master",
"committer_date": 1649828816000,
"content_id": "5ead8a97a99176fcacc22566cd5ac3c53c781544",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "7ededf9636370f226f3153882ec0261b76bcf267",
"extension": "py"... | 2.40625 | stackv2 | #-*- coding:utf-8; mode:python; indent-tabs-mode: nil; c-basic-offset: 2; tab-width: 2 -*-
import os, shutil
from os import path
from collections import namedtuple
from bes.system.check import check
from bes.archive.archiver import archiver
from bes.archive.archive_extension import archive_extension
from bes.fs.file_... | 193 | 48.67 | 146 | 19 | 2,223 | python | [{"finding_id": "codeql_py/overly-permissive-file_e34f6fce32d1bc8d_a010b104", "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": ... | 4 | true | [
"CWE-732",
"CWE-732",
"CWE-732",
"CWE-732"
] | [
"py/overly-permissive-file",
"py/overly-permissive-file",
"py/overly-permissive-file",
"py/overly-permissive-file"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"Overly permissive mask in chmod sets file to world readable.",
"Overly permissive mask in chmod sets file to world readable.",
"Overly permissive mask in chmod sets file to world readable.",
"Overly permissive mask in chmod sets file to world readable."
] | [
30,
47,
63,
79
] | [
null,
null,
null,
null
] | [
5,
5,
5,
5
] | [
25,
25,
30,
45
] | |
2024-11-19T01:38:27.397721+00:00 | 1,527,258,400,000 | a3bbac086372776b672dd800e27c5e51a454f6bd | 3 | {
"blob_id": "a3bbac086372776b672dd800e27c5e51a454f6bd",
"branch_name": "refs/heads/master",
"committer_date": 1527258400000,
"content_id": "43db112725f91f047785702bec5b64b6f70a7e4a",
"detected_licenses": [
"MIT"
],
"directory_id": "afa3d9852e316b65efaa7625e41d32cf2dfa4d87",
"extension": "py",
"fi... | 3.015625 | stackv2 |
# The class and its functions are designed to write into an empty .html file
# Each object takes three parameters - center latitude and -longitude and the zoom
# for the height of the map
class GoogleMaps_HeatMap(object):
def __init__(self, center_lat, center_lng, zoom, apikey=''):
self.center = ... | 106 | 43.24 | 177 | 16 | 1,153 | python | [{"finding_id": "codeql_py/clear-text-storage-sensitive-data_cdb22a7e8d4177b0_fe434a8f", "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."
] | [
57
] | [
null
] | [
20
] | [
176
] | |
2024-11-19T01:38:34.212853+00:00 | 1,507,171,825,000 | 2ad1b82051e91a960ea273f6b90d84b0acf9670b | 3 | {
"blob_id": "2ad1b82051e91a960ea273f6b90d84b0acf9670b",
"branch_name": "refs/heads/master",
"committer_date": 1507171825000,
"content_id": "41a42f7c350d81a7cedd51dd49499d152516252b",
"detected_licenses": [
"MIT"
],
"directory_id": "dea90d9ed94a96b8d6a3ecd9e98ea6efaa923a12",
"extension": "py",
"fi... | 3.0625 | stackv2 | """
module containing the class TimeDynamicGeoJson, which can be used to
create choropleth maps with a time slider.
"""
from jinja2 import Template
from branca.element import JavascriptLink, Figure
from folium.features import GeoJson
class TimeDynamicGeoJson(GeoJson):
"""
Creates a GeoJson object for plotting... | 175 | 42.93 | 143 | 15 | 1,507 | python | [{"finding_id": "codeql_py/jinja2/autoescape-false_6748c18072aeffe1_91f38671", "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."
] | [
68
] | [
168
] | [
26
] | [
17
] | |
2024-11-19T01:39:09.278045+00:00 | 1,534,434,072,000 | 0d8793fd8d33e723569380ae83c635533e1a884a | 3 | {
"blob_id": "0d8793fd8d33e723569380ae83c635533e1a884a",
"branch_name": "refs/heads/master",
"committer_date": 1534434072000,
"content_id": "cce1db62301a43dca95a3554c07dbc5b2637ea50",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "7c60b0ceadd7b2446deecbd0b7cde552dca49fd0",
"extension": "py"... | 2.78125 | stackv2 | import os
from jinja2 import Environment, FileSystemLoader
EXTENSIONS = {
'html': 'text/html'
}
PATH = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
TEMPLATE_ENVIRONMENT = Environment(
autoescape=False,
loader=FileSystemLoader(os.path.join(PATH, 'templates')),
trim_blocks=False)
def ... | 94 | 19.54 | 71 | 12 | 451 | python | [{"finding_id": "codeql_py/jinja2/autoescape-false_4f90bfdacb531e5d_22c122e1", "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."
] | [
11
] | [
14
] | [
24
] | [
23
] | |
2024-11-19T02:04:45.920506+00:00 | 1,553,140,210,000 | 758c9c1186fd1bb6b1eaa1e035e36d19b1952314 | 2 | {
"blob_id": "758c9c1186fd1bb6b1eaa1e035e36d19b1952314",
"branch_name": "refs/heads/master",
"committer_date": 1553140210000,
"content_id": "cc644cfb0d3ccc8acbe2cf3e173fbe4d21f3f02b",
"detected_licenses": [
"MIT"
],
"directory_id": "7c7eb5f17c60bb41fc47d990dc7ebd4d34450dc1",
"extension": "py",
"fi... | 2.484375 | stackv2 | import requests
import json
class FirUploadInfo:
downloadUrl = ''
log = ''
ipaName = ''
ipaBuild = ''
ipaVersion = ''
bundle_id = ''
ipaRelease_type = 'Adhoc' #打包类型,只针对 iOS (Adhoc, Inhouse)(上传 ICON 时不需要)
appsUrl = ''
type = ''
api_token = ''
def __init__(self, config):
... | 78 | 30.58 | 74 | 12 | 639 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_f1fe56ad6bfbb8d4_3df7ba4c", "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."
] | [
45
] | [
null
] | [
11
] | [
42
] | |
2024-11-19T02:28:16.319199+00:00 | 1,633,236,316,000 | 26d38e9f835b271a585f011424bf185ab64fbfc2 | 3 | {
"blob_id": "26d38e9f835b271a585f011424bf185ab64fbfc2",
"branch_name": "refs/heads/main",
"committer_date": 1633236316000,
"content_id": "d882e3221a30d130419a8cf93a46eecbe91e9cc6",
"detected_licenses": [
"MIT"
],
"directory_id": "3a5a333c65d2ffd06a6ffaba00778162ad94c8b2",
"extension": "py",
"file... | 3.171875 | stackv2 | #!/usr/bin/python
from pathlib import Path
from zipfile import ZipFile
import click
def extract_zip(zip_file: ZipFile, password_file: Path):
with open(password_file, 'r') as passwords:
for password in passwords.readlines():
try:
zip_file.extractall(pwd=password.strip().encode(... | 35 | 26.37 | 72 | 18 | 205 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_180dd2ea03bef2f4_e1ba13bc", "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."
] | [
13
] | [
null
] | [
23
] | [
52
] | |
2024-11-19T02:28:20.162283+00:00 | 1,502,603,385,000 | 6be715daa1949f50b4fb18b0096c9640ff356628 | 2 | {
"blob_id": "6be715daa1949f50b4fb18b0096c9640ff356628",
"branch_name": "refs/heads/master",
"committer_date": 1502603385000,
"content_id": "3fe4bf5f80c2f37a40cb4883080ace2ed870f1a9",
"detected_licenses": [
"MIT"
],
"directory_id": "b5ee100e91976b5ba9666b6bc6d8a4d713233343",
"extension": "py",
"fi... | 2.375 | stackv2 | # coding: utf-8
import logging
import typing
from bot.cache import AbstractCache
from bot.cache import mongo_settings as settings
Cur = typing.TypeVar('Cur')
class MongoCurrencyCache(AbstractCache):
def __init__(self, currency_cls, logger_name):
import pymongo
self.server_delay = 10
se... | 53 | 33.3 | 70 | 15 | 357 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_321c2993a8453c70_275eb23c", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (password)](1) as clear text.", ... | 1 | true | [
"CWE-312"
] | [
"py/clear-text-logging-sensitive-data"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"This expression logs [sensitive data (password)](1) as clear text."
] | [
38
] | [
39
] | [
31
] | [
70
] | |
2024-11-19T02:28:29.465720+00:00 | 1,489,323,292,000 | 37f2afe5e7282b22f4e19dcfc13db81e85e9ada7 | 2 | {
"blob_id": "37f2afe5e7282b22f4e19dcfc13db81e85e9ada7",
"branch_name": "refs/heads/master",
"committer_date": 1489323292000,
"content_id": "aa128d282d06ddbe951b6b9befa1db19e0ce5d25",
"detected_licenses": [
"MIT"
],
"directory_id": "300d8cfbe0a5c91121fd086a1c7861e2634bd25a",
"extension": "py",
"fi... | 2.40625 | stackv2 | #!/usr/bin/env python
# bootstrap.py
# Bootstrap and setup a virtualenv with the specified requirements.txt
import os
import stat
import sys
import shutil
from subprocess import call
import argparse
from tempfile import mkstemp
from shutil import move
description = """
Set up my development environment for me!
"""
p... | 106 | 38.55 | 129 | 14 | 952 | python | [{"finding_id": "codeql_py/overly-permissive-file_fa5a9cb1e9597871_6e8da233", "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."
] | [
47
] | [
null
] | [
5
] | [
29
] | |
2024-11-19T02:28:46.878037+00:00 | 1,418,770,828,000 | 725b700424fc9ba4301c4ad945063de811de683f | 3 | {
"blob_id": "725b700424fc9ba4301c4ad945063de811de683f",
"branch_name": "refs/heads/master",
"committer_date": 1418770828000,
"content_id": "7f1c7a549049704e85f0438458f2e400e85e0ef3",
"detected_licenses": [
"MIT"
],
"directory_id": "da4156137cabca43da538b55fae5897459d7f183",
"extension": "py",
"fi... | 2.625 | stackv2 | import string
import time
from flask import abort, jsonify, request
import json
import requests
from github_status.blueprints import api_query_github
from github_status.extensions import db
from github_status.models.helpers import count
from github_status.models.repositories import Repository
VALID_CHARACTERS = stri... | 137 | 35.34 | 118 | 16 | 1,131 | python | [{"finding_id": "codeql_py/stack-trace-exposure_c0c824ae562b9ff1_5c98ed1a", "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-918",
"CWE-918"
] | [
"py/stack-trace-exposure",
"py/partial-ssrf",
"py/partial-ssrf"
] | [
"HIGH",
"MEDIUM",
"MEDIUM"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"[Stack trace information](1) flows to this location and may be exposed to an external user.\n[Stack trace information](1) flows to this location and may be exposed to an external user.",
"Part of the URL of this request depends on a [user-provided value](1).",
"Part of the URL of this request depends on a [use... | [
126,
33,
71
] | [
null,
null,
null
] | [
45,
11,
15
] | [
51,
83,
98
] | |
2024-11-19T02:28:51.454835+00:00 | 1,553,530,042,000 | ec349d7a8595ff2699fe212ed1d3775bf1091c21 | 3 | {
"blob_id": "ec349d7a8595ff2699fe212ed1d3775bf1091c21",
"branch_name": "refs/heads/master",
"committer_date": 1553530042000,
"content_id": "02734366299a3a1eb7e388f62a48b3db8509a4cd",
"detected_licenses": [
"MIT"
],
"directory_id": "3a54d0bffcc1b0796f6ba863cea3537f60f3ace2",
"extension": "py",
"fi... | 2.625 | stackv2 | #!/usr/bin/env python
"""Symlinks model output files from ILAMBv1 to ILAMBv2."""
import os
src_dir = '/nas/data/ILAMB/MODELS/original'
dst_dir = '/nas/data/ilamb/MODELS'
for root, dirs, files in os.walk(src_dir):
if len(files) == 0:
model_name = os.path.basename(root)
new_model_dir = os.path.jo... | 20 | 27.25 | 58 | 15 | 155 | python | [{"finding_id": "codeql_py/overly-permissive-file_a2602196a8e8c493_0d07a19f", "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."
] | [
16
] | [
null
] | [
9
] | [
38
] | |
2024-11-19T02:36:50.652398+00:00 | 1,579,692,040,000 | 891cb0b585adbe15c5f99cd20a786e40303bd734 | 2 | {
"blob_id": "891cb0b585adbe15c5f99cd20a786e40303bd734",
"branch_name": "refs/heads/master",
"committer_date": 1579692040000,
"content_id": "1b38c9d8fa1f540032fa4181118b96d9ec85df4b",
"detected_licenses": [
"MIT"
],
"directory_id": "49c678243bbd80f1af2b9d8a413e68bfc42ba931",
"extension": "py",
"fi... | 2.421875 | stackv2 | from rest_framework import serializers
from authentication.models import User
from django.contrib.auth import authenticate
from django.contrib.auth.password_validation import validate_password
from django.core.exceptions import ValidationError
class RegistrationSerializer(serializers.ModelSerializer):
first_name... | 90 | 31.53 | 80 | 18 | 562 | python | [{"finding_id": "codeql_py/stack-trace-exposure_95a884b9ee8a4e98_a15e759a", "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."
] | [
47
] | [
49
] | [
47
] | [
49
] | |
2024-11-19T02:36:58.915138+00:00 | 1,616,489,482,000 | 95bdfb2c742245d08633645ef1b78b71ce098edb | 3 | {
"blob_id": "95bdfb2c742245d08633645ef1b78b71ce098edb",
"branch_name": "refs/heads/main",
"committer_date": 1616489482000,
"content_id": "788c33752218e8306ab658dfa67164692174d431",
"detected_licenses": [
"MIT"
],
"directory_id": "d27ed1b61d8eb6192f10818980505a6f486beef1",
"extension": "py",
"file... | 2.59375 | stackv2 | from flask import Flask, render_template, flash, redirect, url_for
from app import app, bcrypt, db
from app.forms import RegisterForm, LoginForm
from app.models import User
@app.route('/')
def index():
title = 'Flask Web App'
paragraphs = [
'Section 1',
'Section 2',
'Section 3'
]
... | 42 | 28.4 | 70 | 13 | 264 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_2713bc830eb29bef_8fad2ba0", "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."
] | [
26
] | [
null
] | [
32
] | [
40
] | |
2024-11-19T02:37:03.369512+00:00 | 1,618,937,398,000 | af8d29607ceeb798b010c8c46186e6474956744b | 3 | {
"blob_id": "af8d29607ceeb798b010c8c46186e6474956744b",
"branch_name": "refs/heads/master",
"committer_date": 1618937398000,
"content_id": "57d6eddd2c90f2b24c8fb48157ff86fed4f766fe",
"detected_licenses": [
"MIT"
],
"directory_id": "4404810143d96aa4ab08675ad7efdaf2abe1576e",
"extension": "py",
"fi... | 2.53125 | stackv2 | """
MIT License
Copyright (c) 2017-2020 Ioan Coman
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, modify, merge, publi... | 372 | 33.98 | 136 | 23 | 2,782 | python | [{"finding_id": "codeql_py/insecure-default-protocol_2246f27fd3bf1740_5265fac7", "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."
] | [
317
] | [
320
] | [
22
] | [
30
] | |
2024-11-19T02:37:04.373303+00:00 | 1,516,254,348,000 | 86ab07704bcd092df5e4e2765cf35705d3450efe | 2 | {
"blob_id": "86ab07704bcd092df5e4e2765cf35705d3450efe",
"branch_name": "refs/heads/master",
"committer_date": 1516254348000,
"content_id": "c708740b75a74a1b511a213e3de8452cb48d8af4",
"detected_licenses": [
"MIT"
],
"directory_id": "00a75b610546dc5b08b8e6b344d9ae8e67122c4d",
"extension": "py",
"fi... | 2.34375 | stackv2 | # -*- coding:utf-8 -*-
from . import auth
from .. import db
from flask import render_template, redirect, url_for, flash, request,current_app
from .forms import LoginForm, RegisterForm, ChangePassword, FindPassword, ResetPassword
from ..models import User
from flask_login import login_user, logout_user, login_required,... | 171 | 27.06 | 107 | 16 | 1,134 | python | [{"finding_id": "codeql_py/url-redirection_4fb12544dcde0dce_552ccdd8", "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
] | [
29
] | [
78
] | |
2024-11-19T02:37:18.045038+00:00 | 1,611,699,542,000 | e55d27204aba553ac3150ffcb7313285223e5fce | 3 | {
"blob_id": "e55d27204aba553ac3150ffcb7313285223e5fce",
"branch_name": "refs/heads/master",
"committer_date": 1611699542000,
"content_id": "12713704349918d883358d5b64987a47110de0e6",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "af5b676d45a503b0e499e601eb66f0bef9ae4adb",
"extension": "py"... | 2.984375 | stackv2 | #!/usr/bin/env python3
import os, sys, json
from templates import login_page, secret_page
from secret import username, password
print("Content-Type: text/html")
# How to read cookies
# - https://stackoverflow.com/a/20899685 By user "Mosiur"
is_logged_in = False
if "HTTP_COOKIE" in os.environ:
# Will probably have... | 56 | 37.45 | 101 | 15 | 511 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_4cad27e79a4c5607_fd60e825", "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."
] | [
20
] | [
null
] | [
11
] | [
42
] | |
2024-11-19T02:37:26.334322+00:00 | 1,480,739,660,000 | b925d2dec41d636e8454020a31a28b21c257af54 | 3 | {
"blob_id": "b925d2dec41d636e8454020a31a28b21c257af54",
"branch_name": "refs/heads/master",
"committer_date": 1480739660000,
"content_id": "fd195170eabccc0fc929dee34fdc8ddf88a10fdf",
"detected_licenses": [
"MIT"
],
"directory_id": "062efe2deea461b6b2562a616cbcdd6e731e8539",
"extension": "py",
"fi... | 2.53125 | stackv2 | import socket
import os
import json
import time
import sys
import select
import cmd
import hashlib
class Client(cmd.Cmd):
def preloop(self):
abs_prefix = os.path.join(os.path.dirname(__file__), "../client")
cfig = "config.json"
with open(abs_prefix + '/' + cfig,'r') as f:
conf ... | 77 | 28.68 | 118 | 16 | 562 | python | [{"finding_id": "codeql_py/weak-sensitive-data-hashing_3174f9b7e7fb5702_1a19bb4a", "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."
] | [
25
] | [
null
] | [
18
] | [
31
] | |
2024-11-19T02:37:42.506169+00:00 | 1,522,398,813,000 | a8cda2d75f2cc6cb45f956c84fd6eedc9e919324 | 3 | {
"blob_id": "a8cda2d75f2cc6cb45f956c84fd6eedc9e919324",
"branch_name": "refs/heads/master",
"committer_date": 1522398813000,
"content_id": "5ad79d3fc899f4276eaf87453d058595e1dbd909",
"detected_licenses": [
"BSD-3-Clause"
],
"directory_id": "a3b673d2fd20d62e6a455f3fd1e182f5ea5e5756",
"extension": "p... | 2.609375 | stackv2 | """
Files - a Page kind - used in pages/sections, as download links
mix-in class for Page.py
"""
from evoke.render import html
from evoke.lib import *
from io import StringIO
from os.path import lexists
import os
class File(object):
""
# def permitted(self,user):
# ""
## print ">>>>>>>>>>>... | 183 | 35.6 | 111 | 17 | 1,585 | python | [{"finding_id": "codeql_py/overly-permissive-file_63d8a9aba75fb388_7a076eb3", "tool_name": "codeql", "rule_id": "py/overly-permissive-file", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Overly permissive mask in chmod sets file to world writable.", "remediation": "", "location": ... | 2 | true | [
"CWE-732",
"CWE-732"
] | [
"py/overly-permissive-file",
"py/overly-permissive-file"
] | [
"MEDIUM",
"MEDIUM"
] | [
"MEDIUM",
"MEDIUM"
] | [
"Overly permissive mask in chmod sets file to world writable.",
"Overly permissive mask in chmod sets file to world readable."
] | [
110,
112
] | [
null,
null
] | [
17,
9
] | [
36,
29
] | |
2024-11-19T02:37:49.935424+00:00 | 1,651,192,017,000 | 093a121a50df121621e031df34081e9395e494be | 3 | {
"blob_id": "093a121a50df121621e031df34081e9395e494be",
"branch_name": "refs/heads/master",
"committer_date": 1651192017000,
"content_id": "77da3c2eaab2a2cbd6755f83a5a3595ec60c9100",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "0f5e25e846e73d9ec203a210d175dac44d76d982",
"extension": "py"... | 2.78125 | stackv2 | """
A collection of utility functions for querying and checking Ethereum data
"""
import aiohttp
from hummingbot.client.config.global_config_map import global_config_map
from hummingbot.core.utils import async_ttl_cache
import itertools as it
import logging
from typing import List
from web3 import Web3
def is_connec... | 102 | 33.23 | 115 | 14 | 792 | python | [{"finding_id": "codeql_py/incomplete-url-substring-sanitization_82f9d8344f6ec384_c8fac4b7", "tool_name": "codeql", "rule_id": "py/incomplete-url-substring-sanitization", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "The string [http://mainnet.infura.io](1) may be at an arbitrary po... | 2 | true | [
"CWE-020",
"CWE-020"
] | [
"py/incomplete-url-substring-sanitization",
"py/incomplete-url-substring-sanitization"
] | [
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM"
] | [
"The string [http://mainnet.infura.io](1) may be at an arbitrary position in the sanitized URL.",
"The string [mainnet.infura.io](1) may be at an arbitrary position in the sanitized URL."
] | [
32,
36
] | [
null,
null
] | [
12,
12
] | [
67,
60
] | |
2024-11-19T02:49:10.906218+00:00 | 1,615,732,697,000 | e77f56752cb97033b60785e6103453f662a40f16 | 2 | {
"blob_id": "e77f56752cb97033b60785e6103453f662a40f16",
"branch_name": "refs/heads/master",
"committer_date": 1615732697000,
"content_id": "d4dba535f893832599737a3fbfb51ebae34fcff2",
"detected_licenses": [
"MIT"
],
"directory_id": "7d08a2c69668c132306b5c4c698ff3649832de57",
"extension": "py",
"fi... | 2.46875 | stackv2 | #!/usr/bin/env python
import os
import struct
import jinja2
def render(ctxt={}):
#load template and render
return jinja2.Environment(
loader=jinja2.FileSystemLoader('.')
).get_template('traffic.prototxt.j2').render(ctxt)
def read_short(fname):
with open(fname, 'rb') as f:
return [struc... | 96 | 21.59 | 82 | 15 | 788 | python | [{"finding_id": "codeql_py/jinja2/autoescape-false_90287dd2bb7b6877_d5d71d50", "tool_name": "codeql", "rule_id": "py/jinja2/autoescape-false", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Using jinja2 templates with autoescape=False can potentially allow XSS attacks.", "remediati... | 1 | true | [
"CWE-079"
] | [
"py/jinja2/autoescape-false"
] | [
"MEDIUM"
] | [
"MEDIUM"
] | [
"Using jinja2 templates with autoescape=False can potentially allow XSS attacks."
] | [
8
] | [
10
] | [
12
] | [
6
] | |
2024-11-19T02:49:44.781328+00:00 | 1,602,005,272,000 | 259ea0deb4ab3a987797ecf2d446bcf7563731a5 | 2 | {
"blob_id": "259ea0deb4ab3a987797ecf2d446bcf7563731a5",
"branch_name": "refs/heads/master",
"committer_date": 1602005272000,
"content_id": "cd2927e58e2b9e68d2e0c494c29af5565a8dc69e",
"detected_licenses": [
"MIT"
],
"directory_id": "6eaeb9d19552a2352cc552e21c9d07fbe242ae7b",
"extension": "py",
"fi... | 2.390625 | stackv2 | import base64
import logging
import random
import requests
from typing import List
from .device import Device
from .mib_mapper import to_devices
from .single_value_cache import SingleValueCache
LOG = logging.getLogger(__name__)
class ConnectBox:
USERNAME = "admin"
TOKEN_EXPIRY_TIME = 5 * 60 * 1000
def ... | 55 | 28.58 | 97 | 15 | 384 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_5f278f8d5c194b28_4a984cf5", "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
] | [
41
] | [
46
] | |
2024-11-19T03:00:02.620144+00:00 | 1,536,109,642,000 | 368af34a6d0681024af4c320b74520658fef53ce | 2 | {
"blob_id": "368af34a6d0681024af4c320b74520658fef53ce",
"branch_name": "refs/heads/master",
"committer_date": 1536109642000,
"content_id": "ce0108603862823acbd6cd160b6b99b514634bb8",
"detected_licenses": [
"MIT"
],
"directory_id": "ba206b5b31ff69f7d671600fd076b0f23689567e",
"extension": "py",
"fi... | 2.453125 | stackv2 | # -*- coding: utf-8 -*-
"""One-file Flask app that displays Salesforce Contact sObject records.
Additionally, the records may be edited and have the record changes
automatically synced back to Salesforce. This app requires a PostGreSQL
database that is connected to Salesforce via Heroku Connect.
"""
from base64 import... | 280 | 28.89 | 79 | 19 | 1,794 | python | [{"finding_id": "codeql_py/incomplete-hostname-regexp_5435cf97ae179347_ecde8ff9", "tool_name": "codeql", "rule_id": "py/incomplete-hostname-regexp", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "This regular expression has an unescaped '.' before 'herokuapp.com', so it might match m... | 2 | true | [
"CWE-020",
"CWE-601"
] | [
"py/incomplete-hostname-regexp",
"py/url-redirection"
] | [
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM"
] | [
"This regular expression has an unescaped '.' before 'herokuapp.com', so it might match more hosts than expected.",
"Untrusted URL redirection depends on a [user-provided value](1)."
] | [
206,
192
] | [
null,
null
] | [
10,
25
] | [
44,
28
] | |
2024-11-19T03:11:33.568631+00:00 | 1,579,499,916,000 | 74e88265c6b94ff3885cd1ac0f39be1f24f1aaa5 | 3 | {
"blob_id": "74e88265c6b94ff3885cd1ac0f39be1f24f1aaa5",
"branch_name": "refs/heads/master",
"committer_date": 1579499916000,
"content_id": "651b095b0fd11cfd89a3e9d09c3ca966bf978923",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "8540e8d59c454a02b85666b9bbea8ae83209165a",
"extension": "py"... | 2.890625 | stackv2 | #!/usr/bin/python3
import requests
import re
comments = "<\W*--.*?--\W*>"
#<!-- -->
def finder(f):
for url in f:
finds = []
a = re.sub("\n|%0a", "", url)
response = requests.get(a, allow_redirects=True)
for comment in re.findall(comments, response.text):
finds.ap... | 50 | 19.26 | 94 | 17 | 241 | python | [{"finding_id": "codeql_py/bad-tag-filter_6fb929055dc72451_25128076", "tool_name": "codeql", "rule_id": "py/bad-tag-filter", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "This regular expression does not match comments containing newlines.", "remediation": "", "location": {"file_pat... | 1 | true | [
"CWE-116"
] | [
"py/bad-tag-filter"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"This regular expression does not match comments containing newlines."
] | [
5
] | [
null
] | [
13
] | [
28
] | |
2024-11-19T03:11:44.176934+00:00 | 1,593,786,745,000 | 914dea63e0ef385896d88eeaf2d328504528d35a | 2 | {
"blob_id": "914dea63e0ef385896d88eeaf2d328504528d35a",
"branch_name": "refs/heads/master",
"committer_date": 1593786745000,
"content_id": "e155153495b1aff0027f611d52a82738161b0509",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "22484bfb5abd65293cbfcdec531c2ba4904e332a",
"extension": "py"... | 2.484375 | stackv2 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
"""
Usage: import bel.Config as config
Get first belbio_conf.{yml|yaml} and belbio_secrets.{yml|yaml} files in:
current dir or parent directories starting with immediate parent of current dir
OR
~/.belbio_{conf|secrets} (dotfiles in home directory)
"""
# S... | 255 | 28.7 | 126 | 19 | 1,795 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_a6d5319472fb9078_11c4b35d", "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."
] | [
75
] | [
null
] | [
14
] | [
85
] | |
2024-11-19T03:11:59.230535+00:00 | 1,477,757,846,000 | c3df76e7e5698f39cbad675c91784e313adea2be | 2 | {
"blob_id": "c3df76e7e5698f39cbad675c91784e313adea2be",
"branch_name": "refs/heads/master",
"committer_date": 1477757846000,
"content_id": "bbfe46bb1c6d02f9d6df8f6706971a255680b795",
"detected_licenses": [
"MIT"
],
"directory_id": "b543f0c07907ee99e296668f4dd2f63e25ea0aea",
"extension": "py",
"fi... | 2.421875 | stackv2 | #!/usr/bin/env python
######################################################################
## $Revision: 1.1 $
## $Date: 2015/07/15 12:24:41 $
## Author: Carl Schaefer, Smithsonian Institution Archives
######################################################################
import time
import os
import re
import code... | 191 | 28.79 | 96 | 18 | 1,548 | python | [{"finding_id": "codeql_py/overly-large-range_0820f33ecb7f7420_2d8247e4", "tool_name": "codeql", "rule_id": "py/overly-large-range", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Suspicious character range that is equivalent to \\[\\u000e\\u000f\\u0010\\u0011\\u0012\\u0013\\u0014\\u... | 1 | true | [
"CWE-020"
] | [
"py/overly-large-range"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"Suspicious character range that is equivalent to \\[\\u000e\\u000f\\u0010\\u0011\\u0012\\u0013\\u0014\\u0015\\...."
] | [
44
] | [
null
] | [
49
] | [
52
] | |
2024-11-19T03:12:18.104815+00:00 | 1,653,985,956,000 | ab11e551fe3cf83298b22d64da45776f4e0d5288 | 2 | {
"blob_id": "ab11e551fe3cf83298b22d64da45776f4e0d5288",
"branch_name": "refs/heads/master",
"committer_date": 1653985956000,
"content_id": "050e8a19bdaca56b0f06e457690b0222a7d89e05",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "5f23b46e8af691b0ba95d480d988150e553b1a56",
"extension": "py"... | 2.421875 | stackv2 | #
# Copyright 2021 Grupo de Sistemas Inteligentes, DIT, Universidad Politecnica de Madrid (UPM)
#
# 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... | 170 | 29.05 | 93 | 19 | 1,166 | python | [{"finding_id": "codeql_py/tarslip_9b442b7628724f41_95abf8fd", "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)."
] | [
124
] | [
null
] | [
9
] | [
12
] | |
2024-11-19T03:12:47.476098+00:00 | 1,577,719,053,000 | dd2d4f212b79d6d3ec3a46e34d7e04886568391b | 3 | {
"blob_id": "dd2d4f212b79d6d3ec3a46e34d7e04886568391b",
"branch_name": "refs/heads/master",
"committer_date": 1577719053000,
"content_id": "c99865fe8c61fe8d0c05f5558d624bfb7e2545df",
"detected_licenses": [
"MIT"
],
"directory_id": "c643ae390ed6b173107192e25b13c19fec1e666e",
"extension": "py",
"fi... | 2.671875 | stackv2 | from pdb import set_trace
import json
import os
import random
import re
import sys
from textblob import TextBlob
from botfriend.bot import TextGeneratorBot
from olipy import corpora
from wordfilter import blacklisted
class IAMAExtractor(object):
re_parts = [
"[^.]+[!.] [^.]+[!.]",
"[^.]+[!.\n]",
... | 247 | 35.68 | 89 | 19 | 2,050 | python | [{"finding_id": "codeql_py/overly-large-range_703648ab4c4ce42e_814b6d9d", "tool_name": "codeql", "rule_id": "py/overly-large-range", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Suspicious character range that overlaps with \\ufffd-\\ufffd in the same character class.", "remediatio... | 1 | true | [
"CWE-020"
] | [
"py/overly-large-range"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"Suspicious character range that overlaps with \\ufffd-\\ufffd in the same character class."
] | [
20
] | [
null
] | [
26
] | [
30
] | |
2024-11-19T03:12:53.431868+00:00 | 1,598,293,200,000 | 45d271848b269cad7cb342f2f547401fcd41f205 | 2 | {
"blob_id": "45d271848b269cad7cb342f2f547401fcd41f205",
"branch_name": "refs/heads/master",
"committer_date": 1598293200000,
"content_id": "44e06de2ab62147cd0cf92fbba01e613b3d9abc1",
"detected_licenses": [
"MIT"
],
"directory_id": "f00e2d5d9c792cf355e6f6b603bd95ebb207567b",
"extension": "py",
"fi... | 2.5 | stackv2 | #!/usr/bin/python
# https://media.readthedocs.org/pdf/pynag/latest/pynag.pdf
from pynag.Model import Parsers
import os
from tempfile import mkstemp
from shutil import move
from os import remove, close
import re
import time
nagios_config = '/usr/local/nagios/etc/nagios.cfg'
nagios_sock = '/usr/local/nagios/var/rw/live... | 119 | 30.99 | 95 | 20 | 881 | python | [{"finding_id": "codeql_py/overly-permissive-file_1344562da1a4ace5_7482c436", "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."
] | [
111
] | [
null
] | [
5
] | [
31
] | |
2024-11-19T03:12:55.075740+00:00 | 1,683,478,818,000 | 0afc9cd5bb6c98911c56db8d309fa4f54a017cba | 3 | {
"blob_id": "0afc9cd5bb6c98911c56db8d309fa4f54a017cba",
"branch_name": "refs/heads/master",
"committer_date": 1683478818000,
"content_id": "81f2f40ba250c93b18bd4df224fefbe5f2714784",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "e2ca3205bb5240a1e4c87de0bdb13faa70241f16",
"extension": "py"... | 3 | stackv2 | """
Custom configuration parser
"""
import io
import os
import configparser
from typing import Any, List, Text, Mapping
from jinja2 import Template
def render_config_parser(config_parser: configparser.ConfigParser):
return {section: dict(config_parser[section]) for section in config_parser.sections()}
class En... | 64 | 29.89 | 90 | 15 | 415 | python | [{"finding_id": "codeql_py/jinja2/autoescape-false_a3a9fb53d70dcd3a_918fe83c", "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."
] | [
51
] | [
null
] | [
20
] | [
36
] | |
2024-11-19T03:25:20.349605+00:00 | 1,640,624,315,000 | 6b69bb942c3e32b1446dfe5f1b4191ca11b4658f | 2 | {
"blob_id": "6b69bb942c3e32b1446dfe5f1b4191ca11b4658f",
"branch_name": "refs/heads/master",
"committer_date": 1640624315000,
"content_id": "05f2240d149831da4cda91342af8e5effecfc7f7",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "e83c081067f06ee85a4358099baf0b35d62f88ae",
"extension": "py"... | 2.40625 | stackv2 | import pypureomapi
from lib.base_action import BaseAction
class CreateDHCPLeaseReservation(BaseAction):
def run(
self,
reserved_ip,
mac_addr,
auth_key_name,
auth_key,
server_name,
dhcp_host,
dhcp_port=7911
):
try:
# cast auths... | 33 | 28.15 | 94 | 15 | 214 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_5e666dec748eeb57_5877e1d8", "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."
] | [
29
] | [
null
] | [
19
] | [
72
] | |
2024-11-19T03:35:54.455341+00:00 | 1,680,634,799,000 | 2751e15ed7b65a58113057be0693cbbdfdfe7fe9 | 2 | {
"blob_id": "2751e15ed7b65a58113057be0693cbbdfdfe7fe9",
"branch_name": "refs/heads/master",
"committer_date": 1680634799000,
"content_id": "390f029443b9d30bdcaf35960636f931b238e698",
"detected_licenses": [
"MIT"
],
"directory_id": "4b187ffcdafd6cb27b3ed68e3b39782c9f2c0a58",
"extension": "py",
"fi... | 2.46875 | stackv2 | #!/usr/bin/env python
import jinja2
import os
import random
import string
print("Bootstrapping Zues for local usage")
template_file = os.getenv("ZUES_SITE_LOCAL_SETTINGS_TEMPLATE_PATH", "zuessite/templates/local_settings_template.py")
template_file_full_path = template_file
local_settings_file = os.getenv("ZUES_SIT... | 49 | 31.51 | 134 | 12 | 337 | python | [{"finding_id": "codeql_py/jinja2/autoescape-false_5ab71c5728adfa4d_3edd7fe8", "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."
] | [
34
] | [
null
] | [
16
] | [
58
] | |
2024-11-19T01:28:51.900016+00:00 | 1,590,729,182,000 | e9b25a05986206b629c9a42950cf2cf9e4a9d855 | 2 | {
"blob_id": "e9b25a05986206b629c9a42950cf2cf9e4a9d855",
"branch_name": "refs/heads/master",
"committer_date": 1590729182000,
"content_id": "e28fd5bcfef98b271756a7acb90a317311fddd84",
"detected_licenses": [
"MIT"
],
"directory_id": "d75b674910ea79a6386c7f552a9fae6495fd501e",
"extension": "py",
"fi... | 2.328125 | stackv2 | from flask import Flask, render_template, request, make_response
import predictor
from predictor import predict, FlairActual
import json
import os
from werkzeug.utils import secure_filename
port = int(os.environ.get("PORT",5000))
app = Flask(__name__)
@app.route('/')
def home():
return render_template('index.html... | 54 | 26.31 | 101 | 14 | 353 | python | [{"finding_id": "codeql_py/path-injection_8618f825e3778cb2_872638c9", "tool_name": "codeql", "rule_id": "py/path-injection", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This path depends on a [user-provided value](1).", "remediation": "", "location": {"file_path": "unknown", ... | 1 | true | [
"CWE-022"
] | [
"py/path-injection"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"This path depends on a [user-provided value](1)."
] | [
35
] | [
null
] | [
13
] | [
28
] | |
2024-11-19T01:28:53.152810+00:00 | 1,606,572,178,000 | 9f94ff70a1badd8cdbd1b02ea35ef364ae7503ee | 3 | {
"blob_id": "9f94ff70a1badd8cdbd1b02ea35ef364ae7503ee",
"branch_name": "refs/heads/main",
"committer_date": 1606572178000,
"content_id": "6049cb85d27337da1026f6e8b640aad26ebf2926",
"detected_licenses": [
"MIT"
],
"directory_id": "5c74b5eb86700a52330137e94e82c83fc8e9d37b",
"extension": "py",
"file... | 3.109375 | stackv2 | from flask import *
from flask_socketio import *
import json
# Init the server
app = Flask(__name__)
app.config['SECRET_KEY'] = 'some super secret key!'
socketio = SocketIO(app, logger=True)
# Send HTML!
@app.route('/')
def root():
return """
<div style="text-align:center;">
<h1>Welcome to ChatRoom... | 78 | 23.23 | 78 | 13 | 511 | python | [{"finding_id": "codeql_py/reflective-xss_afda5002186b40d5_ccc407dc", "tool_name": "codeql", "rule_id": "py/reflective-xss", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "Cross-site scripting vulnerability due to a [user-provided value](1).", "remediation": "", "location": {"fi... | 1 | true | [
"CWE-079"
] | [
"py/reflective-xss"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"Cross-site scripting vulnerability due to a [user-provided value](1)."
] | [
28
] | [
null
] | [
12
] | [
19
] | |
2024-11-19T01:29:06.334146+00:00 | 1,559,126,016,000 | 48b5df825256b8b1790a2c6b18b552f5a1d53f82 | 3 | {
"blob_id": "48b5df825256b8b1790a2c6b18b552f5a1d53f82",
"branch_name": "refs/heads/master",
"committer_date": 1559126016000,
"content_id": "7860e8f6b57c731907395598fb502459462d98e8",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "85783d72e82ea9da4e2f94d79e1f0c18a29f8561",
"extension": "py"... | 2.609375 | stackv2 | import autopep8
import networkx as nx
from jinja2 import Environment, PackageLoader
# TODO: Define most of this function parameters in a config file?
# Or extent the tagging language and provide defaults.
# Need to implement tag arguments first.
def gen_kfp_code(nb_graph, pipeline_name, pipeline_description, do... | 82 | 34.63 | 99 | 18 | 587 | python | [{"finding_id": "codeql_py/jinja2/autoescape-false_29281051ec6243a0_6d5e6eca", "tool_name": "codeql", "rule_id": "py/jinja2/autoescape-false", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Using jinja2 templates with autoescape=False can potentially allow XSS attacks.", "remediati... | 1 | true | [
"CWE-079"
] | [
"py/jinja2/autoescape-false"
] | [
"MEDIUM"
] | [
"MEDIUM"
] | [
"Using jinja2 templates with autoescape=False can potentially allow XSS attacks."
] | [
32
] | [
null
] | [
20
] | [
74
] | |
2024-11-19T01:29:55.951207+00:00 | 1,509,488,087,000 | b0d3894503cfd872a797a669d9b45fcdc6bd4ddb | 3 | {
"blob_id": "b0d3894503cfd872a797a669d9b45fcdc6bd4ddb",
"branch_name": "refs/heads/master",
"committer_date": 1509488087000,
"content_id": "046e0070b4ae940e392c57471fa7c144c38c4af4",
"detected_licenses": [
"Artistic-2.0"
],
"directory_id": "1372ad67933bb0222214075fba1223acdb739634",
"extension": "p... | 2.9375 | stackv2 | """
Web app that controlls other web applications
"""
import flask
import config
from flask import request
import logging
# import geocoder
import requests
# Globals
app = flask.Flask(__name__)
CONFIG = config.configuration()
app.secret_key = CONFIG.SECRET_KEY
app.debug = CONFIG.DEBUG
if app.debug:
app.logger.se... | 107 | 25.83 | 120 | 12 | 731 | python | [{"finding_id": "codeql_py/partial-ssrf_6a076b478ccd43f2_1cdf2305", "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)."
] | [
101
] | [
null
] | [
9
] | [
26
] | |
2024-11-19T01:30:07.340502+00:00 | 1,596,449,238,000 | e2ad4c059d0ad146951683e4789ad35550fe4712 | 3 | {
"blob_id": "e2ad4c059d0ad146951683e4789ad35550fe4712",
"branch_name": "refs/heads/master",
"committer_date": 1596449238000,
"content_id": "18faa9e1961f75f41c9d619028d14c87c69d6901",
"detected_licenses": [
"MIT"
],
"directory_id": "dc5c89a16013befc1791cf1a39a578f354558e0a",
"extension": "py",
"fi... | 2.625 | stackv2 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# Copyright (C) 2018 Elvis Yu-Jing Lin <elvisyjlin@gmail.com>
# Licensed under the MIT License - https://opensource.org/licenses/MIT
import requests
import os
import time
import json
from .downloader import Downloader
from .utils.helpers import get_imgur, get_gfycat, req... | 84 | 35.31 | 139 | 21 | 688 | python | [{"finding_id": "codeql_py/incomplete-url-substring-sanitization_4cf058e629cc0534_9c667a31", "tool_name": "codeql", "rule_id": "py/incomplete-url-substring-sanitization", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "The string [imgur.com/](1) may be at an arbitrary position in the ... | 2 | true | [
"CWE-020",
"CWE-020"
] | [
"py/incomplete-url-substring-sanitization",
"py/incomplete-url-substring-sanitization"
] | [
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM"
] | [
"The string [imgur.com/](1) may be at an arbitrary position in the sanitized URL.",
"The string [gfycat.com/](1) may be at an arbitrary position in the sanitized URL."
] | [
65,
69
] | [
null,
null
] | [
24,
26
] | [
47,
50
] | |
2024-11-19T01:30:12.630268+00:00 | 1,443,541,705,000 | a228ef481438fc5bb5b315a91d5cee6d580a4acc | 2 | {
"blob_id": "a228ef481438fc5bb5b315a91d5cee6d580a4acc",
"branch_name": "refs/heads/master",
"committer_date": 1443541705000,
"content_id": "25f79330261990540fa386b0eef090488b72131e",
"detected_licenses": [
"MIT"
],
"directory_id": "99006432a671004193d59f8957d05f5002f86d9b",
"extension": "py",
"fi... | 2.46875 | stackv2 | import json
import os
import requests
from boto_client import BotoClient
FILE_DIR = "audio_files"
class EchoNestRestClient(object):
BASE_URL = 'http://developer.echonest.com/api/v4/'
UPLOAD_ENDPOINT = 'track/upload'
PROFILE_ENDPOINT = 'track/profile?format=json&bucket=audio_summary'
def __init__(s... | 89 | 34.34 | 133 | 14 | 771 | python | [{"finding_id": "codeql_py/clear-text-storage-sensitive-data_abb1b1042ee7181a_fa1aadec", "tool_name": "codeql", "rule_id": "py/clear-text-storage-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression stores [sensitive data (password)](1) as clear text.\... | 1 | true | [
"CWE-312"
] | [
"py/clear-text-storage-sensitive-data"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"This expression stores [sensitive data (password)](1) as clear text.\nThis expression stores [sensitive data (password)](2) as clear text.\nThis expression stores [sensitive data (password)](3) as clear text."
] | [
73
] | [
null
] | [
13
] | [
48
] | |
2024-11-19T01:30:12.697893+00:00 | 1,558,108,867,000 | cbb5826224117272a4dd3f0ed6452da59740756e | 2 | {
"blob_id": "cbb5826224117272a4dd3f0ed6452da59740756e",
"branch_name": "refs/heads/master",
"committer_date": 1558108867000,
"content_id": "7b2fdb8cbc8b3bfb95e4b6d7756bdb8e9b7d4b31",
"detected_licenses": [
"MIT"
],
"directory_id": "5d5412af91c10ea7089e3cef254b051ad97710fb",
"extension": "py",
"fi... | 2.359375 | stackv2 | import os
import random
from PIL import Image
from django.db.models import Q
from django.http import JsonResponse, HttpResponse
from rest_framework.response import Response
from rest_framework.views import APIView
from DjangoGoodsExchange import settings
from app.models import Carousel
from app.serializers import Car... | 158 | 30.97 | 103 | 19 | 1,222 | python | [{"finding_id": "codeql_py/code-injection_b125c549335ab84b_a77758ba", "tool_name": "codeql", "rule_id": "py/code-injection", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This code execution depends on a [user-provided value](1).", "remediation": "", "location": {"file_path": "... | 1 | true | [
"CWE-094"
] | [
"py/code-injection"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"This code execution depends on a [user-provided value](1)."
] | [
149
] | [
null
] | [
28
] | [
35
] | |
2024-11-19T01:30:14.177231+00:00 | 1,491,533,979,000 | a36eb4fbda81538a5bb51e9b46f160a9c6b98f8f | 2 | {
"blob_id": "a36eb4fbda81538a5bb51e9b46f160a9c6b98f8f",
"branch_name": "refs/heads/master",
"committer_date": 1491533979000,
"content_id": "ae2efdc8dba9abf6c6d3a6a39dc3bfc66b8e6bec",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "e661c7a02635416adeb30f17e4484bfaa5331f0b",
"extension": "py"... | 2.484375 | stackv2 | #!/usr/bin/env python
# coding: utf-8
from wxbot import *
import datetime
import re
class AddUserToGroup(WXBot):
def __init__(self):
WXBot.__init__(self)
def writeFile(self,msg):
d = datetime.date.today()
f = open('./errorlog/' + d + '.json','a+')
f.write(msg)
f.close();
def getGroupName(self,groupn... | 73 | 20.29 | 81 | 17 | 460 | python | [{"finding_id": "codeql_py/overly-large-range_4d6663394313915f_cf9a00de", "tool_name": "codeql", "rule_id": "py/overly-large-range", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Suspicious character range that is empty.", "remediation": "", "location": {"file_path": "unknown", "lin... | 1 | true | [
"CWE-020"
] | [
"py/overly-large-range"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"Suspicious character range that is empty."
] | [
22
] | [
null
] | [
15
] | [
18
] | |
2024-11-19T01:55:10.011991+00:00 | 1,543,118,968,000 | 8a9b42c444737307b928ba62caf0934fc55901e6 | 3 | {
"blob_id": "8a9b42c444737307b928ba62caf0934fc55901e6",
"branch_name": "refs/heads/master",
"committer_date": 1543118968000,
"content_id": "3754260012053739425a75f1a1173a33a2c30207",
"detected_licenses": [
"MIT"
],
"directory_id": "f5e4e4820622fb1cbb3ec2ab33b11a3aa5c7abe8",
"extension": "py",
"fi... | 3.203125 | stackv2 | from dotenv import load_dotenv
import json
import os
import requests
from datetime import datetime
import pytest
from dateutil.parser import parse
# load environment variable
load_dotenv()
api_key = os.environ.get("ACCUWEATHER_API_KEY") or "OOPS. Please set an environment variable named 'ACCUWEATHER_API_KEY'."
# chec... | 397 | 36.6 | 137 | 19 | 3,525 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_d53003b474f9c934_408c966d", "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... | 3 | true | [
"CWE-312",
"CWE-312",
"CWE-312"
] | [
"py/clear-text-logging-sensitive-data",
"py/clear-text-logging-sensitive-data",
"py/clear-text-logging-sensitive-data"
] | [
"HIGH",
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"This expression logs [sensitive data (password)](1) as clear text.\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... | [
60,
119,
375
] | [
null,
null,
null
] | [
15,
23,
11
] | [
68,
75,
35
] | |
2024-11-19T01:55:23.557782+00:00 | 1,455,226,875,000 | 585455deed4df724618200449145825f45999cf9 | 2 | {
"blob_id": "585455deed4df724618200449145825f45999cf9",
"branch_name": "refs/heads/master",
"committer_date": 1455227080000,
"content_id": "56e1d186fdddbeb897a138ff264e6bb4056b4382",
"detected_licenses": [
"MIT"
],
"directory_id": "007b44f500c897e421c2ed8bd391ef063bfac799",
"extension": "py",
"fi... | 2.328125 | stackv2 | import json
import logging
import os
import re
from google.appengine.ext import ndb
from google.appengine.api import users
import jinja2
import webapp2
import api
import jsonify
import models
JINJA_ENVIRONMENT = jinja2.Environment(
loader=jinja2.FileSystemLoader(os.path.dirname(__file__)),
extensions=['jinj... | 186 | 34.36 | 77 | 27 | 1,386 | python | [{"finding_id": "codeql_py/jinja2/autoescape-false_f22c37b797216f7c_c17a0491", "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."
] | [
16
] | [
20
] | [
21
] | [
6
] | |
2024-11-19T01:55:24.169071+00:00 | 1,607,524,093,000 | eb08557985786873ce615bf3c2b9268185314d55 | 3 | {
"blob_id": "eb08557985786873ce615bf3c2b9268185314d55",
"branch_name": "refs/heads/master",
"committer_date": 1607524093000,
"content_id": "c927de9d03fc235b4397596c4f234b96064018af",
"detected_licenses": [
"MIT"
],
"directory_id": "9a9d7bc793e6fb3ddbaada871a748d39c6e4db03",
"extension": "py",
"fi... | 2.6875 | stackv2 | from flask import Flask, request
import urllib.request
import requests
import time
from threading import Timer
app = Flask(__name__)
app.config['DEBUG'] = False
print("START __ 0001")
check_if_one = 0
what_now = 0
number_of_repeats = 0
sleeping_time = 0
link = ""
@app.route("/btn_find")
def get_ses():
global che... | 148 | 22.83 | 74 | 14 | 981 | python | [{"finding_id": "codeql_py/full-ssrf_03b1d37a05d8fb0e_64376c39", "tool_name": "codeql", "rule_id": "py/full-ssrf", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "The full URL of this request depends on a [user-provided value](1).", "remediation": "", "location": {"file_path": "u... | 2 | true | [
"CWE-918",
"CWE-079"
] | [
"py/full-ssrf",
"py/reflective-xss"
] | [
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM"
] | [
"The full URL of this request depends on a [user-provided value](1).",
"Cross-site scripting vulnerability due to a [user-provided value](1).\nCross-site scripting vulnerability due to a [user-provided value](1)."
] | [
89,
83
] | [
null,
null
] | [
13,
12
] | [
28,
16
] | |
2024-11-19T02:07:01.253064+00:00 | 1,646,523,129,000 | 698272209cf8b31d998162ee517432c3b2814980 | 2 | {
"blob_id": "698272209cf8b31d998162ee517432c3b2814980",
"branch_name": "refs/heads/master",
"committer_date": 1646523129000,
"content_id": "56af8ee41bebd6d3a5611f415bf4de830319d9ab",
"detected_licenses": [
"MIT"
],
"directory_id": "d7da6fcf9be7cd88dfe5e447cb9b2dd78fc2bfaf",
"extension": "py",
"fi... | 2.3125 | stackv2 | """
@file
@brief Extends :epkg:`Sphinx` to easily write documentation with :epkg:`ML.net`.
"""
import os
import jinja2
import sphinx
from sphinx.util import logging
from pyquickhelper.sphinxext.sphinx_runpython_extension import RunPythonDirective
from csharpy.sphinxext import RunCSharpDirective
from ..binaries import g... | 270 | 35.87 | 116 | 22 | 2,171 | python | [{"finding_id": "codeql_py/jinja2/autoescape-false_d76e7c6a68a976ae_2f9f9c04", "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... | 3 | true | [
"CWE-079",
"CWE-079",
"CWE-079"
] | [
"py/jinja2/autoescape-false",
"py/jinja2/autoescape-false",
"py/jinja2/autoescape-false"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"Using jinja2 templates with autoescape=False can potentially allow XSS attacks.",
"Using jinja2 templates with autoescape=False can potentially allow XSS attacks.",
"Using jinja2 templates with autoescape=False can potentially allow XSS attacks."
] | [
143,
146,
147
] | [
null,
null,
null
] | [
16,
16,
16
] | [
47,
46,
51
] | |
2024-11-19T02:07:04.408362+00:00 | 1,548,448,710,000 | 4bc4e5794e645bd44d313a14cd73e1c82b6d964c | 3 | {
"blob_id": "4bc4e5794e645bd44d313a14cd73e1c82b6d964c",
"branch_name": "refs/heads/master",
"committer_date": 1548448710000,
"content_id": "5d18621bf94d41bc5a3f3a23c6f35f32121bd8e6",
"detected_licenses": [
"CC0-1.0"
],
"directory_id": "7295e3c3f50e67e84ff05d8b5f06899a863e3e4a",
"extension": "py",
... | 2.6875 | stackv2 | import sys
import yaml
import jinja2
class DuplicateValueException(Exception):
pass
def assert_field_unique(iterable, key):
seen_values = set()
for obj in iterable:
if key in obj:
assert obj[key] not in seen_values
seen_values.add(obj[key])
return True
def parse(ya... | 49 | 25.16 | 79 | 16 | 258 | python | [{"finding_id": "codeql_py/jinja2/autoescape-false_66e07195314e6b74_9f30c45c", "tool_name": "codeql", "rule_id": "py/jinja2/autoescape-false", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Using jinja2 templates with autoescape=False can potentially allow XSS attacks.", "remediati... | 1 | true | [
"CWE-079"
] | [
"py/jinja2/autoescape-false"
] | [
"MEDIUM"
] | [
"MEDIUM"
] | [
"Using jinja2 templates with autoescape=False can potentially allow XSS attacks."
] | [
21
] | [
null
] | [
23
] | [
51
] | |
2024-11-19T02:07:09.698975+00:00 | 1,579,220,868,000 | 5546983243a366aa1f1f2387567bd429f5924c91 | 2 | {
"blob_id": "5546983243a366aa1f1f2387567bd429f5924c91",
"branch_name": "refs/heads/master",
"committer_date": 1579220868000,
"content_id": "d9db77b521998121b380063cdcbab78dd9ff8c39",
"detected_licenses": [
"MIT"
],
"directory_id": "8a5a9299add9556c010b3988825a229d15af6813",
"extension": "py",
"fi... | 2.484375 | stackv2 | """
Routes and views for the flask application.
"""
from datetime import datetime
from flask import *
from Image_Detection import app
from Image_Detection.predict import *
import os
import requests
from werkzeug.utils import secure_filename
app.secret_key = 'vzP7jO/N4kXnLsutcCRe6mYBFoJnLevSNbf0uB6J'
@app.route('/... | 74 | 27.99 | 94 | 17 | 449 | python | [{"finding_id": "codeql_py/full-ssrf_b2a58f08373b4f83_45ffbe64", "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).\nThe full URL of this request depends on a [user-... | 3 | true | [
"CWE-918",
"CWE-601",
"CWE-601"
] | [
"py/full-ssrf",
"py/url-redirection",
"py/url-redirection"
] | [
"HIGH",
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"The full URL of this request depends on a [user-provided value](1).\nThe full URL of this request depends on a [user-provided value](2).\nThe full URL of this request depends on a [user-provided value](3).",
"Untrusted URL redirection depends on a [user-provided value](1).\nUntrusted URL redirection depends on a... | [
60,
45,
52
] | [
null,
null,
null
] | [
17,
33,
33
] | [
39,
44,
44
] | |
2024-11-19T02:07:21.023649+00:00 | 1,522,655,381,000 | a57eef9c4521a6b993627afbdb2f3915eae3af3c | 3 | {
"blob_id": "a57eef9c4521a6b993627afbdb2f3915eae3af3c",
"branch_name": "refs/heads/master",
"committer_date": 1522655381000,
"content_id": "6c00fe3cba1066aa653e126da08c49bfb9e08520",
"detected_licenses": [
"MIT"
],
"directory_id": "52b8ee7d2f6fdecd34774ba33b2e4b780d2c17a1",
"extension": "py",
"fi... | 2.859375 | stackv2 | import sqlite3
from flask import Flask, render_template, request
app = Flask(__name__)
conn = sqlite3.connect('main.db')
def is_valid_card_id(cardid):
return True
@app.route("/")
def index():
return "Hello world"
@app.route("/checkin/<rid>")
def checkin(rid):
"""
- check trang thai
- topup page
... | 41 | 22.9 | 87 | 12 | 273 | python | [{"finding_id": "codeql_py/flask-debug_041c282280e5a222_b0473505", "tool_name": "codeql", "rule_id": "py/flask-debug", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", ... | 2 | true | [
"CWE-215",
"CWE-079"
] | [
"py/flask-debug",
"py/reflective-xss"
] | [
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM"
] | [
"A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.",
"Cross-site scripting vulnerability due to a [user-provided value](1)."
] | [
41,
23
] | [
null,
null
] | [
5,
16
] | [
24,
48
] | |
2024-11-19T02:07:25.712981+00:00 | 1,641,036,951,000 | 441789d3715f05d9236c75afb5e5b1c62bcb816e | 2 | {
"blob_id": "441789d3715f05d9236c75afb5e5b1c62bcb816e",
"branch_name": "refs/heads/master",
"committer_date": 1641036951000,
"content_id": "a800d76793a9c52b28953db2c410d965515a6f78",
"detected_licenses": [
"MIT"
],
"directory_id": "c40045b23a2580447f237c23cd9fe8a986aae41a",
"extension": "py",
"fi... | 2.34375 | stackv2 | import os
from flask import request, redirect, url_for, render_template, Blueprint, current_app
from werkzeug.utils import secure_filename
main = Blueprint('main', __name__)
@main.route('/')
@main.route('/home')
def home():
os.makedirs("uploads/", exist_ok=True)
return render_template('home.html')
@main.r... | 38 | 31.08 | 85 | 16 | 252 | python | [{"finding_id": "codeql_py/url-redirection_762fedce06fc9df6_f0f1185e", "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)."
] | [
33
] | [
null
] | [
21
] | [
32
] | |
2024-11-19T02:31:38.784828+00:00 | 1,610,849,939,000 | 03860027ebeeba748536a250599d8623075483bf | 2 | {
"blob_id": "03860027ebeeba748536a250599d8623075483bf",
"branch_name": "refs/heads/master",
"committer_date": 1610849939000,
"content_id": "8df95184dea6dcb6cf9a178d155cc1f090c089d6",
"detected_licenses": [
"BSD-3-Clause"
],
"directory_id": "7182c241bc380f00dbb47536ffb0d7e16b205fc9",
"extension": "p... | 2.359375 | stackv2 | import os
import tempfile
from collections.abc import Generator
from typing import Iterable, List
import jinja2
from snapflow.storage.data_formats import Records
from snapflow.utils.common import rand_str
from sqlalchemy.engine import ResultProxy, RowProxy
def result_proxy_to_records(
result_proxy: ResultProxy, ... | 77 | 26.9 | 86 | 13 | 516 | python | [{"finding_id": "codeql_py/jinja2/autoescape-false_f529ec479cd3ea92_aff1b449", "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."
] | [
48
] | [
52
] | [
11
] | [
6
] | |
2024-11-19T02:31:40.757528+00:00 | 1,541,899,974,000 | e2d964236fb21658bbc107f0ac1009810b6213b1 | 3 | {
"blob_id": "e2d964236fb21658bbc107f0ac1009810b6213b1",
"branch_name": "refs/heads/master",
"committer_date": 1541899974000,
"content_id": "71e34cac9c60700c6dbb806d1492ae698407eca0",
"detected_licenses": [
"MIT"
],
"directory_id": "02bfbdbe2b2e70d5d1fdf5075e17b883d25d4334",
"extension": "py",
"fi... | 3.125 | stackv2 | # coding:utf-8
# 豆瓣爬虫核心方法
from __future__ import unicode_literals
from jinja2 import Environment, FileSystemLoader
import sys
reload(sys)
sys.setdefaultencoding('utf-8')
class TableTplRender(object):
'''
通用的HTML表格渲染工具
'''
def __init__(self, title, keys, data_dicts):
'''
初始化
:p... | 71 | 22.77 | 103 | 14 | 461 | python | [{"finding_id": "codeql_py/jinja2/autoescape-false_c6b0b34a364cf9f0_9dfb5523", "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."
] | [
35
] | [
null
] | [
15
] | [
67
] | |
2024-11-19T02:31:49.757015+00:00 | 1,446,702,840,000 | a631c15b31e76913fea2cd9045494ac84e8e4ace | 3 | {
"blob_id": "a631c15b31e76913fea2cd9045494ac84e8e4ace",
"branch_name": "refs/heads/master",
"committer_date": 1446702840000,
"content_id": "e90d83df90674fa790d66a0a3307ff13f8a7e803",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "cad54953185ac478042a5e0e9ef169195be8c3d4",
"extension": "py"... | 2.578125 | stackv2 | import datetime
import nutchpy
import os
import sys
import time
import re
#Constants and fields used
crawlFolder = ""
crawlDbPath = ""
linkDbPath = ""
segmentsPath = ""
statisticsPath = ""
count1 = 0;
count2 = 0;
count3 = 0;
count4 = 0;
count5 = 0;
count6 = 0;
count7 = 0;
totalImages = 0;
totalRecordCount = 0;
counts... | 192 | 35.68 | 170 | 20 | 1,974 | python | [{"finding_id": "codeql_py/overly-permissive-file_b7e9c8dab82b1ad5_74fc76f4", "tool_name": "codeql", "rule_id": "py/overly-permissive-file", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "Overly permissive mask in chmod sets file to world writable.", "remediation": "", "location": ... | 2 | true | [
"CWE-732",
"CWE-732"
] | [
"py/overly-permissive-file",
"py/overly-permissive-file"
] | [
"MEDIUM",
"MEDIUM"
] | [
"MEDIUM",
"MEDIUM"
] | [
"Overly permissive mask in chmod sets file to world writable.",
"Overly permissive mask in chmod sets file to world writable."
] | [
160,
163
] | [
null,
null
] | [
3,
3
] | [
30,
30
] | |
2024-11-19T02:31:54.583602+00:00 | 1,601,532,187,000 | f8538d535637931cc5d9bacaea3154d323cb4c05 | 3 | {
"blob_id": "f8538d535637931cc5d9bacaea3154d323cb4c05",
"branch_name": "refs/heads/master",
"committer_date": 1601532187000,
"content_id": "2ede681c0c70b8bba5a56598fc61319ddb628dbc",
"detected_licenses": [
"MIT"
],
"directory_id": "ce15c1bf95e7bd1621c6bacaa114704e4b45bb74",
"extension": "py",
"fi... | 2.859375 | stackv2 | import requests
from bs4 import BeautifulSoup
profile_urls = [] #To store the Profile URLs
ctr = 0 #To traverse through Google results pages
#Loop through first 15 pages
#(10 per page, so count 15*10=150)
while ctr < 150:
query = 'https://google.com/search?q=site:linkedin.com/in \
AND "Technical Recruiter" AN... | 25 | 24.72 | 61 | 15 | 181 | python | [{"finding_id": "codeql_py/incomplete-url-substring-sanitization_533d5b67807adf58_66d6ad1a", "tool_name": "codeql", "rule_id": "py/incomplete-url-substring-sanitization", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "The string [https://www.linkedin.com/](1) may be at an arbitrary p... | 1 | true | [
"CWE-020"
] | [
"py/incomplete-url-substring-sanitization"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"The string [https://www.linkedin.com/](1) may be at an arbitrary position in the sanitized URL."
] | [
16
] | [
null
] | [
8
] | [
42
] | |
2024-11-19T02:31:56.047731+00:00 | 1,543,751,719,000 | bc28c45d36dfc91ad7840a4e34d529e276322d0e | 3 | {
"blob_id": "bc28c45d36dfc91ad7840a4e34d529e276322d0e",
"branch_name": "refs/heads/master",
"committer_date": 1543751719000,
"content_id": "00ed0e41f58d272b4f5fbde370d7cd8820dcbbe0",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "af59b7a26f2ed5fa5dd28a15e09124f672e9bdf0",
"extension": "py"... | 2.875 | stackv2 | from __future__ import annotations
import requests
from requests.auth import HTTPBasicAuth
from dataclasses import dataclass, asdict
from mashumaro import DataClassJSONMixin
@dataclass
class Response(DataClassJSONMixin):
statusCode: int = 200
body: str = ''
@classmethod
def of(cls, status_code: int, ... | 48 | 25.4 | 83 | 16 | 305 | python | [{"finding_id": "codeql_py/request-without-cert-validation_60bef56d14a64b61_be8ba946", "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)."
] | [
27
] | [
32
] | [
12
] | [
19
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.