Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
86 commits
Select commit Hold shift + click to select a range
da2f2ae
persist credentials: false
vszakats Oct 23, 2025
34c89e5
order/formatting
vszakats Oct 23, 2025
025a1d0
pages-ci.yml permissions: {}
vszakats Oct 23, 2025
f30e866
sync upload-artifacts version with other jobs
vszakats Oct 23, 2025
54ffb88
pages.yml limit permissions to deploy job
vszakats Oct 23, 2025
af44f18
silence zizmor about unpinned oss-fuzz action
vszakats Oct 23, 2025
90f8921
use full version for python install action
vszakats Oct 23, 2025
cf4b5e9
use full version for deploy-pages action
vszakats Oct 23, 2025
eda6e78
avoid GH macros in shell code
vszakats Oct 23, 2025
85118a5
pages.yml permissions: {} by default
vszakats Oct 23, 2025
63b90e4
add name for each job for zizmor pedantic
vszakats Oct 23, 2025
b0df63a
say why we need write permisions (for zizmor) copied from the action …
vszakats Oct 23, 2025
f493160
add zizmor job
vszakats Oct 23, 2025
678575a
sh: add missing quote, drop no longer used var, fixup printf mask, sh…
vszakats Oct 23, 2025
79608b8
sh: add missing quote, drop no longer used var, fixup printf mask, sh…
vszakats Oct 23, 2025
a4943f6
sh: add missing quote, drop no longer used var, fixup printf mask, sh…
vszakats Oct 23, 2025
8efe6d8
sh: add missing quote, drop no longer used var, fixup printf mask, sh…
vszakats Oct 23, 2025
2a6b733
move jobs from ci to local 1
vszakats Oct 23, 2025
a2b10ca
move jobs from ci to local 2
vszakats Oct 23, 2025
4772856
build.yml cleanup checkout
vszakats Oct 23, 2025
768105f
checksrc.yml fixup
vszakats Oct 23, 2025
2afde68
fixup pages upload action
vszakats Oct 23, 2025
d313e2b
test_corpus_decoder.py fix indent to be consistently 4
vszakats Oct 23, 2025
9702b25
try dropping actions/setup-python to install 3.12
vszakats Oct 23, 2025
c36f41d
build.yml formatting
vszakats Oct 23, 2025
93cb739
build.yml formatting 2
vszakats Oct 23, 2025
58aa9e8
yamllint fix indentation, spacing
vszakats Oct 23, 2025
5d24909
yamllint fix more
vszakats Oct 23, 2025
8516662
add comment
vszakats Oct 23, 2025
3c55bfc
format like other workflows
vszakats Oct 24, 2025
f5dbde0
format like other workflows 2, drop main from local workflow
vszakats Oct 24, 2025
1b0f8db
set/ignore concurrency limits for zizmor 1.16.0
vszakats Oct 24, 2025
f0f7dc3
pages.yml replace hard-coded string with gh variable
vszakats Oct 24, 2025
7bad78c
use imperative in comment
vszakats Oct 26, 2025
14a9756
pages-ci.yml move pytest-playwright to pyproject.toml
vszakats Oct 26, 2025
43fcfc4
pyproject.toml: move default set into a group, add 'python-tests' target
vszakats Oct 26, 2025
1f368d0
run ruff in ci
vszakats Oct 26, 2025
f405dbb
use imperative in comment more
vszakats Oct 26, 2025
cdb44a4
fix minor ruff issues, drop exception
vszakats Oct 26, 2025
9c4c043
fix more minor ruff issues, drop another exception
vszakats Oct 26, 2025
b707d40
ruff drop the last exception, no longer triggering
vszakats Oct 26, 2025
85a674d
ruff: drop setting causing 2 configuration conflict warnings
vszakats Oct 26, 2025
b384d7e
ruff: sync config with other curl repos
vszakats Oct 26, 2025
5942556
generate_corpus.py fix two ruff warnings
vszakats Oct 26, 2025
32dc437
test_corpus_decoder.py fix comment to pass ruff
vszakats Oct 26, 2025
c99a1be
python: sync all shebang to say `python3`
vszakats Oct 26, 2025
dd807ec
generate_decoder_html.py add missing shebang
vszakats Oct 26, 2025
1de585a
curl_fuzzer_tools: set exec flag for runnable scripts, where missing
vszakats Oct 26, 2025
a690a0e
try not upgrading pip for more determinism/security
vszakats Oct 26, 2025
61c3ca6
GHA tidy-un one-liner runs
vszakats Oct 26, 2025
de1a148
pages-ci.yml optimize apt a little
vszakats Oct 26, 2025
b7b545f
drop step name from actions/checkout
vszakats Oct 26, 2025
ec57669
inline a comment
vszakats Oct 26, 2025
56bd8ac
debug 1
vszakats Oct 26, 2025
0391613
Revert "debug 1"
vszakats Oct 26, 2025
3ecb5ed
tidy up shell shebangs
vszakats Oct 26, 2025
6c67b44
drop copyright year from a file
vszakats Oct 26, 2025
bcc83bc
CMakeLists.txt fix indent/spaces
vszakats Oct 26, 2025
148cf25
CMakeLists.txt rename custom macro to begin with curl_
vszakats Oct 26, 2025
7797d36
CMakeLists.txt rename local vars to begin with _
vszakats Oct 26, 2025
411d945
ci.yml format if expression to match rest of project
vszakats Oct 26, 2025
cc2a263
pip apply std args
vszakats Oct 26, 2025
4749f1f
GHA/ci: try suppressing CodeQL warnings
vszakats Oct 26, 2025
46637a1
Revert "GHA/ci: try suppressing CodeQL warnings"
vszakats Oct 26, 2025
068abc0
run python in venv, also apply some pip options from curl
vszakats Oct 26, 2025
c5a4d7b
pyproject.toml: move scapy to dev group (only used by corpus to pcap …
vszakats Oct 26, 2025
1e77944
switch back to py action
vszakats Oct 26, 2025
96d0f38
Revert "switch back to py action"
vszakats Oct 26, 2025
a01bcd9
pages-ci.yml installing page-gen pkgs
vszakats Oct 26, 2025
ebe35be
Reapply "switch back to py action"
vszakats Oct 26, 2025
619edeb
pyproject.toml formatting to prev
vszakats Oct 26, 2025
d55a74d
pyproject.toml tidy up version formats
vszakats Oct 26, 2025
a5ddc39
cmake: drop redundant DEFINED check for envs. enough to check if the …
vszakats Oct 26, 2025
34c9d1e
cmake: check for non-empty env value, to not accept defined but empty…
vszakats Oct 26, 2025
2f9c6ae
cmake: use string(APPEND)
vszakats Oct 26, 2025
1e58bd7
cmake: do not add CFLAGS/CXXFLAGS manually, they are used by cmake au…
vszakats Oct 26, 2025
94ba626
cmake fold long (>132) lines
vszakats Oct 27, 2025
14ba64a
drop copyright year
vszakats Oct 27, 2025
63b1b35
drop copyright year
vszakats Oct 27, 2025
8a2f1c6
whitespace fixes
vszakats Oct 27, 2025
6297e70
debug 2
vszakats Oct 27, 2025
d0ad1e9
Revert "debug 2"
vszakats Oct 27, 2025
688b837
ossfuzzdeps.sh indent
vszakats Oct 27, 2025
eb4f36b
bash: sync up indent spaces between files (to 2)
vszakats Oct 27, 2025
4692da0
cmake: unfold externalproject name to the ExternalProject_Add line fo…
vszakats Oct 27, 2025
96a3b03
cmake make zlib configure path relative, syncing with the others
vszakats Oct 27, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
78 changes: 78 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
name: Build

'on':
push:
branches:
- master
pull_request:
branches:
- master

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }}
cancel-in-progress: true

