Community discussions

MikroTik App
 
oopsxp
just joined
Topic Author
Posts: 3
Joined: Tue Sep 04, 2018 2:53 pm

How can I enable a device to connect wifi for only 2 hours per day without setting hotspot

Sun Sep 23, 2018 9:47 am

as subject. Thanks

Static IP of the device has been set (i.e. 192.168.88.20)
 
UpRunTech
Member Candidate
Member Candidate
Posts: 126
Joined: Fri Jul 27, 2012 12:11 pm

Re: How can I enable a device to connect wifi for only 2 hours per day without setting hotspot

Tue Sep 25, 2018 10:11 pm

as subject. Thanks

Static IP of the device has been set (i.e. 192.168.88.20)
Use Kid Control. It's not very well named as it actually drives them crazy and out of control.

https://wiki.mikrotik.com/wiki/Manual:Kid-control
 
Redmor
Member Candidate
Member Candidate
Posts: 251
Joined: Wed May 31, 2017 7:40 pm
Location: Italy

Re: How can I enable a device to connect wifi for only 2 hours per day without setting hotspot

Wed Sep 26, 2018 4:19 pm

You can use Time under access list rule, never tried it, but should work.
ImageImage
 
User avatar
xvo
Forum Veteran
Forum Veteran
Posts: 731
Joined: Sat Mar 03, 2018 1:12 am
Location: Moscow, Russia

Re: How can I enable a device to connect wifi for only 2 hours per day without setting hotspot

Wed Sep 26, 2018 6:31 pm

You can use Time under access list rule, never tried it, but should work.
That won't work.
And the kid control feature as well.
They both can only restrict the hour ranges when the client can stay connect, not the total connected time per day.
 
UpRunTech
Member Candidate
Member Candidate
Posts: 126
Joined: Fri Jul 27, 2012 12:11 pm

Re: How can I enable a device to connect wifi for only 2 hours per day without setting hotspot

Wed Sep 26, 2018 11:43 pm

You can use Time under access list rule, never tried it, but should work.
That won't work.
And the kid control feature as well.
They both can only restrict the hour ranges when the client can stay connect, not the total connected time per day.
True, there was some ambiguity to the question.

Hotspot might be easiest. If you want to only have selected devices use the hotspot you can add their MAC in the access list and force them onto a VLAN+bridge that runs the hotspot without needing to use a new SSID. Otherwise, just make a new SSID with the hotspot on it. Even then I don't know if on hotspot you can lock a device out when it's used up it's allocation for a 24H period. It might need some extra scripting to support this.
 
allstarcomps
newbie
Posts: 32
Joined: Sat Jul 08, 2017 10:36 pm
Location: San Diego, CA, USA
Contact:

Re: How can I enable a device to connect wifi for only 2 hours per day without setting hotspot

Thu Sep 27, 2018 8:56 am

Set DHCP lease time to 24hrs

DHCP lease script add the host IP to a firewall list named "allowedLan" with a 2hr time out.

Firewall filter forward chain accept traffic from the src address list=allowedLan

Firewall filter forward chain drop traffic from the screen address list!=allowedLan
 
UpRunTech
Member Candidate
Member Candidate
Posts: 126
Joined: Fri Jul 27, 2012 12:11 pm

Re: How can I enable a device to connect wifi for only 2 hours per day without setting hotspot

Thu Sep 27, 2018 11:52 pm

Set DHCP lease time to 24hrs

DHCP lease script add the host IP to a firewall list named "allowedLan" with a 2hr time out.

Firewall filter forward chain accept traffic from the src address list=allowedLan

Firewall filter forward chain drop traffic from the screen address list!=allowedLan
This is only good if the requirement is to start the clock from the moment the device is turned on. I think the OP needs to define the problem more succinctly.

Is it:

* 2 hours from device powerup?
* 2 hours of web browsing?
* 2 hours contiguous use?
* 2 hours accumulated over 24h rolling window?
* 2 hour window before kids bedtime?

Given most computing devices are on all the time and sleep and wake and do a DHCP request often the DHCP script might not be the solution.
 
User avatar
Jotne
Forum Guru
Forum Guru
Posts: 1759
Joined: Sat Dec 24, 2016 11:17 am
Location: jo.overland at gmail.com

Re: How can I enable a device to connect wifi for only 2 hours per day without setting hotspot

Sun Sep 30, 2018 10:23 am

The problem I do have with this, is that the kids uses internet on the cell phone if I turn of the Wifi.
Either their own phone or friend phone.
 
How to use Splunk to monitor your MikroTik Router(s)

MikroTik->Splunk
 

Who is online

Users browsing this forum: No registered users and 22 guests