Rasmus Wriedt Larsen
a5a7f3e38a
Python: Add taint-step for sqlalchemy.text
2021-06-29 11:06:25 +02:00
Rasmus Wriedt Larsen
ef48734206
Python: Add taint-tests for SQLAlchemy
2021-06-29 11:03:40 +02:00
Rasmus Wriedt Larsen
cb112395f8
Python: Fixup after merging main
2021-06-29 11:02:43 +02:00
Rasmus Wriedt Larsen
684f51ae5f
Merge branch 'main' into python-use-sqlalchemy
2021-06-29 10:58:51 +02:00
Rasmus Wriedt Larsen
eac1c5d109
Python: Fix concepts-tests for SQLAlchemy
2021-06-29 10:58:28 +02:00
Rasmus Wriedt Larsen
686638a65f
Merge pull request #6049 from RasmusWL/jmespath
...
Python: Add modeling of `jmespath`
2021-06-24 11:13:19 +02:00
CodeQL CI
469e709113
Merge pull request #6055 from RasmusWL/rsa-modeling
...
Approved by yoff
2021-06-23 08:35:25 -07:00
Rasmus Wriedt Larsen
447099a1df
Python: Update jmespath tests
2021-06-23 13:32:19 +02:00
Rasmus Wriedt Larsen
e05d6e71b8
Merge pull request #6064 from tausbn/python-add-get-method-call
...
Python: Add `getAMethodCall` to `LocalSourceNode`
2021-06-22 11:16:39 +02:00
Taus
768cab3642
Python: Address review comments
...
- changes `getReceiver` to `getObject`
- fixes `calls` to avoid unwanted cross-talk
- adds some more documentation to highlight the above issue
2021-06-21 14:57:19 +00:00
Rasmus Wriedt Larsen
1c48aca630
Merge branch 'main' into jmespath
2021-06-21 15:26:45 +02:00
yoff
baf8d0a990
Merge pull request #6045 from RasmusWL/twisted
...
Python: Model twisted
2021-06-21 14:52:57 +02:00
Rasmus Wriedt Larsen
8208aebd7e
Python: Apply suggestions from code review
...
Co-authored-by: yoff <lerchedahl@gmail.com >
2021-06-21 10:43:25 +02:00
Anders Schack-Mulligen
b173b4141d
Merge pull request #6096 from smowton/smowton/fix/inline-expectations-missing-prefix
...
Inline expectation tests: accept // $MISSING: and // $SPURIOUS:
2021-06-17 11:41:15 +02:00
Chris Smowton
558813acf7
Inline expectation tests: accept // $MISSING: and // $SPURIOUS:
...
Previously there had to be a space after the $ token, unlike ordinary expectations (i.e., // $xss was already accepted)
2021-06-17 09:44:39 +01:00
CodeQL CI
bcafe532ac
Merge pull request #5944 from RasmusWL/async-api-graph-tests
...
Approved by tausbn
2021-06-16 08:46:26 -07:00
yoff
0ddeb7a8c1
Merge pull request #5950 from RasmusWL/promote-clickhouse
...
Python: Promote ClickHouse SQL models
2021-06-16 13:38:41 +02:00
yoff
b19d64f173
Merge pull request #6013 from RasmusWL/sensitive-improvements
...
Python: Improve sensitive data modeling
2021-06-15 14:45:40 +02:00
Rasmus Wriedt Larsen
156b10cb59
Merge branch 'main' into promote-clickhouse
2021-06-15 11:30:19 +02:00
Rasmus Wriedt Larsen
53f7633662
Python: Model await request.post() as MultiDictProxy
...
as highlight as being quite easy to do by @yoff 👍
2021-06-11 14:53:30 +02:00
Rasmus Wriedt Larsen
dee93783a2
Python: Update .expected for py/weak-sensitive-data-hashing
...
Now there is a path from the _imports_ of the functions that would
return sensitive data, so we produce more alerts.
I'm not entirely happy about this "double reporting", but I'm not sure
how to get around it without either:
1. disabling the extra taint-step for calls. Not ideal since we would
loose good sources.
2. disabling the extra sources based on function name. Not ideal since
we would loose good sources.
3. disabling the extra sources based on function name, for those calls
that would be handled with the extra taint-step for calls. Not ideal
since that would require running the data-flow query initially to
prune these out :|
So for now, I think the best approach is to accept some risk on this,
and ship to learn :)
2021-06-11 13:56:55 +02:00
Rasmus Wriedt Larsen
df67028a1d
Python: Model aiohttp.StreamReader
2021-06-11 12:06:53 +02:00
Rasmus Wriedt Larsen
2d31ef7016
Python: Fix last TODOs in aiohttp tests
2021-06-11 12:00:02 +02:00
Rasmus Wriedt Larsen
64a0e3fd0a
Merge branch 'main' into aiohttp-modeling
2021-06-11 11:42:24 +02:00
Rasmus Wriedt Larsen
6f29b01abc
Python: Model rsa
2021-06-11 11:23:06 +02:00
Rasmus Wriedt Larsen
40714c05b7
Python: Add tests for rsa PyPI package
2021-06-11 11:17:13 +02:00
Rasmus Wriedt Larsen
3d5f379b8c
Merge branch 'main' into sensitive-improvements
2021-06-11 10:48:20 +02:00
Taus
e7b9603c5b
Merge pull request #6053 from RasmusWL/fix-tests
...
Python: Fix tests
2021-06-10 16:55:45 +02:00
Rasmus Wriedt Larsen
dd457f9641
Python: Fix tests
2021-06-10 15:58:56 +02:00
CodeQL CI
a241c114da
Merge pull request #5836 from RasmusWL/ec-class-improvement
...
Approved by tausbn
2021-06-10 06:20:56 -07:00
Rasmus Wriedt Larsen
04db33513e
Merge branch 'main' into sensitive-improvements
2021-06-10 15:11:09 +02:00
Rasmus Wriedt Larsen
ea0c1d7db3
Python: Better handling of sensitive functions
...
This solution was the best I could come up with, but it _is_ a bit
brittle since you need to remember to add this additional taint step
to any configuration that relies on sensitive data sources... I don't
see an easy way around this though :|
2021-06-10 15:08:21 +02:00
Rasmus Wriedt Larsen
f167143a84
Python: Use real config in TestSensitiveDataSources
...
This will enable better tests in just one second
2021-06-10 15:01:31 +02:00
Rasmus Wriedt Larsen
c341643ec1
Python: Add more tests for sensitive function handling
2021-06-10 14:36:05 +02:00
Rasmus Wriedt Larsen
eb4f168dd4
Python: Clarify SensitiveAttributeAccess
...
The comment about imports was placed wrong. I also realized we didn't
even have a single test-case for
`this.(DataFlow::AttrRead).getAttributeNameExpr() = sensitiveLookupStringConst(classification)`
so I added that (notice that this is only `getattr(foo, x)` and not
`getattr(foo, "password")`)
2021-06-10 14:09:47 +02:00
yoff
716627c1dd
Merge pull request #5878 from RasmusWL/fix-concept-tests-pretty-print
...
Python: Fix concept tests pretty print
2021-06-10 11:21:08 +02:00
Rasmus Wriedt Larsen
aaddd36236
Python: Add another type-tracking attr test
...
This one just works out of the box 💪
2021-06-09 14:20:50 +02:00
Rasmus Wriedt Larsen
89cba216ca
Python: Apply suggestions from code review
...
Co-authored-by: Taus <tausbn@github.com >
2021-06-09 14:15:59 +02:00
Rasmus Wriedt Larsen
dec6723183
Python: Minor refactor
...
A bit too much copy paste 😄
2021-06-09 12:19:11 +02:00
Rasmus Wriedt Larsen
fa6abea465
Python: Add modeling of jmespath
2021-06-09 12:14:35 +02:00
Rasmus Wriedt Larsen
5cdd60d0d6
Python: Add jmespath tests
2021-06-09 12:12:50 +02:00
Rasmus Wriedt Larsen
3d2de03674
Python: Add type-tracking test for attr set in function
2021-06-08 19:03:53 +02:00
Rasmus Wriedt Larsen
dcd448b743
Python: Refactor formatting
2021-06-08 19:03:53 +02:00
Rasmus Wriedt Larsen
09de1bcf44
Python: Add tests for type-tracking attrs on instances
2021-06-08 19:03:53 +02:00
Rasmus Wriedt Larsen
23f668f8ee
Python: Model redirects in twisted
2021-06-08 16:16:56 +02:00
Rasmus Wriedt Larsen
a21039170b
Python: Model (most of) twisted
2021-06-08 16:11:18 +02:00
Rasmus Wriedt Larsen
151a733ff2
Python: Add tests for twisted
...
These were largely based on the old tests in
6011cb74f8/python/ql/test/library-tests/web/twisted/test.py
2021-06-08 15:27:51 +02:00
Rasmus Wriedt Larsen
3819a361b5
Python: Autoformat
2021-06-07 14:16:33 +02:00
Rasmus Wriedt Larsen
350f79e1e1
Python: Model sensitive data based on variable names
2021-06-04 11:28:07 +02:00
Rasmus Wriedt Larsen
f5fd0f8d1c
Python: Model sensitive data based on parameter names
2021-06-04 11:28:07 +02:00