Summary
Follow-up to #1187, implementing the approach agreed in the review comments.
- Adds a line-scoped
nosemgrepcomment directly on thescheme: basicline insrc/api-docs/openapi.yaml - Does not use
.semgrepignore(which would suppress all rules on the whole file) - Inline justification documents the three mitigations: brute-force throttling, HTTPS requirement, and
OIDC_DISABLE_BASIC_AUTHopt-out - The spec stays accurate and the Swagger UI Authorize dialog retains the Basic option
The comment matches the exact format suggested by @timothepoznanski in #1187 (comment).
Test plan
- Run
semgrep --config=auto src/api-docs/openapi.yaml—use-of-basic-authenticationfinding should be suppressed - Confirm no other semgrep rules newly suppressed (only this one line annotated)
- Confirm OpenAPI spec is still valid YAML (
python3 -c "import yaml; yaml.safe_load(open('src/api-docs/openapi.yaml'))")
🤖 Generated with Claude Code