Commit Graph

12729 Commits

Author SHA1 Message Date
Dave Bartolomeo
3832d4cae6 C++: Mark deprecated overrides as deprecated
The QL compiler is about to be changed to emit a warning when overriding a deprecated predicate. This PR marks the existing overrides of deprecated predicates as `deprecated` themselves, which avoids the warning.

The `Print.qll` models seem to preserve the `isWideCharDefault()` predicate for backwards compatibility, so we can't remove them and must continue overriding them.

The `XML.qll` override is necessary because both superclasses declare the `getName()` predicate. One is `deprecated`, and the other is `abstract`, so we have to have an override.
2020-05-19 16:33:33 -04:00
semmle-qlci
0a8b3adc25 Merge pull request #3518 from felicitymay/merge-124-master
Approved by shati-patel
2020-05-19 19:30:47 +01:00
Felicity Chapman
99d7a21425 Merge branch 'rc/1.24' into merge-124-master 2020-05-19 19:04:44 +01:00
Felicity Chapman
cca3922d00 Merge pull request #3517 from felicitymay/1.24/SD-54-update-contact
CodeQL 1.24: Update information on support
2020-05-19 18:57:34 +01:00
Tom Hvitved
f0f833b58f Merge pull request #3512 from jbj/mergeback-2020-05-19
Mergeback rc/1.24 -> master
2020-05-19 19:51:36 +02:00
Felicity Chapman
70d642a956 Update information on support 2020-05-19 18:17:17 +01:00
Jonas Jensen
d38700a87c Merge remote-tracking branch 'upstream/master' into mergeback-2020-05-19
Conflicts:
	cpp/ql/test/library-tests/dataflow/DefaultTaintTracking/tainted.expected
	cpp/ql/test/library-tests/dataflow/DefaultTaintTracking/test_diff.expected
2020-05-19 17:44:15 +02:00
semmle-qlci
26dfca80f6 Merge pull request #3510 from max-schaefer/cull-boring-queries
Approved by asgerf, esbena
2020-05-19 15:41:53 +01:00
Mathias Vorreiter Pedersen
f0f7e531d7 Merge pull request #3511 from jbj/simplify-field-conflation-test
C++: Simplify field conflation test
2020-05-19 16:04:45 +02:00
yo-h
bfeaeccf60 Merge pull request #3507 from aschackmull/java/cleanup-deprecated-overrides
Java: Clean up deprecated overrides.
2020-05-19 09:47:57 -04:00
Max Schaefer
a803120414 Lower precision for a number of queries.
These queries are currently run by default, but don't have their results displayed.

Looking through results on LGTM.com, they are either false positives (e.g., `BitwiseSignCheck` which flags many perfectly harmless operations and `CompareIdenticalValues` which mostly flags NaN checks) or harmless results that developers are unlikely to care about (e.g., `EmptyArrayInit` or `MisspelledIdentifier`).

With this PR, the only queries that are still run but not displayed are security queries, where different considerations may apply.
2020-05-19 13:43:17 +01:00
Jonas Jensen
5318d42c4f Merge remote-tracking branch 'upstream/rc/1.24' into mergeback-2020-05-19 2020-05-19 14:42:58 +02:00
Jonas Jensen
486f06ab18 C++: Simplify field conflation test
It turned out the `memcpy` step was not even necessary.
2020-05-19 14:12:11 +02:00
Alexander Eyers-Taylor
57dbe5793f Merge pull request #3501 from jbj/dispatch-global-union
C++: Fix struct field conflation in IR data flow
2020-05-19 12:29:25 +01:00
Anders Schack-Mulligen
6f03a0bc39 Merge pull request #3487 from luchua-bc/java-sensitive-jboss-logging
Add JBoss logging
2020-05-19 11:04:18 +02:00
Anders Schack-Mulligen
c36e6213f1 Merge pull request #3288 from ggolawski/jndi-injection
CodeQL query to detect JNDI injections
2020-05-19 11:03:29 +02:00
Anders Schack-Mulligen
9d7329de30 Java: Clean up deprecated overrides. 2020-05-19 10:41:41 +02:00
semmle-qlci
0c081a8e87 Merge pull request #3497 from esbena/js/yield-and-local-objects
Approved by asgerf, erik-krogh
2020-05-19 09:02:22 +01:00
semmle-qlci
0d762066f5 Merge pull request #3504 from erik-krogh/unique
Approved by esbena
2020-05-19 08:35:08 +01:00
Grzegorz Golawski
73e736b47a Enhanced comments according to the review comment 2020-05-18 23:37:48 +02:00
Grzegorz Goławski
0075d35346 Update java/ql/src/experimental/Security/CWE/CWE-074/JndiInjectionLib.qll
Co-authored-by: Anders Schack-Mulligen <aschackmull@users.noreply.github.com>
2020-05-18 23:18:16 +02:00
semmle-qlci
192bf918c3 Merge pull request #3488 from asger-semmle/js/sql-type-tracking
Approved by erik-krogh
2020-05-18 19:57:32 +01:00
Erik Krogh Kristensen
202b8a56b7 apply the unique aggregate where trivially applicable 2020-05-18 20:37:38 +02:00
Asger F
96d6115452 Merge branch 'master' into js/sql-type-tracking 2020-05-18 15:58:42 +01:00
Jonas Jensen
76e194c8be C++: Fix struct field conflation in IR data flow
The virtual-dispatch code for globals was missing any relationship
between the union field access and the global variable, which meant it
propagated function-pointer flow between any two fields of a global
struct. This resulted in false positives from
`cpp/tainted-format-string` on projects using SDL, such as
WohlSoft/PGE-Project.

