Skip to content

Commit

Permalink
Add intra42 client secret matcher (#86)
Browse files Browse the repository at this point in the history
intra42 is the intranet and API of "42 School", a CS school.
The API is open to all students in 57 campus around the world.
It is thus often subject to credentials leaks on GitHub
See https://42.fr and https://api.intra.42.fr/
  • Loading branch information
alexandregv committed May 12, 2024
1 parent 033ec51 commit 4bdd9b0
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ fn predefined_secret_regexes() -> Vec<&'static str> {
"-----BEGIN RSA PRIVATE KEY-----(?:$|[^-]{63}[^-]*-----END)",
"-----BEGIN SSH2 ENCRYPTED PRIVATE KEY-----(?:$|[^-]{63}[^-]*-----END)",
"PuTTY-User-Key-File-2",
"s-s4t2(?:ud|af)-[abcdef0123456789]{64}", // intra42 client secret
matcher::RANDOM_STRING_REGEX,
];
}
Expand Down
2 changes: 2 additions & 0 deletions test/one_per_line/intra42
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
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
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

0 comments on commit 4bdd9b0

Please sign in to comment.