]> www.infradead.org Git - users/dwmw2/openconnect.git/commit
add ppp-over-tls tests (with pppd as the reference peer implementation)
authorDaniel Lenski <dlenski@gmail.com>
Fri, 22 May 2020 03:47:59 +0000 (20:47 -0700)
committerDaniel Lenski <dlenski@gmail.com>
Mon, 29 Mar 2021 02:27:01 +0000 (19:27 -0700)
commiteaabbb09ea74bb82a3c8593dc5014a6ff51062c6
tree7d4a8dbf7e5526691888108606643e903ff8bb15
parent9830ff83392c71acceba269ab918bab04c024869
add ppp-over-tls tests (with pppd as the reference peer implementation)

These test OpenConnect's ability to communicate with the standard pppd using
PPP-over-TLS, with a variety of PPP negotiation options:

  ± IPv4
  ± IPv6
  ± DNS and NBNS server negotiation
  ± PPP header protocol/address field compression
  ± Van Jacobson header compression (always rejected by OpenConnect)

These tests use socat to create TLS socket pairs, connecting `openconnect
--protocol=nullppp` to one end and `pppd` to the other.

I tried and failed to combine socat and pppd invocations, but pppd seemingly
cannot handle being wrapped by libsocket_wrapper.so (nor libuid_wrapper.so;
it must run as root).

`pppd sync` (non-HDLC framing) appears to have trouble reacting to incoming
packets in this configuration, so OpenConnect has to invoke retry timers during
negotiation. This seems to be a bug in pppd, rather than a flaw in OpenConnect's
implementation of PPP. Added logging of the time that each run takes.

Signed-off-by: Daniel Lenski <dlenski@gmail.com>
configure.ac
tests/Makefile.am
tests/common.sh
tests/ppp-over-tls [new file with mode: 0755]