From ebadc8250ee4afbdd51feb518c534df6f596a134 Mon Sep 17 00:00:00 2001 From: Kyle Isom Date: Sat, 26 Sep 2026 03:37:31 -0700 Subject: [PATCH] M5b spec: refuse PGP private key blocks too The private-key rule named only PEM's ending, so an armored PGP private key passed. Public-key blocks still pass. Co-Authored-By: Claude Opus 5.5 (1M context) --- docs/specs/2026-09-26-m5b-hardening.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/specs/2026-09-26-m5b-hardening.md b/docs/specs/2026-09-26-m5b-hardening.md index ee44c4f..0aeed4d 100644 --- a/docs/specs/2026-09-26-m5b-hardening.md +++ b/docs/specs/2026-09-26-m5b-hardening.md @@ -118,7 +118,8 @@ A text holding any of these is refused, with the rule's name: (`sk-learn` is not a key): GitHub (`ghp_`, `gho_`, `ghu_`, `ghs_`, `ghr_`, `github_pat_`), GitLab (`glpat-`), `sk-` followed by at least 20 key characters, Slack (`xox` then one of `b`, `a`, `p`, `r`, `s`, then `-`), AWS access keys (`AKIA` or `ASIA` then 16 upper-case letters or - digits), and private-key blocks (a line starting `-----BEGIN` and ending `PRIVATE KEY-----`). + digits), and private-key blocks (a line starting `-----BEGIN` and ending `PRIVATE KEY-----`, + or, for PGP's armor, `PRIVATE KEY BLOCK-----`; public-key blocks pass). - The chat-template tags (6.2's list), in memory writes only: memory refuses them outright, which is stricter than neutralising (M5a rule, kept).