Package: ppp
Version: 2.4.7-2+4.1+deb10u1
Control: subscribe -1

Hello!

pppoe-discovery with -U option (Use Host-Unique to allow multiple PPPoE
sessions) is in Debian Buster currently broken.

Its output on PPPoE network via eth0 interface is just:

  # pppoe-discovery -U -I eth0
  Timeout waiting for PADO packets

But tcpdump on eth0 interface confirms that PADO packets were received:

  # tcpdump -n -p -vvvv -i eth0
  tcpdump: listening on eth0, link-type EN10MB (Ethernet), capture size 262144 
bytes
  ...
  21:04:23.835174 PPPoE PADI [Service-Name] [Host-Uniq 0x0DCC]
  21:04:23.853135 PPPoE PADO [Service-Name] [AC-Name "ke-pols-bras-1"] 
[Host-Uniq 0x0DCC] [AC-Cookie 0x37591CD0FA31C63720E0CF08D4340C61]
  21:04:23.853396 PPPoE PADO [Service-Name] [AC-Name "po-maue-bras-1"] 
[Host-Uniq 0x0DCC] [AC-Cookie 0xEC3CB571EEF00E875E46F71059CA58F9]
  21:04:26.853685 PPPoE PADO [Service-Name] [AC-Name "ba-jros-bras-3"] 
[Host-Uniq 0x0DCC] [AC-Cookie 0x7D802A631A6DC4F1F3C70737DA71678A]
  21:04:31.858854 PPPoE PADI [Service-Name] [Host-Uniq 0x0DCC]
  21:04:31.868204 PPPoE PADO [Service-Name] [AC-Name "ke-pols-bras-1"] 
[Host-Uniq 0x0DCC] [AC-Cookie 0x37591CD0FA31C63720E0CF08D4340C61]
  21:04:31.868358 PPPoE PADO [Service-Name] [AC-Name "po-maue-bras-1"] 
[Host-Uniq 0x0DCC] [AC-Cookie 0xEC3CB571EEF00E875E46F71059CA58F9]
  21:04:34.948714 PPPoE PADO [Service-Name] [AC-Name "ba-jros-bras-3"] 
[Host-Uniq 0x0DCC] [AC-Cookie 0x7D802A631A6DC4F1F3C70737DA71678A]
  21:04:39.953858 PPPoE PADI [Service-Name] [Host-Uniq 0x0DCC]
  21:04:39.962591 PPPoE PADO [Service-Name] [AC-Name "ke-pols-bras-1"] 
[Host-Uniq 0x0DCC] [AC-Cookie 0x37591CD0FA31C63720E0CF08D4340C61]
  21:04:39.962649 PPPoE PADO [Service-Name] [AC-Name "po-maue-bras-1"] 
[Host-Uniq 0x0DCC] [AC-Cookie 0xEC3CB571EEF00E875E46F71059CA58F9]
  21:04:43.048720 PPPoE PADO [Service-Name] [AC-Name "ba-jros-bras-3"] 
[Host-Uniq 0x0DCC] [AC-Cookie 0x7D802A631A6DC4F1F3C70737DA71678A]
  ...

Without -U option pppoe-discovery is working fine:

  # pppoe-discovery -I eth0
  Access-Concentrator: ke-pols-bras-1
  Got a cookie: 37 59 1c d0 fa 31 c6 37 20 e0 cf 08 d4 34 0c 61
  --------------------------------------------------
  AC-Ethernet-Address: 24:21:24:e9:be:3f
  Access-Concentrator: po-maue-bras-1
  Got a cookie: ec 3c b5 71 ee f0 0e 87 5e 46 f7 10 59 ca 58 f9
  --------------------------------------------------
  AC-Ethernet-Address: 20:e0:9c:3e:98:01
  Access-Concentrator: ba-jros-bras-3
  Got a cookie: 7d 80 2a 63 1a 6d c4 f1 f3 c7 07 37 da 71 67 8a
  --------------------------------------------------
  AC-Ethernet-Address: 24:21:24:b9:76:3f

It looks like that ppp package in Debian Buster has custom patch which
implements -U option [1] which differs from upstream implementation of
-U option [2] [3].

I compiled pppoe-discovery from upstream ppp project with upstream -U
patch [3] and this is working fine. Output is:

  # ./pppd/plugins/rp-pppoe/pppoe-discovery -U -I eth0
  Access-Concentrator: ke-pols-bras-1
  Got a cookie: 37 59 1c d0 fa 31 c6 37 20 e0 cf 08 d4 34 0c 61
  AC-Ethernet-Address: 24:21:24:e9:be:3f
  --------------------------------------------------
  Access-Concentrator: po-maue-bras-1
  Got a cookie: ec 3c b5 71 ee f0 0e 87 5e 46 f7 10 59 ca 58 f9
  AC-Ethernet-Address: 20:e0:9c:3e:98:01
  --------------------------------------------------
  Access-Concentrator: ba-jros-bras-3
  Got a cookie: 7d 80 2a 63 1a 6d c4 f1 f3 c7 07 37 da 71 67 8a
  AC-Ethernet-Address: 24:21:24:b9:76:3f
  --------------------------------------------------

So it means that Debian's custom patch in Buster [1] is broken. Please
replace this broken Debian patch by working upstream patch [3]. To make
pppoe-discovery from ppp package in Debian working.

[1] - 
https://sources.debian.org/patches/ppp/2.4.7-2+4.1+deb10u1/pr-28-pppoe-custom-host-uniq-tag.patch/
[2] - https://github.com/paulusmack/ppp/pull/97
[3] - 
https://github.com/paulusmack/ppp/commit/c9d9dbfb8459b528ab56bd1cf0c41460801bbfdf

-- 
Pali Rohár
pali.ro...@gmail.com

Reply via email to