Commit Graph

248 Commits

Author SHA1 Message Date
Max Schaefer
8614d7bddb Address review feedback. 2024-01-17 14:29:52 +00:00
Max Schaefer
90a4552c4f Fix omittable exists. 2024-01-15 13:45:03 +00:00
Max Schaefer
fee44074f7 Autoformat. 2024-01-15 13:44:45 +00:00
Max Schaefer
3befce98b3 When checking whether an endpoint has already been modelled, make sure to take the extensibleType into account. 2024-01-15 12:09:39 +00:00
Max Schaefer
68cf9aca12 Remove a few getExtensibleType checks which are now unnecessary. 2024-01-15 11:50:59 +00:00
Max Schaefer
919330fb53 Some more performance refactoring. 2024-01-12 17:38:58 +00:00
Max Schaefer
bb63fcde43 Refactor to avoid bad join order. 2024-01-12 15:24:24 +00:00
Max Schaefer
45ca301593 Rename a predicate. 2024-01-12 13:18:05 +00:00
Max Schaefer
ea26e21454 Extend negative characteristics for exceptions to source models. 2024-01-12 12:20:22 +00:00
Max Schaefer
06ba5ea9f8 Eliminate GetCallable modules and use getCallable instead. 2024-01-12 12:03:49 +00:00
Max Schaefer
76b84301e3 Share some code. 2024-01-12 12:03:49 +00:00
Max Schaefer
9f443d4f83 Make Unexploitable*Characteristic more precise. 2024-01-12 12:03:41 +00:00
Max Schaefer
6e9c90a6bb Properly distinguish negative source and sink characteristics.
In particular, `IsSanitizerCharacteristic` is a negative _source_ characteristic (not a negative sink characteristic), while `NeutralModelCharacteristic` is both.

This eliminates the erroneous test results.
2024-01-11 12:36:48 +00:00
Max Schaefer
ff4555ac5b Get rid of negative sink types.
Instead of positively implying the negative sink type, negative sink characteristics now negatively imply all sink types (but not source types). This is simpler and sice we will never have a huge number of sink types it doesn't impact performance either.

Changes to test results:

- The call to `createDirectories` at `Test.java:87` is now correctly classified as a source candidate, having previously been erroneously excluded by a negative _sink_ characteristic.
- The call to `compareTo` at `Test.java:48` is now erroneously classified as a source candidate; it should be suppressed by `IsSanitizerCharacteristic`, which is a negative sink characteristic, but should really be a negative source characteristic.
- In framework mode, several endpoints are now erroneously classified as source candidates even though they have neutral models, because `NeutralModelCharacteristic` is currently only a negative sink characteristic and not a negative source characteristic.
2024-01-11 12:19:53 +00:00
Max Schaefer
bcf4f4febd Drop a conjunct which is now spurious. 2024-01-11 11:56:59 +00:00
Max Schaefer
03ca244df2 Associate endpoints with their potential endpoint types and check these when determining candidates.
This prevents us from associating a sink candidate with a source type and vice versa.

