lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <Pine.LNX.4.61.1303241153000.20041@envy.nxs.se>
Date:	Sun, 24 Mar 2013 12:05:43 +0100 (CET)
From:	Tomas Agartz <tlund@....se>
To:	netdev@...r.kernel.org
Subject: unmanaged L2TPv3 ethernet pseudowire Cisco <=> Linux

I am trying to set up an unmanaged L2TPv3 ethernet pseudowire from a Cisco 
7200 (running IOS 15.2M) and a Linux box with kernel 3.2 (Debian Wheezy).

Using Wireshark I can see L2TPv3 packets arriving from the Cisco router, 
but they are not parsed correctly by the kernel and only a few (mangled) 
frames are showing up on the l2tpeth0 interface.

The actualy tunnel packets that arrive from the cisco router looks like 
this: [IPv4][L2TPv3][payload]. The L2TPv3 header is only 4 bytes, the 
bytes 00 00 00 c8 (just the session id, 200) and the payload is an 
ethernet frame recived by the Cisco on the interface where the tunnel is 
configured. A quick glance at the RFC seem to indicate that this is 
correct.

I am assuming that the kernel is trying to parse more data then just the 4 
bytes, for example expecting a cookie and/or sequence numbers. It is also 
possible it is expecting a L2 sublayer header after the L2TPv3 header. I 
had to tune wireshark and set cookie size to "0", L2-Specific sublayer to 
"none" and tell it to decode the packet contents as "ethernet". With these 
settings, it is showing me exactly what I am expecting.

To configure the tunnel in the linux end, I have done this:

ip l2tp add tunnel remote 172.16.0.1 local 192.168.0.1 tunnel_id 200 peer_tunnel_id 200 encap ip
ip l2tp add session tunnel_id 200 session_id 200 peer_session_id 200

The cisco has the following config:
!
interface GigabitEthernet0/0
  no ip address
  xconnect 192.168.0.1 200 encapsulation l2tpv3 manual pw-class tlund
   l2tp id 200 200
!
pseudowire-class tlund
  encapsulation l2tpv3
  interworking ethernet
  protocol none
  ip local interface Loopback0
!

I can not understand how Linux could possibly auto-detect the cookie size 
and know what kind L2 sublayer header to expect, meaning it needs to be 
configured. Is there some other tool outside of iproute2 that can be used 
to configure these aspect of the L2TPv3 tunnel in the Linux side?

Best regards,
Tomas
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