The following changes in version 1.24 affect Python analysis in all applications.
-
Support for Django version 2.x and 3.x
-
Taint tracking now correctly tracks taint in destructuring assignments. For example, if
tainted_listis a list of tainted tainted elements, thenhead, *tail = tainted_list
will result in
tailbeing tainted with the same taint astainted_list, andheadbeing tainted with the taint of the elements oftainted_list. -
A large number of libraries and queries have been moved to the new
ValueAPI, which should result in more precise results. -
The
Valueinterface has been extended in various ways:- A new
StringValueclass has been added, for tracking string literals. - Values now have a
booleanValuemethod which returns the boolean interpretation of the given value. - Built-in methods for which the return type is not fixed are now modeled as returning an unknown value by default.
- A new
The CodeQL library has improved support for the web frameworks: Bottle, CherryPy, Falcon, Pyramid, TurboGears, Tornado, and Twisted. They now provide a proper HttpRequestTaintSource, instead of a TaintSource. This will enable results for the following queries:
py/path-injectionpy/command-line-injectionpy/reflective-xsspy/sql-injectionpy/code-injectionpy/unsafe-deserializationpy/url-redirection
The library also has improved support for the web framework Twisted. It now provides a proper
HttpResponseTaintSink, instead of a TaintSink. This will enable results for the following
queries:
py/reflective-xsspy/stack-trace-exposure
- The
urlsplitandurlparsefunctions now propagate taint appropriately. - HTTP requests using the
requestslibrary are now modeled.
