Skip to content

Commit 0a60563

Browse files
author
Stephan Brandauer
authored
Merge branch 'main' into java/update-mad-decls-after-triage-2023-03-13T13-21-27
2 parents 05b0cc2 + 956f991 commit 0a60563

File tree

2,389 files changed

+91888
-39349
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

2,389 files changed

+91888
-39349
lines changed

.git-blame-ignore-revs

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# .git-blame-ignore-revs
2+
# Auto-formatted Java
3+
730eae952139209fe9fdf598541d608f4c0c0c84
4+
# Auto-formatted C#
5+
5ad7ed49dd3de03ec6dcfcb6848758a6a987e11c
6+
# Auto-formatted C/C++
7+
ef97e539ec1971494d4bba5cafe82e00bc8217ac
8+
# Auto-formatted Python
9+
21d5fa836b3a7d020ba45e8b8168b145a9772131
10+
# Auto-formatted JavaScript
11+
8d97fe9ed327a9546ff2eaf515cf0f5214deddd9
12+
# Auto-formatted Ruby
13+
a5d229903d2f12d45f2c2c38822f1d0e7504ae7f
14+
# Auto-formatted Go
15+
08c658e66bf867090033ea096e244a93d46c0aa7
16+
# Auto-formatted Swift
17+
711d7057f79fb7d72fc3b35e010bd018f9009169
18+
# Auto-formatted shared ql packs
19+
3640b6d3a8ce9edf8e1d3ed106fe8526cf255bc0
20+
# Auto-formatted taint tracking files
21+
159d8e978c51959b380838c080d891b66e763b19

.github/workflows/go-tests-other-os.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313
runs-on: macos-latest
1414
steps:
1515
- name: Set up Go 1.20
16-
uses: actions/setup-go@v3
16+
uses: actions/setup-go@v4
1717
with:
1818
go-version: 1.20.0
1919
id: go
@@ -48,7 +48,7 @@ jobs:
4848
runs-on: windows-latest-xl
4949
steps:
5050
- name: Set up Go 1.20
51-
uses: actions/setup-go@v3
51+
uses: actions/setup-go@v4
5252
with:
5353
go-version: 1.20.0
5454
id: go

.github/workflows/go-tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ jobs:
2121
runs-on: ubuntu-latest-xl
2222
steps:
2323
- name: Set up Go 1.20
24-
uses: actions/setup-go@v3
24+
uses: actions/setup-go@v4
2525
with:
2626
go-version: 1.20.0
2727
id: go

.github/workflows/ruby-build.yml

