diff --git a/.gitignore b/.gitignore index 58bd849..9346951 100644 --- a/.gitignore +++ b/.gitignore @@ -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 + # build output dist/ .astro/ @@ -21,4 +31,4 @@ pnpm-debug.log* .DS_Store # jetbrains setting folder -.idea/ +.idea/ \ No newline at end of file diff --git a/.gitleaks.toml b/.gitleaks.toml index fa99dcc..6bbde1c 100644 --- a/.gitleaks.toml +++ b/.gitleaks.toml @@ -29,6 +29,15 @@ paths = [ '''.*\.min\.(js|css)$''', '''dist/.*''', '''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