Commit Graph

16185 Commits

Author SHA1 Message Date
Mathias Vorreiter Pedersen
c560c7584c C++: Add QLDoc for BufferMayWriteSideEffectFieldStoreQualifierNode 2020-09-21 11:08:06 +02:00
Mathias Vorreiter Pedersen
49dd576352 C++: Add more tests 2020-09-21 10:59:16 +02:00
Mathias Vorreiter Pedersen
6dd7675a97 Update cpp/ql/src/semmle/code/cpp/ir/dataflow/internal/DataFlowPrivate.qll
Co-authored-by: Jonas Jensen <jbj@github.com>
2020-09-21 09:31:30 +02:00
Mathias Vorreiter Pedersen
53da751b15 C++: Accept tests 2020-09-18 17:12:27 +02:00
Mathias Vorreiter Pedersen
b6b17fe95e C++: Add a read and store step that replace ArrayContent with FieldContent when we realize that the target of a store is a field. 2020-09-18 17:12:09 +02:00
Tom Hvitved
dff9f8264b Merge pull request #4296 from hvitved/csharp/useless-upcast-nomagic
C#: Avoid bad magic in `UselessUpcast.ql`
2020-09-18 16:24:20 +02:00
Anders Schack-Mulligen
b3bf570fb7 Merge pull request #4301 from lcartey/java/update-cwe-claims
Java: Update some CWE claims
2020-09-18 16:08:40 +02:00
Mathias Vorreiter Pedersen
b4edbe4773 Merge pull request #4298 from MathiasVP/field-conflation-with-array-content
C++: Add test demonstrating field conflation after merging #4230
2020-09-18 15:16:33 +02:00
Anders Schack-Mulligen
4f9d2f118d Merge pull request #4288 from joefarebrother/printAST-java
Java: Add a container node for Imports in the PrintAst view
2020-09-18 14:17:26 +02:00
Jonas Jensen
6463a94258 Merge pull request #4297 from github/igfoo/compileTimeConstantInt
C++: Improve `compileTimeConstantInt`
2020-09-18 13:58:16 +02:00
lcartey@github.com
2c6f587ee9 Java: Add coverage claim for CWE 193 (off by one) 2020-09-18 12:51:24 +01:00
lcartey@github.com
39200566c3 Java: Update CWE claims for XXE.
This matches the claims in the C# equivalent.
2020-09-18 12:30:52 +01:00
Mathias Vorreiter Pedersen
b40941b89c C++: Add test demonstrating field conflation after merging #4230 2020-09-18 13:23:23 +02:00
Tom Hvitved
4090859207 C#: Avoid bad magic in UselessUpcast.ql 2020-09-18 12:14:52 +02:00
Joe
3258134098 Java: Remove superfluous conjunct 2020-09-18 10:41:06 +01:00
lcartey@github.com
32f43a84be Java: Add CWE 564 (SQL Injection: Hibernate) 2020-09-18 10:20:21 +01:00
Jonas Jensen
c67605f15c Merge pull request #4230 from MathiasVP/mathiasvp/array-field-flow
C++: Replace `field -> object` taint rule with `ArrayContent` dataflow
2020-09-18 10:56:51 +02:00
Mathias Vorreiter Pedersen
8c615ece8a Merge pull request #4292 from MathiasVP/mathiasvp/cache-simpleLocalFlowStep
C++: Cache simpleLocalFlowStep instead of simpleInstructionLocalFlowStep
2020-09-18 10:18:21 +02:00
Mathias Vorreiter Pedersen
3ef6e8a580 Merge pull request #4283 from geoffw0/stringstream4
C++: Model getline
2020-09-18 10:17:47 +02:00
Mathias Vorreiter Pedersen
c6ff805a07 C++: Cache simpleLocalFlowStep instead of simpleInstructionLocalFlowStep 2020-09-17 21:13:02 +02:00
Robert Marsh
3d07ba9d0b Merge pull request #4290 from MathiasVP/mathiasvp/fix-join-order-in-single-field-flow
C++: Fix bad join order introduced by #4270
2020-09-17 14:52:59 -04:00
Mathias Vorreiter Pedersen
8e1d9e0996 C++: Fix bad join order introduced by #4270 2020-09-17 19:23:01 +02:00
Joe
2da6234317 Java: Fix QLDoc 2020-09-17 17:31:24 +01:00
Joe
6d0df7cb3a Java: Add a container node for Imports in the PrintAst view 2020-09-17 17:29:36 +01:00
Ian Lynagh
c7b6374e55 C++: Improve compileTimeConstantInt
It is possible for the frontend to make
    (bool)e
