Commit Graph

3044 Commits

Author SHA1 Message Date
AlexDenisov
d254524f3f Merge pull request #6027 from AlexDenisov/alexdenisov/fix-string-literal-expectation
C++: Fix string literal expectation
2021-06-07 17:13:12 +02:00
Geoffrey White
6f05fd4839 C++: Autoformat. 2021-06-07 11:01:00 +01:00
Mathias Vorreiter Pedersen
3923acb5e0 Merge pull request #6017 from github/dbartol/pack/extra-queries-xml
C++: Replace an odd `queries.xml` with `qlpack.yml`
2021-06-07 10:58:19 +02:00
Alex Denisov
17be6e1271 C++: Fix string literal expectation 2021-06-07 09:47:26 +02:00
Dave Bartolomeo
ac3ded7d5a Replace an odd queries.xml with qlpack.yml
This one C++ test has its own `queries.xml` to make "outside-of-source" path filtering work, as detailed in commit 2550788598. I've replaced the `queries.xml` with `qlpack.yml`, added a comment, and added that pack to the `.codeqlmanifest.json` at the root of the repo. This will allow the library dependencies of this pack to be resolved without the need for a `--search-path` option with the upcoming packaging changes.
2021-06-06 09:04:18 -04:00
Dave Bartolomeo
e276e2684e Merge pull request #5986 from MathiasVP/side-effects-for-nonconst-smart-pointers
C++: Fix `hasDefaultSideEffect` for non-const smart pointers
2021-06-04 13:57:44 -04:00
Mathias Vorreiter Pedersen
8e8c2e677a C++: Accept test changes. 2021-06-04 18:49:20 +02:00
Mathias Vorreiter Pedersen
f2d7988d72 C++: Add tests involving various non-const and const smart pointers. 2021-06-04 18:46:05 +02:00
Geoffrey White
799e19bdc2 C++: Update the other version as well. 2021-06-04 16:21:04 +01:00
Geoffrey White
b24dc810c9 C++: Combine results from cpp/weak-cryptographic-algorithm that are in the same file. 2021-06-04 14:04:02 +01:00
Geoffrey White
a93246d28b C++: Fix maxCols. 2021-06-04 13:05:13 +01:00
Geoffrey White
ea96826810 C++: Add a test of charLoc and subsumes. 2021-06-04 13:05:07 +01:00
Mathias Vorreiter Pedersen
d450aa2ce4 C++: Add some testcases that require path sensitivity. 2021-06-03 18:02:29 +02:00
Jonas Jensen
7282ad90d0 Merge pull request #5854 from dbartol/dbartol/smart-pointers/side-effects
C++: Generate side effect instructions for smart pointer indirections
2021-06-01 16:57:05 +02:00
Dave Bartolomeo
da14647e5a Merge pull request #5522 from github/rdmarsh2/cpp/ssa-reuse
C++: reuse unaliased SSA results when computing aliased SSA
2021-06-01 10:17:54 -04:00
Mathias Vorreiter Pedersen
41c93d92d7 C++: Remove FPs from right shifts and explicitly bounded random functions. 2021-05-31 15:40:02 +02:00
Mathias Vorreiter Pedersen
10755ece88 C++: Add testcase with bounded randomness source. 2021-05-31 15:33:39 +02:00
Mathias Vorreiter Pedersen
66d284ee59 Merge pull request #5766 from ihsinme/ihsinme-patch-267
CPP: Add query for CWE-415 Double Free
2021-05-31 10:51:32 +02:00
ihsinme
d808a5b131 Update cpp/ql/test/experimental/query-tests/Security/CWE/CWE-415/semmle/tests/test.c
Co-authored-by: Mathias Vorreiter Pedersen <mathiasvp@github.com>
2021-05-31 11:16:38 +03:00
ihsinme
2909dde179 Update test.c 2021-05-26 09:31:15 +03:00
Geoffrey White
2fd461e984 Merge pull request #5938 from MathiasVP/promote-access-of-memory-location-after-end-of-buffer-using-strncat
C++: Promote `cpp/access-memory-location-after-end-buffer-strncat` out of experimental
2021-05-25 14:36:53 +01:00
Mathias Vorreiter Pedersen
b33adb8630 Merge pull request #5930 from MathiasVP/promote-incorrect-allocation-error-out
C++: Promote `cpp/incorrect-allocation-error-handling`
2021-05-25 10:57:31 +02:00
Mathias Vorreiter Pedersen
e857ac1149 C++: Add more tests and remove redundant conjunct. 2021-05-25 09:17:42 +02:00
Mathias Vorreiter Pedersen
12cd09d5d4 C++: Delete the experimental query and its tests, and accept the test changes. 2021-05-21 10:35:57 +02:00
Mathias Vorreiter Pedersen
8d0cfb4e91 C++: Merge tests from 'cpp/access-memory-location-after-end-buffer-strncat' into the tests from 'cpp/unsafe-strncat'. 2021-05-21 10:34:59 +02:00
Alex Denisov
694eba66f3 C++: Adjust tests for new specifiers 2021-05-20 10:49:20 +02:00
Mathias Vorreiter Pedersen
9504592909 C++: Promote cpp/incorrect-allocation-error-handling out of experimental. 2021-05-20 09:47:45 +02:00
Geoffrey White
aaae717328 Merge branch 'main' into weak_crypto 2021-05-19 11:19:08 +01:00
Mathias Vorreiter Pedersen
26c4a66dc4 C++: Add range analysis to fix FPs. 2021-05-18 17:54:30 +02:00
Mathias Vorreiter Pedersen
df9981de4f C++: Add testcases with false positives. 2021-05-18 17:53:20 +02:00
Geoffrey White
cdf261b54b C++: In fact it's just not good enough to get additional evidence from the declaring type. 2021-05-18 14:31:19 +01:00
Geoffrey White
c7382ee06d C++: Repair for function call macros. 2021-05-18 14:27:08 +01:00
Geoffrey White
012840e602 C++: Add more test cases. 2021-05-18 14:26:12 +01:00
Geoffrey White
09d00b133e C++: Acknowledge another not detected result in tests. 2021-05-17 15:53:03 +01:00
Geoffrey White
930b9fe3e5 C++: Add triple-DES to the bad algorithms list. 2021-05-17 15:51:17 +01:00
Mathias Vorreiter Pedersen
d46452e8de Merge pull request #5903 from MathiasVP/tainted-allocation-size-barrier
C++: Add barriers to `cpp/uncontrolled-allocation-size`
2021-05-17 15:24:45 +02:00
Mathias Vorreiter Pedersen
31091c66c1 C++: Add a test containing a guarded long. 2021-05-17 08:06:06 +02:00
Robert Marsh
d706d7b7a4 Merge pull request #5887 from MathiasVP/fewer-rand-sources-in-uncontrolled-arithmetic
C++: Add more sanitizers to `cpp/uncontrolled-arithmetic`
2021-05-14 15:35:56 -07:00
Mathias Vorreiter Pedersen
2d0a56128d C++: Prevent flow out of pointer-difference expressions. 2021-05-14 13:49:48 +02:00
Mathias Vorreiter Pedersen
c1d41b3169 C++: Add false positive result from pointer-difference expressions. 2021-05-14 13:47:23 +02:00
Mathias Vorreiter Pedersen
5031b73f35 C++: Add barrier to cpp/uncontrolled-allocation-size that blocks flow when overflow isn't possible. 2021-05-14 13:43:20 +02:00
Geoffrey White
3a83ff54e6 C++: Add support for class methods. 2021-05-13 16:02:00 +01:00
Geoffrey White
2576075b98 C++: Repair result message. 2021-05-13 15:52:28 +01:00
Geoffrey White
5d1ef49f8f C++: Add support for enum constants. 2021-05-13 15:42:42 +01:00
Geoffrey White
e4d2c7cfc4 C++: Rewrite so that we look for additional evidence. 2021-05-13 13:19:39 +01:00
Geoffrey White
123889a671 C++: Fix 'triple DES' false positives. 2021-05-13 10:21:06 +01:00
Geoffrey White
0450caa73d C++: Exclude array initializers. 2021-05-12 19:39:30 +01:00
Geoffrey White
52a88af6c1 C++: Exclude macro invocations in switch case expressions. 2021-05-12 19:33:18 +01:00
Geoffrey White
9404d0676d C++: Exclude macros that don't generate anything. 2021-05-12 19:28:08 +01:00
Geoffrey White
b6d5f7c315 C++: Fix FPs caused by substring regexp. 2021-05-12 19:23:49 +01:00