DEV Community

Cover image for Stress Test My Digital Fortress: An eBPF + Shannon Entropy Guard (Open Sourced)
weilong
weilong

Posted on

Stress Test My Digital Fortress: An eBPF + Shannon Entropy Guard (Open Sourced)

I’ve built a "Digital Guillotine" in the Linux kernel, and I want you to help me break it.
​I have combined eBPF (XDP) with multidimensional Shannon Entropy analysis to create Realm 2.5—a security application that doesn't just block IPs; it judges the "chaos" of the traffic itself.
​🛠️ The Architecture: Intelligence at the Edge
​Unlike traditional firewalls, Realm operates at the XDP (Express Data Path) layer. It evaluates every payload before it even touches the socket buffer.
​Entropy Auditing: It calculates the randomness (H) of incoming data. If your payload is too "chaotic" (obfuscated or encrypted attack strings), the kernel executes an instant ban.
​L3 Honeypots: I’ve integrated traps on ports 2375, 2222, and 6379. One wrong move, and you are marked in the eBPF map.
​👁️ The Tactical Command Center (Live)
​You can visit the dashboard as a "Normal User" right now. You will see the Total Threat Archive—a real-time list of IPs that have already been "beheaded" by the system.
​🌐 Live Dashboard: http://35.212.157.202/
​🛠️ GitHub Repository: xingkong0508/realm
​⚔️ The Challenge: Give Me Pressure
​If you attempt to breach my "Realm," your IP will be added to the Blacklist immediately.
​The Sentence: Bans are enforced at the kernel level.
​The Mercy: I’ve set an auto-unban timer of 10 minutes. After 600 seconds, the eBPF map will clear your entry, and you can try again.
​I am asking for your help. Give my server some pressure. Let’s see if my entropy logic holds up against professional-grade obfuscation.
​🚀 The Future: Lowering the Shield for All
​This project is already Open Source. However, I plan to lower the "entry bar" for this framework soon. I want to refine the code so that any developer—not just kernel experts—can deploy these advanced shields with a single command.
​Let’s complete this masterpiece together. Do your worst, and let the logs tell the story.

Top comments (0)