Announcement

Collapse
No announcement yet.

Can I automate a linksys router settings?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Can I automate a linksys router settings?

    I have a Linksys Router that i use for Internet access and WiFi. I would like to run a HS script that would add an IP address to the filtered address list and then remove it again based on a time schedule.

    I want to restrict internet access to the Kids PC after 8PM and turn it back on at 10 AM.

    I am able to do this manualy by logging into the Linksys web interface but if i forget to turn it off or on all hell breaks loose and I get WAF issues to deal with.

    AB

    #2
    With is proggy:
    http://www.hiddensoft.com/autoit3/

    You can make scripts and turn them into stand alone .EXE files that can do anything you can do from a Windows keyboard and mouse.

    Bill


    ~Bill

    Comment


      #3
      Andrew,
      I thought CFGuy(Jeff) had posted a script to change the ipaddress access list but I couldn't locate it. Maybe a quick email will get you what you need.
      💁‍♂️ Support & Customer Service 🙋‍♂️ Sales Questions 🛒 Shop HomeSeer Products

      Comment


        #4
        Interesting. I also have a Linksys router (BEFSX41) and you can limit internet access by combinations of time, day, IP, or MAC. I wonder if this is something in the newer units, or does mine have it because it's also a firewall?
        My system is described in my profile.

        Comment


          #5
          I know I may get flamed for suggesting a non-autmated response, but I highly suggest Cyber Sitter I run it on my daughters computer (9yrs) and it works great, schedules, emails reports to me, filters all kinds of stuff. Well worth the small price. Especially considering what is out there now, including the spam...

          Comment


            #6
            sbessel,
            No flames at all. I use a combonation of both. I have filtering software on the kids computers and I use a script that sets my LinkSys router to control when they can access the internet. And since its a script for HomeSeer, that means I can control it from work as well.
            I also use a script to open and close the port forwarding. I open VNC ports while at work and close them when I'm home.

            And now that the Message Server plugin has added a chat feature, my kids can Message me at work even if their Internet access is turned off. Its long distance to call me at work, so we use the chat feature when they need to talk to me.
            --
            Jeff Farmer
            HS 3, HSPhone
            My HS3 Plugins: CFHSExtras, Random, Restart, Tracker, WeatherXML, PanaBluRay
            Other Plugins In Use: APCUPSD, BLOnkyo, Device History, EasyTrigger, HSTouch Server, PHLocation2, Pushover, RFXCom, UltraGCIR3, UltraMon3, UltraPioneerAVR3, X10, Z-Wave

            Hardware: GoControl Irrigation Controler, Schlage Lever Lock, Schlage Deadbolt, Way2Call Hi-Phone, RFXCom RFXrec433 Receiver, WGL 800, TI-103, Z-Net, Pioneer 1120, Pioneer 1021, Pioneer LX302, Panasonic BDT-110, Panasonic BDT-210 x2

            Comment


              #7
              <BLOCKQUOTE class="ip-ubbcode-quote"><font size="-1">quote:</font><HR> and I use a script that sets my LinkSys router to control when they can access the internet. And since its a script for HomeSeer <HR></BLOCKQUOTE>
              Jeff:

              I would be very interested in seeing this script if you wouldn't mind!
              --------------------------------------------------
              **** Do You "Cocoon"? ****

              Comment


                #8
                Andrew,

                Do you have a Linksys WRT54G? I ended up buy two of these because they run Linux. I now have direct access to iptables allowing direct control of the underlying firewall.

                If interested in this custom firmware, check out: http://www.sveasoft.com/modules/phpBB2/index.php I paid the $20.00 subscription and am very pleased with new features it adds to the default Linksys WRT54G wireless router. You could probably write a CRON job to modify iptables to add/remove the address based on time of day.

                Regards,
                Ultrajones
                Plug-ins: UltraMon, UltraM1G, UltraCID, Ultra1Wire, UltraLog, UltraWeatherBug, UltraPioneerAVR, UltraGCIR

                Comment


                  #9
                  CFGuy

                  Do you have a copy of that script ?

                  Andrew

                  Comment


                    #10
                    Sure,
                    I've attached it here.
                    I have the LinkSys BEFSR41. It looks in an ini file to get the routers password.
                    Since it using the username and password on the URL, you have to edit the registry on the HomeSeer server to allow that.

                    The way I call the script is like this:
                    <pre class="ip-ubbcode-code-pre">
                    LinkSysOutgoing.txt ("main","2|5|7|7")
                    </pre>

                    You can have up to 5 pairs of filters. The above example would block outgoing for IPs 2 through 5 and 7.

                    Line 46 gets the router IP from a virutal device but you can replace the line with the actual internal IP.
                    <pre class="ip-ubbcode-code-pre">
                    fs.Add hs.GetINISetting ("Settings","LinkSys RouterPassword","",strPluginINI)
                    </pre>
                    Attached Files
                    --
                    Jeff Farmer
                    HS 3, HSPhone
                    My HS3 Plugins: CFHSExtras, Random, Restart, Tracker, WeatherXML, PanaBluRay
                    Other Plugins In Use: APCUPSD, BLOnkyo, Device History, EasyTrigger, HSTouch Server, PHLocation2, Pushover, RFXCom, UltraGCIR3, UltraMon3, UltraPioneerAVR3, X10, Z-Wave

                    Hardware: GoControl Irrigation Controler, Schlage Lever Lock, Schlage Deadbolt, Way2Call Hi-Phone, RFXCom RFXrec433 Receiver, WGL 800, TI-103, Z-Net, Pioneer 1120, Pioneer 1021, Pioneer LX302, Panasonic BDT-110, Panasonic BDT-210 x2

                    Comment


                      #11
                      <BLOCKQUOTE class="ip-ubbcode-quote"><font size="-1">quote:</font><HR>Originally posted by CFGuy:
                      Since it using the username and password on the URL, you have to edit the registry on the HomeSeer server to allow that. <HR></BLOCKQUOTE>
                      Jeff, Could you please explain this? TIA

                      Comment


                        #12
                        It deals with what was discussed in this post.

                        http://ubb.homeseer.com/eve/ubb.x?a=...655#1406014655

                        If your HomeSeer server has the update that takes the url login away, you will need to edit the registry to allow it again if you want to use this script. Its been several weeks but I found the fix on microsofts site.
                        --
                        Jeff Farmer
                        HS 3, HSPhone
                        My HS3 Plugins: CFHSExtras, Random, Restart, Tracker, WeatherXML, PanaBluRay
                        Other Plugins In Use: APCUPSD, BLOnkyo, Device History, EasyTrigger, HSTouch Server, PHLocation2, Pushover, RFXCom, UltraGCIR3, UltraMon3, UltraPioneerAVR3, X10, Z-Wave

                        Hardware: GoControl Irrigation Controler, Schlage Lever Lock, Schlage Deadbolt, Way2Call Hi-Phone, RFXCom RFXrec433 Receiver, WGL 800, TI-103, Z-Net, Pioneer 1120, Pioneer 1021, Pioneer LX302, Panasonic BDT-110, Panasonic BDT-210 x2

                        Comment


                          #13
                          Thanks for the script...

                          I am unable to figure out exactly what is going on with it though. I am not sure what format the Farmnet.ini file should be in. and what hs devices need to be created.

                          I would like to extract the one part in your script that just blocks access to one IP address and then unblocks it. but i cannot figure out which part of the script deals with that. and do i need the CGI script file called Gozila.cgi to make this work ?

                          Can anyone point me in the correct direction.

                          Thanks Andrew

                          Comment


                            #14
                            you can change it to any ini file.
                            The only entry you need is

                            <pre class="ip-ubbcode-code-pre">
                            [Settings]
                            LinkSys RouterPassword=Your Password here
                            </pre>

                            I just put my password in an ini file so that its not in the script.

                            The CGI Script Gozilla.cgi is built into the router.

                            All the script does is build a URL to submit to the router.

                            Here is an easy way to get the needed URL.
                            Go to the filter tab on your router, set it up the way you want it when the script runs. Click Apply and then copy the URL that is in the Address section of your browser. That is the URL that you need to send to the router.
                            Paste that URL into a hs.GetURL statement and you are done.

                            The only thing my script is doing is allowing me to use one script and send params to it for which computers I want blocked.
                            --
                            Jeff Farmer
                            HS 3, HSPhone
                            My HS3 Plugins: CFHSExtras, Random, Restart, Tracker, WeatherXML, PanaBluRay
                            Other Plugins In Use: APCUPSD, BLOnkyo, Device History, EasyTrigger, HSTouch Server, PHLocation2, Pushover, RFXCom, UltraGCIR3, UltraMon3, UltraPioneerAVR3, X10, Z-Wave

                            Hardware: GoControl Irrigation Controler, Schlage Lever Lock, Schlage Deadbolt, Way2Call Hi-Phone, RFXCom RFXrec433 Receiver, WGL 800, TI-103, Z-Net, Pioneer 1120, Pioneer 1021, Pioneer LX302, Panasonic BDT-110, Panasonic BDT-210 x2

                            Comment


                              #15
                              That was easy..

                              Thanks sooooooo much


                              Andrew

                              Comment

                              Working...
                              X