permissions: {}

jobs:
Mainline:
name: 'Mainline'
strategy:
matrix:
sanitizer:
- address
- memory

runs-on: ubuntu-latest
steps:
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
persist-credentials: false

- name: Install Dependencies
run: |
sudo rm -f /etc/apt/sources.list.d/microsoft-prod.list
sudo apt-get -o Dpkg::Use-Pty=0 update
sudo rm -f /var/lib/man-db/auto-update
sudo apt-get -o Dpkg::Use-Pty=0 install -y cmake clang ninja-build

- name: Compile mainline
env:
SANITIZER: '${{ matrix.sanitizer }}' # test with different "sanitizers"
run: ./mainline.sh

just_dependencies:
name: 'Just dependencies'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
persist-credentials: false

- name: Install Dependencies
run: |
sudo rm -f /etc/apt/sources.list.d/microsoft-prod.list
sudo apt-get -o Dpkg::Use-Pty=0 update
sudo rm -f /var/lib/man-db/auto-update
sudo apt-get -o Dpkg::Use-Pty=0 install -y cmake clang ninja-build

- name: Compile deps target
run: ./scripts/compile_target.sh deps

PythonTests:
name: 'Python tests'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
persist-credentials: false

- uses: actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c # v6
with:
python-version: '3.12'

