@aegis-scan/skills 0.4.0 → 0.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/ATTRIBUTION.md +204 -0
- package/CHANGELOG.md +48 -3
- package/package.json +1 -1
- package/sbom.cdx.json +1 -1
- package/skills/compliance/aegis-native/brutaler-anwalt/.claude-plugin/plugin.json +108 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/CHANGELOG.md +1080 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/HANDOVER-LO-LIVE-VERIFICATION-2026-05-15.md +187 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/LICENSE +43 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/README.md +242 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/SKILL.md +427 -14
- package/skills/compliance/aegis-native/brutaler-anwalt/commands/audit.md +193 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/commands/avv-redline.md +246 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/commands/az-verify.md +155 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/commands/cold-start.md +157 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/commands/dsar-respond.md +180 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/commands/health.md +50 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/commands/simulate.md +158 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/hooks/post_write.py +315 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/hooks/prompt_submit.py +144 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/hooks/session_start.py +57 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/hooks/triggers.json +191 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/INDEX.md +102 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/abmahn-templates.md +1 -1
- package/skills/compliance/aegis-native/brutaler-anwalt/references/aegis-integration.md +63 -9
- package/skills/compliance/aegis-native/brutaler-anwalt/references/audit-patterns.md +1581 -10
- package/skills/compliance/aegis-native/brutaler-anwalt/references/az-auffuellung-batch1.md +468 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/bgh-urteile.md +323 -31
- package/skills/compliance/aegis-native/brutaler-anwalt/references/branchenrecht.md +610 -1
- package/skills/compliance/aegis-native/brutaler-anwalt/references/checklisten.md +107 -1
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-aufsichtsbehoerden-taetigkeitsberichte-2024.md +310 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-bussgeld-argumentations-layer.md +598 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-dsk-beschluesse.md +346 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/AGG/audit-relevance.md +76 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/AGG/paragraphs.md +115 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/AMG/audit-relevance.md +58 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/AMG/paragraphs.md +95 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/ArbZG/audit-relevance.md +60 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/ArbZG/paragraphs.md +90 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/BetrVG/audit-relevance.md +73 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/BetrVG/paragraphs.md +114 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/DDG/audit-relevance.md +72 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/DDG/paragraphs.md +103 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/DiGAV/audit-relevance.md +65 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/DiGAV/paragraphs.md +102 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/ElektroG/audit-relevance.md +66 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/ElektroG/paragraphs.md +108 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/FernUSG/audit-relevance.md +80 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/FernUSG/paragraphs.md +102 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/GeschGehG/audit-relevance.md +89 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/GeschGehG/paragraphs.md +107 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/GwG/audit-relevance.md +62 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/GwG/paragraphs.md +119 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/HWG/audit-relevance.md +70 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/HWG/paragraphs.md +125 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/HinSchG/audit-relevance.md +70 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/HinSchG/paragraphs.md +116 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/INDEX.md +152 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/KWG/audit-relevance.md +64 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/KWG/paragraphs.md +110 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/LFGB/audit-relevance.md +63 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/LFGB/paragraphs.md +90 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/MPDG/audit-relevance.md +61 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/MPDG/paragraphs.md +96 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/NachwG/audit-relevance.md +54 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/NachwG/paragraphs.md +82 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/PAngV/audit-relevance.md +76 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/PAngV/paragraphs.md +86 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/RDG/audit-relevance.md +84 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/RDG/paragraphs.md +114 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/TDDDG/audit-relevance.md +92 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/TDDDG/paragraphs.md +91 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/UrhG-UrhDaG/audit-relevance.md +85 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/UrhG-UrhDaG/paragraphs.md +166 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/VDuG/audit-relevance.md +71 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/VDuG/paragraphs.md +102 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/VERIFICATION-NOTES.md +111 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/VVG/audit-relevance.md +65 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/VVG/paragraphs.md +101 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/VerpackG/audit-relevance.md +62 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/VerpackG/paragraphs.md +120 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/WpHG/audit-relevance.md +64 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/WpHG/paragraphs.md +120 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/ZAG/audit-relevance.md +68 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/de-statute-tier1/ZAG/paragraphs.md +110 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/dsgvo.md +81 -8
- package/skills/compliance/aegis-native/brutaler-anwalt/references/eu-edpb-guidelines.md +505 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/eu-eugh-dsgvo-schadensersatz.md +223 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/BDSG/audit-relevance.md +31 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/BDSG/paragraphs.md +62 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/BFSG/audit-relevance.md +39 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/BFSG/paragraphs.md +85 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/BGB/audit-relevance.md +42 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/BGB/paragraphs.md +112 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/DDG/audit-relevance.md +28 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/DDG/paragraphs.md +71 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/DSGVO/articles.md +182 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/DSGVO/audit-relevance.md +35 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/AI-Act-2024-1689/articles.md +111 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/AI-Act-2024-1689/audit-relevance.md +139 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/AI-Act-2024-1689/gpai-pflichten.md +102 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/AI-Act-2024-1689/hochrisiko-annex-iii.md +134 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/AI-Act-2024-1689/sanktionen-art-99.md +97 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/AI-Act-2024-1689/transparenz-art-50.md +120 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/AI-Act-2024-1689/uebergangsfristen.md +109 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/CER-2022-2557/articles.md +42 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/CRA-2024-2847/articles.md +87 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/CSDDD-2024-1760/articles.md +43 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/CSRD-2022-2464/articles.md +42 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/DGA-2022-868/articles.md +53 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/DMA-2022-1925/articles.md +55 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/DORA-2022-2554/articles.md +164 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/DORA-2022-2554/audit-relevance.md +86 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/DSA-2022-2065/articles.md +134 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/DSA-2022-2065/audit-relevance.md +110 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/DSA-2022-2065/notice-and-action.md +138 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/DSA-2022-2065/small-platform-pflichten.md +109 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/DSA-2022-2065/trusted-flaggers.md +77 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/DSA-2022-2065/vlop-vlose.md +130 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/Data-Act-2023-2854/articles.md +102 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/Data-Act-2023-2854/audit-relevance.md +77 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/MiCA-2023-1114/articles.md +124 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/MiCA-2023-1114/audit-relevance.md +85 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/NIS2-2022-2555/articles.md +101 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/ProdHaftRL-2024-2853/articles.md +68 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/EU-Verordnungen/eIDAS-2024-1183/articles.md +43 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/Finance/KWG.md +52 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/Finance/PSD2.md +67 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/Finance/ZAG.md +50 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/GlueStV/articles.md +86 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/HGB-AO/audit-relevance.md +27 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/HGB-AO/paragraphs.md +61 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/HinSchG/articles.md +96 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/INDEX.md +93 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/JuSchG-JMStV/articles.md +86 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/KritisDachG/articles.md +39 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/LkSG/articles.md +90 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/MedTech/DiGAV.md +60 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/MedTech/IVDR-2017-746.md +51 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/MedTech/MDR-2017-745.md +85 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/NIS2UmsuCG-BSIG/articles.md +53 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/StGB/relevante-paragraphen.md +157 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/TDDDG/audit-relevance.md +33 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/TDDDG/paragraphs.md +68 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/TKG/articles.md +73 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/UWG/audit-relevance.md +39 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/UWG/paragraphs.md +185 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/VERIFICATION-STATUS.md +266 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/VSBG/audit-relevance.md +37 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/VSBG/paragraphs.md +57 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/ePrivacy-RL-2002-58/articles.md +92 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/gesetze/ePrivacy-RL-2002-58/audit-relevance.md +62 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/it-recht.md +137 -9
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/INDEX.md +122 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/ai/anthropic-dpa.md +87 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/ai/mistral-eu.md +123 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/ai/openai-dpa.md +120 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/astro/cookie-banner-pattern.md +202 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/astro/dse-section-pattern.md +198 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/astro/tracking-server-endpoint.md +193 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/auth/auth0-tom.md +92 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/auth/clerk-tom.md +84 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/auth/nextauth-tom.md +120 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/auth/supabase-auth-tom.md +104 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/django/auth-cookies-pattern.md +295 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/django/cookie-banner-pattern.md +318 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/django/gdpr-cleanup-celery.md +339 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/express/cookie-banner-pattern.md +237 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/express/gdpr-routes-pattern.md +256 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/express/helmet-csp-pattern.md +207 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/laravel/agb-versioning-pattern.md +305 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/laravel/cookie-banner-pattern.md +287 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/laravel/gdpr-models-pattern.md +290 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/laravel/tracking-config-pattern.md +263 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/nest/auth-pattern.md +265 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/nest/cookie-banner-pattern.md +255 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/nest/gdpr-cleanup-cron.md +244 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/nest/tracking-interceptor.md +239 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/nextjs/api-route-bearer-auth.md +103 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/nextjs/dynamic-rendering-headers.md +83 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/nextjs/env-driven-tracking.md +135 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/nextjs/proxy-csp-pattern.md +93 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/payment/stripe-pci-tom.md +121 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/rails/cookie-banner-pattern.md +294 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/rails/devise-dsgvo-pattern.md +262 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/rails/gdpr-anonymization-pattern.md +283 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/react/consent-gate-pattern.md +99 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/react/cookie-banner-pattern.md +204 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/strapi/cms-pii-pattern.md +301 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/strapi/notice-and-action-plugin.md +371 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/svelte/cookie-banner-pattern.md +234 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/svelte/dse-section-pattern.md +231 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/svelte/sveltekit-server-hooks-pattern.md +217 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/tracking/google-analytics-consent.md +129 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/tracking/plausible-pattern.md +107 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/tracking/posthog-consent.md +79 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/vue/cookie-banner-pattern.md +208 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/vue/dse-i18n-pattern.md +204 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/vue/nuxt-vs-vue-only-pattern.md +197 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/stack-patterns/vue/tracking-pinia-pattern.md +211 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/strafrecht-steuer.md +1 -1
- package/skills/compliance/aegis-native/brutaler-anwalt/references/streitwerte.json +176 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/templates/AffiliateDisclaimer.tsx.example +54 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/templates/COMPLIANCE-AUDIT-TRAIL-template.md +95 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/templates/DSE-Section-UGC.md.example +77 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/templates/DSFA-template.md +156 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/templates/LostFoundReportForm-consent.tsx.example +126 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/templates/README.md +33 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/templates/UmamiScript.tsx.example +64 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/templates/VVT-template-file-upload.md +98 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/templates/VVT-template.md +60 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/templates/data-retention-cron.ts.example +52 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/templates/data-retention-workflow.yml.example +47 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/templates/proxy-strict-dynamic.ts.example +80 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/templates/security.txt.example +26 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/templates-avv-layer/AVV-EN-international.md +267 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/templates-avv-layer/AVV-anhang-Audit-Klausel-Varianten.md +148 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/templates-avv-layer/AVV-anhang-CH-revDSG.md +127 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/templates-avv-layer/AVV-anhang-SCC-module2-controller-processor.md +180 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/templates-avv-layer/AVV-anhang-SCC-module3-processor-subprocessor.md +144 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/templates-avv-layer/AVV-anhang-Sub-Processor-List.md +114 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/templates-avv-layer/AVV-anhang-TOMs.md +197 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/templates-avv-layer/AVV-anhang-UK-IDTA.md +131 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/templates-avv-layer/AVV-standard-DE.md +288 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/references/templates-avv-layer/Joint-Controller-Vertrag-Art-26.md +265 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/scripts/health-check.sh +262 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/scripts/test-triggers.sh +145 -0
- package/skills/compliance/aegis-native/brutaler-anwalt/settings.json +90 -0
- package/skills/defensive/aegis-native/rls-defense/SKILL.md +85 -0
- package/skills/defensive/permoon-fork/README.md +40 -0
- package/skills/defensive/permoon-fork/multi-model-consolidation/SKILL.md +47 -0
- package/skills/defensive/permoon-fork/multi-model-severity/SKILL.md +34 -0
- package/skills/defensive/permoon-fork/multi-model-system-prompt/SKILL.md +40 -0
- package/skills/foundation/aegis-native/aegis-handover-writer/SKILL.md +1 -1
- package/skills/foundation/aegis-native/aegis-module-builder/SKILL.md +5 -1
- package/skills/foundation/aegis-native/aegis-orchestrator/SKILL.md +87 -4
- package/skills/foundation/aegis-native/aegis-quality-gates/SKILL.md +69 -9
- package/skills/offensive/airecon-fork/ctf-crypto/SKILL.md +260 -0
- package/skills/offensive/airecon-fork/ctf-crypto-modern-ciphers/SKILL.md +688 -0
- package/skills/offensive/airecon-fork/ctf-forensics/SKILL.md +253 -0
- package/skills/offensive/airecon-fork/ctf-forensics-network/SKILL.md +480 -0
- package/skills/offensive/airecon-fork/ctf-heap-advanced/SKILL.md +336 -0
- package/skills/offensive/airecon-fork/ctf-pwn/SKILL.md +294 -0
- package/skills/offensive/airecon-fork/ctf-pwn-rop-and-shellcode/SKILL.md +392 -0
- package/skills/offensive/airecon-fork/ctf-reversing/SKILL.md +284 -0
- package/skills/offensive/airecon-fork/frameworks-django/SKILL.md +268 -0
- package/skills/offensive/airecon-fork/frameworks-dotnet/SKILL.md +280 -0
- package/skills/offensive/airecon-fork/frameworks-express/SKILL.md +266 -0
- package/skills/offensive/airecon-fork/frameworks-fastapi/SKILL.md +193 -0
- package/skills/offensive/airecon-fork/frameworks-flask/SKILL.md +297 -0
- package/skills/offensive/airecon-fork/frameworks-laravel/SKILL.md +260 -0
- package/skills/offensive/airecon-fork/frameworks-nextjs/SKILL.md +230 -0
- package/skills/offensive/airecon-fork/frameworks-php/SKILL.md +271 -0
- package/skills/offensive/airecon-fork/frameworks-rails/SKILL.md +269 -0
- package/skills/offensive/airecon-fork/frameworks-spring/SKILL.md +245 -0
- package/skills/offensive/airecon-fork/frameworks-wordpress/SKILL.md +348 -0
- package/skills/offensive/airecon-fork/payloads-command-injection/SKILL.md +459 -0
- package/skills/offensive/airecon-fork/payloads-http-parameter-pollution/SKILL.md +129 -0
- package/skills/offensive/airecon-fork/payloads-ldap-injection/SKILL.md +100 -0
- package/skills/offensive/airecon-fork/payloads-lfi/SKILL.md +485 -0
- package/skills/offensive/airecon-fork/payloads-sqli/SKILL.md +419 -0
- package/skills/offensive/airecon-fork/payloads-ssrf/SKILL.md +125 -0
- package/skills/offensive/airecon-fork/payloads-ssti/SKILL.md +443 -0
- package/skills/offensive/airecon-fork/payloads-xss/SKILL.md +447 -0
- package/skills/offensive/airecon-fork/payloads-xxe/SKILL.md +172 -0
- package/skills/offensive/airecon-fork/postexploit-ad-credential-attacks/SKILL.md +306 -0
- package/skills/offensive/airecon-fork/postexploit-container-escape/SKILL.md +299 -0
- package/skills/offensive/airecon-fork/postexploit-credential-dumping/SKILL.md +249 -0
- package/skills/offensive/airecon-fork/postexploit-lateral-movement/SKILL.md +194 -0
- package/skills/offensive/airecon-fork/postexploit-linux-privesc/SKILL.md +252 -0
- package/skills/offensive/airecon-fork/postexploit-netexec-workflow/SKILL.md +302 -0
- package/skills/offensive/airecon-fork/postexploit-pivoting/SKILL.md +205 -0
- package/skills/offensive/airecon-fork/postexploit-windows-privesc/SKILL.md +210 -0
- package/skills/offensive/airecon-fork/protocols-active-directory/SKILL.md +314 -0
- package/skills/offensive/airecon-fork/protocols-dns/SKILL.md +203 -0
- package/skills/offensive/airecon-fork/protocols-ftp/SKILL.md +159 -0
- package/skills/offensive/airecon-fork/protocols-graphql/SKILL.md +648 -0
- package/skills/offensive/airecon-fork/protocols-kerberos/SKILL.md +168 -0
- package/skills/offensive/airecon-fork/protocols-ldap/SKILL.md +245 -0
- package/skills/offensive/airecon-fork/protocols-rdp/SKILL.md +186 -0
- package/skills/offensive/airecon-fork/protocols-smb/SKILL.md +191 -0
- package/skills/offensive/airecon-fork/protocols-smtp-imap/SKILL.md +263 -0
- package/skills/offensive/airecon-fork/protocols-snmp/SKILL.md +147 -0
- package/skills/offensive/airecon-fork/protocols-ssh/SKILL.md +287 -0
- package/skills/offensive/airecon-fork/reconnaissance-asn-whois-osint/SKILL.md +236 -0
- package/skills/offensive/airecon-fork/reconnaissance-ctf-methodology/SKILL.md +435 -0
- package/skills/offensive/airecon-fork/reconnaissance-dorking/SKILL.md +182 -0
- package/skills/offensive/airecon-fork/reconnaissance-exposed-devtools-detection/SKILL.md +513 -0
- package/skills/offensive/airecon-fork/reconnaissance-full-recon/SKILL.md +305 -0
- package/skills/offensive/airecon-fork/reconnaissance-internal-pentest/SKILL.md +202 -0
- package/skills/offensive/airecon-fork/reconnaissance-javascript-analysis/SKILL.md +167 -0
- package/skills/offensive/airecon-fork/reconnaissance-js-internal-hostname-intelligence/SKILL.md +391 -0
- package/skills/offensive/airecon-fork/reconnaissance-monitoring-secrets-exposure/SKILL.md +394 -0
- package/skills/offensive/airecon-fork/reconnaissance-shodan-censys/SKILL.md +279 -0
- package/skills/offensive/airecon-fork/reconnaissance-subdomain-enum/SKILL.md +952 -0
- package/skills/offensive/airecon-fork/technologies-cicd-attacks/SKILL.md +283 -0
- package/skills/offensive/airecon-fork/technologies-cloud-security/SKILL.md +299 -0
- package/skills/offensive/airecon-fork/technologies-docker-container/SKILL.md +266 -0
- package/skills/offensive/airecon-fork/technologies-elasticsearch/SKILL.md +226 -0
- package/skills/offensive/airecon-fork/technologies-firebase-firestore/SKILL.md +213 -0
- package/skills/offensive/airecon-fork/technologies-frida-hooking/SKILL.md +387 -0
- package/skills/offensive/airecon-fork/technologies-gitlab-github/SKILL.md +259 -0
- package/skills/offensive/airecon-fork/technologies-jenkins/SKILL.md +256 -0
- package/skills/offensive/airecon-fork/technologies-kubernetes-pentest/SKILL.md +281 -0
- package/skills/offensive/airecon-fork/technologies-memcached/SKILL.md +230 -0
- package/skills/offensive/airecon-fork/technologies-mobile-app-pentesting/SKILL.md +105 -0
- package/skills/offensive/airecon-fork/technologies-mongodb/SKILL.md +257 -0
- package/skills/offensive/airecon-fork/technologies-nginx-apache/SKILL.md +280 -0
- package/skills/offensive/airecon-fork/technologies-observability-stack-attacks/SKILL.md +501 -0
- package/skills/offensive/airecon-fork/technologies-redis/SKILL.md +236 -0
- package/skills/offensive/airecon-fork/technologies-supabase/SKILL.md +270 -0
- package/skills/offensive/airecon-fork/technologies-tomcat/SKILL.md +232 -0
- package/skills/offensive/airecon-fork/tools-advanced-fuzzing/SKILL.md +351 -0
- package/skills/offensive/airecon-fork/tools-browser-automation/SKILL.md +300 -0
- package/skills/offensive/airecon-fork/tools-caido/SKILL.md +776 -0
- package/skills/offensive/airecon-fork/tools-code-review/SKILL.md +71 -0
- package/skills/offensive/airecon-fork/tools-dalfox/SKILL.md +189 -0
- package/skills/offensive/airecon-fork/tools-hashcat-john/SKILL.md +258 -0
- package/skills/offensive/airecon-fork/tools-impacket/SKILL.md +227 -0
- package/skills/offensive/airecon-fork/tools-install/SKILL.md +202 -0
- package/skills/offensive/airecon-fork/tools-metasploit/SKILL.md +270 -0
- package/skills/offensive/airecon-fork/tools-nmap/SKILL.md +211 -0
- package/skills/offensive/airecon-fork/tools-nuclei/SKILL.md +175 -0
- package/skills/offensive/airecon-fork/tools-reporting/SKILL.md +47 -0
- package/skills/offensive/airecon-fork/tools-scripting/SKILL.md +1939 -0
- package/skills/offensive/airecon-fork/tools-semgrep/SKILL.md +202 -0
- package/skills/offensive/airecon-fork/tools-source-audit/SKILL.md +308 -0
- package/skills/offensive/airecon-fork/tools-sqlmap/SKILL.md +137 -0
- package/skills/offensive/airecon-fork/tools-tool-catalog/SKILL.md +320 -0
- package/skills/offensive/airecon-fork/tools-wapiti/SKILL.md +293 -0
- package/skills/offensive/airecon-fork/vulnerabilities-2fa-bypass/SKILL.md +219 -0
- package/skills/offensive/airecon-fork/vulnerabilities-account-takeover/SKILL.md +223 -0
- package/skills/offensive/airecon-fork/vulnerabilities-api-schema-exposure/SKILL.md +849 -0
- package/skills/offensive/airecon-fork/vulnerabilities-api-testing/SKILL.md +278 -0
- package/skills/offensive/airecon-fork/vulnerabilities-auth-workflow/SKILL.md +252 -0
- package/skills/offensive/airecon-fork/vulnerabilities-authentication-jwt/SKILL.md +158 -0
- package/skills/offensive/airecon-fork/vulnerabilities-bfla/SKILL.md +156 -0
- package/skills/offensive/airecon-fork/vulnerabilities-blind-xss/SKILL.md +111 -0
- package/skills/offensive/airecon-fork/vulnerabilities-business-logic/SKILL.md +313 -0
- package/skills/offensive/airecon-fork/vulnerabilities-cors/SKILL.md +242 -0
- package/skills/offensive/airecon-fork/vulnerabilities-crlf-injection/SKILL.md +146 -0
- package/skills/offensive/airecon-fork/vulnerabilities-csrf/SKILL.md +200 -0
- package/skills/offensive/airecon-fork/vulnerabilities-csrf-advanced-bypass/SKILL.md +536 -0
- package/skills/offensive/airecon-fork/vulnerabilities-deserialization/SKILL.md +363 -0
- package/skills/offensive/airecon-fork/vulnerabilities-dom-based-vulnerabilities/SKILL.md +105 -0
- package/skills/offensive/airecon-fork/vulnerabilities-exploitation/SKILL.md +286 -0
- package/skills/offensive/airecon-fork/vulnerabilities-grpc/SKILL.md +123 -0
- package/skills/offensive/airecon-fork/vulnerabilities-host-header-injection/SKILL.md +169 -0
- package/skills/offensive/airecon-fork/vulnerabilities-http-smuggling/SKILL.md +411 -0
- package/skills/offensive/airecon-fork/vulnerabilities-idor/SKILL.md +705 -0
- package/skills/offensive/airecon-fork/vulnerabilities-information-disclosure/SKILL.md +867 -0
- package/skills/offensive/airecon-fork/vulnerabilities-insecure-file-uploads/SKILL.md +190 -0
- package/skills/offensive/airecon-fork/vulnerabilities-jwt-attacks/SKILL.md +270 -0
- package/skills/offensive/airecon-fork/vulnerabilities-kubernetes/SKILL.md +252 -0
- package/skills/offensive/airecon-fork/vulnerabilities-mass-assignment/SKILL.md +788 -0
- package/skills/offensive/airecon-fork/vulnerabilities-nosql-injection/SKILL.md +204 -0
- package/skills/offensive/airecon-fork/vulnerabilities-oauth-misconfig/SKILL.md +220 -0
- package/skills/offensive/airecon-fork/vulnerabilities-oauth-saml/SKILL.md +163 -0
- package/skills/offensive/airecon-fork/vulnerabilities-open-redirect/SKILL.md +167 -0
- package/skills/offensive/airecon-fork/vulnerabilities-password-reset-poisoning/SKILL.md +66 -0
- package/skills/offensive/airecon-fork/vulnerabilities-path-traversal/SKILL.md +192 -0
- package/skills/offensive/airecon-fork/vulnerabilities-privilege-escalation/SKILL.md +320 -0
- package/skills/offensive/airecon-fork/vulnerabilities-prototype-pollution/SKILL.md +242 -0
- package/skills/offensive/airecon-fork/vulnerabilities-race-conditions/SKILL.md +192 -0
- package/skills/offensive/airecon-fork/vulnerabilities-rce/SKILL.md +240 -0
- package/skills/offensive/airecon-fork/vulnerabilities-sensitive-file-pii-exposure/SKILL.md +589 -0
- package/skills/offensive/airecon-fork/vulnerabilities-spring4shell/SKILL.md +86 -0
- package/skills/offensive/airecon-fork/vulnerabilities-sql-injection/SKILL.md +313 -0
- package/skills/offensive/airecon-fork/vulnerabilities-ssrf/SKILL.md +183 -0
- package/skills/offensive/airecon-fork/vulnerabilities-ssti/SKILL.md +344 -0
- package/skills/offensive/airecon-fork/vulnerabilities-subdomain-takeover/SKILL.md +160 -0
- package/skills/offensive/airecon-fork/vulnerabilities-supply-chain/SKILL.md +125 -0
- package/skills/offensive/airecon-fork/vulnerabilities-unhandled-exception-differential/SKILL.md +742 -0
- package/skills/offensive/airecon-fork/vulnerabilities-waf-detection/SKILL.md +90 -0
- package/skills/offensive/airecon-fork/vulnerabilities-web-cache-poisoning/SKILL.md +233 -0
- package/skills/offensive/airecon-fork/vulnerabilities-websocket/SKILL.md +180 -0
- package/skills/offensive/airecon-fork/vulnerabilities-xss/SKILL.md +316 -0
- package/skills/offensive/airecon-fork/vulnerabilities-xxe/SKILL.md +222 -0
- package/skills/offensive/matty-fork/cicd-redteam/SKILL.md +531 -0
- package/skills/offensive/matty-fork/cloud-security/SKILL.md +106 -0
- package/skills/offensive/matty-fork/container-escape/SKILL.md +174 -0
- package/skills/offensive/matty-fork/mobile-pentester/SKILL.md +357 -0
- package/skills/offensive/matty-fork/subdomain-takeover/SKILL.md +154 -0
- package/skills/osint/elementalsouls-fork/offensive-osint/README.md +92 -0
- package/skills/osint/elementalsouls-fork/offensive-osint/SKILL.md +4177 -0
- package/skills/osint/elementalsouls-fork/osint-methodology/README.md +66 -0
- package/skills/osint/elementalsouls-fork/osint-methodology/SKILL.md +1695 -0
|
@@ -0,0 +1,262 @@
|
|
|
1
|
+
---
|
|
2
|
+
license: MIT (snippet)
|
|
3
|
+
provider: Ruby on Rails + Devise (Open-Source)
|
|
4
|
+
last-checked: 2026-05-05
|
|
5
|
+
purpose: Devise + § 26 BDSG-konforme User-Verwaltung mit Audit-Trail.
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
# Rails + Devise — DSGVO-Pattern
|
|
9
|
+
|
|
10
|
+
## Trigger / Detection
|
|
11
|
+
|
|
12
|
+
Repo enthaelt:
|
|
13
|
+
- `gem 'devise'` in `Gemfile`
|
|
14
|
+
- `app/models/user.rb` mit `devise :database_authenticatable, ...`
|
|
15
|
+
- `config/initializers/devise.rb`
|
|
16
|
+
- Migration mit `:lockable, :trackable, :timeoutable` Feldern
|
|
17
|
+
- Optional: `gem 'pundit'` / `gem 'cancancan'` fuer Authorization
|
|
18
|
+
|
|
19
|
+
## Default-Verhalten (was passiert ohne Konfiguration)
|
|
20
|
+
|
|
21
|
+
- Devise loggt `last_sign_in_ip`, `current_sign_in_ip` als Klartext → Art. 5 lit. f Verstoss
|
|
22
|
+
- Default-Confirmable-Token-Lifetime ungesetzt → unbegrenzte Confirmation-Tokens
|
|
23
|
+
- Failed-Login-Errors leaken User-Existence ("Email not found")
|
|
24
|
+
- Default-Password-Length 6 Zeichen → zu schwach
|
|
25
|
+
- `:rememberable` ohne Expiration → Permanent-Sessions
|
|
26
|
+
|
|
27
|
+
## Compliance-Risiken
|
|
28
|
+
|
|
29
|
+
| Risiko | Norm | Severity | Fix |
|
|
30
|
+
|---|---|---|---|
|
|
31
|
+
| `last_sign_in_ip` Klartext | Art. 5 lit. f DSGVO | KRITISCH | Custom-Setter mit Hash |
|
|
32
|
+
| User-Enumeration via Devise-Errors | Art. 32 DSGVO | HOCH | `paranoid: true` setzen |
|
|
33
|
+
| Password-Length 6 | Art. 32 DSGVO | HOCH | `password_length: 12..128` |
|
|
34
|
+
| Remember-Me unbegrenzt | Art. 32 DSGVO | MITTEL | `remember_for: 14.days` |
|
|
35
|
+
| Audit-Log fuer Account-aenderungen fehlt | Art. 5 Abs. 2 | HOCH | `audited` Gem oder Custom |
|
|
36
|
+
| `current_password`-Check fuer kritische Aktionen | Art. 32 DSGVO | HOCH | `before_action :require_recent_auth` |
|
|
37
|
+
|
|
38
|
+
## Code-Pattern (sanitized)
|
|
39
|
+
|
|
40
|
+
```ruby
|
|
41
|
+
# File: config/initializers/devise.rb
|
|
42
|
+
Devise.setup do |config|
|
|
43
|
+
config.mailer_sender = '<placeholder-noreply-email>'
|
|
44
|
+
|
|
45
|
+
config.password_length = 12..128
|
|
46
|
+
|
|
47
|
+
# Bestaetigungs-Token: 7 Tage, danach abgelaufen
|
|
48
|
+
config.confirm_within = 7.days
|
|
49
|
+
|
|
50
|
+
# Lockable: 5 Versuche, 30 Minuten Lock
|
|
51
|
+
config.maximum_attempts = 5
|
|
52
|
+
config.unlock_in = 30.minutes
|
|
53
|
+
config.unlock_strategy = :time
|
|
54
|
+
|
|
55
|
+
# Timeoutable: Auto-Logout nach 60 min Inaktivitaet
|
|
56
|
+
config.timeout_in = 60.minutes
|
|
57
|
+
|
|
58
|
+
# Rememberable: max. 14 Tage
|
|
59
|
+
config.remember_for = 14.days
|
|
60
|
+
config.expire_all_remember_me_on_sign_out = true
|
|
61
|
+
|
|
62
|
+
# paranoid: kein User-Enumeration via Reset-Password-Form
|
|
63
|
+
config.paranoid = true
|
|
64
|
+
|
|
65
|
+
# Argon2 / bcrypt-Cost auf >= 12
|
|
66
|
+
config.stretches = Rails.env.test? ? 1 : 12
|
|
67
|
+
|
|
68
|
+
# Reset-Password-Token: 6 Stunden
|
|
69
|
+
config.reset_password_within = 6.hours
|
|
70
|
+
end
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
```ruby
|
|
74
|
+
# File: app/models/user.rb
|
|
75
|
+
class User < ApplicationRecord
|
|
76
|
+
devise :database_authenticatable, :registerable,
|
|
77
|
+
:recoverable, :rememberable, :validatable,
|
|
78
|
+
:confirmable, :lockable, :timeoutable, :trackable
|
|
79
|
+
|
|
80
|
+
has_many :user_audit_logs, dependent: :destroy
|
|
81
|
+
has_many :user_legal_acceptances, dependent: :destroy
|
|
82
|
+
|
|
83
|
+
validates :name, length: { maximum: 100 }, allow_blank: true
|
|
84
|
+
|
|
85
|
+
# Anonymisierungs-Felder ueberschreiben statt loeschen
|
|
86
|
+
def anonymize!
|
|
87
|
+
update!(
|
|
88
|
+
email: "deleted-#{id}@<placeholder-domain>",
|
|
89
|
+
name: 'GELOESCHT',
|
|
90
|
+
phone: nil,
|
|
91
|
+
last_sign_in_ip_hash: nil,
|
|
92
|
+
current_sign_in_ip_hash: nil,
|
|
93
|
+
sign_in_count: 0
|
|
94
|
+
)
|
|
95
|
+
end
|
|
96
|
+
|
|
97
|
+
# Hash IP statt Klartext (override Devise-Default)
|
|
98
|
+
def update_tracked_fields!(request)
|
|
99
|
+
super
|
|
100
|
+
self.current_sign_in_ip = nil # explicit nil
|
|
101
|
+
self.last_sign_in_ip = nil
|
|
102
|
+
self.current_sign_in_ip_hash = ip_hash(request.remote_ip)
|
|
103
|
+
save(validate: false)
|
|
104
|
+
end
|
|
105
|
+
|
|
106
|
+
private
|
|
107
|
+
|
|
108
|
+
def ip_hash(ip)
|
|
109
|
+
return nil if ip.blank?
|
|
110
|
+
salt = Rails.application.credentials.dig(:ip_hash_salt) || ''
|
|
111
|
+
Digest::SHA256.hexdigest(ip + salt)[0...16]
|
|
112
|
+
end
|
|
113
|
+
end
|
|
114
|
+
```
|
|
115
|
+
|
|
116
|
+
```ruby
|
|
117
|
+
# File: db/migrate/2026_05_05_add_dsgvo_fields_to_users.rb
|
|
118
|
+
class AddDsgvoFieldsToUsers < ActiveRecord::Migration[7.1]
|
|
119
|
+
def change
|
|
120
|
+
add_column :users, :current_sign_in_ip_hash, :string, limit: 16
|
|
121
|
+
add_column :users, :last_sign_in_ip_hash, :string, limit: 16
|
|
122
|
+
add_column :users, :anonymized_at, :datetime
|
|
123
|
+
add_index :users, :anonymized_at
|
|
124
|
+
|
|
125
|
+
# Loesche Klartext-IP-Felder (oder lasse sie als deprecated)
|
|
126
|
+
# remove_column :users, :current_sign_in_ip, :inet # vorsichtig!
|
|
127
|
+
end
|
|
128
|
+
end
|
|
129
|
+
```
|
|
130
|
+
|
|
131
|
+
```ruby
|
|
132
|
+
# File: app/models/user_audit_log.rb
|
|
133
|
+
class UserAuditLog < ApplicationRecord
|
|
134
|
+
belongs_to :user
|
|
135
|
+
|
|
136
|
+
validates :action, presence: true, inclusion: {
|
|
137
|
+
in: %w[
|
|
138
|
+
sign_in sign_out registration confirmation password_change
|
|
139
|
+
email_change profile_update consent_change account_deletion
|
|
140
|
+
]
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
before_destroy { raise 'Audit-Log ist append-only' }
|
|
144
|
+
|
|
145
|
+
def self.log!(user, action, ip:, user_agent:)
|
|
146
|
+
salt = Rails.application.credentials.dig(:ip_hash_salt) || ''
|
|
147
|
+
create!(
|
|
148
|
+
user: user,
|
|
149
|
+
action: action,
|
|
150
|
+
ip_hash: Digest::SHA256.hexdigest((ip || '') + salt)[0...16],
|
|
151
|
+
user_agent: (user_agent || '').first(200),
|
|
152
|
+
occurred_at: Time.current
|
|
153
|
+
)
|
|
154
|
+
end
|
|
155
|
+
end
|
|
156
|
+
```
|
|
157
|
+
|
|
158
|
+
```ruby
|
|
159
|
+
# File: app/controllers/users/sessions_controller.rb
|
|
160
|
+
class Users::SessionsController < Devise::SessionsController
|
|
161
|
+
def create
|
|
162
|
+
super do |user|
|
|
163
|
+
UserAuditLog.log!(user, 'sign_in', ip: request.remote_ip, user_agent: request.user_agent)
|
|
164
|
+
end
|
|
165
|
+
end
|
|
166
|
+
|
|
167
|
+
def destroy
|
|
168
|
+
user = current_user
|
|
169
|
+
super do
|
|
170
|
+
UserAuditLog.log!(user, 'sign_out', ip: request.remote_ip, user_agent: request.user_agent) if user
|
|
171
|
+
end
|
|
172
|
+
end
|
|
173
|
+
end
|
|
174
|
+
```
|
|
175
|
+
|
|
176
|
+
```ruby
|
|
177
|
+
# File: app/controllers/concerns/recent_auth_concern.rb
|
|
178
|
+
module RecentAuthConcern
|
|
179
|
+
extend ActiveSupport::Concern
|
|
180
|
+
|
|
181
|
+
RECENT_AUTH_WINDOW = 5.minutes
|
|
182
|
+
|
|
183
|
+
def require_recent_auth
|
|
184
|
+
return if recent_auth?
|
|
185
|
+
session[:return_to] = request.fullpath
|
|
186
|
+
redirect_to new_user_confirm_password_path,
|
|
187
|
+
alert: 'Bitte bestaetigen Sie Ihr Passwort erneut'
|
|
188
|
+
end
|
|
189
|
+
|
|
190
|
+
def recent_auth?
|
|
191
|
+
session[:recent_auth_at].present? &&
|
|
192
|
+
Time.zone.at(session[:recent_auth_at]) > RECENT_AUTH_WINDOW.ago
|
|
193
|
+
end
|
|
194
|
+
end
|
|
195
|
+
```
|
|
196
|
+
|
|
197
|
+
## AVV / DPA
|
|
198
|
+
|
|
199
|
+
- Datenbank (Postgres EU) — AVV mit IP-Hash-Garantie
|
|
200
|
+
- Mailer (SES EU / Postmark / Mailgun EU) — AVV
|
|
201
|
+
- Optional: SSO-Provider (Auth0 EU / Keycloak self-host) — AVV mit Drittland-TIA
|
|
202
|
+
|
|
203
|
+
## DSE-Wording-Vorlage
|
|
204
|
+
|
|
205
|
+
```markdown
|
|
206
|
+
### Account-Anlage und Anmeldung
|
|
207
|
+
|
|
208
|
+
Bei Registrierung und Anmeldung verarbeiten wir folgende Daten:
|
|
209
|
+
|
|
210
|
+
- E-Mail-Adresse (Pflichtfeld, zur Identifizierung)
|
|
211
|
+
- Name (optional)
|
|
212
|
+
- Passwort (gespeichert als bcrypt-Hash mit Cost-Faktor 12)
|
|
213
|
+
- Hash der IP-Adresse (zur Brute-Force-Erkennung; SHA-256 mit Salt, 16 Zeichen)
|
|
214
|
+
- Anzahl Anmeldungen
|
|
215
|
+
- Letzter Anmelde-Zeitpunkt
|
|
216
|
+
- User-Agent (max. 200 Zeichen)
|
|
217
|
+
|
|
218
|
+
**Audit-Log:** Wir protokollieren Anmeldungen, Passwort-aenderungen,
|
|
219
|
+
Profil-aenderungen und Account-Loeschungen mit anonymisierter IP zur
|
|
220
|
+
Sicherheits-Auswertung.
|
|
221
|
+
|
|
222
|
+
**Rechtsgrundlage:** Art. 6 Abs. 1 lit. b DSGVO (Vertrag) +
|
|
223
|
+
Art. 6 Abs. 1 lit. f DSGVO (Sicherheit).
|
|
224
|
+
**Speicherdauer:**
|
|
225
|
+
- Account: bis Loeschung (manuell oder via Inaktivitaets-Cleanup nach 2 Jahren)
|
|
226
|
+
- Audit-Log: 90 Tage
|
|
227
|
+
- Failed-Login-Counter: 30 Minuten (Lockout-Window)
|
|
228
|
+
```
|
|
229
|
+
|
|
230
|
+
## Verify-Commands (Live-Probe)
|
|
231
|
+
|
|
232
|
+
```bash
|
|
233
|
+
# 1. paranoid-Mode aktiv (kein User-Enumeration)
|
|
234
|
+
curl -X POST https://<placeholder-domain>/users/password \
|
|
235
|
+
-H "Content-Type: application/json" \
|
|
236
|
+
-d '{"user":{"email":"nonexistent@example.com"}}' -i
|
|
237
|
+
# Erwartung: 200 mit "If your email exists..." (statt "Email not found")
|
|
238
|
+
|
|
239
|
+
# 2. Account-Lockout nach 5 Versuchen
|
|
240
|
+
for i in {1..6}; do
|
|
241
|
+
curl -X POST https://<placeholder-domain>/users/sign_in \
|
|
242
|
+
-d 'user[email]=<placeholder-user-email>&user[password]=wrong' -s -o /dev/null -w "%{http_code}\n"
|
|
243
|
+
done
|
|
244
|
+
# Erwartung: letzter Code zeigt Account-Lockout
|
|
245
|
+
|
|
246
|
+
# 3. IP-Hash statt Klartext
|
|
247
|
+
# DB-Query: SELECT current_sign_in_ip_hash, current_sign_in_ip FROM users WHERE id = '<test>';
|
|
248
|
+
# Erwartung: ip_hash gefuellt, ip-Feld NULL/leer
|
|
249
|
+
|
|
250
|
+
# 4. Password-Length-Enforcement
|
|
251
|
+
curl -X POST https://<placeholder-domain>/users \
|
|
252
|
+
-d 'user[email]=test@test.com&user[password]=short' -i
|
|
253
|
+
# Erwartung: 422 mit "Password is too short (minimum is 12 characters)"
|
|
254
|
+
```
|
|
255
|
+
|
|
256
|
+
## Cross-References
|
|
257
|
+
|
|
258
|
+
- AEGIS-Scanner: `auth-flow-checker.ts`, `password-policy-checker.ts`, `audit-trail-checker.ts`
|
|
259
|
+
- Skill-Reference: `references/dsgvo.md` Art. 32 (Sicherheit), Art. 5 lit. f (Vertraulichkeit)
|
|
260
|
+
- BDSG: § 26 Abs. 8 (Beschaeftigtendaten — bei Mitarbeiter-Accounts)
|
|
261
|
+
- BGH-Rechtsprechung: `references/bgh-urteile.md`
|
|
262
|
+
- Audit-Pattern: `references/audit-patterns.md` Phase 9 (Auth-Audit)
|
|
@@ -0,0 +1,283 @@
|
|
|
1
|
+
---
|
|
2
|
+
license: MIT (snippet)
|
|
3
|
+
provider: Ruby on Rails + Sidekiq (Open-Source)
|
|
4
|
+
last-checked: 2026-05-05
|
|
5
|
+
purpose: Sidekiq-Worker-Pattern fuer asynchrone Anonymisierung + Hard-Delete-Cron.
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
# Rails — GDPR-Anonymisierungs-Worker (Sidekiq-Pattern)
|
|
9
|
+
|
|
10
|
+
## Trigger / Detection
|
|
11
|
+
|
|
12
|
+
Repo enthaelt:
|
|
13
|
+
- `gem 'sidekiq'` in `Gemfile`
|
|
14
|
+
- `app/workers/` oder `app/jobs/` Verzeichnis
|
|
15
|
+
- `Sidekiq::Worker` / `ActiveJob::Base` Subclasses
|
|
16
|
+
- Optional: `gem 'sidekiq-cron'` / `gem 'whenever'` fuer Cron-Scheduling
|
|
17
|
+
|
|
18
|
+
## Default-Verhalten (was passiert ohne Konfiguration)
|
|
19
|
+
|
|
20
|
+
- Account-Loeschung erfolgt synchron im Request → Timeout-Risiko
|
|
21
|
+
- Anonymisierung uebersieht abhaengige Records (Activity, Comments, Uploads)
|
|
22
|
+
- Search-Index (Elasticsearch / Algolia) wird nicht synchron mit DB-Loeschung geupdatet
|
|
23
|
+
- Soft-Deletes haeufen sich → Storage-Kosten + DSGVO-Drift
|
|
24
|
+
- Sidekiq-Logs enthalten Klartext-PII bei Job-Args
|
|
25
|
+
|
|
26
|
+
## Compliance-Risiken
|
|
27
|
+
|
|
28
|
+
| Risiko | Norm | Severity | Fix |
|
|
29
|
+
|---|---|---|---|
|
|
30
|
+
| Search-Index nicht ge-updated | Art. 17 DSGVO | KRITISCH | Worker triggert `unsearchable!` |
|
|
31
|
+
| Sidekiq-Args mit User-PII (Email/Name) | Art. 5 lit. c | HOCH | Nur User-ID als Arg, Lookup im Worker |
|
|
32
|
+
| Hard-Delete-Cron fehlt | Art. 5 lit. e | KRITISCH | `sidekiq-cron` mit taeglicher Schedule |
|
|
33
|
+
| Job-Failure unbemerkt | Art. 5 Abs. 2 | HOCH | Sidekiq-Web + Alert-Hook |
|
|
34
|
+
| Backup-Files nicht rotated | Art. 5 lit. e | HOCH | Backup-Provider-Policy + Doku |
|
|
35
|
+
|
|
36
|
+
## Code-Pattern (sanitized)
|
|
37
|
+
|
|
38
|
+
```ruby
|
|
39
|
+
# File: app/workers/gdpr/anonymize_user_worker.rb
|
|
40
|
+
module Gdpr
|
|
41
|
+
class AnonymizeUserWorker
|
|
42
|
+
include Sidekiq::Worker
|
|
43
|
+
|
|
44
|
+
sidekiq_options queue: 'gdpr', retry: 3, backtrace: true
|
|
45
|
+
|
|
46
|
+
def perform(user_id, reason = nil)
|
|
47
|
+
user = User.with_deleted.find_by(id: user_id)
|
|
48
|
+
return unless user
|
|
49
|
+
|
|
50
|
+
ActiveRecord::Base.transaction do
|
|
51
|
+
# 1. PII anonymisieren
|
|
52
|
+
user.anonymize!
|
|
53
|
+
|
|
54
|
+
# 2. Audit-Log
|
|
55
|
+
UserAuditLog.create!(
|
|
56
|
+
user: user,
|
|
57
|
+
action: 'account_deletion',
|
|
58
|
+
ip_hash: nil,
|
|
59
|
+
user_agent: 'GDPR-Worker',
|
|
60
|
+
occurred_at: Time.current,
|
|
61
|
+
metadata: { reason: reason }.to_json
|
|
62
|
+
)
|
|
63
|
+
|
|
64
|
+
# 3. Search-Index entfernen
|
|
65
|
+
user.unsearchable! if user.respond_to?(:unsearchable!)
|
|
66
|
+
|
|
67
|
+
# 4. Cascade-Anonymisierung auf abhaengige Records
|
|
68
|
+
user.comments.update_all(author_name: 'GELOESCHT')
|
|
69
|
+
user.uploads.find_each(&:purge)
|
|
70
|
+
|
|
71
|
+
# 5. Soft-Delete setzen (falls noch nicht)
|
|
72
|
+
user.update!(deleted_at: Time.current) unless user.deleted_at
|
|
73
|
+
|
|
74
|
+
# 6. Hard-Delete via separatem Cron in 30 Tagen
|
|
75
|
+
end
|
|
76
|
+
|
|
77
|
+
Rails.logger.info "[GDPR] User #{user_id} anonymized"
|
|
78
|
+
rescue => e
|
|
79
|
+
Rails.logger.error "[GDPR] Anonymization failed for #{user_id}: #{e.message}"
|
|
80
|
+
raise # Sidekiq retry
|
|
81
|
+
end
|
|
82
|
+
end
|
|
83
|
+
end
|
|
84
|
+
```
|
|
85
|
+
|
|
86
|
+
```ruby
|
|
87
|
+
# File: app/workers/gdpr/hard_delete_worker.rb
|
|
88
|
+
module Gdpr
|
|
89
|
+
class HardDeleteWorker
|
|
90
|
+
include Sidekiq::Worker
|
|
91
|
+
|
|
92
|
+
sidekiq_options queue: 'gdpr', retry: 3
|
|
93
|
+
|
|
94
|
+
HARD_DELETE_GRACE_PERIOD = 30.days
|
|
95
|
+
|
|
96
|
+
def perform
|
|
97
|
+
cutoff = HARD_DELETE_GRACE_PERIOD.ago
|
|
98
|
+
|
|
99
|
+
User.with_deleted.where('deleted_at < ?', cutoff).find_each do |user|
|
|
100
|
+
ActiveRecord::Base.transaction do
|
|
101
|
+
# Cascade-Loeschung
|
|
102
|
+
user.user_audit_logs.delete_all # Audit-Log raus
|
|
103
|
+
user.comments.delete_all
|
|
104
|
+
user.uploads.find_each(&:destroy!)
|
|
105
|
+
user.user_legal_acceptances.delete_all
|
|
106
|
+
|
|
107
|
+
# Hard-Delete
|
|
108
|
+
user.really_destroy! # paranoia-gem
|
|
109
|
+
end
|
|
110
|
+
|
|
111
|
+
Rails.logger.info "[GDPR] User #{user.id} hard-deleted"
|
|
112
|
+
end
|
|
113
|
+
|
|
114
|
+
# Cron-Run-Tracking
|
|
115
|
+
CronRun.create!(
|
|
116
|
+
job_name: 'gdpr-hard-delete',
|
|
117
|
+
finished_at: Time.current,
|
|
118
|
+
status: 'success'
|
|
119
|
+
)
|
|
120
|
+
rescue => e
|
|
121
|
+
CronRun.create!(
|
|
122
|
+
job_name: 'gdpr-hard-delete',
|
|
123
|
+
finished_at: Time.current,
|
|
124
|
+
status: 'failed',
|
|
125
|
+
error: e.message
|
|
126
|
+
)
|
|
127
|
+
raise
|
|
128
|
+
end
|
|
129
|
+
end
|
|
130
|
+
end
|
|
131
|
+
```
|
|
132
|
+
|
|
133
|
+
```ruby
|
|
134
|
+
# File: app/workers/gdpr/inactive_user_cleanup_worker.rb
|
|
135
|
+
module Gdpr
|
|
136
|
+
class InactiveUserCleanupWorker
|
|
137
|
+
include Sidekiq::Worker
|
|
138
|
+
|
|
139
|
+
sidekiq_options queue: 'gdpr', retry: 3
|
|
140
|
+
|
|
141
|
+
INACTIVITY_PERIOD = 2.years
|
|
142
|
+
|
|
143
|
+
def perform
|
|
144
|
+
cutoff = INACTIVITY_PERIOD.ago
|
|
145
|
+
|
|
146
|
+
User.where('current_sign_in_at < ? AND deleted_at IS NULL', cutoff)
|
|
147
|
+
.where(consent_inactivity_warning_sent_at: nil)
|
|
148
|
+
.find_each(batch_size: 100) do |user|
|
|
149
|
+
# Erste Stufe: Warning-Mail
|
|
150
|
+
UserMailer.inactivity_warning(user).deliver_later
|
|
151
|
+
user.update!(consent_inactivity_warning_sent_at: Time.current)
|
|
152
|
+
end
|
|
153
|
+
|
|
154
|
+
# Zweite Stufe: User die bereits gewarnt + 30 Tage spaeter immer noch inaktiv
|
|
155
|
+
User.where('consent_inactivity_warning_sent_at < ?', 30.days.ago)
|
|
156
|
+
.where('current_sign_in_at < ?', cutoff)
|
|
157
|
+
.where(deleted_at: nil)
|
|
158
|
+
.find_each do |user|
|
|
159
|
+
Gdpr::AnonymizeUserWorker.perform_async(user.id, 'inactivity_2_years')
|
|
160
|
+
user.update!(deleted_at: Time.current)
|
|
161
|
+
end
|
|
162
|
+
end
|
|
163
|
+
end
|
|
164
|
+
end
|
|
165
|
+
```
|
|
166
|
+
|
|
167
|
+
```ruby
|
|
168
|
+
# File: config/sidekiq_cron.yml
|
|
169
|
+
gdpr_hard_delete:
|
|
170
|
+
cron: '0 3 * * *' # Taeglich 3 Uhr UTC
|
|
171
|
+
class: 'Gdpr::HardDeleteWorker'
|
|
172
|
+
|
|
173
|
+
gdpr_inactive_cleanup:
|
|
174
|
+
cron: '0 4 * * 0' # Sonntag 4 Uhr UTC
|
|
175
|
+
class: 'Gdpr::InactiveUserCleanupWorker'
|
|
176
|
+
|
|
177
|
+
analytics_events_cleanup:
|
|
178
|
+
cron: '0 5 * * *'
|
|
179
|
+
class: 'AnalyticsEventCleanupWorker'
|
|
180
|
+
```
|
|
181
|
+
|
|
182
|
+
```ruby
|
|
183
|
+
# File: config/initializers/sidekiq.rb
|
|
184
|
+
Sidekiq.configure_server do |config|
|
|
185
|
+
config.redis = { url: ENV.fetch('REDIS_URL') }
|
|
186
|
+
|
|
187
|
+
# Sidekiq-Cron-Schedule laden
|
|
188
|
+
if File.exist?(Rails.root.join('config/sidekiq_cron.yml'))
|
|
189
|
+
schedule = YAML.load_file(Rails.root.join('config/sidekiq_cron.yml'))
|
|
190
|
+
Sidekiq::Cron::Job.load_from_hash(schedule)
|
|
191
|
+
end
|
|
192
|
+
|
|
193
|
+
# Args-Filtering: PII niemals in Logs
|
|
194
|
+
config.logger.formatter = lambda do |severity, time, prog, msg|
|
|
195
|
+
# Strip Email-Patterns
|
|
196
|
+
safe_msg = msg.to_s.gsub(/[\w.+-]+@[\w-]+\.[\w-]+/, '[EMAIL_REDACTED]')
|
|
197
|
+
"#{time.iso8601} [#{severity}] #{safe_msg}\n"
|
|
198
|
+
end
|
|
199
|
+
end
|
|
200
|
+
```
|
|
201
|
+
|
|
202
|
+
```ruby
|
|
203
|
+
# File: app/controllers/gdpr_controller.rb
|
|
204
|
+
class GdprController < ApplicationController
|
|
205
|
+
before_action :authenticate_user!
|
|
206
|
+
|
|
207
|
+
def destroy_account
|
|
208
|
+
reason = params[:reason]&.first(500)
|
|
209
|
+
|
|
210
|
+
# Synchron: nur Soft-Delete + Logout
|
|
211
|
+
current_user.update!(deleted_at: Time.current, deletion_reason: reason)
|
|
212
|
+
|
|
213
|
+
# Async: Anonymisierung
|
|
214
|
+
Gdpr::AnonymizeUserWorker.perform_async(current_user.id, reason)
|
|
215
|
+
|
|
216
|
+
sign_out current_user
|
|
217
|
+
render json: {
|
|
218
|
+
status: 'PENDING_HARD_DELETE',
|
|
219
|
+
soft_deleted_at: Time.current.iso8601,
|
|
220
|
+
hard_delete_scheduled: '30 Tage'
|
|
221
|
+
}, status: :accepted
|
|
222
|
+
end
|
|
223
|
+
end
|
|
224
|
+
```
|
|
225
|
+
|
|
226
|
+
## AVV / DPA
|
|
227
|
+
|
|
228
|
+
- Datenbank — AVV mit Hard-Delete-Wirksamkeit
|
|
229
|
+
- Sidekiq-Redis (Upstash EU / Redis Cloud EU) — AVV
|
|
230
|
+
- Search-Index (Algolia / Meilisearch) — AVV + Index-Sync-Garantie
|
|
231
|
+
- Mailer fuer Warning-Mails — AVV
|
|
232
|
+
|
|
233
|
+
## DSE-Wording-Vorlage
|
|
234
|
+
|
|
235
|
+
```markdown
|
|
236
|
+
### Loesch-Workflow und Inaktivitaets-Cleanup
|
|
237
|
+
|
|
238
|
+
**Bei Loesch-Antrag (manuell):**
|
|
239
|
+
|
|
240
|
+
1. Sofort: Account deaktiviert, ausgeloggt
|
|
241
|
+
2. Sofort (asynchron): PII anonymisiert, Search-Index entfernt, Comments
|
|
242
|
+
anonymisiert, Uploads geloescht
|
|
243
|
+
3. Nach 30 Tagen: Endgueltige Loeschung aus Datenbank
|
|
244
|
+
|
|
245
|
+
**Bei Inaktivitaet (automatisch):**
|
|
246
|
+
|
|
247
|
+
1. Nach 2 Jahren ohne Login: Erinnerungs-Mail
|
|
248
|
+
2. 30 Tage nach Erinnerungs-Mail (immer noch keine Aktivitaet):
|
|
249
|
+
automatischer Loesch-Workflow
|
|
250
|
+
3. Hard-Delete folgt nach weiteren 30 Tagen
|
|
251
|
+
|
|
252
|
+
**Rechtsgrundlage:** Art. 5 lit. e DSGVO (Speicherbegrenzung), Art. 17 DSGVO
|
|
253
|
+
(Recht auf Loeschung).
|
|
254
|
+
```
|
|
255
|
+
|
|
256
|
+
## Verify-Commands (Live-Probe)
|
|
257
|
+
|
|
258
|
+
```bash
|
|
259
|
+
# 1. Sidekiq-Web-Health
|
|
260
|
+
curl https://<placeholder-domain>/sidekiq/cron
|
|
261
|
+
# Erwartung: aktivitaet aller Cron-Jobs sichtbar
|
|
262
|
+
|
|
263
|
+
# 2. Anonymize-Worker manuell anstossen
|
|
264
|
+
bundle exec rails console
|
|
265
|
+
# > Gdpr::AnonymizeUserWorker.perform_async(<test-user-id>, 'test')
|
|
266
|
+
# > Sidekiq::Queue.new('gdpr').size # Erwartung: 1, dann 0 nach Verarbeitung
|
|
267
|
+
|
|
268
|
+
# 3. Job-Logs ohne PII
|
|
269
|
+
tail -100 log/sidekiq.log | grep -E '[\w.+-]+@[\w-]+\.[\w-]+' | head -5
|
|
270
|
+
# Erwartung: 0 Treffer oder ausschliesslich [EMAIL_REDACTED]
|
|
271
|
+
|
|
272
|
+
# 4. Hard-Delete nach 30 Tagen wirksam
|
|
273
|
+
# DB-Query: SELECT COUNT(*) FROM users WHERE deleted_at < now() - interval '30 days';
|
|
274
|
+
# Erwartung: 0
|
|
275
|
+
```
|
|
276
|
+
|
|
277
|
+
## Cross-References
|
|
278
|
+
|
|
279
|
+
- AEGIS-Scanner: `data-retention-checker.ts`, `cron-coverage-checker.ts`, `pii-anonymization-checker.ts`
|
|
280
|
+
- Skill-Reference: `references/dsgvo.md` Art. 17, Art. 5 lit. e
|
|
281
|
+
- BGH-Rechtsprechung: `references/bgh-urteile.md`
|
|
282
|
+
- EuGH: `references/eu-eugh-dsgvo-schadensersatz.md` (Loesch-Anspruch)
|
|
283
|
+
- Audit-Pattern: `references/audit-patterns.md` Phase 4 (DSE-Drift / Cron-Coverage)
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
---
|
|
2
|
+
license: MIT (snippet)
|
|
3
|
+
provider: React (Open-Source)
|
|
4
|
+
last-checked: 2026-05-02
|
|
5
|
+
purpose: React useConsent Hook fuer ConsentGate-Pattern.
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
# React — useConsent Hook + ConsentGate (Pattern)
|
|
9
|
+
|
|
10
|
+
## 1. Use-Case
|
|
11
|
+
|
|
12
|
+
Tracker / Embeds / Drittanbieter sollen NUR nach User-Consent geladen werden.
|
|
13
|
+
|
|
14
|
+
## 2. Code-Pattern
|
|
15
|
+
|
|
16
|
+
```tsx
|
|
17
|
+
// File: src/lib/consent.ts
|
|
18
|
+
import { useState, useEffect } from 'react';
|
|
19
|
+
|
|
20
|
+
type ConsentCategory = 'necessary' | 'analytics' | 'marketing';
|
|
21
|
+
|
|
22
|
+
type ConsentState = Record<ConsentCategory, boolean>;
|
|
23
|
+
|
|
24
|
+
const STORAGE_KEY = 'cookie-consent';
|
|
25
|
+
|
|
26
|
+
export function useConsent() {
|
|
27
|
+
const [consent, setConsent] = useState<ConsentState>({
|
|
28
|
+
necessary: true,
|
|
29
|
+
analytics: false,
|
|
30
|
+
marketing: false,
|
|
31
|
+
});
|
|
32
|
+
|
|
33
|
+
useEffect(() => {
|
|
34
|
+
const stored = localStorage.getItem(STORAGE_KEY);
|
|
35
|
+
if (stored) {
|
|
36
|
+
setConsent(JSON.parse(stored));
|
|
37
|
+
}
|
|
38
|
+
// Listen fuer Consent-Aenderungen
|
|
39
|
+
const handler = () => {
|
|
40
|
+
const updated = localStorage.getItem(STORAGE_KEY);
|
|
41
|
+
if (updated) setConsent(JSON.parse(updated));
|
|
42
|
+
};
|
|
43
|
+
window.addEventListener('storage', handler);
|
|
44
|
+
return () => window.removeEventListener('storage', handler);
|
|
45
|
+
}, []);
|
|
46
|
+
|
|
47
|
+
const hasConsented = (category: ConsentCategory) => consent[category];
|
|
48
|
+
|
|
49
|
+
return { consent, hasConsented };
|
|
50
|
+
}
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
```tsx
|
|
54
|
+
// File: src/components/ConsentGate.tsx
|
|
55
|
+
'use client';
|
|
56
|
+
|
|
57
|
+
import { ReactNode } from 'react';
|
|
58
|
+
import { useConsent } from '@/lib/consent';
|
|
59
|
+
|
|
60
|
+
type Props = {
|
|
61
|
+
category: 'analytics' | 'marketing';
|
|
62
|
+
children: ReactNode;
|
|
63
|
+
fallback?: ReactNode;
|
|
64
|
+
};
|
|
65
|
+
|
|
66
|
+
export default function ConsentGate({ category, children, fallback }: Props) {
|
|
67
|
+
const { hasConsented } = useConsent();
|
|
68
|
+
|
|
69
|
+
if (!hasConsented(category)) {
|
|
70
|
+
return fallback ? <>{fallback}</> : null;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
return <>{children}</>;
|
|
74
|
+
}
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
```tsx
|
|
78
|
+
// Verwendung: YouTube-Embed nur nach Consent
|
|
79
|
+
import ConsentGate from '@/components/ConsentGate';
|
|
80
|
+
|
|
81
|
+
<ConsentGate category="marketing" fallback={
|
|
82
|
+
<div className="consent-fallback">
|
|
83
|
+
<p>YouTube-Video benoetigt Ihre Einwilligung.</p>
|
|
84
|
+
<button onClick={() => /* Banner re-open */}>Cookies aendern</button>
|
|
85
|
+
</div>
|
|
86
|
+
}>
|
|
87
|
+
<iframe src="https://www.youtube-nocookie.com/embed/..." />
|
|
88
|
+
</ConsentGate>
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
## 3. Az.-Anker
|
|
92
|
+
|
|
93
|
+
- EuGH C-40/17 Fashion-ID (Mit-Verantwortlichkeit)
|
|
94
|
+
- LG Muenchen I 3 O 17493/20 (Google Fonts ohne Consent)
|
|
95
|
+
|
|
96
|
+
## 4. Cross-Reference
|
|
97
|
+
|
|
98
|
+
- Cookie-Banner: `cookie-banner-pattern.md`
|
|
99
|
+
- Audit-Pattern Phase 5: `audit-patterns.md`
|