scrub: /Users/Shared is the system shared folder, not a home path

This commit is contained in:
CRTkafa 2026-10-26 20:17:46 +07:00
parent 0858f4e538
commit 3dc3104bbc

View file

@ -27,7 +27,7 @@ export const RULES: Rule[] = [
{ id: 'private-name', re: new RegExp(['Yon', 'ga'].join(''), 'gi') },
{ id: 'google-api-key', re: new RegExp('AI' + 'za[0-9A-Za-z_-]{35}', 'g') },
// absolute home folders leak a machine's account name (placeholders like /Users/you are fine)
{ id: 'home-path', re: /(?:\/Users\/|\/home\/|[A-Z]:\\Users\\)(?!(?:you|me|user|runner|name|example)\b)[A-Za-z0-9._-]+/g },
{ id: 'home-path', re: /(?:\/Users\/|\/home\/|[A-Z]:\\Users\\)(?!(?:you|me|user|runner|name|example|Shared)\b)[A-Za-z0-9._-]+/g },
];
const SKIP = /(^|\/)(bun\.lock|Cargo\.lock|LICENSE)$|\.(png|jpe?g|webp|gif|ico|icns|woff2?|ttf|otf|p8|p12|aab|ipa|zip)$/i;