In addition to fixing that bug, this commit also brings the code up to
date with the new style of modeling flow through global variables:
`DataFlow::Node.asVariable()`.
2020-05-18 16:24:22 +02:00
Bt2018
69f2525e62 Remove the ending blank lines for auto-format check 2020-05-18 10:02:37 -04:00
Jonas Jensen
f2402c5abb C++: Test virtual dispatch field conflation
This test demonstrates that IR data flow conflates unrelated fields of a
global struct-typed variable and that this bug is not present in the old
AST-based implementation of `semmle.code.cpp.security.TaintTracking`.
2020-05-18 15:37:22 +02:00
semmle-qlci
0da1e68462 Merge pull request #3498 from max-schaefer/js/remote-exec
Approved by esbena
2020-05-18 14:17:20 +01:00
Asger F
a9983fdb49 Update javascript/ql/src/semmle/javascript/frameworks/SQL.qll
Co-authored-by: Erik Krogh Kristensen <erik-krogh@github.com>
2020-05-18 13:23:22 +01:00
Max Schaefer
bdd778f989 JavaScript: Add change note. 2020-05-18 12:08:36 +01:00
Max Schaefer
6797fec1a3 JavaScript: Add more models of packages that execute commands over SSH. 2020-05-18 12:08:14 +01:00
Esben Sparre Andreasen
a9ba6ac659 JS: make LocalObjects::isEscape aware of yield 2020-05-18 12:43:46 +02:00
semmle-qlci
14664be467 Merge pull request #3468 from p0/imp/nodejs-vm-sinks
Approved by esbena
2020-05-18 11:10:13 +01:00
James Fletcher
bd6d2d899d Merge pull request #3495 from jf205/java-article-fix
CodeQL docs: remove stray GH variable
2020-05-18 10:23:22 +01:00
james
06f465bae7 docs: remove gh variable 2020-05-18 10:12:40 +01:00
Jonas Jensen
cc00f0f584 C++: Move identical declarations to shared.h file
This cleans up the test results, which were confusing because functions
like `sink` had multiple locations.

There are some additional results now involving casts to `const char *`
because previously it varied whether `sink` used `const`, and now it
always does.
2020-05-18 10:42:52 +02:00
Asger Feldthaus
a18e0b37cf JS: simplify sequelize model 2020-05-18 09:34:17 +01:00
Asger F
f52c827966 Apply suggestions from code review
Base type of EscapingSanitizer

Co-authored-by: Erik Krogh Kristensen <erik-krogh@github.com>
2020-05-18 09:31:09 +01:00
Asger F
ffb22c061a Apply suggestions from code review
Co-authored-by: Erik Krogh Kristensen <erik-krogh@github.com>
2020-05-18 09:28:22 +01:00
semmle-qlci
6041d52936 Merge pull request #3424 from asger-semmle/js/express-param-handler
Approved by esbena
2020-05-18 08:48:24 +01:00
semmle-qlci
135eae9895 Merge pull request #3483 from esbena/js/fix-qhelp-FNs
Approved by asgerf
2020-05-18 08:47:05 +01:00
semmle-qlci
0230b79efc Merge pull request #3391 from erik-krogh/SplitFPs
Approved by esbena
2020-05-18 08:46:26 +01:00
semmle-qlci
8d41ce1630 Merge pull request #3480 from erik-krogh/moreSlip
Approved by esbena
2020-05-16 21:17:27 +01:00
Mathias Vorreiter Pedersen
a42d80aa14 Merge pull request #3481 from dbartol/github/codeql-c-analysis-team/69
C++/C#: Allow memory operands to lack a definition
2020-05-16 11:53:00 +02:00
Asger Feldthaus
897a3e39c9 JS: Autoformat 2020-05-16 09:37:16 +01:00
Asger Feldthaus
0171c9e10c JS: Autoformat 2020-05-16 09:25:18 +01:00
Asger Feldthaus
d279845a43 JS: Minor fixes 2020-05-16 09:24:53 +01:00
yo-h
4f00e40257 Merge pull request #3474 from aschackmull/java/string-formatted
Java: Add taint steps for String.formatted.
2020-05-15 22:04:36 -04:00
yo-h
69ab158910 Merge pull request #3473 from aschackmull/java/switchexpr
Java: Extend library support for switch expressions.
2020-05-15 20:46:37 -04:00
Dave Bartolomeo
96c87b309b C++/C#: Use unique to get a better join order
The previous changes made the optimizer choose a bad join order for the RHS of the antijoin in `addressOperandAllocationAndOffset`. Once again, `unique` to the rescue.
2020-05-15 17:36:43 -04:00