Tunneling

Aus darkrealm Wiki
Zur Navigation springen Zur Suche springen

GRETAP Tunnel erstellen

Auf Host1:

ip l add GRE type gretap local 192.168.0.253 remote <öffentliche IP-Adresse>
ip l set dev GRE up
ip a add 10.0.0.1/24 dev GRE

Auf Host2:

ip l add GRE type gretap local 192.168.3.253 remote <öffentliche IP-Adresse>
ip l set dev GRE up
ip a add 10.0.0.2/24 dev GRE

L2TPv3 Tunnel erstellen und bridgen

Auf Host1:

ip l2tp add tunnel tunnel_id 1 peer_tunnel_id 2 encap udp local 1.2.3.4 remote 5.6.7.8 udp_sport 5000 udp_dport 6000
ip l2tp add session tunnel_id 1 session_id 1 peer_session_id 2
ip l2tp add tunnel tunnel_id 2 peer_tunnel_id 1 encap udp local 5.6.7.8 remote 1.2.3.4 udp_sport 6000 udp_dport 5000
ip l2tp add session tunnel_id 2 session_id 2 peer_session_id 1