Semgrep SAST Scan
Run static application security testing with Semgrep.
What To Do
Install:
pip install semgreporbrew install semgrepRun scan:
semgrep scan --config=auto --json --output=semgrep-report.jsonCustom rules for .NET:
semgrep scan --config=p/csharp --config=p/owasp-top-ten --config=p/jwtCI Integration:
- script: semgrep scan --config=auto --error --json -o semgrep.json displayName: "SAST Scan"Interpret results: Fix HIGH/ERROR severity first. Use
--severity=errorto filter.
Arguments
--config=<ruleset>: Semgrep config (auto, p/csharp, p/owasp-top-ten)--severity=<level>: Filter by severity (info, warning, error)