Zum Hauptinhalt springen
Echtzeit-Radar & Feeds
Alle RSS Feeds ➔
👥 Community & Social
•••••••
Sichere ProgrammierungVibe coding with GPT-6 Astra: what 35 unattended hours produced(28.09.2026 um 21:46 Uhr)
•
Sichere ProgrammierungI Gave AI Access to Blender. Here's What It Built(28.09.2026 um 21:49 Uhr)
•
AI & KI NachrichtenJev: The Frontier Model That Refuses to Write(28.09.2026 um 21:50 Uhr)
••••••••
Sichere ProgrammierungVibe coding with GPT-6 Astra: what 35 unattended hours produced(28.09.2026 um 21:46 Uhr)
•
Sichere ProgrammierungI Gave AI Access to Blender. Here's What It Built(28.09.2026 um 21:49 Uhr)
•
AI & KI NachrichtenJev: The Frontier Model That Refuses to Write(28.09.2026 um 21:50 Uhr)
•
Intelligence View
⚡ tsecurity.de Intelligence

Gitleaks Pre-Commit Hook

As a software engineer, sometimes when troubleshooting something I need to hardcode passwords locally to connect to DEV environments. Yeah, I could use environment variables and all that... but let's be honest - when you just want to…

0
↗ Quelle (dev.to)
Reagiere als Erste:r — dein Feedback zählt!

As a software engineer, sometimes when troubleshooting something I need to hardcode passwords locally to connect to DEV environments. Yeah, I could use environment variables and all that... but let's be honest - when you just want to quickly check something, hardcoding it is the fastest way. I know, I'm lazy.



Specifically, I was trying to verify that a password for connecting to Redis in DEV was correct. After adding it to the code and testing it, I had that sinking feeling about "what if I accidentally commit and push this?" That got me thinking - I really need to automate this check.



Initially I used TruffleHog and wrote a pre-commit hook script for it. But after chatting with a few colleagues, they suggested I have a look at Gitleaks instead. The key difference? TruffleHog tries to verify if secrets are actually valid, but that's not what I wanted. Even if something looks like a false positive, I want to be the one who decides that. Gitleaks just flags patterns and lets you deal with it - which is exactly the behavior I needed.



Now, Gitleaks does offer a pre-commit setup in their README, but that involves installing the pre-commit package manager and configuring it per repository. I work with over 100 repos. I need something simple that works globally across all of them, not something I have to set up individually for each project. Yes, I am still lazy..



So I wrote a script that does it all in one go.






What it does



Basically runs Gitleaks before every commit. If it finds something that looks like a secret (API keys, tokens, passwords, whatever), it blocks the commit. Simple.



Gitleaks catching a Slack token before it gets committed



One command to install:




curl -sSL https://raw.githubusercontent.com/AmedeoV/gitleaks-pre-commit-hook/refs/heads/main/gitleaks-local-git-pre-hook.sh | bash






Then it just works everywhere. All repos, automatically protected.






Why I like it



I don't have to think about it. That's the whole point. I code, I commit, if there's something sensitive in there, it stops me. Done.



It detects like 100+ different types of secrets out of the box. You can add custom rules too if you have specific patterns you want to catch.






One small annoyance



Sometimes it flags false positives. But you can bypass with --no-verify when you're sure it's safe. Haven't needed to do that often though.



Already saved me twice from pushing stuff I shouldn't. Feels good knowing it's there watching.




Link: github.com/AmedeoV/gitleaks-pre-commit-hook


2. Cyber Threat Intelligence & Forensik

🛡️
Exploit PoC Security Sandbox & Payload Analyzer TEXT
Danger Index:25/100 SAFE_ANALYSIS_ONLY
✅ Keine offensichtlich destruktiven Befehle erkannt.
Standard-Analystenprüfung vor Ausführung empfohlen.
Erkannte Gefahrensignaturen (1):
HIGHPAYLOAD_DROPPER:Download-and-Execute Dropper-Muster (Piped Shell-Execution).
curl -sSL https://raw.githubusercontent.
Ähnliche Beiträge
🔍 Verwandte News

Auch interessante Nachrichten Gitleaks Pre-Commit Hook

Thematisch verwandte Begriffe: Gitleaks, PreCommit, Hook · 6 Treffer

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

💬 Kommentare werden geladen…
Zum Aktualisieren ziehen
ZERO-DAY CVE-2026-54710 | FreePBX is an open source IP PBX. Prior to versions 16.0.40 and 17.0.7, …
Advisory →
tsecurity.de Icon
Offline-Lesen, Eilmeldungen & 0ms Ladezeit

Installiere tsecurity.de direkt auf deinen Home-Bildschirm für das ultimative Vollbild-Magazinerlebnis ohne Browser-Leisten.

Nächster Beitrag