[ Web Proxy ]
URL:
Viewing: https://raw.githubusercontent.com/python-zeroconf/python-zeroconf/master/.github/workflows/asan.yml [Back]  [Original]

name: ASan fuzz

on:
  workflow_dispatch:
    inputs:
      profile:
        description: "Hypothesis profile"
        default: "long"
        type: choice
        options:
          - ci
          - long

jobs:
  asan-fuzz:
    runs-on: ubuntu-latest
    timeout-minutes: 120
    steps:
      - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v4
      - name: Set up uv
        uses: astral-sh/setup-uv@c18668ad3cf93ea998bef934396af7bb5c839dc7 # v10.2.0
        with:
          enable-cache: true
      - name: Install poetry
        run: uv tool install poetry
      - name: Set up Python
        uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 # v5
        with:
          python-version: "3.13"
          cache: "poetry"
      - name: Install dependencies with AddressSanitizer instrumentation
        env:
          REQUIRE_CYTHON: 1
          CFLAGS: "-fsanitize=address -g -O1"
          LDFLAGS: "-fsanitize=address"
        run: poetry install --only=main,dev
      - name: Fuzz the parser under ASan
        env:
          HYPOTHESIS_PROFILE: ${{ inputs.profile }}
        run: |
          export LD_PRELOAD=$(gcc -print-file-name=libasan.so)
          export ASAN_OPTIONS=detect_leaks=0:halt_on_error=1
          poetry run pytest --timeout=1800 -v --no-cov tests/test_fuzz_incoming.py tests/test_protocol.py

Web Proxy Viewer  |  New URL  |  Original Page