chore(security): .gitignore + .gitleaks.toml защита от CMS-export leak
All checks were successful
deploy / deploy (push) Successful in 59s
security / security (push) Successful in 2m37s

Превентивная защита от случайной публикации content/logs, content/data, ghost.*.json (см. инцидент moovg_ru 2026-05-24).

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
striker
2026-05-24 20:09:27 +03:00
parent d27b2f6719
commit f006eedf71
2 changed files with 20 additions and 1 deletions

10
.gitignore vendored
View File

@@ -1,3 +1,13 @@
# Security: НЕ коммитить production logs и CMS data exports
# (могут содержать API keys, JWT, private_key). См. инцидент 2026-05-24.
content/logs/
content/data/
*.production.log
*.production.log.*
ghost.json
ghost.*.json
*.ghost.*.json
node_modules/ node_modules/
dist/ dist/
.astro/ .astro/

View File

@@ -29,6 +29,15 @@ paths = [
'''.*\.min\.(js|css)$''', '''.*\.min\.(js|css)$''',
'''dist/.*''', '''dist/.*''',
'''build/.*''', '''build/.*''',
# Защита на случай возврата CMS exports / production logs в репо
# (см. инцидент 2026-05-24 с Ghost ghost_private_key + members_private_key).
# Сами файлы УЖЕ удалены из history через git filter-repo, allowlist —
# дополнительная защита для будущих commit'ов.
'''content/logs/.*''',
'''content/data/.*''',
'''.*\.production\.log(\.[0-9]+)?$''',
'''.*\.ghost\..*\.json$''',
] ]
# Конкретные паттерны, которые false-positive # Конкретные паттерны, которые false-positive