What's new

Script for http filter with time slot

  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

Matt-One

Occasional Visitor
Hello I installed some days ago the gnuton firmware (thx @GNUton for the great firmware full of options and your support) on my dsl-ac68u.
I'm not good to programming and I come here to ask you some help to make a script that can block a website of my interest in certain timeslots
In practice, I would like to block for example only YouTube (or all streaming and entertainment sites if I can't block them individually) to my niece in certain time slots and not 24 hours a day. Is it possible?

Thank you so much :)

Inviato dal mio SM-N950F utilizzando Tapatalk
 
So no chance to block a website like YouTube for example on a static ip from 14 to 16 of a xyz day?
 
This is not a DSL specific question.. a different thread would get you more answers.. or just google for something like this:
https://www.snbforums.com/threads/p...te-from-a-specific-computer-via-router.36056/
a firewall rule set within a crontab would be a solution. google may help u.
Thank you again for your reply :)
I googled before, and I found the answer in opendns but I thought a script could be more efficient :) without using or changing other DNS :)
I will take a look at opendns, thank you again :)

Inviato dal mio SM-N950F utilizzando Tapatalk
 
So, i can't use the firewall rule to block a website of a static ip (or mac) on my device using shedule time, i don'k know why... So looking on google i found this cru command (on this forum), ok i can't block a specific website like youtube, but i can block all the Streaming and Entertainment sites enabling or disabling the AI Feature at XXX hour of YYY day.

Are this commands corrects? They will match what i need?

cru a filtering-on "0 6 MON-FRI * * [turn AiProtection Parental Controls on]"
cru a filtering-off "0 18 MON-FRI * * [turn AiProtection Parental Controls off]"

DISABLE :

nvram set wrs_app_enabled=0
nvram set wrs_enable=0
service "restart_wrs;restart_firewall"

ENABLE :

nvram set wrs_app_enabled=1
nvram set wrs_enable=1
service "restart_wrs;restart_firewall"
 

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!
Top