frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

Open in hackernews

Show HN: TheProtector – Linux Bash script for the paranoid admin on a budget

https://github.com/IHATEGIVINGAUSERNAME/theProtector
76•lotussmellsbad•8h ago
Hi HN,

I spent the past year building this in my spare time because I got tired of enterprise security tools that cost $50K/year and don't understand Linux.

TheProtector is a comprehensive security monitoring tool that actually runs on the systems we use (Linux) instead of being a Windows-first afterthought. Built it entirely on a $500 laptop because I believe good security shouldn't require unlimited budgets.

Features: - Real-time process, network, and file monitoring - YARA malware detection with custom rules - eBPF kernel monitoring (when available) - Behavioral baseline establishment and anomaly detection - Active threat response (blocks IPs, kills processes, quarantines files) - Anti-evasion detection for rootkits and advanced threats - Honeypots for attack detection - Web dashboard for monitoring - Single bash script, no complex installation

The tagline is "not perfect but better than most" because I'm tired of security vendors claiming their tools are flawless. This actually works, costs $0, and you can read every line of code.

I know bash isn't the sexy choice for security tools, but it runs everywhere, has zero dependencies, and most Linux admins can read/modify it. Sometimes boring technology that works is better than fancy technology that doesn't.

It's designed for the intersection of "paranoid about security" and "don't have enterprise budgets" - which describes most of us actually running Linux systems.

GitHub: https://github.com/IHATEGIVINGAUSERNAME/theProtector

Been running it on my own systems for months. Catches the stuff that matters and doesn't flood you with false positives. If you hate expensive security theater as much as I do, might be worth a look.

Open to feedback, especially from folks who know more about this stuff than I do.

Thanks, IHATEGIVINGAUSERNAME (yes, I really do hate giving usernames)

Comments

BLKNSLVR•4h ago
I will check this out, I love the idea.
vanviegen•4h ago
Congratulations on your release! That packs a lot of functionality in a surprisingly small and readable (and thus auditable) shell script. Great work!

One thing though: I can imagine you being rather anonymous (no real name, new HN account, new GitHub account) might make people a bit nervous around a security tool. You probably have good reasons for that, but if not.. you might want to reconsider and take credit?

_QrE•4h ago
Neat, but isn't packing all this stuff into a bash script overkill? You can pretty easily install and configure some good tools (i.e. crowdsec, rkhunter, ssh tarpit or whatever) to cover each of the categories rather than have a bunch of half-measures.

Also, you're calling this TheProtector, but internally it seems to be called ghost sentinel?

> local update_url="https://raw[dot]githubusercontent[dot]com/your-repo/ghost-se..."

FergusArgyll•4h ago
I would probably delete the self_update function[0] if I were to use this, otherwise this is cool!

https://github.com/IHATEGIVINGAUSERNAME/theProtector/blob/ma...

monch1962•4h ago
I love this implementation approach.

At first glance I questioned your choice of bash over something like Python, but you're right - bash is everywhere and every competent Linux admin knows how to use it. There's a zillion unprotected Linux servers out there where this would be very handy.

In terms of next steps, it might be worth documenting more about the notification framework and some simple examples of how we might use it. I can see you've mentioned integrations with email, Slack and webhooks in the tech paper, but I can't spot anything about how to use them

Congratulations on a really worthy project

rfkjrjr•3h ago
"Built by thelotus over a year of free time. Maintained by thelotus. Given away free because expensive security theater is stupid." Who / what is the lotus?
lotussmellsbad•2h ago
I hate the idea of hats - I like the idea of the Lotus growing in something dirty but uses the filth in ponds to make something beautiful
xalg•3h ago
I really like the simplicity. I have added it to a test server and will see how it goes. Congrats on releasing your project.
lotussmellsbad•3h ago
Thanks for all the comments and feedback - the one I run is plugged - has a brain - and can hook - Ill update in a few days with some of the features - if curious and I run a handle name because it would not take much to be more
globalnode•2h ago
This is great. I'm currently trying to use Linux more due to Recall but in terms of security I'm just not sure what I'm doing most of the time. I suppose I should go read a book about it. Any suggestions on that front? Anyway, a tool like this (if trustworthy) would go a long way to helping me in this area. Also I do like that its in bash and not compiled.
_def•2h ago
Was this made with LLMs?
webprofusion•1h ago
Would love to see the prompts used. I can tell from the formatting etc this is AI built, nothing wrong with that.
indigodaddy•1h ago
Really cool and interesting, good work.
panphora•46m ago
As someone who runs production services but isn't a full-time sysadmin, I evaluated this script before thinking about deploying it.

