Captive Portal - Enable / Disable by Schedule or Cron

  • Hi!

    Can I Disable or Enable my captive portal by schedules or cron ?

    I need all time by captive portal, authenticated by vounchers, except 12:00 13:00 captive portal disabled.

    My captive portal is working, but i need disable/enable midday.

    Any ideas?


  • When you disable the portal, all traffic passes through.
    You want to implement some happy hours ?
    And what to do with the existing connections ?

  • you can create a script with

    ipfw add 10 allow ip from any to any keep-state

    and anotheer script with

    ipfw delete 10

    and use cron to launch it at specified time

  • Yess!!! It Works!!

    Here my scripts ;




    ipfw add 10 allow ip from any to any keep-state


    ipfw delete 10

    Now at Cron ;

    11:45 AM Captive Portal Ignored. All traffic passes through.
    13:00 PM Captive Portal Enabled, rule 10 deleted.


    Tomorow I'll see if really works fine!

    Thanks @kiokoman and @Gertjan

Log in to reply