Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I am inside a network where my machine (IP-192.168.4.53) dont have access to Gmail. But I have access to another machine with IP (192.168.4.33/24) through which Gmail is accessible. Now what I want to achieve is redirect all my http traffic through that system. Will I be able to do this using IPTables? I have tried and failed but I dont know why I am sure this can be done.

Also all my traffic goes through a proxy 192.168.53.105 where I guess there is a firewall which actually blocks gmail access based on IP (this is a guess) Any help would be welcome. I would be grateful if you can point me in the right direction..

share|improve this question
    
I am a little confused on posting this question here. Should this be in superuser?? Please let me know I will move it there in that case. :) –  kidd0 Feb 27 '12 at 4:28

2 Answers 2

Don't route your web traffic through your buddy's PC. If you aren't supposed to go to Gmail, don't go there. If that's not the issue, have the network team allow access for your IP.

share|improve this answer
    
I got the same answer from another forum too. But the question is my company is not so organized. :( There is no one who cares. The networking team does not respond as they hire really bad fools who do not know the minimum Linux administration. I am just interested in proving the same :D By the way I own a smart phone. So accessing mails is not an issue . Its just that PC is way more comfortable. :) –  kidd0 Feb 28 '12 at 3:45
    
I understand your perception of the situation but keep in mind that someone knew enough to define a policy stating which content will be allowed and which content will not, setup a proxy server and finally configure rules to filter that content. I stand by my post. There is someone there that has the knowledge to address your issue. My guess is they are not addressing it because they aren't supposed to be allowing you to open personal email and they don't want to upset you by telling you no. If you want the situation to improve, try to improve the network not get around security constraints. –  Paul Ackerman Feb 28 '12 at 13:52

Why don't you try SSH tunneling since you mentioned you have access to another machine which has proper access to internet

Option 1:

ssh and direct connect (SOCKS5) : The following line will start the ssh client and connect to username@remote_machine.com. Port 8080 on localhost (127.0.0.1) will listen for requests and send them to the remote machine. The remote machine will then send the packets out as if they originated from itself. Now all you have to do is set the preference in Firefox/chrome/your browser choice to use a SOCKS proxy. The proxy is, of course, “localhost”, with the port 8080.

ssh -C2qTnN -D 8080 username@remote_machine.com

Option 2:

ssh to squid proxy (HTTP/SSL Proxy) : The following line will also start the ssh client and connect to username@remote_machine.com. Port 8080 on localhost (127.0.0.1) on the current machine will listen for requests and ssh tunnel them to the remote machine. On the remote machine ssh will forward the packets to localhost port 3128. If squid is listening on localhost port 3128 on the remote machine then all requests sent though the ssh tunnel will then be forwarded to squid.

ssh -C2qTnN -L 8080:localhost:3128 username@remote_machine.com
share|improve this answer
    
I tried as you said. But still its not working.. I did ssh into the machine. n changed the proxy to localhost. But wen i access gmail it says "Error 324 (net::ERR_EMPTY_RESPONSE): The server closed the connection without sending any data." –  kidd0 Feb 27 '12 at 6:18
    
All the instructions are for your localmachine not the remote machine –  kaji Feb 27 '12 at 7:48
    
It did not work.. Its giving me the same error. –  kidd0 Feb 28 '12 at 3:42

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.