LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   Linux Tunnel (https://www.linuxquestions.org/questions/linux-networking-3/linux-tunnel-660589/)

webgard3 08-05-2008 06:43 AM

Linux Tunnel
 
I need to have a tunnel between 2 linux server.
but i cant use Vtun,OpenVPN,GRE,PPTP.
do you know another tunnel that creates an interface?

billymayday 08-05-2008 06:45 AM

have you looked at ssh? Tell us why you can't use those other options, what your setup is, etc..

estabroo 08-05-2008 11:22 AM

Stunnel, netcat, socat, but they are more useful for specific ports, I don't think any have an option for using tap/tun. Ssh can do either, portforwarding or using tap/tun interfaces. I have to admit I'm really curious why any of the other ones wouldn't work for you. If its a matter of a protocol inspecting firewall between the two then I'd go with ssh over https.

http://dag.wieers.com/howto/ssh-http-tunneling/

webgard3 08-05-2008 11:56 PM

First thanks for your attention.

Im in Iran. here telecommunication company has filtered those protocols.


i want to have some USA IP address in iran.
i have a server in USA and another in Iran. i need a tunnel between them.

may you explain more about ssh tunnel?
i need an interface tunnel such as tun/tap or gre to route ip on it.

estabroo 08-07-2008 12:06 AM

ssh can setup a vpn using the tap/tun interface with the -w option and the Tunnel config option. I usually set the Tunnel config option to ethernet so it creates a tap interface which is the equivalent of a normal ethernet interface. Then you just ssh -w any user@remote_machine (might want to add -f -N -n)

It results in a pair of interfaces, one on each machine that are connected to one another like the two machines were on the same lan. If you use the tap interface option then just set up your ips and routes or bridge the interface.

MoMule 08-07-2008 08:28 AM

Freenx
 
If you need a tunnel to display an interface then use FREENX which rides on top of ssh which the poster above already suggested...

Deion "Mule" Christopher


All times are GMT -5. The time now is 05:37 AM.