autoitxp Posted August 5, 2009 Share Posted August 5, 2009 (edited) Hi ! i wanted to know if there is any function in wininet.dll to lock internet . i really wanted to know how to lock internet. there is many other function to check internet connection state like InternetGetConnectedState or internetattemptconnect. there should be some lock function aswell ;d DllCall('wininet.dll', 'int', 'InternetCloseHandle', 'long', $l_InternetSession) Edited August 5, 2009 by autoitxp Link to comment Share on other sites More sharing options...
Bert Posted August 5, 2009 Share Posted August 5, 2009 Hi ! i wanted to know is there any function in wininet.dll to lock internet . i really wanted to know how to lock internet. there is many other function to check internet connection state like InternetGetConnectedState or internetattemptconnect. there should be some lock function aswell ;d DllCall('wininet.dll', 'int', 'InternetCloseHandle', 'long', $l_InternetSession) To simply lock the internet? well, you could close port 80 and port 443. That would do most of it. However if they specify a differnt port in the URL string to get to a site that requires a different port number then they can get out to at least that site. Note: If they use a different browser or web access application, then this may not apply. A second option is to run the PC through a router, and block it there with MAC filtering. A third option is to put a proxy setting in the browser. Be warned they may use a different browser and get past this one. You could change the HOST file. Not a good idea for it blocks whoever logs int the PC. Also, look here: http://windowsitpro.com/article/articleid/85079/jsi-tip-10092-how-can-i-block-internet-access-for-a-specific-user-account.html The Vollatran project My blog: http://www.vollysinterestingshit.com/ Link to comment Share on other sites More sharing options...
autoitxp Posted August 5, 2009 Author Share Posted August 5, 2009 so there is no single decent way to lock internet/? Link to comment Share on other sites More sharing options...
Developers Jos Posted August 5, 2009 Developers Share Posted August 5, 2009 so there is no single decent way to lock internet/?Something like LockInternetNow() ?Nope... SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
Authenticity Posted August 5, 2009 Share Posted August 5, 2009 If by lock you mean disconnect you can use this to disconnect an automatic dial-up connection as stated in this function description page. If you're using router connection you can use WinHttp.WinHttpRequest.5.1 object to send requests to the router page to request disconnection, described here. Link to comment Share on other sites More sharing options...
lordicast Posted August 5, 2009 Share Posted August 5, 2009 Cant you just find what ports are open and close them with a 'while'? netstat -an |find /i "listening" > c:'openports.txt From Cmd and FileRead and close the ports that are shown. [Cheeky]Comment[/Cheeky] Link to comment Share on other sites More sharing options...
Developers Jos Posted August 5, 2009 Developers Share Posted August 5, 2009 Maybe it would help when the OP is a little clearer in what it is that is exactly required. There is a magnitude of solutions depending on the requirements from simply "removing the IP gateway and only make other ip addresses available in the pc's subnet" to installing some sort of proxy for filtering the outbound traffic. SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now