› Forums › Network Management › ZeroShell › script for enabling and disabling gateway at a specific time › Reply To: script for enabling and disabling gateway at a specific time
Use the firewall rules to enable a time-based rule in the FORWARD chain.
Note that if you are using the CaptivePortal feature you should use DROP rules. So you should DROP the traffic in the hours when the traffic is not allowed, NOT the contrary!!
This is because there is an invisibile last rule called CapPor that send everything trough the captive portal, but if you ALLOW something before the users don’t pass trough captiveportal since rules are hierarchical (first matched -> exit).