where e has a constant value 0, but the (implicit) cast has no constant
value. This was causing us to not understand assume(0) correctly.

Now compileTimeConstantInt will handle casts itself if necessary.
2020-09-17 14:51:50 +01:00
Geoffrey White
5cc11f1c44 C++: Additional model for 'this' flow through chains. 2020-09-17 14:12:30 +01:00
Geoffrey White
73399cb5f7 C++: Model GetLine. 2020-09-17 14:05:43 +01:00
Geoffrey White
2c15e6f934 C++: Add test cases. 2020-09-17 13:43:07 +01:00
Mathias Vorreiter Pedersen
63afe1da78 Merge pull request #4276 from geoffw0/stringstream3
C++: More stringstream models.
2020-09-17 14:19:52 +02:00
Geoffrey White
4d6125841d C++: Clean up multiply defined functions. 2020-09-17 11:48:26 +01:00
Geoffrey White
c17ae3ad6c C++: Correct dataflow for return (*this). 2020-09-17 11:34:10 +01:00
Geoffrey White
86404af501 Merge pull request #4270 from MathiasVP/mathiasvp/single-field-flow-fix-cwe190test
C++: Use underlying type when checking whether a type is a single-field struct.
2020-09-16 17:21:07 +01:00
Geoffrey White
f1a9547b38 C++: Split off putback. 2020-09-16 16:44:39 +01:00
Taus
4b423feef9 Merge pull request #4245 from RasmusWL/python-dataflow-dynamic-tuple-tests
Python: Add dataflow tests for dynamic tuple creation
2020-09-16 15:19:41 +02:00
CodeQL CI
c2175b678c Merge pull request #4263 from erik-krogh/importScripts
Approved by esbena
2020-09-16 06:01:35 -07:00
Mathias Vorreiter Pedersen
3520b86771 C++: Accept test changes. 2020-09-16 14:51:11 +02:00
Geoffrey White
eedbe839b5 C++: Update change note. 2020-09-16 13:45:05 +01:00
Geoffrey White
c4de071a4c C++: Flow through swap. 2020-09-16 13:39:07 +01:00
Geoffrey White
eb7bd6e176 C++: Flow through putback. 2020-09-16 13:39:07 +01:00
Geoffrey White
7cc60a30a6 C++: Flow through get, peek, read, readsome. 2020-09-16 13:36:41 +01:00
Geoffrey White
56390c1aef C++: Flow through operator>>. 2020-09-16 13:32:13 +01:00
Mathias Vorreiter Pedersen
3026eb4b85 Revert "C++: Remove the same rule in TaintTrackingUtil.qll as 78b24b76a0 removed from DefaultTaintTracking.qll"
This reverts commit 0b97a4a182.
2020-09-16 14:26:01 +02:00
Mathias Vorreiter Pedersen
92d81edae6 Revert "C++: Remove the problematic taint tracking rule. It seems like we get the flows from dataflow already now."
This reverts commit 78b24b76a0.
2020-09-16 14:25:42 +02:00
Tamás Vajk
5079deb92a Merge pull request #4268 from tamasvajk/feature/java-range-analysis-fn
Java: Fix range analysis false negative
2020-09-16 11:08:33 +02:00
Mathias Vorreiter Pedersen
0b97a4a182 C++: Remove the same rule in TaintTrackingUtil.qll as 78b24b76a0 removed from DefaultTaintTracking.qll 2020-09-16 10:54:23 +02:00
Joe Farebrother
4f70af500c Merge pull request #4261 from joefarebrother/printAST-java
Java: Add PrintAst
2020-09-16 09:46:19 +01:00
Mathias Vorreiter Pedersen
7b456d6162 Merge branch 'main' into mathiasvp/array-field-flow 2020-09-16 10:45:31 +02:00
Rasmus Wriedt Larsen
d828bc5f3a Merge pull request #4251 from yoff/SharedDataflow_BarrierGuards
Python: Implement `BarrierGuard`
2020-09-16 10:00:26 +02:00
Mathias Vorreiter Pedersen
c8a3baf356 Merge pull request #4272 from jbj/dataflow-partial-access
C++: Add AST flow through arrays
2020-09-16 09:29:39 +02:00
Rasmus Lerchedahl Petersen
e46ae9b98d Python: Move some query predicates to debug 2020-09-15 21:45:47 +02:00