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-18T22:55:05.106398+00:00 | 1,570,494,782,000 | df14f3b0f47cf8017aed02bd7fabf2f314a214b8 | 3 | {
"blob_id": "df14f3b0f47cf8017aed02bd7fabf2f314a214b8",
"branch_name": "refs/heads/master",
"committer_date": 1570494786000,
"content_id": "b40e9592fe62c2017e79612d2b201dbc82a4fb4e",
"detected_licenses": [
"MIT"
],
"directory_id": "07050a66c5c0efc07c0d9804472329bfd1a06cd2",
"extension": "py",
"fi... | 2.609375 | stackv2 | import os
import sys
import pathlib
from utilities import get_random_hash
from flask import Flask, flash, request, redirect, url_for, send_from_directory, jsonify, Response
UPLOAD_FOLDER = os.environ.get('UPLOAD_FOLDER') if os.environ.get('UPLOAD_FOLDER') else '/tmp'
ALLOWED_EXTENSIONS = {'txt', 'pdf', 'png', 'jpg', '... | 110 | 24.16 | 98 | 15 | 555 | python | [{"finding_id": "codeql_py/path-injection_80f2ad3dace931fd_0cc5a589", "tool_name": "codeql", "rule_id": "py/path-injection", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This path depends on a [user-provided value](1).", "remediation": "", "location": {"file_path": "unknown", ... | 2 | true | [
"CWE-022",
"CWE-022"
] | [
"py/path-injection",
"py/path-injection"
] | [
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM"
] | [
"This path depends on a [user-provided value](1).",
"This path depends on a [user-provided value](1)."
] | [
43,
46
] | [
null,
null
] | [
23,
19
] | [
31,
27
] | |
2024-11-18T23:05:57.980929+00:00 | 1,626,757,434,000 | 9c33afd8db987abf9abd36a748ab8a76b0f1f6ca | 3 | {
"blob_id": "9c33afd8db987abf9abd36a748ab8a76b0f1f6ca",
"branch_name": "refs/heads/main",
"committer_date": 1626757434000,
"content_id": "f5dd87bd097723bb808a97f30c403747c4617d42",
"detected_licenses": [
"MIT"
],
"directory_id": "5efb67e5b9cf6dcb2c47e6e11555ffef2418984a",
"extension": "py",
"file... | 2.546875 | stackv2 | from datetime import datetime
from app.models import SplunkSIEM
import requests
import pandas as pd
import typing
import urllib3
import json
urllib3.disable_warnings(urllib3.exceptions.InsecureRequestWarning)
def signIn(siem: SplunkSIEM) -> str:
"""
Sign into Splunk and return session key
"""
try:
... | 191 | 36.62 | 127 | 19 | 1,833 | python | [{"finding_id": "codeql_py/request-without-cert-validation_33e3e334c61b8758_53d847d4", "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]... | 7 | true | [
"CWE-295",
"CWE-295",
"CWE-295",
"CWE-295",
"CWE-295",
"CWE-295",
"CWE-295"
] | [
"py/request-without-cert-validation",
"py/request-without-cert-validation",
"py/request-without-cert-validation",
"py/request-without-cert-validation",
"py/request-without-cert-validation",
"py/request-without-cert-validation",
"py/request-without-cert-validation"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"This request may run without certificate validation because [it is disabled](1).",
"This request may run without certificate validation because [it is disabled](1).",
"This request may run without certificate validation because [it is disabled](1).",
"This request may run without certificate validation becau... | [
15,
35,
58,
74,
98,
119,
160
] | [
19,
40,
63,
79,
108,
124,
164
] | [
23,
13,
13,
13,
13,
13,
13
] | [
10,
10,
10,
10,
10,
10,
14
] | |
2024-11-18T20:56:51.729557+00:00 | 1,596,216,855,000 | 2e08db0824526c4a4285873e508226bba0474005 | 3 | {
"blob_id": "2e08db0824526c4a4285873e508226bba0474005",
"branch_name": "refs/heads/master",
"committer_date": 1596216855000,
"content_id": "127bafe3b42da3e374839efd042d10539cc6d79f",
"detected_licenses": [
"MIT"
],
"directory_id": "ab875e0135e61a26d33c1aa96678a259b33b55f3",
"extension": "py",
"fi... | 2.578125 | stackv2 | from os import environ
from re import compile as comp
from copy import copy
from pprint import pformat
from typing import List, Optional, Union, Dict, Tuple
from urllib.parse import quote_plus
from requests import post, RequestException, Response
def post_message(
url: str,
headers: Dict[str, str],
body:... | 117 | 32.01 | 108 | 19 | 995 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_c60c93e8b35ddece_052479cb", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (password)](1) as clear text.", ... | 3 | true | [
"CWE-312",
"CWE-312",
"CWE-312"
] | [
"py/clear-text-logging-sensitive-data",
"py/clear-text-logging-sensitive-data",
"py/clear-text-logging-sensitive-data"
] | [
"HIGH",
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"This expression logs [sensitive data (password)](1) as clear text.",
"This expression logs [sensitive data (password)](1) as clear text.",
"This expression logs [sensitive data (password)](1) as clear text."
] | [
92,
95,
100
] | [
null,
null,
null
] | [
11,
15,
15
] | [
23,
28,
35
] | |
2024-11-18T20:56:58.410087+00:00 | 1,619,274,636,000 | 5bdd17e155fb42dab9d47bbe7d0adbf33ae375a3 | 2 | {
"blob_id": "5bdd17e155fb42dab9d47bbe7d0adbf33ae375a3",
"branch_name": "refs/heads/master",
"committer_date": 1619274636000,
"content_id": "2be8dc516d01fc90b8b3cb5592a2da91291270eb",
"detected_licenses": [
"MIT"
],
"directory_id": "5ddcbbecbaa4874cb69287bd2b035dc4d2481fb4",
"extension": "py",
"fi... | 2.375 | stackv2 | import os, platform, subprocess
import plistlib
import re, json
import time
import requests
def get_mac_list():
if platform.system() == 'Windows':
results = subprocess.check_output(["netsh", "wlan", "show", "network", "bssid"])
results = results.decode("ascii", errors='ignore') # needed in python ... | 134 | 46.51 | 134 | 22 | 1,507 | python | [{"finding_id": "codeql_py/clear-text-storage-sensitive-data_4dccf9b3d536280f_052af20b", "tool_name": "codeql", "rule_id": "py/clear-text-storage-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression stores [sensitive data (password)](1) as clear text."... | 2 | true | [
"CWE-312",
"CWE-312"
] | [
"py/clear-text-storage-sensitive-data",
"py/clear-text-storage-sensitive-data"
] | [
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM"
] | [
"This expression stores [sensitive data (password)](1) as clear text.",
"This expression stores [sensitive data (password)](1) as clear text."
] | [
83,
88
] | [
86,
null
] | [
17,
23
] | [
47,
33
] | |
2024-11-18T20:57:01.725411+00:00 | 1,626,056,567,000 | 94376e3f2c927d612260f729738c770f3e6764ba | 3 | {
"blob_id": "94376e3f2c927d612260f729738c770f3e6764ba",
"branch_name": "refs/heads/master",
"committer_date": 1626056567000,
"content_id": "4fb477e03ae0fbf8ba11480307d236b4618c8855",
"detected_licenses": [
"MIT"
],
"directory_id": "d317898dbd0747852fcdb81d7d4ec1ac7ceb9269",
"extension": "py",
"fi... | 2.59375 | stackv2 | """Translate via googlge translate."""
from typing import Union
import json
# from urllib.parse import (quote, urlencode,)
# import urllib3
from datetime import datetime
from joblib import Memory
import httpx
from logzero import logger
# urllib3.disable_warnings(urllib3.exceptions.InsecureRequestWarning)
location = ... | 168 | 29.99 | 141 | 17 | 1,409 | python | [{"finding_id": "codeql_py/request-without-cert-validation_7f6cfa7b442309fb_7e396a6c", "tool_name": "codeql", "rule_id": "py/request-without-cert-validation", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "This request may run without certificate validation because [it is disabled]... | 1 | true | [
"CWE-295"
] | [
"py/request-without-cert-validation"
] | [
"MEDIUM"
] | [
"MEDIUM"
] | [
"This request may run without certificate validation because [it is disabled](1) by [this value](2).\nThis request may run without certificate validation because [it is disabled](1) by [this value](3).\nThis request may run without certificate validation because [it is disabled](4) by [this value](2).\nThis request... | [
144
] | [
null
] | [
16
] | [
61
] | |
2024-11-18T22:43:25.688369+00:00 | 1,672,238,311,000 | 1fa341714c7275a2e3fe155114a49386b533a3f2 | 2 | {
"blob_id": "1fa341714c7275a2e3fe155114a49386b533a3f2",
"branch_name": "refs/heads/master",
"committer_date": 1672238311000,
"content_id": "c6e625354f72a49a3bfa87f829e31b4282fc4c8e",
"detected_licenses": [
"MIT"
],
"directory_id": "0e05e9b9fb2b428f950d9e142ab4efaa43b7d163",
"extension": "py",
"fi... | 2.46875 | stackv2 | import requests
import json
import mypsw
import urllib3
group_set = {"BINANCE":5}
def get_prediction(group,openID):
urllib3.disable_warnings()
if group not in group_set:
return ""
url = "https://35.236.157.42/api/v1/predict_batch?group=" + str(group) + "&secret=" + mypsw.api_secret
response = ... | 41 | 29.83 | 106 | 18 | 372 | python | [{"finding_id": "codeql_py/request-without-cert-validation_3045a2b3170b4631_e3b34d73", "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)."
] | [
13
] | [
null
] | [
16
] | [
46
] | |
2024-11-18T22:43:30.260195+00:00 | 1,454,251,777,000 | c00f55e266e69a099d87f109941c9e940c1349c5 | 3 | {
"blob_id": "c00f55e266e69a099d87f109941c9e940c1349c5",
"branch_name": "refs/heads/master",
"committer_date": 1454251777000,
"content_id": "54b85ed093dcc344df3d4b56a1a5419d34893a54",
"detected_licenses": [
"MIT"
],
"directory_id": "427bd46a3c376cb99b9cef2f6016f2004c0b8ff0",
"extension": "py",
"fi... | 2.5625 | stackv2 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
""" Convert Markdown file to html, which is embeded in html template.
"""
from __future__ import (print_function, with_statement, unicode_literals,
absolute_import)
import os
import os.path
import io
import copy
import traceback
try:
from coll... | 324 | 32.29 | 86 | 18 | 2,334 | python | [{"finding_id": "codeql_py/jinja2/autoescape-false_f23b8177964400ff_b96342a9", "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."
] | [
50
] | [
52
] | [
20
] | [
10
] | |
2024-11-18T22:43:37.616912+00:00 | 1,576,370,585,000 | dbb115ea6936ed44cb819620aab632bf394298b2 | 2 | {
"blob_id": "dbb115ea6936ed44cb819620aab632bf394298b2",
"branch_name": "refs/heads/master",
"committer_date": 1576370585000,
"content_id": "3cd93e2419abef575f51c850a98a13ee91c3acff",
"detected_licenses": [
"MIT"
],
"directory_id": "4e14e9edbbcdb97e8fe7bb234613bebb00c70d5e",
"extension": "py",
"fi... | 2.484375 | stackv2 | import json
import logging
import os
import subprocess
import sys
import click
import requests
from flask import Flask, Response, jsonify, request
from value_worker.worker import ValueWorker
logging.basicConfig(filename='worker.log', filemode='w', level=logging.INFO)
def create_server(app, gw):
""" Consists o... | 183 | 36.84 | 176 | 18 | 1,582 | python | [{"finding_id": "codeql_py/log-injection_084e44bcd6efffdc_0828a885", "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)."
] | [
30
] | [
null
] | [
26
] | [
81
] | |
2024-11-18T21:33:37.850352+00:00 | 1,636,429,223,000 | 172578827de95b13334435ac079add52652e0f2e | 2 | {
"blob_id": "172578827de95b13334435ac079add52652e0f2e",
"branch_name": "refs/heads/master",
"committer_date": 1636429223000,
"content_id": "1684aefe8cd6b400fb767ec6f1ce3ae2a9c8db3c",
"detected_licenses": [
"MIT"
],
"directory_id": "6f2112a8fc041a273445db4880c3e8c392658b56",
"extension": "py",
"fi... | 2.484375 | stackv2 | # The MIT License (MIT)
#
# Copyright (c) 2019 Sharad Raj Singh Maurya
#
# 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,... | 106 | 35.14 | 166 | 16 | 811 | python | [{"finding_id": "codeql_py/jinja2/autoescape-false_1749fe5959b30ebc_d77a1dc6", "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."
] | [
53
] | [
null
] | [
12
] | [
48
] | |
2024-11-18T21:33:44.284768+00:00 | 1,641,375,761,000 | 08a03df1de9da4688b1af85c988d438fc1adf022 | 3 | {
"blob_id": "08a03df1de9da4688b1af85c988d438fc1adf022",
"branch_name": "refs/heads/master",
"committer_date": 1641402808000,
"content_id": "e0ebc3592003275a43546f5754c4a673dade556b",
"detected_licenses": [
"ISC"
],
"directory_id": "95fc8eb803bc08c3708a65b7284c1bccfae5a10f",
"extension": "py",
"fi... | 2.84375 | stackv2 | """ Summarize output from ASE.md class (in md.log) """
import json
import shutil
import subprocess
import tarfile
import tempfile
from argparse import ArgumentParser
from pathlib import Path
from vibes import Settings
from vibes.helpers import Timer, talk
new_addr = "http://repository.nomad-coe.eu/app/api/uploads/?t... | 151 | 26.03 | 86 | 15 | 1,019 | python | [{"finding_id": "codeql_py/tarslip_c7b77176665eaab6_a2ca458a", "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).\nThis file extraction depends on a [potentially un... | 1 | true | [
"CWE-022"
] | [
"py/tarslip"
] | [
"MEDIUM"
] | [
"MEDIUM"
] | [
"This file extraction depends on a [potentially untrusted source](1).\nThis file extraction depends on a [potentially untrusted source](1)."
] | [
111
] | [
null
] | [
17
] | [
18
] | |
2024-11-18T22:30:25.160303+00:00 | 1,613,431,112,000 | 17e87e6aa95d5bf2b259c1ed7e87a4705201415d | 2 | {
"blob_id": "17e87e6aa95d5bf2b259c1ed7e87a4705201415d",
"branch_name": "refs/heads/master",
"committer_date": 1613431112000,
"content_id": "d3cc13a44a00b580762d51fc713edec9e622448d",
"detected_licenses": [
"MIT"
],
"directory_id": "200d4c8d26774e4517755568459a3d11a4b746b8",
"extension": "py",
"fi... | 2.359375 | stackv2 | from datetime import datetime
import re
import json
import requests
import hashlib
from os.path import basename
from config import ( hour24, journalsFilesFormat, journalsFilesExtension, journalsFolder,
journalsPrefix,getFirebaseBucketName, getlastNewsDisplayed, setlastNewsDisplayed
... | 220 | 29.35 | 125 | 27 | 1,778 | python | [{"finding_id": "codeql_py/overly-large-range_0d4c184fff7880cc_e4609dc3", "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\\\\[\\\\\\\\]^_\\].", ... | 1 | true | [
"CWE-020"
] | [
"py/overly-large-range"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"Suspicious character range that is equivalent to \\[$%&'()*+,\\-.\\/0-9:;<=>?@A-Z\\\\[\\\\\\\\]^_\\]."
] | [
60
] | [
null
] | [
52
] | [
55
] | |
2024-11-18T22:44:42.328201+00:00 | 1,625,734,832,000 | 3384587f349d5776159b8d19352422c20e9c14c4 | 4 | {
"blob_id": "3384587f349d5776159b8d19352422c20e9c14c4",
"branch_name": "refs/heads/main",
"committer_date": 1625734832000,
"content_id": "ca8a355754a1943388c0c4005eed449eee568499",
"detected_licenses": [
"MIT"
],
"directory_id": "e1db2d4d1c766b8921372d5d80e8467b35834066",
"extension": "py",
"file... | 3.84375 | stackv2 |
import random
import os
def random_string(string):
tmpList = list(string)
random.shuffle(tmpList)
return ''.join(tmpList)
while(True):
print("1.Generate password\n")
print("2.Exit program\n")
option = int(input("Your option: "))
if(option == None):
print("Please enter option")
... | 29 | 27.07 | 117 | 15 | 190 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_f3b49ab60c4799fd_a89fe8f6", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (password)](1) as clear text.\nT... | 1 | true | [
"CWE-312"
] | [
"py/clear-text-logging-sensitive-data"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"This expression logs [sensitive data (password)](1) as clear text.\nThis expression logs [sensitive data (password)](2) as clear text.\nThis expression logs [sensitive data (password)](3) as clear text."
] | [
22
] | [
null
] | [
34
] | [
42
] | |
2024-11-18T23:37:04.020828+00:00 | 1,545,168,028,000 | 799a0f0dfcbc9604cc300efb2ea20be2054b9b8a | 3 | {
"blob_id": "799a0f0dfcbc9604cc300efb2ea20be2054b9b8a",
"branch_name": "refs/heads/master",
"committer_date": 1545168028000,
"content_id": "64aecede6cc1adbf3d0d329ecd397d126101c03d",
"detected_licenses": [
"MIT"
],
"directory_id": "0bf3999ded3fc81403fd779b2d9317b86e4863e6",
"extension": "py",
"fi... | 2.671875 | stackv2 | from flask import Flask, redirect, url_for
app = Flask(__name__)
@app.route('/blog/<int:postID>')
def show_blog(postID):
return 'Blog Number %d' % postID
@app.route('/rev/<float:revNo>')
def revision(revNo):
return 'Revision Number %f' % revNo
@app.route('/admin')
def hello_admin():
return 'Hello Admin'
@ap... | 35 | 16.74 | 53 | 14 | 160 | python | [{"finding_id": "codeql_py/reflective-xss_8344e77d2b4a4097_fa22f432", "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... | 3 | true | [
"CWE-079",
"CWE-079",
"CWE-079"
] | [
"py/reflective-xss",
"py/reflective-xss",
"py/reflective-xss"
] | [
"HIGH",
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"Cross-site scripting vulnerability due to a [user-provided value](1).",
"Cross-site scripting vulnerability due to a [user-provided value](1).",
"Cross-site scripting vulnerability due to a [user-provided value](1)."
] | [
8,
13,
23
] | [
null,
null,
null
] | [
9,
9,
9
] | [
34,
37,
36
] | |
2024-11-18T23:37:04.988142+00:00 | 1,554,938,422,000 | 4f03976408ec161698be70495b81352e7b2b21c8 | 3 | {
"blob_id": "4f03976408ec161698be70495b81352e7b2b21c8",
"branch_name": "refs/heads/master",
"committer_date": 1554938422000,
"content_id": "e1292d8ab15af38734806e3edc0a4329d9d41229",
"detected_licenses": [
"Unlicense"
],
"directory_id": "cfad0044a5d50be42ff78651b1f1460f3dadb014",
"extension": "py",... | 3.359375 | stackv2 | import re
import os
def accountcreation():
username=input("Enter your username: ")
password=input("Enter your password: ")
with open('Login.txt', 'a') as file:
file.writelines(username + "," + password + "\n")
with open('Accountbook.txt', 'a') as file:
file.writelines(usern... | 170 | 29.18 | 109 | 16 | 1,259 | python | [{"finding_id": "codeql_py/clear-text-storage-sensitive-data_a5c5b7b2b6341ba6_e813f974", "tool_name": "codeql", "rule_id": "py/clear-text-storage-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression stores [sensitive data (password)](1) as clear text."... | 1 | true | [
"CWE-312"
] | [
"py/clear-text-storage-sensitive-data"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"This expression stores [sensitive data (password)](1) as clear text."
] | [
11
] | [
null
] | [
25
] | [
57
] | |
2024-11-18T23:37:05.174177+00:00 | 1,444,477,357,000 | 5f57f0c6c73b00f1eb70b3a36a029f969586aef1 | 3 | {
"blob_id": "5f57f0c6c73b00f1eb70b3a36a029f969586aef1",
"branch_name": "refs/heads/master",
"committer_date": 1444477357000,
"content_id": "913be9875c773bbdd5ae58346d8a108b775cfce4",
"detected_licenses": [
"MIT"
],
"directory_id": "fa4ac8cca78381cc7a9857d8fe6e8c2c8b0fd4bb",
"extension": "py",
"fi... | 2.578125 | stackv2 | import torndb
import hashlib
#The MIT License (MIT)
#Copyright (c) 2015 Bostjan Jerko
#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 rig... | 63 | 40.68 | 152 | 15 | 610 | python | [{"finding_id": "codeql_py/weak-sensitive-data-hashing_a856232b3052f4cc_a55acc13", "tool_name": "codeql", "rule_id": "py/weak-sensitive-data-hashing", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "[Sensitive data (password)](1) is used in a hashing algorithm (MD5) that is insec... | 1 | true | [
"CWE-327"
] | [
"py/weak-sensitive-data-hashing"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"[Sensitive data (password)](1) is used in a hashing algorithm (MD5) that is insecure for password hashing, since it is not a computationally expensive hash function."
] | [
43
] | [
null
] | [
121
] | [
129
] | |
2024-11-18T23:37:07.765857+00:00 | 1,577,491,776,000 | 1afb42962a4c8aba9288effcde25cd826b509e3a | 3 | {
"blob_id": "1afb42962a4c8aba9288effcde25cd826b509e3a",
"branch_name": "refs/heads/master",
"committer_date": 1577491776000,
"content_id": "42d3a1a49542950491987e70c72a1216025ab101",
"detected_licenses": [
"MIT"
],
"directory_id": "a39298f7fea460186497edd2ef0e03cff640a8e1",
"extension": "py",
"fi... | 3.203125 | stackv2 | #!/usr/bin/env python
"""
MQTT sender, which sends countdown information for ISS (international space station) until it is
overhead.
This Python 3 code uses the **iss_overhead** class to forecast, when ISS is overhead, by providing
coordinates for a given location. See the **iss_overhead** documentation for more det... | 82 | 32.61 | 156 | 13 | 599 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_e301333148fe84c1_9da22b69", "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."
] | [
29,
30
] | [
null,
null
] | [
7,
14
] | [
146,
156
] | |
2024-11-18T21:14:41.024958+00:00 | 1,693,203,317,000 | 3c57491f9dfc8b3c384dcc83051a6545864d9f27 | 3 | {
"blob_id": "3c57491f9dfc8b3c384dcc83051a6545864d9f27",
"branch_name": "refs/heads/master",
"committer_date": 1693203317000,
"content_id": "6b0203e771e863723fe070377f2be97aca10b7de",
"detected_licenses": [
"MIT"
],
"directory_id": "e3258f186ce3aa841891eb56213ade500c258fb4",
"extension": "py",
"fi... | 3.03125 | stackv2 | import requests
import os
from tqdm import tqdm
import urllib3
urllib3.disable_warnings(urllib3.exceptions.InsecureRequestWarning)
def _download_pb(url: str, fname: str, total: int = None):
"""Useful function to get request with a progress bar
Borrowed from
https://gist.github.com/yanqd0/c13ed29e29432e3c... | 38 | 27.39 | 88 | 13 | 290 | python | [{"finding_id": "codeql_py/request-without-cert-validation_e5f184f7614f3341_a52bf156", "tool_name": "codeql", "rule_id": "py/request-without-cert-validation", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "This request may run without certificate validation because [it is disabled]... | 1 | true | [
"CWE-295"
] | [
"py/request-without-cert-validation"
] | [
"MEDIUM"
] | [
"MEDIUM"
] | [
"This request may run without certificate validation because [it is disabled](1)."
] | [
24
] | [
null
] | [
12
] | [
73
] | |
2024-11-18T21:57:26.935486+00:00 | 1,369,769,613,000 | c672fa8f844196632856b911158f98c64b0cf70e | 3 | {
"blob_id": "c672fa8f844196632856b911158f98c64b0cf70e",
"branch_name": "refs/heads/master",
"committer_date": 1369769613000,
"content_id": "6a90b730fe25dae7c28e804e5d24e7dd620a3ca7",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "c7f5880b8740c745b1e553719f25821e006f8d82",
"extension": "py"... | 2.78125 | stackv2 | import os
import datetime
import time
import paramiko
watch_dir = '/home/jlabarba/Desktop/'
class TriggerError(Exception):
'''
base class for categorizing non-fatal trigger func errors
'''
pass
class SSHConnection:
def __init__(self, server, port, user, password=''):
self.client = paramik... | 148 | 33.51 | 141 | 19 | 1,179 | python | [{"finding_id": "codeql_py/paramiko-missing-host-key-validation_6aff38c3b0564ade_09bf4202", "tool_name": "codeql", "rule_id": "py/paramiko-missing-host-key-validation", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Setting missing host key policy to AutoAddPolicy may be unsafe.", "r... | 1 | true | [
"CWE-295"
] | [
"py/paramiko-missing-host-key-validation"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"Setting missing host key policy to AutoAddPolicy may be unsafe."
] | [
18
] | [
null
] | [
9
] | [
74
] | |
2024-11-18T21:58:15.521363+00:00 | 1,579,557,923,000 | 11ea3fc6dafa255df2750179eb262f18ac606908 | 2 | {
"blob_id": "11ea3fc6dafa255df2750179eb262f18ac606908",
"branch_name": "refs/heads/master",
"committer_date": 1579557923000,
"content_id": "72fc6263a190e89c84dc9435e6d542f18eb7b7c9",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "6b2519031af6bb577b084b3324ed0ea1a8f3b0f2",
"extension": "py"... | 2.328125 | stackv2 | import os
import json
import logging
import pandas as pd
from retry import retry
from cloudant.client import Cloudant
from cloudant.query import Query
from cloudant.adapters import Replay429Adapter
from requests import HTTPError, ConnectionError
# get configruation from enviuronment (12-factor)
ADMIN_PARTY = os.enviro... | 276 | 35.62 | 100 | 18 | 2,025 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_541afb65d27b93cf_01299e8c", "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."
] | [
249
] | [
null
] | [
55
] | [
66
] | |
2024-11-18T21:58:18.527080+00:00 | 1,613,910,550,000 | a11a79c2d8823f4b2987ba2989aba18d4c88485d | 2 | {
"blob_id": "a11a79c2d8823f4b2987ba2989aba18d4c88485d",
"branch_name": "refs/heads/main",
"committer_date": 1613910550000,
"content_id": "d2e845fff82b3d4acbe6b74389b689b97a39db79",
"detected_licenses": [
"MIT"
],
"directory_id": "4703d23973ca542040606e6c7acaabf00f6cfa36",
"extension": "py",
"file... | 2.46875 | stackv2 | import requests
import discord
import hashlib
import prawcore
import reddit as reddit_func
import helper_functions as func
import movies as mvdb
import json
from discord.ext import commands
from geopy.geocoders import Nominatim
from pyowm.owm import OWM
client = commands.Bot(command_prefix='$')
# bullyMagnet = ['De ce... | 209 | 30.12 | 136 | 15 | 1,693 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_360a3ab30b1ef839_0fd85f76", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (private)](1) as clear text.\nTh... | 1 | true | [
"CWE-312"
] | [
"py/clear-text-logging-sensitive-data"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"This expression logs [sensitive data (private)](1) as clear text.\nThis expression logs [sensitive data (private)](2) as clear text."
] | [
132
] | [
null
] | [
11
] | [
120
] | |
2024-11-18T21:58:26.991858+00:00 | 1,553,200,673,000 | cdbe8c4c59e2ff54c6f2d707d4ddcaa5dc99543e | 3 | {
"blob_id": "cdbe8c4c59e2ff54c6f2d707d4ddcaa5dc99543e",
"branch_name": "refs/heads/master",
"committer_date": 1553200673000,
"content_id": "f05536d26b66172ecec51928379496b1e0d47d4c",
"detected_licenses": [
"MIT"
],
"directory_id": "efeacdb2eb062d4494a7c93a307f24038976c491",
"extension": "py",
"fi... | 3.03125 | stackv2 | '''
Adapted from github.com/adhocore/php-json-fixer
> © Jitendra Adhikari <jiten.adhikary@gmail.com>
> <https://github.com/adhocore>
> Licensed under MIT license.
Python adaptation by Paul Herz (github.com/phrz)
'''
# Tested to work on Python 3.7.2
#
# Usage: python3 -m jsonfix file.json
# cat file.json | ... | 258 | 25.73 | 92 | 16 | 1,994 | python | [{"finding_id": "codeql_py/redos_457413e5088b0bc1_0f23de2d", "tool_name": "codeql", "rule_id": "py/redos", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "This part of the regular expression may cause exponential backtracking on strings starting with '\"!\":' and containing many repet... | 1 | true | [
"CWE-1333"
] | [
"py/redos"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"This part of the regular expression may cause exponential backtracking on strings starting with '\"!\":' and containing many repetitions of '+\"!\":'."
] | [
231
] | [
null
] | [
37
] | [
42
] | |
2024-11-18T21:58:31.625751+00:00 | 1,546,185,121,000 | 9bcddf2dbc5bc52389a02dafe93551f03b7bc0d7 | 3 | {
"blob_id": "9bcddf2dbc5bc52389a02dafe93551f03b7bc0d7",
"branch_name": "refs/heads/master",
"committer_date": 1546185121000,
"content_id": "3c63ae696d3921e79f42454c89afbc991aac2da8",
"detected_licenses": [
"MIT"
],
"directory_id": "330df1fe551fb76f1a0d7cde6ebdd5efaa5cc662",
"extension": "py",
"fi... | 2.546875 | stackv2 | import os
import json
import re
import pickle
import itertools
# To change accordingly
AUTHOR = 'Joshia Seam'
ROOT = './facebook-joshiaseam'
comments = os.path.join(ROOT, 'comments')
groups = os.path.join(ROOT, 'groups')
messages = os.path.join(ROOT, 'messages')
posts = os.path.join(ROOT, 'posts')
def get_files(dir... | 262 | 23.9 | 73 | 23 | 1,374 | python | [{"finding_id": "codeql_py/overly-large-range_6d69875878771fdf_e5e3be03", "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\\\\[\\\\\\\\]^_\\].", ... | 1 | true | [
"CWE-020"
] | [
"py/overly-large-range"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"Suspicious character range that is equivalent to \\[$%&'()*+,\\-.\\/0-9:;<=>?@A-Z\\\\[\\\\\\\\]^_\\]."
] | [
227
] | [
null
] | [
55
] | [
58
] | |
2024-11-18T21:58:38.356446+00:00 | 1,611,286,066,000 | bf870b3a9b3ed68f22bbc8f0f8262b68e24fffd7 | 3 | {
"blob_id": "bf870b3a9b3ed68f22bbc8f0f8262b68e24fffd7",
"branch_name": "refs/heads/main",
"committer_date": 1611286066000,
"content_id": "8bd16f9b6adb608bb686b8619f57a4008ab1a075",
"detected_licenses": [
"MIT"
],
"directory_id": "afb5db6d2a40a6044f777e7500a59b1ef59968da",
"extension": "py",
"file... | 2.828125 | stackv2 | #!/usr/bin/env python3
import os
import os.path
import sys
# header structure
filename_size = 255
content_size = 14
mtime_size = 12
prefix_size = 4096
header_size = filename_size + content_size + mtime_size + prefix_size
nul = b'\x00'
eof_block = header_size * nul
def decode_header(block):
offset = 0
path =... | 101 | 28.26 | 90 | 22 | 745 | python | [{"finding_id": "codeql_py/overly-permissive-file_58a85106258bee1d_acc61d6a", "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."
] | [
68
] | [
null
] | [
13
] | [
34
] | |
2024-11-18T21:58:38.702038+00:00 | 1,531,839,273,000 | 05adff1c9ac1b185ed5803d71813b63370289a6b | 3 | {
"blob_id": "05adff1c9ac1b185ed5803d71813b63370289a6b",
"branch_name": "refs/heads/master",
"committer_date": 1531839273000,
"content_id": "7867cdb2f862f24957c9c2b15d475530a1c375ce",
"detected_licenses": [
"MIT"
],
"directory_id": "70e7b6bdb59cbadde66f82f42c0046eea1db293c",
"extension": "py",
"fi... | 2.6875 | stackv2 | #/api/auth/views.py
from . import auth_blueprint
import re
from flask.views import MethodView
from flask import make_response, request, jsonify
from flask_jwt_extended import jwt_required, get_raw_jwt, create_access_token
from api.models import User, Ride, Request
blacklist = set()
class SignupView(MethodView):
... | 302 | 38.35 | 117 | 18 | 2,586 | python | [{"finding_id": "codeql_py/stack-trace-exposure_69039b61f6d8bdb1_872f3b33", "tool_name": "codeql", "rule_id": "py/stack-trace-exposure", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "[Stack trace information](1) flows to this location and may be exposed to an external user.", "... | 2 | true | [
"CWE-209",
"CWE-209"
] | [
"py/stack-trace-exposure",
"py/stack-trace-exposure"
] | [
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM"
] | [
"[Stack trace information](1) flows to this location and may be exposed to an external user.",
"[Stack trace information](1) flows to this location and may be exposed to an external user."
] | [
49,
150
] | [
null,
null
] | [
46,
46
] | [
54,
54
] | |
2024-11-18T22:10:53.449215+00:00 | 1,605,781,627,000 | 6797066f06fa4e56aa0741334551e044c5da157d | 4 | {
"blob_id": "6797066f06fa4e56aa0741334551e044c5da157d",
"branch_name": "refs/heads/main",
"committer_date": 1605781627000,
"content_id": "5b7dde957083c405fc04aa73b2ee1397b0c32745",
"detected_licenses": [
"Unlicense"
],
"directory_id": "c47b441502027dbfc2f55f31d71c88602d215b4f",
"extension": "py",
... | 3.59375 | stackv2 | '''
Anas Albedaiwi
albedaiwi1994@gmail.com
'''
def _check_first_format(phone_number):
if len(phone_number) < 14:
return False
if phone_number[0] == '(' and phone_number[4] == ')' and phone_number[5] == ' ' and phone_number[9] == '-':
digits= [1, 2, 3, 6, 7, 8, 10, 11, 12, 13]
for d in d... | 46 | 40.67 | 111 | 21 | 443 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_53f1da362206c3b8_2fc8de00", "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."
] | [
45,
46
] | [
null,
null
] | [
31,
31
] | [
73,
71
] | |
2024-11-18T22:47:25.834852+00:00 | 1,618,854,198,000 | f39956d172a8cbfac21257d723c1929fffcc5596 | 3 | {
"blob_id": "f39956d172a8cbfac21257d723c1929fffcc5596",
"branch_name": "refs/heads/master",
"committer_date": 1618854198000,
"content_id": "a28e5b6f85de42bf3f297b4a4fe224cdf86554c4",
"detected_licenses": [
"MIT"
],
"directory_id": "907c2ac8346b157c3c4b84f5893cbfaf54e57cce",
"extension": "py",
"fi... | 3.3125 | stackv2 | from dataclasses import dataclass
from typing import List
@dataclass
class SampleCSV:
initials: str
position: str
departmentHierarchy: str
quarterlyEstimate: float
salary: int
@dataclass
class DepartmentReport:
department: str
number: int
minSalary: int
maxSalary: int
average... | 89 | 30.75 | 114 | 16 | 608 | python | [{"finding_id": "codeql_py/clear-text-storage-sensitive-data_20ec4e0ad5ec9e29_ad0df7cb", "tool_name": "codeql", "rule_id": "py/clear-text-storage-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression stores [sensitive data (private)](1) as clear text.\n... | 1 | true | [
"CWE-312"
] | [
"py/clear-text-storage-sensitive-data"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"This expression stores [sensitive data (private)](1) as clear text.\nThis expression stores [sensitive data (private)](2) as clear text.\nThis expression stores [sensitive data (private)](3) as clear text."
] | [
56
] | [
null
] | [
13
] | [
23
] | |
2024-11-18T23:10:59.630871+00:00 | 1,512,623,606,000 | 3536f836081eaba4a572408468417b1eb4276b75 | 3 | {
"blob_id": "3536f836081eaba4a572408468417b1eb4276b75",
"branch_name": "refs/heads/master",
"committer_date": 1512623606000,
"content_id": "fbc51196644580c130747d3f698cde245ecbeb04",
"detected_licenses": [
"BSD-3-Clause"
],
"directory_id": "ff6b0917efba2e31b5b89c59f43ee99489d44d21",
"extension": "p... | 2.984375 | stackv2 | """
A simple HandlerClass for getting raw data the Hex API serves up
"""
import json
from os import curdir, sep
from BaseHTTPServer import BaseHTTPRequestHandler, HTTPServer
from HexAPI import HexAPI
class HexHandler(BaseHTTPRequestHandler):
def handle_request(self):
try:
self.send_response(20... | 83 | 30.14 | 70 | 16 | 541 | python | [{"finding_id": "codeql_py/path-injection_9b36d69efe52e82e_4968be4a", "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)."
] | [
52
] | [
null
] | [
26
] | [
50
] | |
2024-11-18T22:05:54.878900+00:00 | 1,571,752,204,000 | af8f1af2822bebe5603b1b2c94501032db69d1a2 | 3 | {
"blob_id": "af8f1af2822bebe5603b1b2c94501032db69d1a2",
"branch_name": "refs/heads/master",
"committer_date": 1571752204000,
"content_id": "fd03e068e4d11f8aeea3ee59e96dce153af9c471",
"detected_licenses": [
"MIT"
],
"directory_id": "9a1e1c523a4e7f186b02511f3e159e202be37549",
"extension": "py",
"fi... | 2.796875 | stackv2 | #!/usr/bin/env python
from __future__ import print_function
from dnac_utils import dnac_token, create_url
import requests
import time
import json
# Entry point for program.
if __name__ == '__main__':
# get an authentication token. The username and password is obtained from an environment file
token = dnac_t... | 49 | 41.88 | 120 | 19 | 440 | python | [{"finding_id": "codeql_py/request-without-cert-validation_fa6fed01bb0c1624_38051cba", "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)."
] | [
21,
46
] | [
null,
null
] | [
16,
16
] | [
64,
64
] | |
2024-11-18T22:49:03.286250+00:00 | 1,630,547,812,000 | 7946d95b4f9363e5e766c586072fea1a338a3b10 | 2 | {
"blob_id": "7946d95b4f9363e5e766c586072fea1a338a3b10",
"branch_name": "refs/heads/main",
"committer_date": 1630547812000,
"content_id": "a016f03ceb6ebda929a790ba31121f6aa363e519",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "1f4a98046fb906f1cc1580647274144480e17439",
"extension": "py",
... | 2.390625 | stackv2 | from flask import Flask
from flask_apscheduler import APScheduler
from flask import jsonify
from flask import request
from flask import render_template
from static.logic.Sensores import Sensores
from static.logic.plots import Plots
import time
import datetime
import os
from pymongo import MongoClient
app = Flask(__na... | 196 | 32.06 | 167 | 15 | 1,852 | python | [{"finding_id": "codeql_py/flask-debug_ab5d4cf9534bbe01_18f33654", "tool_name": "codeql", "rule_id": "py/flask-debug", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", ... | 3 | true | [
"CWE-215",
"CWE-079",
"CWE-079"
] | [
"py/flask-debug",
"py/reflective-xss",
"py/reflective-xss"
] | [
"HIGH",
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.",
"Cross-site scripting vulnerability due to a [user-provided value](1).",
"Cross-site scripting vulnerability due to a [user-provided value](1)."
] | [
196,
189,
192
] | [
null,
null,
null
] | [
null,
20,
20
] | [
45,
34,
36
] | |
2024-11-18T22:49:10.848039+00:00 | 1,334,722,327,000 | 5ba261d89c45c2796b123c371bc8504953e0a74e | 3 | {
"blob_id": "5ba261d89c45c2796b123c371bc8504953e0a74e",
"branch_name": "refs/heads/master",
"committer_date": 1334722327000,
"content_id": "aec879288ab6bc25291223f4ac37478f03ef43ab",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "ba6e4069ad23cf7ef162b75a24e0c7650639c629",
"extension": "py"... | 2.59375 | stackv2 | import base64
import cgi
import hashlib
import hmac
import json
import time
import urllib
import urllib2
from objectifier import Objectifier
import settings
API_BASE = "https://graph.facebook.com/"
class FacebookError(Exception):
"""
Exception for all Facebook Graph API-related errors.
"""
def __ini... | 202 | 31.58 | 92 | 19 | 1,457 | python | [{"finding_id": "codeql_py/weak-sensitive-data-hashing_bd618e46c753625c_3818698c", "tool_name": "codeql", "rule_id": "py/weak-sensitive-data-hashing", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "[Sensitive data (secret)](1) is used in a hashing algorithm (MD5) that is insecur... | 1 | true | [
"CWE-327"
] | [
"py/weak-sensitive-data-hashing"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"[Sensitive data (secret)](1) is used in a hashing algorithm (MD5) that is insecure."
] | [
136
] | [
null
] | [
23
] | [
43
] | |
2024-11-18T23:26:04.810780+00:00 | 1,550,149,878,000 | 203d812025bb160ad2ed177da54420a246d5e85b | 3 | {
"blob_id": "203d812025bb160ad2ed177da54420a246d5e85b",
"branch_name": "refs/heads/master",
"committer_date": 1550149878000,
"content_id": "8f41481a9ac7ac192afb384ffa3b4a6ed240d327",
"detected_licenses": [
"MIT"
],
"directory_id": "697fba667c72adbe4ebf5f309e4b580feee49a4e",
"extension": "py",
"fi... | 3.3125 | stackv2 | import sqlite3 as lite
from hashlib import sha1
def encrypt_password(password):
""" encrypt password using sh1 and upper case the result """
return sha1(password.encode('UTF-8')).hexdigest().upper()
def create_db(db_name_arg):
""" intialize the database for the first time and create the table users if does not e... | 82 | 30.62 | 96 | 14 | 609 | python | [{"finding_id": "codeql_py/weak-sensitive-data-hashing_26f898b0251e5cf7_1bee6c2a", "tool_name": "codeql", "rule_id": "py/weak-sensitive-data-hashing", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "[Sensitive data (password)](1) is used in a hashing algorithm (SHA1) that is inse... | 1 | true | [
"CWE-327"
] | [
"py/weak-sensitive-data-hashing"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"[Sensitive data (password)](1) is used in a hashing algorithm (SHA1) that is insecure for password hashing, since it is not a computationally expensive hash function.\n[Sensitive data (password)](2) is used in a hashing algorithm (SHA1) that is insecure for password hashing, since it is not a computationally expen... | [
7
] | [
null
] | [
14
] | [
38
] | |
2024-11-18T22:27:27.224416+00:00 | 1,375,242,974,000 | 07190f8a23c3d93fe5eb8e3d872ac4422c722950 | 3 | {
"blob_id": "07190f8a23c3d93fe5eb8e3d872ac4422c722950",
"branch_name": "refs/heads/master",
"committer_date": 1375242974000,
"content_id": "34c73ed62263ca56b605d0d478df70c1b16c2556",
"detected_licenses": [
"MIT"
],
"directory_id": "df4c890ac172b92776a69c8d7c8c9cdf14e54641",
"extension": "py",
"fi... | 2.609375 | stackv2 | import datetime
import json
import sqlite3
import bottle
# Database set up
connection = sqlite3.connect('meetup.db')
cursor = connection.cursor()
cursor.execute('CREATE TABLE IF NOT EXISTS people (username TEXT, name TEXT)')
cursor.close()
app = bottle.Bottle()
# The base route loads a simple html file that starts ... | 176 | 27.73 | 78 | 16 | 1,226 | python | [{"finding_id": "codeql_py/reflective-xss_50a00ab778479486_f7515b91", "tool_name": "codeql", "rule_id": "py/reflective-xss", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "Cross-site scripting vulnerability due to a [user-provided value](1).", "remediation": "", "location": {"fi... | 1 | true | [
"CWE-079"
] | [
"py/reflective-xss"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"Cross-site scripting vulnerability due to a [user-provided value](1)."
] | [
45
] | [
null
] | [
12
] | [
30
] | |
2024-11-18T22:14:49.197353+00:00 | 1,618,933,298,000 | 906e192eb4ebdea62062df8c413828694eb874f2 | 3 | {
"blob_id": "906e192eb4ebdea62062df8c413828694eb874f2",
"branch_name": "refs/heads/master",
"committer_date": 1618933298000,
"content_id": "e6bdbbcc549fe4eee0845fc862f1a4d93a5990d1",
"detected_licenses": [
"MIT"
],
"directory_id": "0934f0bef7587d90c47dfb405fcececb91eae01b",
"extension": "py",
"fi... | 2.640625 | stackv2 | '''
Import data from ERNIE postgres and generate a Chord Diagram
Author: VJ Davey
'''
import psycopg2
import argparse
import pandas as pd
import numpy as np
import chord
from math import ceil
def fibonacci(n,memo):
if (n < 2):
return 1
if n in memo:
return memo[n]
else:
memo[n] = fi... | 130 | 48.52 | 156 | 16 | 1,521 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_ca809375136a0922_1fd7d116", "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."
] | [
93
] | [
null
] | [
7
] | [
18
] | |
2024-11-18T22:14:51.047957+00:00 | 1,599,053,689,000 | 6f8f49538034956993b054bd9c9eacecbc1c4669 | 3 | {
"blob_id": "6f8f49538034956993b054bd9c9eacecbc1c4669",
"branch_name": "refs/heads/master",
"committer_date": 1599053689000,
"content_id": "b9e6e8d6dd453811dd5d1dfe09d46976e3f4c827",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "5fe72bb13baf3649058ebe11aa86ad4fc56c69ed",
"extension": "py"... | 2.546875 | stackv2 | """
Simple backend for nginx memcached module
Written by Wojtek 'suda' Siudzinski <admin@suda.pl>
Gist: https://gist.github.com/701904
Nginx config:
location /static {
add_header X-Origin Memcached;
expires modified +48h;
set ... | 73 | 33.81 | 107 | 17 | 597 | python | [{"finding_id": "codeql_py/path-injection_ade065ee3feaac6f_bdfb4be3", "tool_name": "codeql", "rule_id": "py/path-injection", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This path depends on a [user-provided value](1).", "remediation": "", "location": {"file_path": "unknown", ... | 2 | true | [
"CWE-022",
"CWE-022"
] | [
"py/path-injection",
"py/path-injection"
] | [
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM"
] | [
"This path depends on a [user-provided value](1).",
"This path depends on a [user-provided value](1)."
] | [
41,
47
] | [
null,
null
] | [
31,
26
] | [
35,
30
] | |
2024-11-18T22:14:59.570959+00:00 | 1,524,465,301,000 | 651677fcdd26c84a03c6bc5d58758f99f0a2d67f | 3 | {
"blob_id": "651677fcdd26c84a03c6bc5d58758f99f0a2d67f",
"branch_name": "refs/heads/master",
"committer_date": 1524465301000,
"content_id": "342c5beb05cd5128fad12b14d9f8749d31f37fb8",
"detected_licenses": [
"MIT"
],
"directory_id": "3b2296a9cf1167fb3d10525e5724829b3f4dd8e8",
"extension": "py",
"fi... | 3.0625 | stackv2 | from selenium import webdriver
import requests
from lxml import html
import random
from selenium.webdriver.support.ui import Select
import time
import re
def get_details():
# url to get fake address
addr_url = "https://fakena.me/fake-name/"
# file for emails
email_file = "details.csv"
# open file ... | 124 | 27.94 | 141 | 18 | 867 | python | [{"finding_id": "codeql_py/clear-text-storage-sensitive-data_93432b2f10871f79_9ea51dcb", "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."
] | [
70
] | [
null
] | [
17
] | [
141
] | |
2024-11-18T22:15:04.704347+00:00 | 1,629,578,780,000 | 3707973ef318e912233bb1babdeb01ba5ddfb6f8 | 3 | {
"blob_id": "3707973ef318e912233bb1babdeb01ba5ddfb6f8",
"branch_name": "refs/heads/main",
"committer_date": 1629578780000,
"content_id": "0994df83b59cf0074127f693f8e8db2dbe004be9",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "060963b375837a6f4d0913bcdb987b3bf0c93d34",
"extension": "py",
... | 2.734375 | stackv2 | #######################################################
# Takes esigner360 chart and repository index
# finds newest version in the repository
# iterates throu dependencies and if there is newer dependency,
# it is updated
#######################################################
from requests.models import HTTPBasicA... | 99 | 34.25 | 133 | 14 | 841 | python | [{"finding_id": "codeql_py/request-without-cert-validation_a676c009a795af1f_40eb6ae9", "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)."
] | [
54
] | [
55
] | [
20
] | [
81
] | |
2024-11-18T22:55:29.877508+00:00 | 1,378,843,952,000 | 09875697f056708a3b995eaca130c5ee28b14d6f | 2 | {
"blob_id": "09875697f056708a3b995eaca130c5ee28b14d6f",
"branch_name": "refs/heads/master",
"committer_date": 1378843952000,
"content_id": "52d7382ae41e0224c4f086fe23cc44903d8b504c",
"detected_licenses": [
"MIT"
],
"directory_id": "029861d041965db45d7040535d8b8be9b3a57ffb",
"extension": "py",
"fi... | 2.46875 | stackv2 | #!/usr/bin/env python
"""
put.io download script
This script will start downloads on put.io, then download it locally.
ONE DOWNLOAD AT A TIME, and It will delete file on put.io after
successfully downloading it. This way, you don't need much space on put.io.
It is used as an execution script in flexget.
"""
#####... | 290 | 35.76 | 159 | 20 | 2,446 | python | [{"finding_id": "codeql_py/overly-permissive-file_510bee8b91a0f78d_8adf4baa", "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."
] | [
61
] | [
null
] | [
13
] | [
37
] | |
2024-11-18T22:55:41.218895+00:00 | 1,568,873,305,000 | 53a13cdcbe5b1ede9c7b0159165c34f10e824787 | 3 | {
"blob_id": "53a13cdcbe5b1ede9c7b0159165c34f10e824787",
"branch_name": "refs/heads/master",
"committer_date": 1568873305000,
"content_id": "fbd432b41ac3f9852b45700c154127e8e3e2599a",
"detected_licenses": [
"MIT"
],
"directory_id": "efa4120f3814c284ae3313418473f55afc86b40e",
"extension": "py",
"fi... | 2.78125 | stackv2 | """
Code for player scoring, achievements, etc.
"""
from .settings import settings
from . import users
from flask import request, render_template
import json
import sqlite3
# Global variables
with open(settings["ACHIEVEMENTS_FILE"], "r") as f:
achievements = json.loads(f.read())
# Function definitions
def regist... | 71 | 30.03 | 81 | 14 | 511 | python | [{"finding_id": "codeql_py/sql-injection_f0eedb280a6cf701_4b5941b6", "tool_name": "codeql", "rule_id": "py/sql-injection", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This SQL query depends on a [user-provided value](1).", "remediation": "", "location": {"file_path": "unknown... | 1 | true | [
"CWE-089"
] | [
"py/sql-injection"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"This SQL query depends on a [user-provided value](1)."
] | [
22
] | [
null
] | [
20
] | [
27
] | |
2024-11-18T23:24:02.255019+00:00 | 1,624,895,831,000 | 92254bd095609ae9c03c8b57129a084d04557e51 | 3 | {
"blob_id": "92254bd095609ae9c03c8b57129a084d04557e51",
"branch_name": "refs/heads/master",
"committer_date": 1624895831000,
"content_id": "a5043b8fa0c1c46e6613c29d57071d04f3ab62b4",
"detected_licenses": [
"MIT"
],
"directory_id": "026991d5749c55910f4c33cc6f35a778494ef89e",
"extension": "py",
"fi... | 2.515625 | stackv2 | from django.shortcuts import render
from api.models import Company, Vacancy
from django.http.response import JsonResponse, HttpResponse
def companies_list(request):
companies = Company.objects.all()
companies_json = [company.to_json() for company in companies]
return JsonResponse(companies_json, safe=Fals... | 47 | 34.19 | 69 | 14 | 337 | python | [{"finding_id": "codeql_py/stack-trace-exposure_f6846656c8460c8f_ddd9df5c", "tool_name": "codeql", "rule_id": "py/stack-trace-exposure", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "[Stack trace information](1) flows to this location and may be exposed to an external user.", "... | 3 | true | [
"CWE-209",
"CWE-209",
"CWE-209"
] | [
"py/stack-trace-exposure",
"py/stack-trace-exposure",
"py/stack-trace-exposure"
] | [
"HIGH",
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"[Stack trace information](1) flows to this location and may be exposed to an external user.",
"[Stack trace information](1) flows to this location and may be exposed to an external user.",
"[Stack trace information](1) flows to this location and may be exposed to an external user."
] | [
17,
27,
41
] | [
null,
null,
null
] | [
29,
29,
29
] | [
56,
56,
56
] | |
2024-11-18T23:24:04.220061+00:00 | 1,446,554,911,000 | 996f79fb4eada5b9b824bfd44a69181c403cfc1e | 3 | {
"blob_id": "996f79fb4eada5b9b824bfd44a69181c403cfc1e",
"branch_name": "refs/heads/master",
"committer_date": 1446557538000,
"content_id": "82a6f8639f6401aa5ce808461c89b24025e49b7c",
"detected_licenses": [
"BSD-2-Clause"
],
"directory_id": "3aa29d954bd5f5dc947528ae7d4a2f63f017319d",
"extension": "p... | 3.203125 | stackv2 | from __future__ import print_function, absolute_import
from flask import Flask, url_for, request
# Bind app to a Flask instance
app = Flask(__name__)
@app.route('/') # the URL which triggers this function
def hello_world():
return("Hello <i>you</i>. :-}")
# We can define variables in the arg. to `@app.route`
... | 70 | 31.8 | 79 | 11 | 577 | python | [{"finding_id": "codeql_py/reflective-xss_0aab08c6791503f2_47fbd46c", "tool_name": "codeql", "rule_id": "py/reflective-xss", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "Cross-site scripting vulnerability due to a [user-provided value](1).", "remediation": "", "location": {"fi... | 1 | true | [
"CWE-079"
] | [
"py/reflective-xss"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"Cross-site scripting vulnerability due to a [user-provided value](1)."
] | [
20
] | [
null
] | [
12
] | [
15
] | |
2024-11-18T23:55:45.423880+00:00 | 1,539,772,394,000 | 9bcef00f155314c160150d40f793bc71adc8b629 | 3 | {
"blob_id": "9bcef00f155314c160150d40f793bc71adc8b629",
"branch_name": "refs/heads/master",
"committer_date": 1539772394000,
"content_id": "a480cf72301af12419137c2f5819d247abe0a471",
"detected_licenses": [
"MIT"
],
"directory_id": "1853b0676df934602390b3fe4caa1075c481739e",
"extension": "py",
"fi... | 2.578125 | stackv2 | from flask import Flask
from flask import request
import base64
import urllib
import json
import requests
app = Flask(__name__)
# Group's token
token = None
# Last chat's identifier
last_chat_id = None
@app.route('/', methods=['POST'])
def entry():
"""
Recives messages
:return: Always return the answer:... | 121 | 30.48 | 126 | 14 | 881 | python | [{"finding_id": "codeql_py/reflective-xss_21bce4a07776f7dc_703b28c6", "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... | 8 | true | [
"CWE-079",
"CWE-079",
"CWE-079",
"CWE-079",
"CWE-918",
"CWE-918",
"CWE-918",
"CWE-918"
] | [
"py/reflective-xss",
"py/reflective-xss",
"py/reflective-xss",
"py/reflective-xss",
"py/partial-ssrf",
"py/partial-ssrf",
"py/partial-ssrf",
"py/partial-ssrf"
] | [
"HIGH",
"HIGH",
"HIGH",
"HIGH",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"Cross-site scripting vulnerability due to a [user-provided value](1).",
"Cross-site scripting vulnerability due to a [user-provided value](1).",
"Cross-site scripting vulnerability due to a [user-provided value](1).",
"Cross-site scripting vulnerability due to a [user-provided value](1).\nCross-site scriptin... | [
41,
57,
68,
107,
56,
67,
87,
105
] | [
null,
null,
null,
null,
null,
null,
null,
null
] | [
12,
12,
12,
12,
16,
16,
20,
16
] | [
17,
25,
25,
25,
85,
61,
89,
85
] | |
2024-11-18T22:56:17.955038+00:00 | 1,548,969,501,000 | e2c66f36c8cee2891e2e794e150a560dead6bd3e | 3 | {
"blob_id": "e2c66f36c8cee2891e2e794e150a560dead6bd3e",
"branch_name": "refs/heads/master",
"committer_date": 1548969501000,
"content_id": "0ce1a2780c14f59b7f9c0793259ad53778c0d2b7",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "f56ffb4400068cfd775ede9fe4cf890b5aa7db98",
"extension": "py"... | 2.703125 | stackv2 | """
This file contains methods which are used to update the online labstats spaces.
"""
import logging
import requests
from django.conf import settings
from spacescout_labstats import utils
logger = logging.getLogger(__name__)
def get_space_search_parameters():
"""
Returns the URL with which to send a GET re... | 269 | 32.44 | 79 | 18 | 2,036 | python | [{"finding_id": "codeql_py/request-without-cert-validation_f7b689502404931e_76c08f84", "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)."
] | [
68
] | [
70
] | [
11
] | [
37
] | |
2024-11-19T00:07:28.924791+00:00 | 1,427,473,370,000 | 6496e952b073cb9339d4b565ceb17bc05b5af995 | 2 | {
"blob_id": "6496e952b073cb9339d4b565ceb17bc05b5af995",
"branch_name": "refs/heads/master",
"committer_date": 1427473370000,
"content_id": "84a13159c11d9f8ab788c84f5321ed623419e6d5",
"detected_licenses": [
"BSD-2-Clause"
],
"directory_id": "98ccf9473905b25fda057d441381c3b66f4ad9a7",
"extension": "p... | 2.3125 | stackv2 | import requests
from requests.auth import HTTPBasicAuth
import json
from models.models import *
import abc
domain_name = ""
username = ''
password = ''
def _error_400(response=None):
message = 'Problem with request syntax'
if not response is None:
message = "%s : %s" % (message, response)
raise Except... | 384 | 38.52 | 122 | 21 | 3,352 | python | [{"finding_id": "codeql_py/request-without-cert-validation_dbeada7396d9b224_466559bc", "tool_name": "codeql", "rule_id": "py/request-without-cert-validation", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "This request may run without certificate validation because [it is disabled]... | 4 | true | [
"CWE-295",
"CWE-295",
"CWE-295",
"CWE-295"
] | [
"py/request-without-cert-validation",
"py/request-without-cert-validation",
"py/request-without-cert-validation",
"py/request-without-cert-validation"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"This request may run without certificate validation because [it is disabled](1).",
"This request may run without certificate validation because [it is disabled](1).",
"This request may run without certificate validation because [it is disabled](1).",
"This request may run without certificate validation becau... | [
79,
85,
92,
98
] | [
83,
90,
96,
102
] | [
20,
20,
19,
20
] | [
75,
75,
75,
75
] | |
2024-11-19T00:07:31.120278+00:00 | 1,506,648,936,000 | 15b406626a69c5fe8068cbaba542fb5d7b71dbab | 3 | {
"blob_id": "15b406626a69c5fe8068cbaba542fb5d7b71dbab",
"branch_name": "refs/heads/master",
"committer_date": 1506648936000,
"content_id": "052ae47862fab1de14ed679d3a3616c90347882d",
"detected_licenses": [
"MIT"
],
"directory_id": "f725cd9993c1037daf498d10a3da45a558e5c5f2",
"extension": "py",
"fi... | 3.296875 | stackv2 | # Author: Laura Ekstrand (laura@jlekstrand.net)
# Adapted from an example of socketserver.
# https://docs.python.org/3.5/library/socketserver.html
import http.server
import socketserver
import threading
import socket
import requests
## Text methods
# Remove integers
def removeIntegers(text):
for i in range(10):
... | 80 | 31.73 | 105 | 17 | 617 | python | [{"finding_id": "codeql_py/partial-ssrf_84712db86e35e226_5a991293", "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)."
] | [
55
] | [
null
] | [
21
] | [
38
] | |
2024-11-19T00:07:31.438046+00:00 | 1,572,900,553,000 | f867b3e152d892354f305b4ea89689c31b9b9f9c | 3 | {
"blob_id": "f867b3e152d892354f305b4ea89689c31b9b9f9c",
"branch_name": "refs/heads/master",
"committer_date": 1572900553000,
"content_id": "c906638e46f80a602696049e2f2271a43cdef670",
"detected_licenses": [
"BSD-3-Clause-Clear"
],
"directory_id": "c5f2c217501c7a0d4d9c1843e11e614e4e41fb81",
"extensio... | 3.015625 | stackv2 | import pyodbc
import hashlib
# tries to login to a database with the specified server naem and DB name with windows authentication
def get_database_connection(server_name,db_name):
conn_param = (
r'Driver={SQL Server};'
r'Server=' + server_name + ';'
r'Database=' + db_name + ';'
r'Trusted_Connection=... | 87 | 24.41 | 116 | 13 | 541 | python | [{"finding_id": "codeql_py/weak-sensitive-data-hashing_68165d2aa3e71214_a4bada80", "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 (SHA384) that is in... | 2 | true | [
"CWE-327",
"CWE-327"
] | [
"py/weak-sensitive-data-hashing",
"py/weak-sensitive-data-hashing"
] | [
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM"
] | [
"[Sensitive data (password)](1) is used in a hashing algorithm (SHA384) that is insecure for password hashing, since it is not a computationally expensive hash function.",
"[Sensitive data (password)](1) is used in a hashing algorithm (SHA384) that is insecure for password hashing, since it is not a computational... | [
28,
76
] | [
null,
null
] | [
20,
19
] | [
37,
36
] | |
2024-11-18T23:28:26.172745+00:00 | 1,607,110,332,000 | 1f642bc0db461ceb0d1e11e90d8ce769f22d8ecb | 3 | {
"blob_id": "1f642bc0db461ceb0d1e11e90d8ce769f22d8ecb",
"branch_name": "refs/heads/master",
"committer_date": 1607110332000,
"content_id": "58cf10d049031d2d722472a0e827ffd53325395e",
"detected_licenses": [
"BSD-2-Clause"
],
"directory_id": "8f9fe077bfed443e6fec1a72772612abcd5fdd76",
"extension": "p... | 2.515625 | stackv2 | from flask import Blueprint, render_template, request, redirect, url_for, flash
import configparser
import os
import shutil
storage_bp = Blueprint(
'storage_bp', __name__,
template_folder='templates',
static_folder='static',
static_url_path='/storage/static'
)
@storage_bp.route('/storage', methods=['... | 80 | 35.39 | 119 | 26 | 638 | python | [{"finding_id": "codeql_py/path-injection_ecb94ce934a5ce1f_21e692bb", "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)."
] | [
37
] | [
null
] | [
27
] | [
57
] | |
2024-11-18T23:28:31.019805+00:00 | 1,581,808,105,000 | 5b03db2152a536b699a3275279cbb5359c42157a | 4 | {
"blob_id": "5b03db2152a536b699a3275279cbb5359c42157a",
"branch_name": "refs/heads/master",
"committer_date": 1581808105000,
"content_id": "2a06637faa6b7ec285a846e402c3d3c3975d9aff",
"detected_licenses": [
"MIT"
],
"directory_id": "17fb0c014174dad7935a9a23d3924e98d3171936",
"extension": "py",
"fi... | 3.640625 | stackv2 | # Resolve the problem!!
import string
from random import randint, uniform, random
SYMBOLS = list('!"#$%&\'()*+,-./:;?@[]^_`{|}~')
MIN = 8
MAX = 15
CARACTER = list('aA0S')
def generate_password():
# 97 - 122 az
# 65 - 90 AZ
# 48 - 57 09
# 0-27 SYMBOLS
total_caracteres = randint(MIN, MAX)
passw... | 72 | 24.43 | 91 | 14 | 461 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_4842f54d02398815_e3b8e152", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (password)](1) as clear text.\nT... | 1 | true | [
"CWE-312"
] | [
"py/clear-text-logging-sensitive-data"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"This expression logs [sensitive data (password)](1) as clear text.\nThis expression logs [sensitive data (password)](2) as clear text.\nThis expression logs [sensitive data (password)](3) as clear text.\nThis expression logs [sensitive data (password)](4) as clear text.\nThis expression logs [sensitive data (passw... | [
28
] | [
null
] | [
11
] | [
20
] | |
2024-11-18T23:40:02.506856+00:00 | 1,607,061,062,000 | 745d59fcf43d9cb0d4ab19b9972a91654556f813 | 3 | {
"blob_id": "745d59fcf43d9cb0d4ab19b9972a91654556f813",
"branch_name": "refs/heads/master",
"committer_date": 1607061062000,
"content_id": "2327fd48130252787b6136e7874dc71af1353bc0",
"detected_licenses": [
"MIT"
],
"directory_id": "f00df484a02c4eb8322d5d7c8124d393eabb948a",
"extension": "py",
"fi... | 2.734375 | stackv2 | import requests
#accesskey is the python file used to save the api keys. Please dont hardcode your api keys, especially if your code is opensource.
import accesskey
import json
def num_verify():
phone_number = input("Please enter your phone number: ")
print(f"Your phone number is {phone_number}")
... | 24 | 24.25 | 131 | 10 | 139 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_1d429e181f5db6ac_4f879a88", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (private)](1) as clear text.", "... | 2 | true | [
"CWE-312",
"CWE-312"
] | [
"py/clear-text-logging-sensitive-data",
"py/clear-text-logging-sensitive-data"
] | [
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM"
] | [
"This expression logs [sensitive data (private)](1) as clear text.",
"This expression logs [sensitive data (private)](1) as clear text."
] | [
13,
17
] | [
null,
null
] | [
11,
12
] | [
49,
28
] | |
2024-11-19T00:05:01.040610+00:00 | 1,548,455,427,000 | 62f216f222ec0f56654fe198f0ed44be1a5ae29e | 4 | {
"blob_id": "62f216f222ec0f56654fe198f0ed44be1a5ae29e",
"branch_name": "refs/heads/master",
"committer_date": 1548455427000,
"content_id": "300f769d495f2bbc2250ee0dbbba046c7728c9c5",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "11c964db83c973e86956d137f210e5e0a6e09ddd",
"extension": "py"... | 4.3125 | stackv2 | class Dog:
def __init__(self, name, breed, color, gender):
self.name = name
self.breed = breed
self.color = color
self.gender = gender
def printAll(self):
print(self.name, self.breed, self.color, self.gender)
class Person:
def __init__(self, name, weight, height):
... | 113 | 28.37 | 112 | 14 | 876 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_f510e6ba6995fcf3_f6e5fcf0", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (private)](1) as clear text.\nTh... | 1 | true | [
"CWE-312"
] | [
"py/clear-text-logging-sensitive-data"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"This expression logs [sensitive data (private)](1) as clear text.\nThis expression logs [sensitive data (private)](2) as clear text."
] | [
10
] | [
null
] | [
50
] | [
61
] | |
2024-11-19T01:11:19.022141+00:00 | 1,623,011,336,000 | e238326d7cd6b0468c1cacb1b49350dde5835e74 | 2 | {
"blob_id": "e238326d7cd6b0468c1cacb1b49350dde5835e74",
"branch_name": "refs/heads/main",
"committer_date": 1623011336000,
"content_id": "9737e79188362b1a4244c0f5c596e2a156396876",
"detected_licenses": [
"CC0-1.0"
],
"directory_id": "fbeddfe21159d28f74c2ee8b7023a6ffbf5e31f9",
"extension": "py",
"... | 2.40625 | stackv2 | #!/usr/bin/python
import os
import json
import time
import jsonpickle
import mysql.connector
from multiprocessing import Process
from datetime import datetime
from flask import Flask, request # python-flask
app = Flask(__name__)
def get_mydb():
return mysql.connector.connect(
host="localhost",
user="root... | 107 | 25.5 | 98 | 16 | 730 | python | [{"finding_id": "codeql_py/sql-injection_a53cfe9fdea211fe_e44db10d", "tool_name": "codeql", "rule_id": "py/sql-injection", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This SQL query depends on a [user-provided value](1).", "remediation": "", "location": {"file_path": "unknown... | 2 | true | [
"CWE-089",
"CWE-089"
] | [
"py/sql-injection",
"py/sql-injection"
] | [
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM"
] | [
"This SQL query depends on a [user-provided value](1).",
"This SQL query depends on a [user-provided value](1)."
] | [
68,
70
] | [
null,
null
] | [
20,
20
] | [
75,
98
] | |
2024-11-19T01:11:36.502523+00:00 | 1,552,870,231,000 | 76c7040e087546bc07d252cc11caa8e0970dd8c0 | 3 | {
"blob_id": "76c7040e087546bc07d252cc11caa8e0970dd8c0",
"branch_name": "refs/heads/master",
"committer_date": 1552870231000,
"content_id": "ff8d21c12f274ffdfefc8f9584bfa743c0b5f89d",
"detected_licenses": [
"MIT"
],
"directory_id": "4798e44534081304fe0e2b33b7ee2a180589c980",
"extension": "py",
"fi... | 2.875 | stackv2 | #!/usr/bin/env python3
"""
GEOG*4480 W19
Isaac Wismer
wismeri@uoguelph.ca
Created for a project on wildfire vulnerability in Mackenzie County in Alberta
This script extracts all the images from a landsat order, and removes all the
pixels from the images that are not clear according to the QA band.
Run with:
./mask.p... | 58 | 32.66 | 129 | 15 | 535 | python | [{"finding_id": "codeql_py/tarslip_dbe81cc51022f9de_1bb6bf41", "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)."
] | [
35
] | [
null
] | [
9
] | [
12
] | |
2024-11-18T23:46:49.776572+00:00 | 1,482,448,895,000 | dd1ae5f3e01855c211a8fa09b07ab9a86ef653fc | 2 | {
"blob_id": "dd1ae5f3e01855c211a8fa09b07ab9a86ef653fc",
"branch_name": "refs/heads/master",
"committer_date": 1482448895000,
"content_id": "8d06ba8fce38e9e6fd31cae314671175a44c3df7",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "212c3d0f91cec628cff8092c6884da7834339444",
"extension": "py"... | 2.453125 | stackv2 | import pygame
import webcolors
import config
wc = webcolors.name_to_rgb
import time
import os
import re
from hw import disklogging
LogLevel = 2
ConsoleDebug = 0
ConsoleDetail = 1
ConsoleInfo = 2
ConsoleWarning = 3
ConsoleError = 4
class Logs(object):
livelog = True
livelogpos = 0
log = []
LogColors = ("teal",... | 109 | 27.89 | 114 | 19 | 949 | python | [{"finding_id": "codeql_py/overly-permissive-file_c0827656ac3eedc6_5776496e", "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."
] | [
43
] | [
null
] | [
4
] | [
34
] | |
2024-11-19T00:29:33.304731+00:00 | 1,584,660,464,000 | 68b1f079f41801ed23c33a4ce94c08f3d251a32b | 2 | {
"blob_id": "68b1f079f41801ed23c33a4ce94c08f3d251a32b",
"branch_name": "refs/heads/master",
"committer_date": 1584660464000,
"content_id": "7ec637414b36553748735719f2f7626559d300a8",
"detected_licenses": [
"MIT"
],
"directory_id": "725df277ba8275e8fddeea72a4352bc90513b874",
"extension": "py",
"fi... | 2.4375 | stackv2 | from BertFineTuning.utils import *
from BertFineTuning.data_config import *
import os
import sys
import math
import copy
import urllib
import zipfile
import pandas as pd
import requests
import shutil
import numpy as np
import matplotlib.pyplot as plt
from download import download
import re
from collections import Orde... | 260 | 31.55 | 151 | 22 | 2,008 | python | [{"finding_id": "codeql_py/request-without-cert-validation_cd68d0a024e55255_14c394b2", "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)."
] | [
49
] | [
null
] | [
21
] | [
99
] | |
2024-11-19T00:29:35.186429+00:00 | 1,611,304,427,000 | 09211c33c368ebd2d3d89be44e350a012e14bc4e | 3 | {
"blob_id": "09211c33c368ebd2d3d89be44e350a012e14bc4e",
"branch_name": "refs/heads/master",
"committer_date": 1611304427000,
"content_id": "fb4364019c86f3f70edb057a737122f4105e8141",
"detected_licenses": [
"MIT"
],
"directory_id": "41521759280e1e586f7ec4eb333bada33a0192a7",
"extension": "py",
"fi... | 2.5625 | stackv2 | # https://arxiv.org/help/api/user-manual
# built-in modules
import json
import logging
import os
from pathlib import Path
from typing import Dict, List, Tuple
# external modules
import requests
import colorlog
from bs4 import BeautifulSoup
DEFAULT_DOWNLOAD_PATH = Path.home() / "Downloads/ArXiv_Papers"
#############... | 409 | 28.52 | 87 | 17 | 2,861 | python | [{"finding_id": "codeql_py/incomplete-url-substring-sanitization_2fa75aa8ba984b94_f7a7c302", "tool_name": "codeql", "rule_id": "py/incomplete-url-substring-sanitization", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "The string [arxiv.org](1) may be at an arbitrary position in the s... | 1 | true | [
"CWE-020"
] | [
"py/incomplete-url-substring-sanitization"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"The string [arxiv.org](1) may be at an arbitrary position in the sanitized URL."
] | [
95
] | [
null
] | [
8
] | [
26
] | |
2024-11-19T00:44:24.667403+00:00 | 1,605,653,712,000 | c3cae21f683ea75cc484843887af980d68cfe9c3 | 2 | {
"blob_id": "c3cae21f683ea75cc484843887af980d68cfe9c3",
"branch_name": "refs/heads/master",
"committer_date": 1605653712000,
"content_id": "ca2422150d76285fc204cad14599e3960eac1760",
"detected_licenses": [
"BSD-3-Clause",
"Apache-2.0"
],
"directory_id": "da29f1f5b4459fbfec968bb694bedb9586f87b14",... | 2.375 | stackv2 | from Crypto.Cipher import AES
from Crypto.Random import get_random_bytes
from Crypto.Util.Padding import pad, unpad
from qiskit_fast_shor import Shor
from qiskit import Aer, IBMQ
from scapy.all import sniff, TCP
import logging
import re
import RSA
import socket
import sys
# Defaulting level to logging.WARN helps us di... | 126 | 36.69 | 118 | 17 | 1,157 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_2fe06603768e19a7_b42c688e", "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."
] | [
103
] | [
null
] | [
21
] | [
91
] | |
2024-11-18T23:05:49.440175+00:00 | 1,598,518,943,000 | 6cf13743bdca0c6b595362297afed233c70363d2 | 4 | {
"blob_id": "6cf13743bdca0c6b595362297afed233c70363d2",
"branch_name": "refs/heads/master",
"committer_date": 1598518943000,
"content_id": "c14ddd776a547b8a3b99970d2d9b6b62887600a1",
"detected_licenses": [
"BSD-3-Clause"
],
"directory_id": "0f39f3de14a9ad71d7222b41d327d2f7e1b611a8",
"extension": "p... | 4.40625 | stackv2 | # -*- coding: utf-8 -*-
from typing import Tuple
foo = 10
bar = 'Sam'
# Python now has type hints, in order to indicate variable's type
a: int = 10
b: float = 10.5
c: complex = 2 + 3j
d: bool = True
result = a + b
print(result, type(result))
# String
sentence1 = "Nice to meet you."
sentence2 = 'Nice to meet you.... | 103 | 24.41 | 118 | 10 | 811 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_9550a33feeee865f_1db574b6", "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."
] | [
71
] | [
null
] | [
7
] | [
24
] | |
2024-11-18T23:11:09.401434+00:00 | 1,549,263,321,000 | 94dbd1b5364a3465f51bdf495ea7349ef9adbd72 | 2 | {
"blob_id": "94dbd1b5364a3465f51bdf495ea7349ef9adbd72",
"branch_name": "refs/heads/master",
"committer_date": 1549263456000,
"content_id": "ad6752fdb65c44574771b6ef0ce5d0e56fd39231",
"detected_licenses": [
"MIT"
],
"directory_id": "bcd215ea5b8827191d7aa807195712e7e6c08873",
"extension": "py",
"fi... | 2.34375 | stackv2 | from flask import render_template, flash, redirect, url_for, request, session
from flask_login import current_user, login_user, login_required, logout_user
from werkzeug.urls import url_parse
from app import create_app, db
from app.auth import bp
from app.auth.forms import LoginForm, RegistrationForm
from app.models i... | 78 | 38.64 | 80 | 16 | 653 | python | [{"finding_id": "codeql_py/url-redirection_181fe85135091098_3f33f139", "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)."
] | [
27
] | [
null
] | [
25
] | [
34
] | |
2024-11-19T01:21:40.742250+00:00 | 1,603,646,978,000 | a6e7cd2af76695f4874248e99109cb576cd31edc | 3 | {
"blob_id": "a6e7cd2af76695f4874248e99109cb576cd31edc",
"branch_name": "refs/heads/master",
"committer_date": 1603646978000,
"content_id": "48e516ccc36a93563fc01b6fdc0d0aa9369686e7",
"detected_licenses": [
"MIT"
],
"directory_id": "23130cd12e38dbce8db8102810edaad70b240ae2",
"extension": "py",
"fi... | 3.359375 | stackv2 | class GeoHash:
"""
@param: geohash: geohash a base32 string
@return: latitude and longitude a location coordinate pair
"""
def decode(self, geohash):
# write your code here
map = '0123456789bcdefghjkmnpqrstuvwxyz'
char_to_index = {map[i]:i for i in range(len(map))}
... | 59 | 34.14 | 94 | 15 | 508 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_dfb5718304a6658a_9e8b760c", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (private)](1) as clear text.\nTh... | 1 | true | [
"CWE-312"
] | [
"py/clear-text-logging-sensitive-data"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"This expression logs [sensitive data (private)](1) as clear text.\nThis expression logs [sensitive data (private)](2) as clear text."
] | [
59
] | [
null
] | [
7
] | [
31
] | |
2024-11-19T00:11:36.013527+00:00 | 1,690,402,285,000 | dadc90412a09447892a250f4561bfd91454498c6 | 3 | {
"blob_id": "dadc90412a09447892a250f4561bfd91454498c6",
"branch_name": "refs/heads/master",
"committer_date": 1690402285000,
"content_id": "95e3b99c38c9d6dc7b59e2d1d483c0c580734d47",
"detected_licenses": [
"MIT"
],
"directory_id": "0a99505e2a6de3b5488bf682068fc53bfd441e9f",
"extension": "py",
"fi... | 2.953125 | stackv2 | import object_factory
class SpotifyService:
def __init__(self, access_code):
self._access_code = access_code
def test_connection(self):
print('Accessing Spotify with {ac}'.format(ac=self._access_code))
class SpotifyServiceBuilder:
def __init__(self):
self._instance = None
... | 72 | 28.83 | 101 | 13 | 461 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_bfa1eba96b2979d0_e5c1b38e", "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."
] | [
34
] | [
null
] | [
15
] | [
98
] | |
2024-11-19T00:24:54.838338+00:00 | 1,600,437,481,000 | f46ff80772755e8b03d7081c30f40abcbf7a20f4 | 3 | {
"blob_id": "f46ff80772755e8b03d7081c30f40abcbf7a20f4",
"branch_name": "refs/heads/main",
"committer_date": 1600437481000,
"content_id": "b0ae562ddaa692bdd8669808277ac2b616848997",
"detected_licenses": [
"MIT"
],
"directory_id": "ee6c484d3d24d38e59d021a3280ae8d284d4b7e7",
"extension": "py",
"file... | 2.625 | stackv2 | import json
import os
import shutil
import sys
import tarfile
import tempfile
from DockerLayer import DockerLayer
def _get_docker_layers(manifest_json, config_json):
history_arr = config_json['history']
layer_path_arr = manifest_json[0]['Layers']
config_history_not_empty_arr = [historyObject for historyO... | 65 | 36.83 | 114 | 17 | 573 | python | [{"finding_id": "codeql_py/tarslip_19e63188990d35f7_dcf5c90e", "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)."
] | [
37
] | [
null
] | [
9
] | [
10
] | |
2024-11-19T00:25:09.400066+00:00 | 1,485,132,624,000 | 76a746d2064edb92925b6ecf99664f9a9217a0fb | 2 | {
"blob_id": "76a746d2064edb92925b6ecf99664f9a9217a0fb",
"branch_name": "refs/heads/master",
"committer_date": 1485132624000,
"content_id": "a412fcbf0a83a64ddc05f06a85674ccb7ee00ce5",
"detected_licenses": [
"MIT"
],
"directory_id": "dfaf308219f4dee56a3f152360f71fd90953d364",
"extension": "py",
"fi... | 2.4375 | stackv2 | from pyramid.response import Response
from pyramid.view import view_config
from sqlalchemy.exc import DBAPIError
"""Imports we care about."""
from pyramid.httpexceptions import HTTPFound
from ..models import Keyword, Match
from subprocess import call
import os
HERE = os.path.dirname(__file__)
@view_config(route... | 128 | 31.52 | 117 | 22 | 1,012 | python | [{"finding_id": "codeql_py/reflective-xss_3a43a52c799b8798_b6c18c58", "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)."
] | [
81
] | [
null
] | [
12
] | [
54
] | |
2024-11-19T00:36:47.537701+00:00 | 1,622,281,897,000 | 3def549715f636e0833377571953dee761ef8834 | 3 | {
"blob_id": "3def549715f636e0833377571953dee761ef8834",
"branch_name": "refs/heads/main",
"committer_date": 1622281897000,
"content_id": "a213cb016e7e01425200da0465dda1f15c4d792e",
"detected_licenses": [
"MIT"
],
"directory_id": "71fa6cec6b0ed347b6068ff1bf442b214c94f213",
"extension": "py",
"file... | 2.703125 | stackv2 | import uvicorn
import fastapi
from fastapi import FastAPI, Form
app: FastAPI = FastAPI()
@app.get("/")
def index():
html = "<h2>KASSK & Mrozy 2021</h2>"
return fastapi.responses.HTMLResponse(html)
@app.get("/welcome/")
def welcome(user: str, welcome: str = "Python"):
html = f"<h3>Witaj {user} - z tej s... | 54 | 22.22 | 71 | 11 | 362 | python | [{"finding_id": "codeql_py/reflective-xss_4f1f5a0f296a9f65_6b61cac2", "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).\nCross-site scripting vulnerability d... | 1 | true | [
"CWE-079"
] | [
"py/reflective-xss"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"Cross-site scripting vulnerability due to a [user-provided value](1).\nCross-site scripting vulnerability due to a [user-provided value](2)."
] | [
17
] | [
null
] | [
43
] | [
47
] | |
2024-11-19T00:36:51.278303+00:00 | 1,598,053,770,000 | cc670b9cd63eaba335bd53b3af1e27be3854dc71 | 2 | {
"blob_id": "cc670b9cd63eaba335bd53b3af1e27be3854dc71",
"branch_name": "refs/heads/master",
"committer_date": 1598053770000,
"content_id": "bc95ba2ab867a6d661062ff1376168388777a138",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "ca1ca34c9fffee38bcb2ea3e2c210623a2158b0b",
"extension": "py"... | 2.375 | stackv2 | import requests
from datetime import datetime, timedelta
from odoo.exceptions import Warning
import re
import random
from kubernetes import client, config
from kubernetes.stream import stream
def _check_api_rights(api_url, api_token, namespace, verb, resource):
hed = {'Authorization': 'Bearer ' + api_token}
d... | 127 | 30.01 | 84 | 13 | 956 | python | [{"finding_id": "codeql_py/request-without-cert-validation_42854fcb47dd6906_94cb5552", "tool_name": "codeql", "rule_id": "py/request-without-cert-validation", "finding_type": "problem", "severity": "medium", "confidence": "medium", "message": "This request may run without certificate validation because [it is disabled]... | 1 | true | [
"CWE-295"
] | [
"py/request-without-cert-validation"
] | [
"MEDIUM"
] | [
"MEDIUM"
] | [
"This request may run without certificate validation because [it is disabled](1)."
] | [
21
] | [
null
] | [
16
] | [
72
] | |
2024-11-19T00:36:58.699626+00:00 | 1,601,404,460,000 | fd2bcde5385f7511a135dbb78157186899df6c9b | 3 | {
"blob_id": "fd2bcde5385f7511a135dbb78157186899df6c9b",
"branch_name": "refs/heads/master",
"committer_date": 1601404460000,
"content_id": "1c362ad7486b0a1887b8ed6c9c386259848b5a4b",
"detected_licenses": [
"MIT"
],
"directory_id": "6f826a3703a7505e026da283516702067a8d4ffa",
"extension": "py",
"fi... | 2.828125 | stackv2 | #!/usr/bin/env python
__author__ = 'Manuel Velasco'
import requests
def astronaut_info():
astronauts_names = requests.get("http://api.open-notify.org/astros.json")
list_name = astronauts_names.json()["people"]
print(f'number of astronaut {len(list_name)}')
for value in list_name:
print(f"... | 44 | 18.61 | 77 | 13 | 218 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_0f32ccef1ffecdc5_6a0e3bcf", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (private)](1) as clear text.", "... | 2 | true | [
"CWE-312",
"CWE-312"
] | [
"py/clear-text-logging-sensitive-data",
"py/clear-text-logging-sensitive-data"
] | [
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM"
] | [
"This expression logs [sensitive data (private)](1) as clear text.",
"This expression logs [sensitive data (private)](1) as clear text."
] | [
25,
26
] | [
null,
null
] | [
11,
11
] | [
46,
48
] | |
2024-11-19T01:02:16.156143+00:00 | 1,630,752,857,000 | 33d12450a070d423768bce535b78a0ed65a74b59 | 4 | {
"blob_id": "33d12450a070d423768bce535b78a0ed65a74b59",
"branch_name": "refs/heads/main",
"committer_date": 1630752857000,
"content_id": "551d23965cf6cc0fb84bebe42b0a69553169a4bf",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "5f0089466266e5a118b8257a49623b095f972737",
"extension": "py",
... | 4.25 | stackv2 | """
请实现 copyRandomList 函数,复制一个复杂链表。
在复杂链表中,每个节点除了有一个 next 指针指向下一个节点,
还有一个 random 指针指向链表中的任意节点或者 null。
示例 1:
输入:head = [[7,null],[13,0],[11,4],[10,2],[1,0]]
输出:[[7,null],[13,0],[11,4],[10,2],[1,0]]
示例 2:
输入:head = [[1,1],[2,1]]
输出:[[1,1],[2,1]]
示例 3:
输入:head = [[3,null],[3,0],[3,null]]
输出:[[3,null],[3,0],[3,null]]
示例 4... | 102 | 22.16 | 75 | 14 | 856 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_4e5005cdb124e1bc_135c91f3", "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."
] | [
102
] | [
null
] | [
11
] | [
58
] | |
2024-11-18T23:48:43.402947+00:00 | 1,523,128,088,000 | aa7dbb6ad62a3d6e01f27ce86247fc7d7fb46169 | 3 | {
"blob_id": "aa7dbb6ad62a3d6e01f27ce86247fc7d7fb46169",
"branch_name": "refs/heads/master",
"committer_date": 1523128088000,
"content_id": "003aa79969933a4dfbf251ac27ae6e006bb43618",
"detected_licenses": [
"MIT"
],
"directory_id": "31754867be82339d5ae513f964988f674ae3fc84",
"extension": "py",
"fi... | 3.203125 | stackv2 | # Based on the tutorial from https://www.youtube.com/watch?v=27Fjrlx4s-o
from flask import Flask
app = Flask(__name__) # root path
# Routing/Mapping (connect python function to webpage)
# Use @ decorator to wrap and modify behavior of a python function
@app.route('/') # connect a webpage (/ for root directory)
def in... | 26 | 30.88 | 79 | 8 | 217 | python | [{"finding_id": "codeql_py/flask-debug_c9e8de80cb8ee435_30c2511e", "tool_name": "codeql", "rule_id": "py/flask-debug", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", ... | 3 | true | [
"CWE-215",
"CWE-079",
"CWE-079"
] | [
"py/flask-debug",
"py/reflective-xss",
"py/reflective-xss"
] | [
"HIGH",
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.",
"Cross-site scripting vulnerability due to a [user-provided value](1).",
"Cross-site scripting vulnerability due to a [user-provided value](1)."
] | [
26,
19,
23
] | [
null,
null,
null
] | [
2,
9,
9
] | [
21,
40,
47
] | |
2024-11-18T23:50:00.923838+00:00 | 1,555,733,269,000 | e23fade968f2a28851babbf9ef85d3a5b70ed934 | 2 | {
"blob_id": "e23fade968f2a28851babbf9ef85d3a5b70ed934",
"branch_name": "refs/heads/master",
"committer_date": 1555733294000,
"content_id": "514d9e6046d03649db3d7c381ae8ece06bbd0ffa",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "7410c96bbc3414ac7c42c0b7c6847f54fdadbc28",
"extension": "py"... | 2.34375 | stackv2 | from flask import jsonify, request, Response
from app import app
from app.validating_apis import pods
@app.route("/api/v1/validate/podtemplate/pod-readiness", methods=["POST"])
def podtemplate_pod_readiness():
"""
:return: (http) response
"""
allowed = True
result = ""
data = request.json # K... | 32 | 28.47 | 79 | 14 | 216 | python | [{"finding_id": "codeql_py/stack-trace-exposure_163cee55eb035b62_a354af83", "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."
] | [
31
] | [
null
] | [
20
] | [
28
] | |
2024-11-19T01:51:53.797287+00:00 | 1,629,859,079,000 | d9e20cbe3e9870f56d927cc5c51c07e76be7bf0c | 3 | {
"blob_id": "d9e20cbe3e9870f56d927cc5c51c07e76be7bf0c",
"branch_name": "refs/heads/main",
"committer_date": 1629859079000,
"content_id": "6868be8622a31ffd64b6ea4fce2033498c481272",
"detected_licenses": [
"MIT"
],
"directory_id": "087fdfcd157fa626f63ef22da7813b66531c18e9",
"extension": "py",
"file... | 2.796875 | stackv2 | # -*- coding: utf-8 -*-
__author__ = 'Kay'
import datetime
import json
import os
import re
import numpy as np
import pandas as pd
import pendulum
keywords = [w.strip() for w in open("data/keywords.txt")]
def load_user_data(in_name):
'''
载入用户全部数据
:param in_name:
:return:
'''
user_data = []
... | 233 | 24.36 | 105 | 19 | 1,678 | python | [{"finding_id": "codeql_py/clear-text-storage-sensitive-data_45c25808b616bbbf_035b51ec", "tool_name": "codeql", "rule_id": "py/clear-text-storage-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression stores [sensitive data (private)](1) as clear text.",... | 2 | true | [
"CWE-312",
"CWE-312"
] | [
"py/clear-text-storage-sensitive-data",
"py/clear-text-logging-sensitive-data"
] | [
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM"
] | [
"This expression stores [sensitive data (private)](1) as clear text.",
"This expression logs [sensitive data (private)](1) as clear text."
] | [
228,
227
] | [
null,
null
] | [
25,
23
] | [
62,
24
] | |
2024-11-19T01:51:54.302365+00:00 | 1,558,204,993,000 | f3647ce0db9d9d49331718264efb7c09bd4b9041 | 3 | {
"blob_id": "f3647ce0db9d9d49331718264efb7c09bd4b9041",
"branch_name": "refs/heads/master",
"committer_date": 1558204993000,
"content_id": "9e45b928153e9e51577811b3a49c1ffae16dfa7e",
"detected_licenses": [
"MIT"
],
"directory_id": "db82aa7ccbe18abc7078e0caba69647e2ca6bfe6",
"extension": "py",
"fi... | 2.734375 | stackv2 | from __future__ import division
from nltk.stem.porter import PorterStemmer
from collections import defaultdict
from collections import Counter
import statistics
import math
import re
def apply_boost(scores, boost=1.0):
return {uuid: score * boost for uuid, score in scores.items()}
class TagsField(object):
... | 135 | 35.82 | 120 | 23 | 1,130 | python | [{"finding_id": "codeql_py/overly-large-range_c643ec135d673fdb_3a059e39", "tool_name": "codeql", "rule_id": "py/overly-large-range", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Suspicious character range that is equivalent to \\[A-Z\\\\[\\\\\\\\]^_`a-z\\].", "remediation": "", "lo... | 1 | true | [
"CWE-020"
] | [
"py/overly-large-range"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"Suspicious character range that is equivalent to \\[A-Z\\\\[\\\\\\\\]^_`a-z\\]."
] | [
82
] | [
null
] | [
32
] | [
35
] | |
2024-11-19T00:55:23.440084+00:00 | 1,630,567,426,000 | f16587ec68569b6a29690f37f732cc70350e2131 | 3 | {
"blob_id": "f16587ec68569b6a29690f37f732cc70350e2131",
"branch_name": "refs/heads/main",
"committer_date": 1630567426000,
"content_id": "c11c29b95af7a0bb80e067996bd5047677ac266e",
"detected_licenses": [
"MIT"
],
"directory_id": "a71266c618fbc9ec554bc916265c04489d580ed1",
"extension": "py",
"file... | 2.875 | stackv2 | import tkinter as tk
from tkinter.constants import CENTER, RIDGE
from tkinter import messagebox
import sqlite3
def login():
root.destroy()
from loginwindow import loginWindow
loginWindow()
def signUp():
Name = name.get()
Username = username.get()
Email = email.get()
Password = password.get... | 110 | 45.92 | 172 | 15 | 1,433 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_4965960aadb2e817_78a3a87a", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (password)](1) as clear text.\nT... | 1 | true | [
"CWE-312"
] | [
"py/clear-text-logging-sensitive-data"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"This expression logs [sensitive data (password)](1) as clear text.\nThis expression logs [sensitive data (password)](2) as clear text.\nThis expression logs [sensitive data (password)](3) as clear text.\nThis expression logs [sensitive data (password)](4) as clear text."
] | [
38
] | [
null
] | [
19
] | [
137
] | |
2024-11-19T00:55:25.609743+00:00 | 1,426,850,574,000 | c50c12f9d7c414dde9cb025d3cbeda7d4acc8646 | 3 | {
"blob_id": "c50c12f9d7c414dde9cb025d3cbeda7d4acc8646",
"branch_name": "refs/heads/master",
"committer_date": 1426850574000,
"content_id": "9900845de705eb64f7ad4cc37082398f96083ec0",
"detected_licenses": [
"MIT"
],
"directory_id": "4d4397e7d478ac11e9098ceec107c2aa16197944",
"extension": "py",
"fi... | 2.671875 | stackv2 | #!/usr/bin/python
import os
import paramiko
import subprocess
import json
def ssh_command(ip, port, user, passwd, command):
client = paramiko.SSHClient()
if os.path.exists("~/.ssh/known_hosts"):
client.load_host_keys('~/.ssh/known_hosts')
client.set_missing_host_key_policy(paramiko.AutoAddPolicy... | 47 | 25.51 | 73 | 16 | 290 | python | [{"finding_id": "codeql_py/paramiko-missing-host-key-validation_6b78d70d43a1bd47_121ee13e", "tool_name": "codeql", "rule_id": "py/paramiko-missing-host-key-validation", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Setting missing host key policy to AutoAddPolicy may be unsafe.", "r... | 1 | true | [
"CWE-295"
] | [
"py/paramiko-missing-host-key-validation"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"Setting missing host key policy to AutoAddPolicy may be unsafe."
] | [
14
] | [
null
] | [
5
] | [
65
] | |
2024-11-19T00:55:25.989693+00:00 | 1,470,415,398,000 | cf6d2f2d8bfb472ad9479b7311b41692762574fd | 2 | {
"blob_id": "cf6d2f2d8bfb472ad9479b7311b41692762574fd",
"branch_name": "refs/heads/master",
"committer_date": 1470415398000,
"content_id": "df11df56dbd2206ca9045c2a81006c48432cc9a1",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "a2ee50cba4fe11a6960f9980f435d2c97fead0eb",
"extension": "py"... | 2.46875 | stackv2 | #!/usr/bin/python
# -*- coding: utf-8 -*-
DOCUMENTATION = '''
---
module: ipa_group
short_description: Manager IPA group
description:
- Add, modify and delete group within IPA server
options:
name:
description:
- Group name
required: true
gidnumber:
description:
- GID
required: false
stat... | 199 | 30.73 | 119 | 17 | 1,420 | python | [{"finding_id": "codeql_py/request-without-cert-validation_f2c9a858280b05ea_e7dd65f5", "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)."
] | [
103,
113
] | [
null,
null
] | [
17,
17
] | [
81,
120
] | |
2024-11-18T23:43:31.553576+00:00 | 1,620,187,435,000 | a25c09d04dcadf41ef5ec6555bcedc443ce45154 | 3 | {
"blob_id": "a25c09d04dcadf41ef5ec6555bcedc443ce45154",
"branch_name": "refs/heads/master",
"committer_date": 1620187435000,
"content_id": "a5b557d5769dbc26fe50f31ce6a8066348a9f6b2",
"detected_licenses": [
"MIT"
],
"directory_id": "a0f1322c5125d8feeb823288bbca5332e58b8d92",
"extension": "py",
"fi... | 2.828125 | stackv2 | from blind_watermark import WaterMark
import os
import argparse
import logging
import random
logging.basicConfig(level=logging.INFO)
lg = logging.getLogger(__name__)
class Marker:
def __init__(self, password_wm, password_img):
self._password_wm = password_wm
self._password_img = password_img
... | 137 | 35.15 | 110 | 17 | 1,170 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_a0d2d378e502215f_a7d2bab2", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (password)](1) as clear text.\nT... | 4 | true | [
"CWE-312",
"CWE-312",
"CWE-312",
"CWE-312"
] | [
"py/clear-text-logging-sensitive-data",
"py/clear-text-logging-sensitive-data",
"py/clear-text-logging-sensitive-data",
"py/clear-text-logging-sensitive-data"
] | [
"HIGH",
"HIGH",
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"This expression logs [sensitive data (password)](1) as clear text.\nThis expression logs [sensitive data (password)](2) as clear text.\nThis expression logs [sensitive data (password)](3) as clear text.\nThis expression logs [sensitive data (password)](4) as clear text.\nThis expression logs [sensitive data (passw... | [
47,
48,
54,
126
] | [
null,
null,
null,
null
] | [
17,
17,
17,
25
] | [
58,
110,
25,
29
] | |
2024-11-19T00:33:03.699839+00:00 | 1,561,873,712,000 | 164d20fb5bad81b8fbc98cfa2bd6ecadbbda6d8f | 3 | {
"blob_id": "164d20fb5bad81b8fbc98cfa2bd6ecadbbda6d8f",
"branch_name": "refs/heads/master",
"committer_date": 1561873712000,
"content_id": "a5a7ab3c7f4bc537afd29621d974a6e7da395f32",
"detected_licenses": [
"MIT"
],
"directory_id": "034bff64c7d0b36f2ac9018bbb9052d0b0ee08b9",
"extension": "py",
"fi... | 2.828125 | stackv2 |
import codecs
import qrcode
import sh
import StringIO
import sys
from jinja2 import Template
from urlparse import urljoin
def main():
template_file = sys.argv[1]
students_list_file = sys.argv[2]
base_url = sys.argv[3]
for student in get_students_list(students_list_file, base_url):
s... | 87 | 29.05 | 77 | 15 | 667 | python | [{"finding_id": "codeql_py/jinja2/autoescape-false_d623222115fcb9bb_34a008d9", "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."
] | [
73
] | [
null
] | [
20
] | [
38
] | |
2024-11-19T00:33:05.091126+00:00 | 1,617,907,633,000 | d0416487680557b63a979f1ffee147a61ef1397c | 3 | {
"blob_id": "d0416487680557b63a979f1ffee147a61ef1397c",
"branch_name": "refs/heads/main",
"committer_date": 1617907633000,
"content_id": "988009317ea0ced4c96a3a71fc2d983364fe492f",
"detected_licenses": [
"MIT"
],
"directory_id": "e9bdb670784c52fe114f9d6021da279efaa642af",
"extension": "py",
"file... | 2.53125 | stackv2 | # Author: Irv Shapiro
# Website: https://cogitations.com
# YouTube Channel: https://youtube.com/c/drvax
# This program is derived from the Twilio example for microPython posted
# at https://www.twilio.com/blog/sms-doorbell-micropython-twilio
# It is also derived from various Adafruit CircuitPython web examples.
# Co... | 284 | 30.9 | 85 | 16 | 2,196 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_b101913d16b2bda3_8f208b6b", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (secret)](1) as clear text.", "r... | 2 | true | [
"CWE-312",
"CWE-312"
] | [
"py/clear-text-logging-sensitive-data",
"py/clear-text-logging-sensitive-data"
] | [
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM"
] | [
"This expression logs [sensitive data (secret)](1) as clear text.",
"This expression logs [sensitive data (secret)](1) as clear text."
] | [
97,
99
] | [
null,
null
] | [
15,
15
] | [
51,
51
] | |
2024-11-19T01:18:01.800500+00:00 | 1,576,059,985,000 | b437231c80645d2dc1f4eaba7e5603910a24d900 | 3 | {
"blob_id": "b437231c80645d2dc1f4eaba7e5603910a24d900",
"branch_name": "refs/heads/master",
"committer_date": 1576059985000,
"content_id": "a6231a7d0b5408bcdf2153858f6d2e598d2ce5d7",
"detected_licenses": [
"MIT"
],
"directory_id": "a7c3504236af0f2522bb8c547b31553876240537",
"extension": "py",
"fi... | 2.53125 | stackv2 | import copy
import re
from abc import abstractmethod
from emarkdown.Processor.ExtractProcessor.Config import TagConfig as Tag
from emarkdown.System.Tool import UUID, HTML_Entities
class BasicProcessor:
@property
@abstractmethod
def tag_name(self):
return NotImplementedError
@staticmethod
... | 67 | 38.39 | 116 | 18 | 670 | python | [{"finding_id": "codeql_py/redos_1ad1750fb8073908_cc6a24eb", "tool_name": "codeql", "rule_id": "py/redos", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "This part of the regular expression may cause exponential backtracking on strings starting with '<' and containing many repetition... | 1 | true | [
"CWE-1333"
] | [
"py/redos"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"This part of the regular expression may cause exponential backtracking on strings starting with '<' and containing many repetitions of 'a'."
] | [
20
] | [
null
] | [
29
] | [
38
] | |
2024-11-19T01:54:18.719324+00:00 | 1,621,032,840,000 | 29d5fa46f858a32b4906c92dc85cf3c31325bf28 | 2 | {
"blob_id": "29d5fa46f858a32b4906c92dc85cf3c31325bf28",
"branch_name": "refs/heads/master",
"committer_date": 1621032840000,
"content_id": "5a99c7fb86f8cf1b151ed16aec665942f395c001",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "022509b9caa1c42770243673bc725e248db5a4d5",
"extension": "py"... | 2.421875 | stackv2 | from datetime import datetime
import platform
import os
import csv
import implementML
import json
from flask import Flask, render_template, send_file, flash, request, redirect, url_for, send_from_directory
from polybot.version import __version__ # noqa: F401
from flask_cors import CORS
def create_app(test_config: di... | 83 | 35.24 | 146 | 16 | 657 | python | [{"finding_id": "codeql_py/url-redirection_cecb3ea9569baf60_b7d50c90", "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)."
] | [
41
] | [
null
] | [
29
] | [
40
] | |
2024-11-19T00:15:29.877409+00:00 | 1,599,562,599,000 | 87c1ac81b0fd7672b602568a101e9719c0b93094 | 4 | {
"blob_id": "87c1ac81b0fd7672b602568a101e9719c0b93094",
"branch_name": "refs/heads/master",
"committer_date": 1599562599000,
"content_id": "90fe4466f0fb5b85d1cbf2bcb2a41bc8e6635ae8",
"detected_licenses": [
"MIT"
],
"directory_id": "989a9a4fb42d68de68f5ec03dd83b880ff18cf22",
"extension": "py",
"fi... | 3.5625 | stackv2 | #!/usr/bin/env python3.8
from passwords import User, Credentials
import random
import string
def create_new_user(username, password):
'''
Function to create an instance of a user
'''
new_user = User(username, password)
return new_user
def save_user(user):
'''
Function that save a new user
... | 200 | 32.69 | 110 | 20 | 1,342 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_5a83649f7c18b6f5_c0668237", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (password)](1) as clear text.\nT... | 4 | true | [
"CWE-312",
"CWE-312",
"CWE-312",
"CWE-312"
] | [
"py/clear-text-logging-sensitive-data",
"py/clear-text-logging-sensitive-data",
"py/clear-text-logging-sensitive-data",
"py/clear-text-logging-sensitive-data"
] | [
"HIGH",
"HIGH",
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"This expression logs [sensitive data (password)](1) as clear text.\nThis expression logs [sensitive data (password)](2) as clear text.\nThis expression logs [sensitive data (password)](3) as clear text.\nThis expression logs [sensitive data (password)](4) as clear text.\nThis expression logs [sensitive data (passw... | [
143,
154,
167,
190
] | [
148,
157,
null,
null
] | [
27,
27,
23,
19
] | [
24,
23,
104,
70
] | |
2024-11-19T00:15:59.912708+00:00 | 1,534,989,055,000 | 55135443e22838e326920206bfb58db6b7b85d66 | 2 | {
"blob_id": "55135443e22838e326920206bfb58db6b7b85d66",
"branch_name": "refs/heads/master",
"committer_date": 1534989055000,
"content_id": "e638a81bdbd444f8753c14a42a1a29d526b2fc48",
"detected_licenses": [
"MIT"
],
"directory_id": "fa2874fbabcacd3719da2a4ecb27eb7afb682996",
"extension": "py",
"fi... | 2.40625 | stackv2 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import codecs
import os
import shutil
import json
import jinja2
import subprocess
import datetime
import time
import distutils
class XExecption(Exception):
pass
def save_file(fpath, fcontent):
with codecs.open(fpath, 'w', 'utf-8') as fp:
fp.write(fcont... | 188 | 23.7 | 69 | 15 | 1,207 | python | [{"finding_id": "codeql_py/jinja2/autoescape-false_3fc7c99a15ffef43_e5650972", "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."
] | [
38
] | [
null
] | [
19
] | [
52
] | |
2024-11-19T00:16:07.315305+00:00 | 1,564,516,350,000 | dfcf1958c906c6f367f566551686e7ca44d41140 | 2 | {
"blob_id": "dfcf1958c906c6f367f566551686e7ca44d41140",
"branch_name": "refs/heads/master",
"committer_date": 1564516350000,
"content_id": "125737a395345093c0161b8ef9f42204daf15ff5",
"detected_licenses": [
"BSD-2-Clause"
],
"directory_id": "61c60b0f1c3f5b9c757d73937b25235a347a1602",
"extension": "p... | 2.4375 | stackv2 | #!/usr/bin/python
#-*- coding: utf-8 -*-
#===========================================================
# File Name: vgg_dataset.py
# Author: Xu Zhang, Columbia University
# Creation Date: 09-26-2017
# Last Modified: Sun Mar 3 16:56:21 2019
#
# Description: VGG dataset
#
# Copyright (C) 2018 Xu Zhang
# All right... | 81 | 28.62 | 108 | 17 | 531 | python | [{"finding_id": "codeql_py/tarslip_4b8fcac6c3ff2f1a_43f4dbc9", "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)."
] | [
64
] | [
null
] | [
17
] | [
20
] | |
2024-11-19T00:16:09.662925+00:00 | 1,565,557,689,000 | 60e7b91e9066b4760eac660d84dc09bf013019dd | 3 | {
"blob_id": "60e7b91e9066b4760eac660d84dc09bf013019dd",
"branch_name": "refs/heads/master",
"committer_date": 1565557689000,
"content_id": "1ab61a6ab0417d29cc51284d97cf8012e3ac7896",
"detected_licenses": [
"MIT"
],
"directory_id": "4f4db6cba2c08aaeea683d176258792b82e07d1d",
"extension": "py",
"fi... | 2.703125 | stackv2 | # python package
import csv
import time
import random
import codecs
# selenium package
from selenium import webdriver
from selenium.webdriver.common.desired_capabilities import DesiredCapabilities
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.support import expected_conditions as EC
f... | 105 | 29.27 | 106 | 16 | 729 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_184b45ce34a7d98b_5f25f090", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (private)](1) as clear text.\nTh... | 1 | true | [
"CWE-312"
] | [
"py/clear-text-logging-sensitive-data"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"This expression logs [sensitive data (private)](1) as clear text.\nThis expression logs [sensitive data (private)](2) as clear text."
] | [
96
] | [
null
] | [
19
] | [
75
] | |
2024-11-19T00:28:42.529585+00:00 | 1,540,101,602,000 | b52a8638be5346d9707bdced24be23693522c12e | 3 | {
"blob_id": "b52a8638be5346d9707bdced24be23693522c12e",
"branch_name": "refs/heads/master",
"committer_date": 1540101602000,
"content_id": "e9390434fdd9a57cb8d871abf46438d1325b588c",
"detected_licenses": [
"MIT"
],
"directory_id": "9a7069a9044b2b26f7f95c4c611b69f3c4d91007",
"extension": "py",
"fi... | 2.625 | stackv2 | #!/usr/local/bin/python
# -*- coding: utf-8 -*-
from influxdb import InfluxDBClient
from pytz import timezone
from datetime import datetime
from flask import Flask, jsonify, request, render_template, make_response
import json
import calc
app = Flask(__name__)
# "/api"で起動するアプリ:書き込み
@app.route("/api", methods=['GET'])... | 102 | 31.59 | 132 | 17 | 1,008 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_5f52a54bbda0a8b3_e18459e9", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (password)](1) as clear text.", ... | 2 | true | [
"CWE-312",
"CWE-215"
] | [
"py/clear-text-logging-sensitive-data",
"py/flask-debug"
] | [
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM"
] | [
"This expression logs [sensitive data (password)](1) as clear text.",
"A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger."
] | [
94,
102
] | [
null,
null
] | [
40,
5
] | [
48,
51
] | |
2024-11-19T01:30:50.489142+00:00 | 1,648,524,643,000 | 21d9baf01991c3f4b2fd752aa3189dd235bbd569 | 2 | {
"blob_id": "21d9baf01991c3f4b2fd752aa3189dd235bbd569",
"branch_name": "refs/heads/master",
"committer_date": 1648524643000,
"content_id": "13b43a1fdb0ad067237c9d0f8f584e70ebbcb15f",
"detected_licenses": [
"BSD-2-Clause"
],
"directory_id": "f90d68474a77c838665dd08c18dd6e4acca09c86",
"extension": "p... | 2.3125 | stackv2 |
import os
import logging
import requests
from flask import Flask, Response, request
class ElasticsearchKibanaCLIInternalProxy:
debug = False
listen_port = 59200
listen_proto = 'http'
listen_address = '127.0.0.1'
header_overrides = {}
request_methods = ['GET', 'POST']
client_connect_addr... | 82 | 38.11 | 115 | 21 | 687 | python | [{"finding_id": "codeql_py/reflective-xss_14d2316e8233155f_8814d735", "tool_name": "codeql", "rule_id": "py/reflective-xss", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "Cross-site scripting vulnerability due to a [user-provided value](1).", "remediation": "", "location": {"fi... | 2 | true | [
"CWE-079",
"CWE-918"
] | [
"py/reflective-xss",
"py/partial-ssrf"
] | [
"HIGH",
"MEDIUM"
] | [
"MEDIUM",
"MEDIUM"
] | [
"Cross-site scripting vulnerability due to a [user-provided value](1).",
"Part of the URL of this request depends on a [user-provided value](1)."
] | [
80,
79
] | [
null,
null
] | [
29,
17
] | [
38,
91
] | |
2024-11-19T01:30:54.275753+00:00 | 1,603,391,706,000 | 52d6d19e70d96ede0dd1e1cbff87d826e3d6e18d | 2 | {
"blob_id": "52d6d19e70d96ede0dd1e1cbff87d826e3d6e18d",
"branch_name": "refs/heads/master",
"committer_date": 1603391706000,
"content_id": "b0371db9171fabd9da45824badd99ec8c03949ac",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "23f7b3e681b1a2a1ac03aac553482230ed653c41",
"extension": "py"... | 2.34375 | stackv2 | """
Copyright 2019 ShipChain, Inc.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, softwar... | 58 | 34.03 | 118 | 15 | 408 | python | [{"finding_id": "codeql_py/stack-trace-exposure_11a5de7de72ce1e5_7b33f001", "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."
] | [
36
] | [
37
] | [
53
] | [
65
] | |
2024-11-19T02:00:44.183230+00:00 | 1,583,156,628,000 | b8ad7856d22bd7d5f41e84ce82ef90cded0ddd6f | 3 | {
"blob_id": "b8ad7856d22bd7d5f41e84ce82ef90cded0ddd6f",
"branch_name": "refs/heads/master",
"committer_date": 1583156628000,
"content_id": "cb61fd15abb45fbbeed0d9df05473cc46f1a4267",
"detected_licenses": [
"MIT"
],
"directory_id": "afa484c201c79ad61d20f80f2555757814bf928b",
"extension": "py",
"fi... | 2.84375 | stackv2 | # -*- coding: utf-8 -*-
"""
Created on Tue Nov 12 21:45:48 2019
@author: user
"""
# -*- coding: utf-8 -*-
"""
Created on Tue Nov 12 20:50:42 2019
@author: user
"""
import requests
import xml.sax #xml解析套件
class XMLHandler(xml.sax.ContentHandler):
def __init__(self):#定義三個變數
self.car=''
self.time=... | 45 | 21.64 | 76 | 13 | 294 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_963f6543b12289b1_2ac573a3", "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."
] | [
30
] | [
null
] | [
19
] | [
28
] | |
2024-11-19T02:00:57.772317+00:00 | 1,613,540,013,000 | 0d01b5c285a8bb67cd2abf782bfede357184ce78 | 3 | {
"blob_id": "0d01b5c285a8bb67cd2abf782bfede357184ce78",
"branch_name": "refs/heads/main",
"committer_date": 1613540013000,
"content_id": "f1a163ba8eefee1287743e72bc77dc6671ccff7f",
"detected_licenses": [
"MIT"
],
"directory_id": "cd798e7b7754c2cc2482b9d3aeee5dd4718be93a",
"extension": "py",
"file... | 2.625 | stackv2 | from flask import Flask, request
import json
import requests
import argparse
app = Flask(__name__)
@app.route('/', methods=['GET', 'POST'])
def index():
print("****SNS Body", request.data)
data_json = json.loads(request.data)
if data_json['Type'] == 'Notification':
# New message received from the... | 48 | 35.06 | 104 | 14 | 373 | python | [{"finding_id": "codeql_py/flask-debug_34ff119ed7b18625_71001471", "tool_name": "codeql", "rule_id": "py/flask-debug", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.", ... | 3 | true | [
"CWE-215",
"CWE-918",
"CWE-918"
] | [
"py/flask-debug",
"py/full-ssrf",
"py/full-ssrf"
] | [
"HIGH",
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"A Flask app appears to be run in debug mode. This may allow an attacker to run arbitrary code through the debugger.",
"The full URL of this request depends on a [user-provided value](1).",
"The full URL of this request depends on a [user-provided value](1)."
] | [
48,
28,
33
] | [
null,
null,
null
] | [
5,
9,
9
] | [
56,
89,
48
] | |
2024-11-19T02:00:58.591831+00:00 | 1,345,773,641,000 | 6c3fde47d5c57ce4a98c57da42502a0fa42e112c | 2 | {
"blob_id": "6c3fde47d5c57ce4a98c57da42502a0fa42e112c",
"branch_name": "refs/heads/master",
"committer_date": 1345773641000,
"content_id": "ec25e5adc42ebbca08ad1bd25a80112ff0241afa",
"detected_licenses": [
"BSD-2-Clause"
],
"directory_id": "64a27a9d6f0035dfd52914e94a0ce86514b4612b",
"extension": "p... | 2.4375 | stackv2 | #!/usr/bin/env python3
import socket, sys, threading, queue, configparser, argparse
from re import split, sub, match
from time import sleep
import ssl, logging
class SingleMessageSocketWrapper:
def __init__(self, socket):
self.socket = socket
self.recvBuffer = ""
def recv(self):
... | 296 | 34.92 | 90 | 25 | 2,470 | python | [{"finding_id": "codeql_py/insecure-protocol_2d5d2f24ff6177fd_e5eb68cf", "tool_name": "codeql", "rule_id": "py/insecure-protocol", "finding_type": "problem", "severity": "medium", "confidence": "high", "message": "Insecure SSL/TLS protocol version TLSv1 allowed by [call to ssl.SSLContext](1).\nInsecure SSL/TLS protocol... | 1 | true | [
"CWE-327"
] | [
"py/insecure-protocol"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"Insecure SSL/TLS protocol version TLSv1 allowed by [call to ssl.SSLContext](1).\nInsecure SSL/TLS protocol version TLSv1_1 allowed by [call to ssl.SSLContext](1)."
] | [
147
] | [
null
] | [
20
] | [
27
] | |
2024-11-19T00:40:23.623206+00:00 | 1,544,645,609,000 | b60d1a45873654cdba31ee65ff609844043e4fcb | 3 | {
"blob_id": "b60d1a45873654cdba31ee65ff609844043e4fcb",
"branch_name": "refs/heads/master",
"committer_date": 1544645609000,
"content_id": "c03e6065bb6dd03888cfcecd73e8bca8057d6f2d",
"detected_licenses": [
"MIT"
],
"directory_id": "b36b9acbf618e8457a844fa5cfe86977b109fb18",
"extension": "py",
"fi... | 2.53125 | stackv2 | from flask import (
Blueprint, redirect, render_template, request, session, url_for
)
from . import reddit
from flask import current_app
from datetime import datetime
import pymongo
import json
import requests
import pytz
bp = Blueprint('reddit', __name__, url_prefix='/reddit')
def time_from_int(unix_time):
... | 139 | 40.62 | 149 | 16 | 1,397 | python | [{"finding_id": "codeql_py/partial-ssrf_53fadbbbf4d6f3c2_d46a132b", "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)."
] | [
77
] | [
null
] | [
16
] | [
50
] | |
2024-11-19T00:40:27.990476+00:00 | 1,515,834,052,000 | 90af8232c0f61640e3d2a72c2aad55a2e5c59c91 | 3 | {
"blob_id": "90af8232c0f61640e3d2a72c2aad55a2e5c59c91",
"branch_name": "refs/heads/master",
"committer_date": 1515834052000,
"content_id": "764dde291a921c11629047b9893d07859cb33f45",
"detected_licenses": [
"MIT"
],
"directory_id": "6c393ee872d411d5aec8d99bd893ddd603ba7da6",
"extension": "py",
"fi... | 2.71875 | stackv2 | from selenium import webdriver
from bs4 import BeautifulSoup
from collections import defaultdict
import time
import json
import urllib
import re
import csv
import sys
driver = webdriver.Chrome()
linkedin_email = ""
linkedin_password = ""
with open('jquery-3.2.1.min.js', 'r') as jquery_js:
jquery = jquery_js.read()... | 108 | 32.1 | 138 | 14 | 857 | python | [{"finding_id": "codeql_py/clear-text-logging-sensitive-data_654814bcb9604ffe_8ecaa4d4", "tool_name": "codeql", "rule_id": "py/clear-text-logging-sensitive-data", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This expression logs [sensitive data (private)](1) as clear text.", "... | 1 | true | [
"CWE-312"
] | [
"py/clear-text-logging-sensitive-data"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"This expression logs [sensitive data (private)](1) as clear text."
] | [
58
] | [
null
] | [
8
] | [
39
] | |
2024-11-19T01:17:12.585967+00:00 | 1,421,279,762,000 | 18a668362b0f11432e83880f5622e41bd5312978 | 2 | {
"blob_id": "18a668362b0f11432e83880f5622e41bd5312978",
"branch_name": "refs/heads/master",
"committer_date": 1421279762000,
"content_id": "18de0d00cd6b994e77090b3b732bb93f16d07f27",
"detected_licenses": [
"MIT"
],
"directory_id": "150967e8258c697152c4f167e571784e796a07c3",
"extension": "py",
"fi... | 2.328125 | stackv2 | from flask import Flask
from flask import render_template
from flask import request
import subprocess
from subprocess import TimeoutExpired
import platform
app = Flask(__name__)
@app.route('/', methods=['POST', 'GET'])
def main():
if request.method == 'POST':
dataRow = request.data.decode('utf-8')
... | 46 | 26.91 | 88 | 17 | 287 | python | [{"finding_id": "codeql_py/command-line-injection_4a63c59e3add5378_6660c3c7", "tool_name": "codeql", "rule_id": "py/command-line-injection", "finding_type": "path-problem", "severity": "medium", "confidence": "high", "message": "This command line depends on a [user-provided value](1).", "remediation": "", "location": {... | 1 | true | [
"CWE-078"
] | [
"py/command-line-injection"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"This command line depends on a [user-provided value](1)."
] | [
30
] | [
null
] | [
34
] | [
40
] | |
2024-11-19T01:17:24.906310+00:00 | 1,626,287,989,000 | 4515374f911d76dc77a623a357bb49190c171936 | 2 | {
"blob_id": "4515374f911d76dc77a623a357bb49190c171936",
"branch_name": "refs/heads/main",
"committer_date": 1626287989000,
"content_id": "2aba3174c5e1aa5f8cb2809e28c8bd52a4ee89fa",
"detected_licenses": [
"MIT"
],
"directory_id": "8c6f2b3fc0ff7bd2a4dc854654959df86c0a55ea",
"extension": "py",
"file... | 2.390625 | stackv2 | import uuid
from logging import getLogger
from typing import Any, Dict, List
from fastapi import APIRouter
from src.configurations import ModelConfigurations
from src.ml.prediction import Data, classifier
logger = getLogger(__name__)
router = APIRouter()
@router.get("/health")
def health() -> Dict[str, str]:
re... | 43 | 29.02 | 83 | 13 | 317 | python | [{"finding_id": "codeql_py/log-injection_acf1a3c847c4707a_0a82fb24", "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... | 2 | true | [
"CWE-117",
"CWE-117"
] | [
"py/log-injection",
"py/log-injection"
] | [
"MEDIUM",
"MEDIUM"
] | [
"MEDIUM",
"MEDIUM"
] | [
"This log entry depends on a [user-provided value](1).",
"This log entry depends on a [user-provided value](1)."
] | [
34,
42
] | [
null,
null
] | [
17,
17
] | [
75,
75
] | |
2024-11-19T01:18:09.371456+00:00 | 1,557,979,708,000 | 23e588b3f819e5dca3f32fe4ea111dbc36f7eebb | 3 | {
"blob_id": "23e588b3f819e5dca3f32fe4ea111dbc36f7eebb",
"branch_name": "refs/heads/master",
"committer_date": 1557979708000,
"content_id": "7b2764958e89114bc6e4574167a73e17c8a3931e",
"detected_licenses": [
"MIT"
],
"directory_id": "3c5b2449c8e791702bb7f40e9ec083f7e7f67111",
"extension": "py",
"fi... | 2.6875 | stackv2 | import requests
import csv
from datetime import datetime
from requests.packages.urllib3.exceptions import InsecureRequestWarning
requests.packages.urllib3.disable_warnings(InsecureRequestWarning)
url = 'https://pemilu2019.kpu.go.id/static/json/wilayah'
t_url = 'https://pemilu2019.kpu.go.id/static/json/hhcw/ppwp'
de... | 91 | 32.22 | 115 | 18 | 890 | python | [{"finding_id": "codeql_py/request-without-cert-validation_cebcfea7adf19dce_01182c2a", "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)."
] | [
13,
22
] | [
null,
null
] | [
12,
14
] | [
49,
57
] | |
2024-11-19T01:18:10.911009+00:00 | 1,481,832,259,000 | 4c59dae1517d81941077431e1d168d6c616cb01b | 3 | {
"blob_id": "4c59dae1517d81941077431e1d168d6c616cb01b",
"branch_name": "refs/heads/master",
"committer_date": 1481832259000,
"content_id": "95c2ffba949f818e6f14e86d23b8f9f829ea9af6",
"detected_licenses": [
"MIT"
],
"directory_id": "7a2cf4c5b97612cf5d3c8224045750a455ea0e33",
"extension": "py",
"fi... | 3.03125 | stackv2 | # Server.py
# Python 2.7
# Authors: Coleman Platt, Erich Smith
# Last modified: Dec. 2, 2016
#This program creates servers with either raw socket/https/tcp
#protocols. (needs to be added)
import BaseHTTPServer
import socket
import sys
import ssl
MAX_FILENAME = 255
#==============================Function that makes ... | 160 | 26.79 | 86 | 16 | 1,067 | python | [{"finding_id": "codeql_py/insecure-default-protocol_cdf2296c66d1f672_8f4dabd8", "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."
] | [
44
] | [
null
] | [
17
] | [
87
] | |
2024-11-19T01:32:02.695009+00:00 | 1,668,124,250,000 | def853e3f339fddc297c11dfc67f7b0c7ba35e95 | 3 | {
"blob_id": "def853e3f339fddc297c11dfc67f7b0c7ba35e95",
"branch_name": "refs/heads/main",
"committer_date": 1668124250000,
"content_id": "8eba9dd2a8eedd2715ace1a71c7f972dd7d8a5b6",
"detected_licenses": [
"BSD-3-Clause"
],
"directory_id": "5350578337b8aa87cf1cef555d1e2b7fef8f4345",
"extension": "py"... | 2.578125 | stackv2 | #!/usr/bin/env python3
"Summarise open issues."
from email.mime.multipart import MIMEMultipart
from email.mime.text import MIMEText
import json
import os
import smtplib
import ssl
import sys
from jinja2 import Template
import github_utils as github
def run(args):
people = json.load(args.subscriber_file)
fo... | 91 | 31.49 | 87 | 17 | 685 | python | [{"finding_id": "codeql_py/jinja2/autoescape-false_1ccd5c37c782cdb6_e35208ca", "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
] | [
16
] | [
39
] | |
2024-11-19T01:32:19.492166+00:00 | 1,623,426,288,000 | 86eba8ccc30fd958f53a6875abbee0914c3c5ddf | 2 | {
"blob_id": "86eba8ccc30fd958f53a6875abbee0914c3c5ddf",
"branch_name": "refs/heads/master",
"committer_date": 1623426288000,
"content_id": "31fe1b75002d1031b393d5e4245520509229e7bd",
"detected_licenses": [
"MIT"
],
"directory_id": "b4d336d3a2e0368e65a6a3b944d14a5cf6a1865a",
"extension": "py",
"fi... | 2.5 | stackv2 | #!/usr/bin/python
# -*- coding: utf-8 -*-
import argparse
import os
import requests
import time
import urllib3 # ignore InsecureRequestWarning
urllib3.disable_warnings(urllib3.exceptions.InsecureRequestWarning) # ignore InsecureRequestWarning
proxies = {
"http" : "http://127.0.0.1:8080",
"https" : "http://127.0.... | 50 | 32 | 120 | 10 | 439 | python | [{"finding_id": "codeql_py/request-without-cert-validation_3e54530e820b368a_36c80f67", "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)."
] | [
25,
30
] | [
null,
null
] | [
11,
11
] | [
102,
71
] | |
2024-11-19T01:43:44.448013+00:00 | 1,508,069,381,000 | b86fbd67d63315cb2e1775c1dd850269d01c6db2 | 3 | {
"blob_id": "b86fbd67d63315cb2e1775c1dd850269d01c6db2",
"branch_name": "refs/heads/master",
"committer_date": 1508069381000,
"content_id": "65cba0d33c2ba825fbd90a63b57e5d4940ea800e",
"detected_licenses": [
"MIT"
],
"directory_id": "d63b987111c939bb8442daedddc45eb713b9b811",
"extension": "py",
"fi... | 3.171875 | stackv2 | """template engine for container_generator
This module abstracts the template engine for the application.
At the moment, Jinja2 is used as engine
"""
import shutil
import re
from jinja2 import Environment
from jinja2 import FileSystemLoader
class TemplateEngine(object):
"""TemplateEngine class
This class can... | 44 | 35.36 | 79 | 16 | 329 | python | [{"finding_id": "codeql_py/jinja2/autoescape-false_b660472b821a6834_efb7ea62", "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
] | [
36
] | [
75
] | |
2024-11-19T01:44:05.667824+00:00 | 1,481,567,496,000 | 4c2c468ca1be05cc56f7dd57f72c0d258d28a7c1 | 3 | {
"blob_id": "4c2c468ca1be05cc56f7dd57f72c0d258d28a7c1",
"branch_name": "refs/heads/master",
"committer_date": 1481567496000,
"content_id": "21314854c8f9774c56bf13ee55a8c364067246f5",
"detected_licenses": [
"MIT"
],
"directory_id": "4e00210407ccb53e3ecc8261eddb37db59285abd",
"extension": "py",
"fi... | 2.6875 | stackv2 | from __future__ import unicode_literals, print_function
import logging
from nltk.corpus import stopwords
import nltk
import string
import re
from nltk.stem.snowball import SnowballStemmer
from nltk.stem.porter import *
from nltk.stem import porter
from nltk.stem.util import suffix_replace
from nltk.stem.api import St... | 91 | 23.55 | 110 | 14 | 583 | python | [{"finding_id": "codeql_py/overly-large-range_af45b635ee3c4dcc_bd7b6261", "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:;<=\\].", "remediation": "", "location"... | 1 | true | [
"CWE-020"
] | [
"py/overly-large-range"
] | [
"HIGH"
] | [
"MEDIUM"
] | [
"Suspicious character range that is equivalent to \\[+,\\-.\\/0-9:;<=\\]."
] | [
40
] | [
null
] | [
91
] | [
94
] | |
2024-11-19T00:59:46.920117+00:00 | 1,582,785,024,000 | 7b16910de9108218cc9cbb51054df52850f59ca6 | 2 | {
"blob_id": "7b16910de9108218cc9cbb51054df52850f59ca6",
"branch_name": "refs/heads/master",
"committer_date": 1582785024000,
"content_id": "c71ff90630aa2a4fa1ec400251a0923e96d51d6d",
"detected_licenses": [
"MIT"
],
"directory_id": "57909060d4fc4467a2aba10e74065e9a24f9c055",
"extension": "py",
"fi... | 2.4375 | stackv2 | import os
from flask import Flask, request, session
import cv2
import matplotlib.pyplot as plt
import numpy as np
import shutil
import glob
import pandas as pd
import pickle
import sys
Anomaly_Reference = pickle.load(open("Anomaly_Reference.pkl", "rb"))
app = Flask(__name__)
# what file extensions are allowed
ALLOWED... | 190 | 34.88 | 98 | 18 | 1,677 | python | [{"finding_id": "codeql_py/path-injection_cdc4bc955bf607b6_f8b047a6", "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", ... | 12 | true | [
"CWE-022",
"CWE-022",
"CWE-022",
"CWE-022",
"CWE-022",
"CWE-022",
"CWE-022",
"CWE-022",
"CWE-022",
"CWE-022",
"CWE-022",
"CWE-022"
] | [
"py/path-injection",
"py/path-injection",
"py/path-injection",
"py/path-injection",
"py/path-injection",
"py/path-injection",
"py/path-injection",
"py/path-injection",
"py/path-injection",
"py/path-injection",
"py/path-injection",
"py/path-injection"
] | [
"HIGH",
"HIGH",
"HIGH",
"HIGH",
"HIGH",
"HIGH",
"HIGH",
"HIGH",
"HIGH",
"HIGH",
"HIGH",
"HIGH"
] | [
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM",
"MEDIUM"
] | [
"This path depends on a [user-provided value](1).",
"This path depends on a [user-provided value](1).",
"This path depends on a [user-provided value](1).",
"This path depends on a [user-provided value](1).",
"This path depends on a [user-provided value](1).",
"This path depends on a [user-provided value](... | [
98,
99,
102,
105,
106,
107,
108,
109,
110,
123,
130,
130
] | [
null,
null,
null,
null,
null,
null,
null,
null,
null,
null,
null,
null
] | [
27,
27,
18,
18,
18,
18,
18,
18,
18,
18,
22,
32
] | [
31,
31,
38,
42,
35,
41,
45,
40,
42,
29,
30,
40
] | |
2024-11-19T00:59:59.646340+00:00 | 1,619,509,978,000 | c8850e7630e97e04e52b18de1001fcb41356258a | 2 | {
"blob_id": "c8850e7630e97e04e52b18de1001fcb41356258a",
"branch_name": "refs/heads/master",
"committer_date": 1619509978000,
"content_id": "d3a9ab85eb0c8d511464addd6e1e21832f70919b",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "67a0b708ee86c23102dcb03b90bcfed3e4e4181b",
"extension": "py"... | 2.40625 | stackv2 | import os
import textwrap
import shutil
import stat
from jinja2 import Environment, FileSystemLoader
import yzrpc
from . import CommandBase, CommandError
from yzrpc.utils import get_abspath
class Command(CommandBase):
formatter_cls_name = 'RawDescriptionHelpFormatter'
description = textwrap.dedent('''\
... | 200 | 33.42 | 79 | 22 | 1,465 | python | [{"finding_id": "codeql_py/jinja2/autoescape-false_777b235c27d3036f_221bf7c0", "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."
] | [
115
] | [
null
] | [
15
] | [
70
] | |
2024-11-19T01:00:07.831642+00:00 | 1,628,495,398,000 | d9a0f9e9f2d66616fd1e33ed29e20e1f65fd65a3 | 4 | {
"blob_id": "d9a0f9e9f2d66616fd1e33ed29e20e1f65fd65a3",
"branch_name": "refs/heads/main",
"committer_date": 1628495398000,
"content_id": "794c4441c01ae050a9e680708e354fffd75de17f",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "a87d09755a90e48d130a0f5ac4862fd1f19fbe86",
"extension": "py",
... | 3.6875 | stackv2 | import emoji
import string
import nltk
from nltk.corpus import stopwords
from nltk.corpus import wordnet
import re
import time
nltk.download('stopwords')
nltk.download('punkt')
def clean_tweets(df,content,col_name,
general_clean=True,lemma=True,stem=False,remove_tag=True,remove_mention=True,
... | 184 | 35.28 | 140 | 15 | 1,735 | python | [{"finding_id": "codeql_py/overly-large-range_02c1aea6f08ca196_09289164", "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 is equivalent to \\[$%&'()*+,\\-.\\/0-9:;<=>?@A-Z\\\\[\\\\\\\\]^_\\]."
] | [
159,
160
] | [
null,
null
] | [
50,
50
] | [
53,
53
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.