Skip to content

Commit b7b8104

Browse files
authored
Merge branch 'main' into unifiedcommandinjection
2 parents 00029ff + 2864ac8 commit b7b8104

34 files changed

Lines changed: 74 additions & 57 deletions

‎.github/workflows/csv-coverage-pr-artifacts.yml‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,10 +47,10 @@ jobs:
4747
git checkout HEAD^1
4848
git log -1 --format='%H'
4949
working-directory: base
50-
- name: Set up Python 3.8
50+
- name: Set up Python 3.12
5151
uses: actions/setup-python@v4
5252
with:
53-
python-version: 3.8
53+
python-version: "3.12"
5454
- name: Download CodeQL CLI
5555
uses: ./merge/.github/actions/fetch-codeql
5656
- name: Generate CSV files on merge commit of the PR

‎.github/workflows/csv-coverage-pr-comment.yml‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,10 @@ jobs:
2525
run: echo "$GITHUB_CONTEXT"
2626
- name: Clone self (github/codeql)
2727
uses: actions/checkout@v5
28-
- name: Set up Python 3.8
28+
- name: Set up Python 3.12
2929
uses: actions/setup-python@v4
3030
with:
31-
python-version: 3.8
31+
python-version: "3.12"
3232

3333
- name: Check coverage difference file and comment
3434
env:

‎.github/workflows/csv-coverage-timeseries.yml‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,10 @@ jobs:
2020
with:
2121
path: codeqlModels
2222
fetch-depth: 0
23-
- name: Set up Python 3.8
23+
- name: Set up Python 3.12
2424
uses: actions/setup-python@v4
2525
with:
26-
python-version: 3.8
26+
python-version: "3.12"
2727
- name: Download CodeQL CLI
2828
uses: ./script/.github/actions/fetch-codeql
2929
- name: Build modeled package list

‎.github/workflows/csv-coverage-update.yml‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,10 @@ jobs:
2525
with:
2626
path: ql
2727
fetch-depth: 0
28-
- name: Set up Python 3.8
28+
- name: Set up Python 3.12
2929
uses: actions/setup-python@v4
3030
with:
31-
python-version: 3.8
31+
python-version: "3.12"
3232
- name: Download CodeQL CLI
3333
uses: ./ql/.github/actions/fetch-codeql
3434
- name: Generate coverage files

‎.github/workflows/csv-coverage.yml‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,10 +24,10 @@ jobs:
2424
with:
2525
path: codeqlModels
2626
ref: ${{ github.event.inputs.qlModelShaOverride || github.ref }}
27-
- name: Set up Python 3.8
27+
- name: Set up Python 3.12
2828
uses: actions/setup-python@v4
2929
with:
30-
python-version: 3.8
30+
python-version: "3.12"
3131
- name: Download CodeQL CLI
3232
uses: ./script/.github/actions/fetch-codeql
3333
- name: Build modeled package list

‎.github/workflows/query-list.yml‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,10 @@ jobs:
2626
uses: actions/checkout@v5
2727
with:
2828
path: codeql
29-
- name: Set up Python 3.8
29+
- name: Set up Python 3.12
3030
uses: actions/setup-python@v4
3131
with:
32-
python-version: 3.8
32+
python-version: "3.12"
3333
- name: Download CodeQL CLI
3434
# Look under the `codeql` directory, as this is where we checked out the `github/codeql` repo
3535
uses: ./codeql/.github/actions/fetch-codeql

‎cpp/ql/src/Security/CWE/CWE-078/ExecTainted.qhelp‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ should be safe against command injection.</p>
3434
Sanitize data passed to complex subsystems</a>.</li>
3535
<li>
3636
OWASP:
37-
<a href="https://www.owasp.org/index.php/Command_Injection">Command Injection</a>.
37+
<a href="https://community.owasp.org/attacks/Command_Injection">Command Injection</a>.
3838
</li>
3939

4040

‎cpp/ql/src/experimental/Security/CWE/CWE-078/WordexpTainted.qhelp‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ is performed, making this safe from command injection.</p>
3131
Sanitize data passed to complex subsystems</a>.</li>
3232
<li>
3333
OWASP:
34-
<a href="https://www.owasp.org/index.php/Command_Injection">Command Injection</a>.
34+
<a href="https://community.owasp.org/attacks/Command_Injection">Command Injection</a>.
3535
</li>
3636

3737

‎csharp/ql/src/Security Features/CWE-078/CommandInjection.qhelp‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ without examining it first.</p>
3333

3434
<li>
3535
OWASP:
36-
<a href="https://www.owasp.org/index.php/Command_Injection">Command Injection</a>.
36+
<a href="https://community.owasp.org/attacks/Command_Injection">Command Injection</a>.
3737
</li>
3838

3939
<!-- LocalWords: CWE untrusted unsanitized Runtime

‎go/extractor/registries/registryproxy.go‎

Lines changed: 7 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,13 @@ func getEnvVars() []string {
103103
slog.Error("Failed to close the temporary certificate file", slog.String("error", err.Error()))
104104
} else {
105105
proxy_cert_file = f.Name()
106-
result = append(result, fmt.Sprintf("SSL_CERT_FILE=%s", proxy_cert_file))
106+
// `SSL_CERT_FILE` is used by Go itself; `GIT_SSL_CAINFO` is used by the `git`
107+
// processes that `go` spawns to fetch `git_source` modules.
108+
result = append(
109+
result,
110+
fmt.Sprintf("SSL_CERT_FILE=%s", proxy_cert_file),
111+
fmt.Sprintf("GIT_SSL_CAINFO=%s", proxy_cert_file),
112+
)
107113
}
108114
}
109115

@@ -160,18 +166,6 @@ func getEnvVars() []string {
160166

161167
if len(git_sources) > 0 {
162168
goprivate = append(goprivate, git_sources...)
163-
164-
if proxy_cert_file != "" {
165-
slog.Info("Configuring `git` to use proxy certificate", slog.String("path", proxy_cert_file))
166-
cmd := exec.Command("git", "config", "--global", "http.sslCAInfo", proxy_cert_file)
167-
168-
out, cmdErr := cmd.CombinedOutput()
169-
slog.Info(string(out))
170-
171-
if cmdErr != nil {
172-
slog.Error("Failed to configure `git` to accept the certificate file", slog.String("error", cmdErr.Error()))
173-
}
174-
}
175169
}
176170

177171
result = append(result, fmt.Sprintf("GOPRIVATE=%s", strings.Join(goprivate, ",")))

0 commit comments

Comments
 (0)