| View previous topic :: View next topic |
| Author |
Message |
ruivilela Apprentice


Joined: 05 Oct 2004 Posts: 236 Location: Łódź
|
Posted: Sun Nov 25, 2007 8:05 pm Post subject: redirect - iptables [solved] |
|
|
Hi
I have been trying to solve this issue:
From my PC (home) I have a limited services to a external site that contains IP restrictions (also I can't connect without using full domain name)
I have access to a server (root + iptables) in my job that is able to use all services from that external site. So I was thinking to do a connection via my server
(not real IPs)
PC(Home): dynamic (anything)
myServer: 80.0.0.1
site: www.site.com (Domain name has to be suplied)
In my server i have apache running at 80, so I want to use port 5780 for example. when i connect to my server (only one interface) using such port with firefox I want a redirection to www.site.com:80.
Is it done by iptables, or I need some kind of proxy software like squid ?
Last edited by ruivilela on Sun Nov 25, 2007 10:41 pm; edited 1 time in total |
|
| Back to top |
|
 |
Zhaozhou Tux's lil' helper


Joined: 25 Oct 2007 Posts: 121 Location: Sweden
|
Posted: Sun Nov 25, 2007 8:25 pm Post subject: |
|
|
If you want the requests to be sent by the server you'll need some sort of proxy application, yes.
I dont know the capabilities of squid, so i can't give you an answer on that. _________________ lunix. |
|
| Back to top |
|
 |
SnEptUne l33t


Joined: 23 Aug 2004 Posts: 643
|
Posted: Sun Nov 25, 2007 8:31 pm Post subject: |
|
|
It depends on what you are trying to do. If you want to setup a permanent redirect link with apache, you can use mod_rewrite. If you want to cache the content of other websites on your server with clients (home PC) connected to it, you can use squid. If you just want to overcome service limitation on your home PC, you can set up SSH tunnel or other kind of tunnel (such as VPN).
Proxy is probably the simplest route. I personally use privoxy instead of squid because I want javascript and ads filtering. _________________ "There will be more joy in heaven over the tear-bathed face of a repentant sinner than over the white robes of a hundred just men." (LM, 114) |
|
| Back to top |
|
 |
ruivilela Apprentice


Joined: 05 Oct 2004 Posts: 236 Location: Łódź
|
Posted: Sun Nov 25, 2007 8:48 pm Post subject: |
|
|
uh,
I see proxy is the way to solve this. I will explain in other way.
In my home I can do "www.site.com" (can't use IP because domain name is required) in Firefox and I have a site with limited application level services.
But at my Job I have all this services, that i want. So I thinked in using the server at the job as a "gateway", I can't use ssh/links/lynx for this because the page is not compatible. So I want to use my server as i would be in an internal network (but i'm not). |
|
| Back to top |
|
 |
SnEptUne l33t


Joined: 23 Aug 2004 Posts: 643
|
Posted: Sun Nov 25, 2007 9:00 pm Post subject: |
|
|
Well, web proxies are for web browsing. If you want to access other services beside browsing web page (HTTP/HTTPS), you probably want to use dynamic SSH tunnels (dynamic port forwarding like SOCKS5 proxy).
You could refer to this link for more information.
http://forums.macosxhints.com/archive/index.php/t-66411.html _________________ "There will be more joy in heaven over the tear-bathed face of a repentant sinner than over the white robes of a hundred just men." (LM, 114) |
|
| Back to top |
|
 |
Dagger Developer


Joined: 11 Jun 2003 Posts: 763 Location: UK
|
Posted: Sun Nov 25, 2007 9:21 pm Post subject: |
|
|
if you want it only for www, that web proxy is the easiest way. If you want also other services I would consider VPN _________________ 95% of all computer errors occur between chair and keyboard (TM)
Join the FSF as an Associate Member!
Post under CC license. |
|
| Back to top |
|
 |
ruivilela Apprentice


Joined: 05 Oct 2004 Posts: 236 Location: Łódź
|
Posted: Sun Nov 25, 2007 10:40 pm Post subject: |
|
|
It's only for www. I didn't knew this "so" easy solution. Great
Thanks |
|
| Back to top |
|
 |
|