跳转到主要内容
此内容尚未提供您的语言版本,正在以英文显示。

AddressSanitizer

技能 活跃

AddressSanitizer detects memory errors during fuzzing. Use when fuzzing C/C++ code to find buffer overflows and use-after-free bugs.

目的

To enable developers to effectively use AddressSanitizer for finding memory corruption bugs in C/C++ code during fuzzing and testing.

功能

  • Detects memory errors like buffer overflows and use-after-free
  • Integrates with C/C++ compilation toolchains (Clang/GCC)
  • Configurable runtime options via environment variables
  • Provides step-by-step integration guides for fuzzers (libFuzzer, AFL++, cargo-fuzz)
  • Includes troubleshooting for common ASan issues

使用场景

  • Fuzzing C/C++ code to find memory safety vulnerabilities
  • Debugging crashes related to memory corruption
  • Enhancing unit test suites with memory error detection
  • Improving the security posture of C/C++ projects

非目标

  • Applying ASan in production environments due to performance overhead
  • Fuzzing pure safe languages without FFI or platforms with limited ASan support (Windows, macOS)
  • Replacing fundamental fuzzing techniques or harness writing
  • Detecting non-memory-related bugs

工作流

  1. Compile C/C++ code with AddressSanitizer flags (`-fsanitize=address`)
  2. Configure ASan runtime behavior using `ASAN_OPTIONS` environment variable
  3. Run the instrumented program or fuzzer
  4. Analyze ASan's detailed error reports when memory errors are detected
  5. Adjust fuzzer memory limits if necessary for ASan's virtual memory requirements

Trust

  • warning:Issues Attention13 issues opened, 4 closed in the last 90 days, indicating a low closure rate and slow maintainer response.

安装

请先添加 Marketplace

/plugin marketplace add trailofbits/skills
/plugin install testing-handbook-skills@trailofbits

质量评分

85 /100
about 23 hours ago 分析

信任信号

最近提交3 days ago
星标5.2k
许可证CC-BY-SA-4.0
状态
查看源代码