CodeQL library for Python
codeql/python-all 0.12.1 (changelog, source)
Search

Module StdlibPrivate

INTERNAL: Do not use.

Provides models for the Python standard library.

This module is marked private as exposing it means committing to 1-year deprecation policy, and the code is not in a polished enough state that we want to do so – at least not without having convincing use-cases for it :)

Import path

import semmle.python.frameworks.Stdlib

Predicates

base64

Gets a reference to the base64 module.

baseHttpServer

DEPRECATED: Use API-graphs directly instead.

cgi

Gets a reference to the cgi module.

cgiHttpServer

DEPRECATED: Use API-graphs directly instead.

compiledRegex
elementTreeClassRef

Gets a reference to the xml.etree.ElementTree class

getHmacConstructorCall
http

DEPRECATED: Use API-graphs directly instead.

json

Gets a reference to the json module.

os

Gets a reference to the os module.

pathlibPath

Gets a reference to a pathlib.Path object.

pickle

Gets a reference to any of the pickle modules.

pickle_load

Gets a reference to pickle.load

pickle_loads

Gets a reference to pickle.loads

platform

Gets a reference to the platform module.

popen2

Gets a reference to the popen2 module (only available in Python 2).

saxParserWithFeatureExternalGesTurnedOn

Gets a reference to a XML sax parser that has feature_external_ges turned on.

simpleHttpServer

DEPRECATED: Use API-graphs directly instead.

subprocess

Gets a reference to the subprocess module.

Classes

CopySummary

A flow summary for copy.

DictGetAnySummary

A flow summary for dict.get disregarding content.

DictGetSummary

A flow summary for dict.get at specific content.

DictItems

A flow summary for dict.items.

DictKeys

A flow summary for dict.keys.

DictPopSummary

A flow summary for dict.pop

DictPopitemSummary

A flow summary for dict.popitem

DictSetdefaultKeySummary

A flow summary for dict.setdefault at specific content. See https://docs.python.org/3.10/library/stdtypes.html#dict.setdefault This summary handles read and store steps. See DictSetdefaultSummary for the dataflow steps.

DictSetdefaultSummary

A flow summary for dict.setdefault.

DictSummary

A flow summary for dict.

DictValues

A flow summary for dict.values.

FrozensetSummary

A flow summary for frozenset

HashlibDataPassedToHashClass

A hashing operation from the hashlib package using one of the predefined classes (such as hashlib.md5), by passing data to when instantiating the class.

HashlibGenericHashOperation

A hashing operation from the hashlib package using one of the predefined classes (such as hashlib.md5). hashlib.new is not included, since it is handled by HashlibNewCall and HashlibNewUpdateCall.

HashlibHashClassUpdateCall

A hashing operation from the hashlib package using one of the predefined classes (such as hashlib.md5), by calling its’ update method.

HashlibNewCall

A hashing operation by supplying initial data when calling the hashlib.new function.

HashlibNewUpdateCall

A hashing operation by using the update method on the result of calling the hashlib.new function.

HmacCryptographicOperation
HmacDigestCall

A call to hmac.digest.

HmacNewCall

A call to hmac.new/hmac.HMAC.

HmacUpdateCall

A call to .update on an HMAC object.

IterSummary

A flow summary for iter.

ListAppend

A flow summary for list.append.

ListSummary

A flow summary for list.

LoggerLogCall

A call to one of the logging methods from logging or on a logging.Logger subclass.

NextSummary

A flow summary for next.

OsGetEnv

A flow summary for os.getenv / os.getenvb

PopSummary

A flow summary for pop either for list or set. This ignores the index if given, since content is imprecise anyway.

ReFunctionsSummary

A flow summary for re methods not returning a re.Match object

ReMatchMethodsSummary

A flow summary for methods on a re.Match object

ReMatchSummary

A flow summary for methods returning a re.Match object

RePatternSummary

A flow summary for compiled regex objects

ReversedSummary

A flow summary for reversed.

SetAdd

A flow summary for set.add.

SetSummary

A flow summary for set

SortedSummary

A flow summary for sorted.

Sqlite3

A model of sqlite3 as a module that implements PEP 249, providing ways to execute SQL statements against a database.

TupleSummary

A flow summary for tuple

UrllibParseUrlsplitCall

A call to urllib.parse.urlsplit

Modules

AsyncIO

Provides models for the asyncio module.

BaseHttpRequestHandler

Provides models for the BaseHTTPRequestHandler class and subclasses.

BaseHttpServer

DEPRECATED: Use API-graphs directly instead.

Cgi

Provides models for the cgi module.

CgiHttpServer

Provides models for the CGIHTTPServer module.

HttpConnection

Provides models for the http.client.HTTPConnection and HTTPSConnection classes

HttpResponse

Provides models for the http.client.HTTPResponse class

OS

Provides models for the os module.

SimpleHttpServer

DEPRECATED: Use API-graphs directly instead.

StdlibHttp

Provides models for the http module.

StringIO

Provides models for the io.StringIO/io.BytesIO classes

WsgirefSimpleServer

Provides models for the wsgiref.simple_server module.

XmlParser

Provides models for xml.etree parsers