- name: Install test dependencies
run: pip --disable-pip-version-check --no-input --no-cache-dir install --progress-bar off --prefer-binary '.[python-tests]'

- name: Run TLV constants sync test
run: pytest tests/test_tlv_constants_sync.py
50 changes: 50 additions & 0 deletions .github/workflows/checksrc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
# Copyright (C) Daniel Stenberg, <[email protected]>, et al.
#
# SPDX-License-Identifier: curl

name: 'Source'

'on':
push:
branches:
- master
pull_request:
branches:
- master

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }}
cancel-in-progress: true

permissions: {}

jobs:
linters:
name: 'linters'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
persist-credentials: false

- uses: actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c # v6
with:
python-version: '3.12'

- name: 'install prereqs'
run: |
/home/linuxbrew/.linuxbrew/bin/brew install zizmor
pip --disable-pip-version-check --no-input --no-cache-dir install --progress-bar off --prefer-binary '.[ci-tests]'

- name: 'zizmor GHA'
env:
GH_TOKEN: '${{ secrets.GITHUB_TOKEN }}'
run: |
eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)"
zizmor --pedantic .github/workflows/*.yml

- name: 'ruff'
run: |
ruff --version
# shellcheck disable=SC2046
ruff check $(git ls-files '*.py')
127 changes: 39 additions & 88 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
# Workflow used by curl/curl

name: CI

'on':
push:
branches:
Expand All @@ -20,14 +23,16 @@ permissions: {}

jobs:
DetermineMatrix:
name: 'Determine matrix'
runs-on: ubuntu-latest
outputs:
matrix: ${{ steps.set-matrix.outputs.matrix }}
steps:
- name: Checkout
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
persist-credentials: false
repository: curl/curl-fuzzer

- name: Set matrix
id: set-matrix
run: |
Expand All @@ -36,29 +41,31 @@ jobs:
python3 -m generate_matrix | tee $GITHUB_OUTPUT

BuildFuzzers:
name: 'Build fuzzers'
runs-on: ubuntu-latest
steps:
# Use the CIFuzz job to test the repository.
- name: Build Fuzzers
uses: google/oss-fuzz/infra/cifuzz/actions/build_fuzzers@master
with:
oss-fuzz-project-name: 'curl'
dry-run: false
keep-unaffected-fuzz-targets: true
# Use the CIFuzz job to test the repository.
- name: Build Fuzzers
uses: google/oss-fuzz/infra/cifuzz/actions/build_fuzzers@master # zizmor: ignore[unpinned-uses]
with:
oss-fuzz-project-name: 'curl'
dry-run: false
keep-unaffected-fuzz-targets: true

# Archive the fuzzer output (which maintains permissions)
- name: Create fuzz tar
run: tar cvf fuzz.tar build-out/
# Archive the fuzzer output (which maintains permissions)
- name: Create fuzz tar
run: tar cvf fuzz.tar build-out/

# Upload the fuzzer output
- name: Archive fuzz tar
uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0
with:
name: fuzz_tar
path: fuzz.tar
# Upload the fuzzer output
- name: Archive fuzz tar
uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0
with:
name: fuzz_tar
path: fuzz.tar

RunFuzzers:
needs: [ BuildFuzzers, DetermineMatrix ]
name: 'Run fuzzers'
needs: [BuildFuzzers, DetermineMatrix]
runs-on: ubuntu-latest
strategy:
matrix: ${{ fromJSON(needs.DetermineMatrix.outputs.matrix) }}
Expand All @@ -67,89 +74,33 @@ jobs:
with:
name: fuzz_tar
- name: Unpack fuzzer ${{ matrix.fuzzer }}
run: tar xvf fuzz.tar build-out/${{ matrix.fuzzer }} build-out/${{ matrix.fuzzer }}_seed_corpus.zip
env:
MATRIX_FUZZER: '${{ matrix.fuzzer }}'
run: tar xvf fuzz.tar build-out/"${MATRIX_FUZZER}" build-out/"${MATRIX_FUZZER}"_seed_corpus.zip
- name: Display extracted files
run: ls -laR build-out/
- name: Run Fuzzer ${{ matrix.fuzzer }}
uses: google/oss-fuzz/infra/cifuzz/actions/run_fuzzers@master
uses: google/oss-fuzz/infra/cifuzz/actions/run_fuzzers@master # zizmor: ignore[unpinned-uses]
with:
oss-fuzz-project-name: 'curl'
fuzz-seconds: 120
dry-run: false
- name: Upload Crash
uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0
if: failure()
if: ${{ failure() }}
with:
name: artifacts
path: ./out/artifacts

Mainline:
strategy:
matrix:
sanitizer:
- address
- memory

runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
repository: curl/curl-fuzzer
- name: Install Dependencies
run: |
sudo rm -f /etc/apt/sources.list.d/microsoft-prod.list
sudo apt-get -o Dpkg::Use-Pty=0 update
sudo rm -f /var/lib/man-db/auto-update
sudo apt-get -o Dpkg::Use-Pty=0 install -y cmake clang ninja-build
- name: Compile mainline
env:
# test with different "sanitizers"
SANITIZER: ${{ matrix.sanitizer }}
run: ./mainline.sh

just_dependencies:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
repository: curl/curl-fuzzer
- name: Install Dependencies
run: |
sudo rm -f /etc/apt/sources.list.d/microsoft-prod.list
sudo apt-get -o Dpkg::Use-Pty=0 update
sudo rm -f /var/lib/man-db/auto-update
sudo apt-get -o Dpkg::Use-Pty=0 install -y cmake clang ninja-build
- name: Compile deps target
run: ./scripts/compile_target.sh deps

PythonTests:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
repository: curl/curl-fuzzer
- name: Set up Python
uses: actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c # v6
with:
python-version: '3.12'
- name: Install test dependencies
run: |
python -m pip install --upgrade pip
pip install pytest
- name: Run TLV constants sync test
run: pytest tests/test_tlv_constants_sync.py

# Ensure that the repository can be built for i386
Testi386:
name: 'Test i386'
runs-on: ubuntu-latest
steps:
- name: Build Fuzzers
uses: google/oss-fuzz/infra/cifuzz/actions/build_fuzzers@master
with:
oss-fuzz-project-name: 'curl'
dry-run: false
keep-unaffected-fuzz-targets: true
architecture: 'i386'
- name: Build Fuzzers
uses: google/oss-fuzz/infra/cifuzz/actions/build_fuzzers@master # zizmor: ignore[unpinned-uses]
with:
oss-fuzz-project-name: 'curl'
dry-run: false
keep-unaffected-fuzz-targets: true
architecture: 'i386'
3 changes: 2 additions & 1 deletion .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@ name: 'CodeQL'
- cron: '0 0 * * 4'

concurrency:
group: ${{ github.workflow }}
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }}
cancel-in-progress: true

permissions: {}

Expand Down
32 changes: 19 additions & 13 deletions .github/workflows/pages-ci.yml
Original file line number Diff line number Diff line change
@@ -1,36 +1,42 @@
name: Playwright browser test for corpus decoder

on:
'on':
push:
branches: [master]
branches:
- master
pull_request:
branches: [master]
branches:
- master
workflow_dispatch:

permissions:
contents: read
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }}
cancel-in-progress: true

permissions: {}

jobs:
test:
name: 'Test pages'
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
persist-credentials: false

- name: Set up Python
uses: actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c # v6
- uses: actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c # v6
with:
python-version: "3.12"
python-version: '3.12'

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install .[browser-tests]
pip install pytest pytest-playwright
pip --disable-pip-version-check --no-input --no-cache-dir install --progress-bar off --prefer-binary '.[page-gen,browser-tests]'
python -m playwright install
- name: Install Playwright system dependencies
run: |
sudo rm -f /etc/apt/sources.list.d/microsoft-prod.list
sudo rm -f /var/lib/man-db/auto-update
playwright install-deps
- name: Run Playwright browser test
Expand Down
Loading