Skip to content

Commit 6ab88f9

Browse files
committed
Add Windows ASan soak (no LeakSan, catches buffer overflows + UAF)
1 parent 817a1fc commit 6ab88f9

File tree

2 files changed

+72
-0
lines changed

2 files changed

+72
-0
lines changed

.github/workflows/dry-run.yml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -649,3 +649,39 @@ jobs:
649649
name: soak-asan-${{ matrix.goos }}-${{ matrix.goarch }}
650650
path: soak-results/
651651
retention-days: 14
652+
653+
soak-asan-windows:
654+
if: ${{ inputs.soak_level == 'full' && !inputs.skip_builds }}
655+
needs: [build-windows]
656+
runs-on: windows-latest
657+
timeout-minutes: 45
658+
steps:
659+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
660+
- uses: msys2/setup-msys2@4f806de0a5a7294ffabaff804b38a9b435a73bda # v2
661+
with:
662+
msystem: CLANG64
663+
path-type: inherit
664+
install: >-
665+
mingw-w64-clang-x86_64-python3
666+
git
667+
coreutils
668+
- name: Build (ASan, no LeakSan on Windows)
669+
shell: msys2 {0}
670+
run: |
671+
SANITIZE="-fsanitize=address,undefined -fno-omit-frame-pointer"
672+
scripts/build.sh CC=clang CXX=clang++ EXTRA_CFLAGS="$SANITIZE" EXTRA_LDFLAGS="$SANITIZE"
673+
- name: ASan soak (15 min, no leak detection)
674+
shell: msys2 {0}
675+
env:
676+
ASAN_OPTIONS: "detect_leaks=0:halt_on_error=0:log_path=soak-results/asan"
677+
run: |
678+
BIN=build/c/codebase-memory-mcp
679+
[ -f "${BIN}.exe" ] && BIN="${BIN}.exe"
680+
scripts/soak-test.sh "$BIN" 15
681+
- name: Upload ASan soak metrics
682+
if: always()
683+
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4
684+
with:
685+
name: soak-asan-windows-amd64
686+
path: soak-results/
687+
retention-days: 14

.github/workflows/release.yml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -641,6 +641,42 @@ jobs:
641641
path: soak-results/
642642
retention-days: 14
643643

644+
soak-asan-windows:
645+
if: ${{ inputs.soak_level == 'full' }}
646+
needs: [build-windows]
647+
runs-on: windows-latest
648+
timeout-minutes: 45
649+
steps:
650+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
651+
- uses: msys2/setup-msys2@4f806de0a5a7294ffabaff804b38a9b435a73bda # v2
652+
with:
653+
msystem: CLANG64
654+
path-type: inherit
655+
install: >-
656+
mingw-w64-clang-x86_64-python3
657+
git
658+
coreutils
659+
- name: Build (ASan, no LeakSan on Windows)
660+
shell: msys2 {0}
661+
run: |
662+
SANITIZE="-fsanitize=address,undefined -fno-omit-frame-pointer"
663+
scripts/build.sh --version ${{ inputs.version }} CC=clang CXX=clang++ EXTRA_CFLAGS="$SANITIZE" EXTRA_LDFLAGS="$SANITIZE"
664+
- name: ASan soak (15 min, no leak detection)
665+
shell: msys2 {0}
666+
env:
667+
ASAN_OPTIONS: "detect_leaks=0:halt_on_error=0:log_path=soak-results/asan"
668+
run: |
669+
BIN=build/c/codebase-memory-mcp
670+
[ -f "${BIN}.exe" ] && BIN="${BIN}.exe"
671+
scripts/soak-test.sh "$BIN" 15
672+
- name: Upload ASan soak metrics
673+
if: always()
674+
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4
675+
with:
676+
name: soak-asan-windows-amd64
677+
path: soak-results/
678+
retention-days: 14
679+
644680
# ── Step 6: Create DRAFT release (not public yet) ─────────────
645681
release-draft:
646682
needs: [smoke-unix, smoke-windows, security-static, codeql-gate, soak-quick, soak-quick-windows]

0 commit comments

Comments
 (0)