Commit c228181
Add gitleaks secret scanning (CI) (#527)
* Add gitleaks secret scanning (CI)
GitHub native secret scanning and gitleaks' default rules miss NCBO BioPortal
API keys because they are bare UUIDs with no provider prefix, so flagging them
generically would be pure noise. Add gitleaks in CI with the community default
ruleset plus one BioPortal-specific rule keyed on the apikey context. The scan
runs on new commits per PR/push (not full history, which is dominated by
false positives in ontology data).
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
* Fix checkout pin to commit SHA + persist-credentials: false (zizmor)
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
* gitleaks: handle whitespace around token= and case-insensitive domain
Addresses Copilot review on #527:
- rule 1: allow optional whitespace around 'token =' so 'apikey token = <uuid>'
is caught (the no-space 'apikey token=<uuid>' form already matched).
- rule 2: add '(?i)' so case variants of the bioontology.org domain are caught.
Validated with gitleaks 8.30.1: all documented BioPortal key forms flagged,
contextless bare UUID not flagged.
Co-Authored-By: Claude <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>1 parent 8275b90 commit c228181
2 files changed
Lines changed: 81 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
0 commit comments