Lines changed: 32 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -55,35 +55,35 @@ jobs:
5555
id: cache-extractor
5656
with:
5757
path: |
58-
ruby/target/release/ruby-autobuilder
59-
ruby/target/release/ruby-autobuilder.exe
60-
ruby/target/release/ruby-extractor
61-
ruby/target/release/ruby-extractor.exe
62-
ruby/ql/lib/codeql/ruby/ast/internal/TreeSitter.qll
63-
key: ${{ runner.os }}-${{ steps.os_version.outputs.version }}-ruby-extractor-${{ hashFiles('ruby/rust-toolchain.toml', 'ruby/**/Cargo.lock') }}--${{ hashFiles('ruby/**/*.rs') }}
58+
ruby/extractor/target/release/autobuilder
59+
ruby/extractor/target/release/autobuilder.exe
60+
ruby/extractor/target/release/extractor
61+
ruby/extractor/target/release/extractor.exe
62+
ruby/extractor/ql/lib/codeql/ruby/ast/internal/TreeSitter.qll
63+
key: ${{ runner.os }}-${{ steps.os_version.outputs.version }}-ruby-extractor-${{ hashFiles('ruby/extractor/rust-toolchain.toml', 'ruby/extractor/Cargo.lock') }}--${{ hashFiles('ruby/extractor/**/*.rs') }}
6464
- uses: actions/cache@v3
6565
if: steps.cache-extractor.outputs.cache-hit != 'true'
6666
with:
6767
path: |
6868
~/.cargo/registry
6969
~/.cargo/git
7070
ruby/target
71-
key: ${{ runner.os }}-${{ steps.os_version.outputs.version }}-ruby-rust-cargo-${{ hashFiles('ruby/rust-toolchain.toml', 'ruby/**/Cargo.lock') }}
71+
key: ${{ runner.os }}-${{ steps.os_version.outputs.version }}-ruby-rust-cargo-${{ hashFiles('ruby/extractor/rust-toolchain.toml', 'ruby/extractor/**/Cargo.lock') }}
7272
- name: Check formatting
7373
if: steps.cache-extractor.outputs.cache-hit != 'true'
74-
run: cargo fmt --all -- --check
74+
run: cd extractor && cargo fmt --all -- --check
7575
- name: Build
7676
if: steps.cache-extractor.outputs.cache-hit != 'true'
77-
run: cargo build --verbose
77+
run: cd extractor && cargo build --verbose
7878
- name: Run tests
7979
if: steps.cache-extractor.outputs.cache-hit != 'true'
80-
run: cargo test --verbose
80+
run: cd extractor && cargo test --verbose
8181
- name: Release build
8282
if: steps.cache-extractor.outputs.cache-hit != 'true'
83-
run: cargo build --release
83+
run: cd extractor && cargo build --release
8484
- name: Generate dbscheme
8585
if: ${{ matrix.os == 'ubuntu-latest' && steps.cache-extractor.outputs.cache-hit != 'true'}}
86-
run: target/release/ruby-generator --dbscheme ql/lib/ruby.dbscheme --library ql/lib/codeql/ruby/ast/internal/TreeSitter.qll
86+
run: extractor/target/release/generator --dbscheme ql/lib/ruby.dbscheme --library ql/lib/codeql/ruby/ast/internal/TreeSitter.qll
8787
- uses: actions/upload-artifact@v3
8888
if: ${{ matrix.os == 'ubuntu-latest' }}
8989
with:
@@ -98,10 +98,10 @@ jobs:
9898
with:
9999
name: extractor-${{ matrix.os }}
100100
path: |
101-
ruby/target/release/ruby-autobuilder
102-
ruby/target/release/ruby-autobuilder.exe
103-
ruby/target/release/ruby-extractor
104-
ruby/target/release/ruby-extractor.exe
101+
ruby/extractor/target/release/autobuilder
102+
ruby/extractor/target/release/autobuilder.exe
103+
ruby/extractor/target/release/extractor
104+
ruby/extractor/target/release/extractor.exe
105105
retention-days: 1
106106
compile-queries:
107107
runs-on: ubuntu-latest-xl
@@ -116,21 +116,22 @@ jobs:
116116
key: ruby-build
117117
- name: Build Query Pack
118118
run: |
119-
rm -rf target/packs
120-
codeql pack create ../misc/suite-helpers --output target/packs
121-
codeql pack create ../shared/regex --output target/packs
122-
codeql pack create ../shared/ssa --output target/packs
123-
codeql pack create ../shared/tutorial --output target/packs
124-
codeql pack create ql/lib --output target/packs
125-
codeql pack create -j0 ql/src --output target/packs --compilation-cache "${{ steps.query-cache.outputs.cache-dir }}"
126-
PACK_FOLDER=$(readlink -f target/packs/codeql/ruby-queries/*)
119+
PACKS=${{ runner.temp }}/query-packs
120+
rm -rf $PACKS
121+
codeql pack create ../misc/suite-helpers --output "$PACKS"
122+
codeql pack create ../shared/regex --output "$PACKS"
123+
codeql pack create ../shared/ssa --output "$PACKS"
124+
codeql pack create ../shared/tutorial --output "$PACKS"
125+
codeql pack create ql/lib --output "$PACKS"
126+
codeql pack create -j0 ql/src --output "$PACKS" --compilation-cache "${{ steps.query-cache.outputs.cache-dir }}"
127+
PACK_FOLDER=$(readlink -f "$PACKS"/codeql/ruby-queries/*)
127128
codeql generate query-help --format=sarifv2.1.0 --output="${PACK_FOLDER}/rules.sarif" ql/src
128129
(cd ql/src; find queries \( -name '*.qhelp' -o -name '*.rb' -o -name '*.erb' \) -exec bash -c 'mkdir -p "'"${PACK_FOLDER}"'/$(dirname "{}")"' \; -exec cp "{}" "${PACK_FOLDER}/{}" \;)
129130
- uses: actions/upload-artifact@v3
130131
with:
131132
name: codeql-ruby-queries
132133
path: |
133-
ruby/target/packs/*
134+
${{ runner.temp }}/query-packs/*
134135
retention-days: 1
135136

136137
package:
@@ -158,12 +159,12 @@ jobs:
158159
mkdir -p ruby
159160
cp -r codeql-extractor.yml tools ql/lib/ruby.dbscheme.stats ruby/
160161
mkdir -p ruby/tools/{linux64,osx64,win64}
161-
cp linux64/ruby-autobuilder ruby/tools/linux64/autobuilder
162-
cp osx64/ruby-autobuilder ruby/tools/osx64/autobuilder
163-
cp win64/ruby-autobuilder.exe ruby/tools/win64/autobuilder.exe
164-
cp linux64/ruby-extractor ruby/tools/linux64/extractor
165-
cp osx64/ruby-extractor ruby/tools/osx64/extractor
166-
cp win64/ruby-extractor.exe ruby/tools/win64/extractor.exe
162+
cp linux64/autobuilder ruby/tools/linux64/autobuilder
163+
cp osx64/autobuilder ruby/tools/osx64/autobuilder
164+
cp win64/autobuilder.exe ruby/tools/win64/autobuilder.exe
165+
cp linux64/extractor ruby/tools/linux64/extractor
166+
cp osx64/extractor ruby/tools/osx64/extractor
167+
cp win64/extractor.exe ruby/tools/win64/extractor.exe
167168
chmod +x ruby/tools/{linux64,osx64}/{autobuilder,extractor}
168169
zip -rq codeql-ruby.zip ruby
169170
- uses: actions/upload-artifact@v3

CODEOWNERS

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
/csharp/ @github/codeql-csharp
33
/go/ @github/codeql-go
44
/java/ @github/codeql-java
5-
/javascript/ @github/codeql-dynamic
6-
/python/ @github/codeql-dynamic
7-
/ruby/ @github/codeql-dynamic
5+
/javascript/ @github/codeql-javascript
6+
/python/ @github/codeql-python
7+
/ruby/ @github/codeql-ruby
88
/swift/ @github/codeql-swift
99
/misc/codegen/ @github/codeql-swift
1010
/java/kotlin-extractor/ @github/codeql-kotlin

config/identical-files.json

Lines changed: 5 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
"java/ql/lib/semmle/code/java/dataflow/internal/DataFlow.qll",
44
"cpp/ql/lib/semmle/code/cpp/dataflow/internal/DataFlow.qll",
55
"cpp/ql/lib/semmle/code/cpp/ir/dataflow/internal/DataFlow.qll",
6-
"cpp/ql/lib/experimental/semmle/code/cpp/ir/dataflow/internal/DataFlow.qll",
76
"csharp/ql/lib/semmle/code/csharp/dataflow/internal/DataFlow.qll",
87
"go/ql/lib/semmle/go/dataflow/internal/DataFlow.qll",
98
"python/ql/lib/semmle/python/dataflow/new/internal/DataFlow.qll",
@@ -14,7 +13,6 @@
1413
"java/ql/lib/semmle/code/java/dataflow/internal/DataFlowImpl.qll",
1514
"cpp/ql/lib/semmle/code/cpp/dataflow/internal/DataFlowImpl.qll",
1615
"cpp/ql/lib/semmle/code/cpp/ir/dataflow/internal/DataFlowImpl.qll",
17-
"cpp/ql/lib/experimental/semmle/code/cpp/ir/dataflow/internal/DataFlowImpl.qll",
1816
"csharp/ql/lib/semmle/code/csharp/dataflow/internal/DataFlowImpl.qll",
1917
"go/ql/lib/semmle/go/dataflow/internal/DataFlowImpl.qll",
2018
"python/ql/lib/semmle/python/dataflow/new/internal/DataFlowImpl.qll",
@@ -28,8 +26,6 @@
2826
"java/ql/lib/semmle/code/java/dataflow/internal/DataFlowImpl4.qll",
2927
"java/ql/lib/semmle/code/java/dataflow/internal/DataFlowImpl5.qll",
3028
"java/ql/lib/semmle/code/java/dataflow/internal/DataFlowImpl6.qll",
31-
"java/ql/lib/semmle/code/java/dataflow/internal/DataFlowImplForSerializability.qll",
32-
"java/ql/lib/semmle/code/java/dataflow/internal/DataFlowImplForOnActivityResult.qll",
3329
"cpp/ql/lib/semmle/code/cpp/dataflow/internal/DataFlowImpl1.qll",
3430
"cpp/ql/lib/semmle/code/cpp/dataflow/internal/DataFlowImpl2.qll",
3531
"cpp/ql/lib/semmle/code/cpp/dataflow/internal/DataFlowImpl3.qll",
@@ -39,10 +35,6 @@
3935
"cpp/ql/lib/semmle/code/cpp/ir/dataflow/internal/DataFlowImpl2.qll",
4036
"cpp/ql/lib/semmle/code/cpp/ir/dataflow/internal/DataFlowImpl3.qll",
4137
"cpp/ql/lib/semmle/code/cpp/ir/dataflow/internal/DataFlowImpl4.qll",
42-
"cpp/ql/lib/experimental/semmle/code/cpp/ir/dataflow/internal/DataFlowImpl1.qll",
43-
"cpp/ql/lib/experimental/semmle/code/cpp/ir/dataflow/internal/DataFlowImpl2.qll",
44-
"cpp/ql/lib/experimental/semmle/code/cpp/ir/dataflow/internal/DataFlowImpl3.qll",
45-
"cpp/ql/lib/experimental/semmle/code/cpp/ir/dataflow/internal/DataFlowImpl4.qll",
4638
"csharp/ql/lib/semmle/code/csharp/dataflow/internal/DataFlowImpl1.qll",
4739
"csharp/ql/lib/semmle/code/csharp/dataflow/internal/DataFlowImpl2.qll",
4840
"csharp/ql/lib/semmle/code/csharp/dataflow/internal/DataFlowImpl3.qll",
@@ -67,7 +59,6 @@
6759
"java/ql/lib/semmle/code/java/dataflow/internal/DataFlowImplCommon.qll",
6860
"cpp/ql/lib/semmle/code/cpp/dataflow/internal/DataFlowImplCommon.qll",
6961
"cpp/ql/lib/semmle/code/cpp/ir/dataflow/internal/DataFlowImplCommon.qll",
70-
"cpp/ql/lib/experimental/semmle/code/cpp/ir/dataflow/internal/DataFlowImplCommon.qll",
7162
"csharp/ql/lib/semmle/code/csharp/dataflow/internal/DataFlowImplCommon.qll",
7263
"go/ql/lib/semmle/go/dataflow/internal/DataFlowImplCommon.qll",
7364
"python/ql/lib/semmle/python/dataflow/new/internal/DataFlowImplCommon.qll",
@@ -77,7 +68,6 @@
7768
"TaintTracking Java/C++/C#/Go/Python/Ruby/Swift": [
7869
"cpp/ql/lib/semmle/code/cpp/dataflow/internal/tainttracking1/TaintTracking.qll",
7970
"cpp/ql/lib/semmle/code/cpp/ir/dataflow/internal/tainttracking1/TaintTracking.qll",
80-
"cpp/ql/lib/experimental/semmle/code/cpp/ir/dataflow/internal/tainttracking1/TaintTracking.qll",
8171
"csharp/ql/lib/semmle/code/csharp/dataflow/internal/tainttracking1/TaintTracking.qll",
8272
"go/ql/lib/semmle/go/dataflow/internal/tainttracking1/TaintTracking.qll",
8373
"java/ql/lib/semmle/code/java/dataflow/internal/tainttracking1/TaintTracking.qll",
@@ -91,9 +81,6 @@
9181
"cpp/ql/lib/semmle/code/cpp/ir/dataflow/internal/tainttracking1/TaintTrackingImpl.qll",
9282
"cpp/ql/lib/semmle/code/cpp/ir/dataflow/internal/tainttracking2/TaintTrackingImpl.qll",
9383
"cpp/ql/lib/semmle/code/cpp/ir/dataflow/internal/tainttracking3/TaintTrackingImpl.qll",
94-
"cpp/ql/lib/experimental/semmle/code/cpp/ir/dataflow/internal/tainttracking1/TaintTrackingImpl.qll",
95-
"cpp/ql/lib/experimental/semmle/code/cpp/ir/dataflow/internal/tainttracking2/TaintTrackingImpl.qll",
96-
"cpp/ql/lib/experimental/semmle/code/cpp/ir/dataflow/internal/tainttracking3/TaintTrackingImpl.qll",
9784
"csharp/ql/lib/semmle/code/csharp/dataflow/internal/tainttracking1/TaintTrackingImpl.qll",
9885
"csharp/ql/lib/semmle/code/csharp/dataflow/internal/tainttracking2/TaintTrackingImpl.qll",
9986
"csharp/ql/lib/semmle/code/csharp/dataflow/internal/tainttracking3/TaintTrackingImpl.qll",
@@ -115,7 +102,6 @@
115102
"java/ql/lib/semmle/code/java/dataflow/internal/DataFlowImplConsistency.qll",
116103
"cpp/ql/lib/semmle/code/cpp/dataflow/internal/DataFlowImplConsistency.qll",
117104
"cpp/ql/lib/semmle/code/cpp/ir/dataflow/internal/DataFlowImplConsistency.qll",
118-
"cpp/ql/lib/experimental/semmle/code/cpp/ir/dataflow/internal/DataFlowImplConsistency.qll",
119105
"csharp/ql/lib/semmle/code/csharp/dataflow/internal/DataFlowImplConsistency.qll",
120106
"python/ql/lib/semmle/python/dataflow/new/internal/DataFlowImplConsistency.qll",
121107
"ruby/ql/lib/codeql/ruby/dataflow/internal/DataFlowImplConsistency.qll",
@@ -293,6 +279,11 @@
293279
"cpp/ql/lib/semmle/code/cpp/ir/implementation/unaliased_ssa/internal/IRBlockImports.qll",
294280
"cpp/ql/lib/semmle/code/cpp/ir/implementation/aliased_ssa/internal/IRBlockImports.qll"
295281
],
282+
"C++ IR IRConsistencyImports": [
283+
"cpp/ql/lib/semmle/code/cpp/ir/implementation/raw/internal/IRConsistencyImports.qll",
284+
"cpp/ql/lib/semmle/code/cpp/ir/implementation/unaliased_ssa/internal/IRConsistencyImports.qll",
285+
"cpp/ql/lib/semmle/code/cpp/ir/implementation/aliased_ssa/internal/IRConsistencyImports.qll"
286+
],
296287
"C++ IR IRFunctionImports": [
297288
"cpp/ql/lib/semmle/code/cpp/ir/implementation/raw/internal/IRFunctionImports.qll",
298289
"cpp/ql/lib/semmle/code/cpp/ir/implementation/unaliased_ssa/internal/IRFunctionImports.qll",

cpp/ql/lib/CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
## 0.5.4
2+
3+
No user-facing changes.
4+
15
## 0.5.3
26

37
No user-facing changes.
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
---
2+
category: breaking
3+
---
4+
* The internal `SsaConsistency` module has been moved from `SSAConstruction` to `SSAConsitency`, and the deprecated `SSAConsistency` module has been removed.
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
---
2+
category: breaking
3+
---
4+
* The `semmle.code.cpp.commons.Buffer` and `semmle.code.cpp.commons.NullTermination` libraries no longer expose `semmle.code.cpp.dataflow.DataFlow`. Please import `semmle.code.cpp.dataflow.DataFlow` directly.
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
---
2+
category: minorAnalysis
3+
---
4+
* Deleted the deprecated `hasGeneratedCopyConstructor` and `hasGeneratedCopyAssignmentOperator` predicates from the `Folder` class.
5+
* Deleted the deprecated `getPath` and `getFolder` predicates from the `XmlFile` class.
6+
* Deleted the deprecated `getMustlockFunction`, `getTrylockFunction`, `getLockFunction`, and `getUnlockFunction` predicates from the `MutexType` class.
7+
* Deleted the deprecated `getPosInBasicBlock` predicate from the `SubBasicBlock` class.
8+
* Deleted the deprecated `getExpr` predicate from the `PointerDereferenceExpr` class.
9+
* Deleted the deprecated `getUseInstruction` and `getDefinitionInstruction` predicates from the `Operand` class.
10+
* Deleted the deprecated `isInParameter`, `isInParameterPointer`, and `isInQualifier` predicates from the `FunctionInput` class.
11+
* Deleted the deprecated `isOutParameterPointer`, `isOutQualifier`, `isOutReturnValue`, and `isOutReturnPointer` predicate from the `FunctionOutput` class.
12+
* Deleted the deprecated 3-argument `isGuardPhi` predicate from the `RangeSsaDefinition` class.

0 commit comments

Comments
 (0)