GT-AC5300 - Need Bash Script to run at Boot


Occasional Visitor
I have a bash script that is designed to prevent connections inbound FROM the Internet from getting through (inbound) my Asus GT-5300.
I am trying to prevent my email server (SMTP Port 25) from (abusive inbound from the Internet) connections.
Script is designed to just "drop" inbound packets from a specific IP and/or subnet address.
I'd like to run this bash script (as root?) at boot time - or just after boot time after Asus GT-5300 is fully running.

Which directory should I put the script?
What command should I run (as root?) to get the script run?
I suppose crontab -e method might be an option as well...

(short example from script)

iptables -I FORWARD -s -j DROP
iptables -I FORWARD -s -j DROP
iptables -I FORWARD -s -j DROP



Part of the Furniture
1) Why have you prefixed this as News? It's not a news article.
2) That's not a bash script, it's just a script. The router doesn't support bash.
3) To make persist changes to the router's firewall you'd have to use a third party firmware. Stock Asus firmware doesn't support custom firewall scripts.
4) Given 3) it's probably better/easier to drop the connections on the email server.
Last edited:


Occasional Visitor
Thanks. I'll buy another Asus that does support Merlin. I know how to do what I want using the Merlin SW.

Similar threads

Latest threads

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!