Here's what you should know:

The Good: It's a comprehensive monitoring solution that actually catches real threats. The YARA integration, eBPF monitoring, and honeypot features are impressive for a bash script.

Security Issues:

1. Command injection in process monitoring - Initially looked like a vulnerability because the code uses xargs basename on process names, which seemed dangerous. However, process names from ps output are already sanitized by the kernel (limited to 15 chars, no shell metacharacters executed).

2. Executing Python scripts from /tmp as root - Real privilege escalation vulnerability. Ghost Sentinel writes to world-writable /tmp then executes as root. Any local user can overwrite the file between write and execute to gain root. Trivial to exploit with inotify or loop, 100% reliable. Turns any compromised service account into root access. Fix: use root-owned directory instead of /tmp.

Email Configuration - Gmail will block direct server emails. Install msmtp and configure it with your Gmail app password (not regular password) to get theProtector to use msmtp's mail command:

  # Install
  sudo apt-get install msmtp msmtp-mta
  
  # Configure ~/.msmtprc (for root since script runs as root)
  sudo tee /root/.msmtprc << 'EOF'
  defaults
  auth           on
  tls            on
  tls_trust_file /etc/ssl/certs/ca-certificates.crt
  account        gmail
  host           smtp.gmail.com
  port           587
  from           your-email@gmail.com
  user           your-email@gmail.com
  password       your-app-password
  account default : gmail
  EOF
  
  sudo chmod 600 /root/.msmtprc
Uninstall TheProtector:

  # Remove cron job
  crontab -l | grep -v ghost_sentinel | crontab -
  
  # Remove systemd timer (if installed)
  sudo systemctl disable ghost-sentinel.timer 2>/dev/null
  
  # Remove logs and data
  sudo rm -rf /var/log/ghost-sentinel
Auto-update concerns: The script does NOT auto-update. self_update() only runs when you explicitly execute ./the_protector.sh update

Performance note: On resource-constrained VPS instances, set ENABLE_EBPF=false and MAX_FIND_DEPTH=1

I'm deploying a patched version this week. The creator spent a year on this and it shows - the eBPF/YARA integration is impressive. They should set up GitHub Sponsors or a donation link. It's better than many commercial solutions I've seen.

bravesoul2•11m ago
Thanks from the community for your insights
bugsMarathon88•6m ago
This cannot conscientiously be called a security tool, as it lacks:

- author attribution (in fact, a mockery is made of it)

- qualified independent security review and endorsement

- designs justifying irrational decisions such as unilateral superuser execution

- any sort of testing, validation or significant documentation of code functionality

- steps to undo whatever this does (since anything is possible, as all liability is explicitely disavowed)

This is not meant to discourage development, but such software should have a clear an EXPERIMENTAL disclaimer and not purport to secure anything; primum non nocere.

Notes on Rewriting JSX as Astro

https://carlosn.com.br/blog/post/notes-on-rewriting-jsx-as-astro/
1•carlosneves•3m ago•0 comments

Addressing Privacy Fatigue

https://www.fastmail.com/blog/addressing-privacy-fatigue/
1•billybuckwheat•4m ago•0 comments

Troubled SPAC to buy iRocket for $400M but it returned most of its cash

https://techcrunch.com/2025/07/23/a-troubled-spac-plans-to-buy-irocket-for-400m-but-it-already-returned-most-of-its-cash/
1•pseudolus•4m ago•0 comments

Vibe coding turned this Swedish AI unicorn into the fastest growing startup ever

https://www.forbes.com/sites/iainmartin/2025/07/23/vibe-coding-turned-this-swedish-ai-unicorn-into-the-fastest-growing-software-startup-ever/
1•myth_drannon•16m ago•0 comments

I Eat

https://taylor.town/how-i-eat
3•paulpauper•16m ago•0 comments

