Getting updates behind a firewall
Last updated at 2:56 pm UTC on 14 January 2006
How to get Updates if you are Behind a Firewall:
If you are behind a firewall and can only get to the outside by using a Proxy Server. We have code in the system for that.
Find out the name of your proxy server (name or number is ok), and the port it uses. Put those into this statement, execute it once, and save your image.
HTTPSocket useProxyServerNamed: 'digi.net.sa' port: 8080.
Anytime you want to, you may ask for updates. Or use any other http service in Squeak.
If you ever want to stop using the proxy server, just execute this.
Question: How does one operate behind a Microsoft Proxy firewall? For some reason, DNS queries do not resolve for me (The proxy is currently set up as the primary DNS).
Mind you, this doesn't seem to be a problem for netscape or IE... but most of the other straight network programs (including telnet and ftp) just can't break through.
Question: How does one operate behind a proxy that requires you to login before connecting to the internet ?
I recently found some german (sorry lost the name of the author) code that go gets the name of documents that are pointed to by hyperlinks in the edit page box. This code launches some request to the internet, via my proxy. My proxy returns a 407 Proxy-Authentication needed. The PWS does not handle this. How to solve ?
HTTPSocket useProxyServerNamed: 'my.proxy.server' port: 80.
HTTPSocket proxyUser: 'myUserID' password: 'myPassword'.
just try to do the above.
If you got an other solution, or any kind of help, please send me an email.
The solution to Frederik's problem is to modify the header of the HTTP request to include the BASE64 encoded password and user id.
I've used this squeak/HTTP.12Nov921pm.cs">file in with a Netscape Proxy Server, which requires a password. It works with Squeak 2.2 and 2.3.
Before following the directions below, you may want to 'browse code' from the file list on this change set, to make sure the revisions are consistent with the Squeak version you are using. The network methods do experience changes.
To use, file in the link above, then go to the method
(Which you can find in Network-Protocols/HTTPSocket class/examples)
Revise the comment in this method to specify your proxy server name, user id, and password. Select and do it and save your image. If you move back and forth from behind a firewall, you will have to remember to clear and restore the user id/password when you do.
This is not a secure mechanism; your user id and password are stored in inside your image. Usual disclaimers apply.
March 6th, 2002
The 'file in' mentioned above might not be accessible to everyone. Here is a more recent version, modified to include a new class
variable in HTTPSocket (HTTPProxyExceptions). Missing File (/squeak/uploads/HTTP%3C%2FB%3E-%3CB%20style%3D%22color%3Ablack%3Bbackground-color%3A%2399ff99%22%3Eproxy%3C%2FB%3E-Mar02.cs)
Thanks Ted! (Frederik Vandendriessche mail
If you are connected to the internet via a Proxy Server behind a firewall, and if your browser accesses the Proxy Server via an Automatic Proxy Configuration file (see the proxy preferences on Netscape 4.x for example):
If that fails, you can examine the file via Squeak by executing:
(HTTPSocket httpGet: '<B style="color:black;background-color:#A0FFFF">http</B>://something/something.pac') contents withSqueakLineEndings
Once you have the name of the proxy server (and the port number), use the command described by Ted Kaehler above to connect Squeak to the outside world.
– Doug Way