However, this does not fix the problem of negative characteristics for sink types excluding source candidates.
2024-01-11 11:44:14 +00:00
Max Schaefer
a6d996b478 Add an example of a missed source candidate.
`Files.list` has a taint step from its first argument to its result, so that first argument should not be considered a sink candidate (and it is not). However, due to a bug in `IsMaDTaintStepCharacteristic` it is also not considered a source candidate, which is wrong: as the example shows, if that argument is a call we do very much want to consider it as a source candidate.
2024-01-11 11:27:34 +00:00
Max Schaefer
8e429bd399 Rename isSinkCandidate (and a related predicate) to isCandidate.
This reflects the fact that these predicates also deal with source candidates.
2024-01-11 11:20:51 +00:00
Max Schaefer
dba2e06a1d Merge pull request #15283 from github/max-schaefer/release-automodel-query-pack
Release automodel extraction queries v0.0.12.
2024-01-11 10:28:55 +00:00
Ian Wright
75545db97c restore files, whether overriding or not 2024-01-10 11:40:31 +00:00
Max Schaefer
8d56ee4a56 Release automodel extraction queries v0.0.12. 2024-01-10 11:29:36 +00:00
Ian Wright
f793ce1e49 remove temp testing comments 2024-01-10 11:07:06 +00:00
Ian Wright
ed8422a2da remove need for CODEQL_DIST path 2024-01-10 11:07:06 +00:00
Ian Wright
0d2ec2d632 install codeql extension 2024-01-10 11:07:06 +00:00
Ian Wright
62bdaf069b use gh tool to access codeql 2024-01-10 11:07:05 +00:00
Ian Wright
30e5be68c9 temp comment for testing 2024-01-10 11:07:05 +00:00
Ian Wright
9895114e05 temp comment for testing 2024-01-10 11:07:05 +00:00
Ian Wright
0f76fbad36 better processing of args 2024-01-10 11:07:05 +00:00
Ian Wright
749f8b9807 fix help message 2024-01-10 11:07:05 +00:00
Ian Wright
00f4991648 support dry-run
fix

fix

temp

temp

better support for dry-run

fix

fix

fix

fix

reinstate exits
2024-01-10 11:07:05 +00:00
Max Schaefer
ac8e92eec5 Merge pull request #15264 from github/max-schaefer/automodel-exclude-generated-calls
Automodel: Do not generate features for compiler-generated program elements.
2024-01-10 10:22:00 +00:00
Max Schaefer
9b7cfd88cd Clarify relationship of isFromSource and Element::fromSource. 2024-01-09 16:21:36 +00:00
Max Schaefer
3e8775daaa Automodel: Do not generate features for compiler-generated program elements.
These have dummy locations, which breaks certain invariants that break downstream processing.
2024-01-09 13:39:46 +00:00
Ian Wright
dab28edfa9 0.0.11 release of automodel extraction queries 2024-01-04 13:10:46 +00:00
Ian Wright
468454645e better 2024-01-04 11:15:05 +00:00
Ian Wright
4530510450 check if provided argument is valid 2024-01-04 11:02:58 +00:00
Ian Wright
545b5e7e83 better comment 2024-01-04 11:02:58 +00:00
Ian Wright
fb44b9c7dd better comment 2024-01-04 11:02:57 +00:00
Ian Wright
e4a798e9cc better comment 2024-01-04 11:02:57 +00:00
Ian Wright
af940f5e41 don't specify defaults 2024-01-04 11:02:57 +00:00
Ian Wright
45b1790fa2 add publication warning 2024-01-04 11:02:57 +00:00
Ian Wright
337512174f wip
wip

wip

more checks

fix bug if release folder already exists

fix bug if release folder already exists

ensure branch has correct release; dry-run

simplify branches

step by step

fix paths

pushd/popd

pushd/popd

use bash

simplify

simplify

simplify

simplify

add dry run
2024-01-04 11:02:57 +00:00
Ian Wright
6572be668c get release version 2024-01-04 11:02:57 +00:00
github-actions[bot]
8f72b0e4f7 Post-release preparation for codeql-cli-2.15.5 2023-12-19 10:32:57 +00:00
github-actions[bot]
19af35b29a Release preparation for version 2.15.5 2023-12-18 21:22:44 +00:00
github-actions[bot]
92af5f5386 Post-release preparation for codeql-cli-2.15.4 2023-12-06 22:59:22 +00:00
github-actions[bot]
c04457e9e7 Release preparation for version 2.15.4 2023-12-06 21:11:50 +00:00
Stephan Brandauer
2e5971bb57 Java automodel: also drop boxed types and number types from endpoints 2023-11-24 15:04:13 +01:00
Stephan Brandauer
f2de449ce4 Merge branch 'main' into kaeluka/automodel-extraction-skip-primitive-types-candidates 2023-11-21 14:57:24 +01:00
Max Schaefer
b5c92408f4 Merge pull request #14845 from github/max-schaefer/minor
Automodel: Fix a few nits.
2023-11-20 15:24:45 +00:00