Show HN: Voice-First AI Code Review Platform (Looking for OSS Beta testers)

https://www.lightlayer.dev/
1•changisaac•24m ago•0 comments

Ask HN: Has anyone deployed LLMs to production?

1•saaspirant•26m ago•0 comments

Surprising Science: How Electric Cars Transform Urban Air

https://modernengineeringmarvels.com/2025/07/22/surprising-science-how-electric-cars-quietly-transform-urban-air/
1•tzs•29m ago•0 comments

What is X-Forwarded-For and when can you trust it?

https://httptoolkit.com/blog/what-is-x-forwarded-for/
1•thunderbong•30m ago•0 comments

Spaghetti All'assassina

https://en.wikipedia.org/wiki/Spaghetti_all%27assassina
1•jameslk•31m ago•0 comments

Show HN: Marchat – Terminal-based chat app written in Go

https://github.com/Cod-e-Codes/marchat
2•Cod-e-Codes•31m ago•0 comments

Donald Trump Is Fairy-Godmothering AI

https://www.theatlantic.com/technology/archive/2025/07/donald-trump-ai-action-plan/683647/
4•CharlesW•35m ago•0 comments

Could you swap your mouse and keyboard for a smart bracelet?

https://www.scimex.org/newsfeed/could-you-swap-your-mouse-and-keyboard-for-a-smart-bracelet
1•geox•35m ago•0 comments

Anyone building P2P alternatives to capitalism?

https://github.com/contribution-protocol/contribution-protocol-project
1•mzk_pi•37m ago•1 comments

Ending 'woke AI' isn't enough: fight the 'monster' within it

https://nypost.com/2025/07/23/opinion/ending-woke-ai-isnt-enough-fight-the-monster-within-it/
2•kvee•41m ago•1 comments

Show HN: Synthetic Users that test your app, catch bugs, and provide feedback

https://synthetic.usejina.com/
1•fearlessboi•45m ago•1 comments

What's That Splatter on Your Windshield?

https://www.nytimes.com/interactive/2025/07/23/science/23xp-bugquiz.html
2•avalys•51m ago•1 comments

When photography was born, fascination, obsession, and danger followed

https://www.washingtonpost.com/books/2025/07/12/flashes-brilliance-history-early-photography-anika-burgess-review/
1•prismatic•51m ago•0 comments

Cluely Paying $1M Salaries

https://twitter.com/im_roy_lee/status/1948112169503207774
7•thisismytest•52m ago•0 comments

The Largest Ever Solar Storm Detected In 14,300-year-old Tree Rings (2023)

https://astrobiology.com/2023/10/the-largest-ever-solar-storm-detected-in-14300-year-old-tree-rings.html
2•georgecmu•55m ago•0 comments

Contextual.ai

https://contextual.ai/
1•handfuloflight•56m ago•0 comments

Guide to PDF security

https://www.unicornforms.com/blog/complete-guide-to-pdf-security
1•waldopat•58m ago•0 comments

A small web July

https://smallcypress.bearblog.dev/a-small-web-july/
30•debo_•1h ago•8 comments

Low cost mmWave 60GHz radar sensor for advanced sensing

https://www.infineon.com/part/BGT60TR13C
2•teleforce•1h ago•0 comments

Why Are We Pretending AI Is Going to Take All the Jobs?

https://www.thebignewsletter.com/p/why-are-we-pretending-ai-is-going
13•pseudolus•1h ago•0 comments

BYD Bets on Budget EV Boom with Atto 1 Debut in Indonesia

https://jakartaglobe.id/business/byd-bets-on-budget-ev-boom-with-atto-1-debut-in-indonesia
3•breve•1h ago•0 comments

Ask HN: Does an RSS-based Read-It-Later service exist?

2•fargoth•1h ago•1 comments

At Victoria Park Model Boat Club

https://spitalfieldslife.com/2025/07/21/at-victoria-park-model-boat-club-i/
2•zeristor•1h ago•0 comments

Don't Use External CSS

https://maurycyz.com/misc/inline_css/
2•LorenDB•1h ago•3 comments

Ask HN: WASM Profiling Icache vs. Dcache

1•dapperdrake•1h ago•0 comments