LS-KEY-005: PKCS8 Private Key¶
| Severity | CRITICAL |
| Blast radius | Server access or identity impersonation |
| Rotate at | https://docs.github.com/en/authentication/connecting-to-github-with-ssh/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent |
If this leaks¶
Allows impersonation of the key owner for TLS, signing, or authentication wherever the matching public key or certificate is trusted.
What to do¶
- Rotate or revoke the credential at https://docs.github.com/en/authentication/connecting-to-github-with-ssh/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent.
- Check the provider's audit logs for use you don't recognise.
- Remove it from git history (
leakscan purge --help) and load it from an environment variable or secret manager instead.
Pattern¶
-----BEGIN PRIVATE KEY-----
Suppress¶
On one line: # leakscan:ignore LS-KEY-005. For the whole project:
disable_rules: [LS-KEY-005]