History

xfrm: add espintcp (RFC 8229)

TCP encapsulation of IKE and IPsec messages (RFC 8229) is implemented as a TCP ULP, overriding in particular the sendmsg and recvmsg operations. A Stream Parser is used to extract messages out of the TCP stream using the first 2 bytes as length marker. Received IKE messages are put on "ike_queue", waiting to be dequeued by the custom recvmsg implementation. Received ESP messages are sent to XFRM, like with UDP encapsulation. Some of this code is taken from the original submission by Herbert Xu. Currently, only IPv4 is supported, like for UDP encapsulation.

Sabrina Dubroca committed 6 years ago

Commit e27cca91 parent eecd2279 files · +760 −3Browse files

Showing the changes to include/uapi/linux (1 of 9 files). Show all

Unified · Split

include/uapi/linux/udp.h+1−0
@@ -42,5 +42,6 @@ struct udphdr { · 41 unmodified lines
42#define UDP_ENCAP_GTP0 4 /* GSM TS 09.60 */42#define UDP_ENCAP_GTP0 4 /* GSM TS 09.60 */
43#define UDP_ENCAP_GTP1U 5 /* 3GPP TS 29.060 */43#define UDP_ENCAP_GTP1U 5 /* 3GPP TS 29.060 */
44#define UDP_ENCAP_RXRPC 644#define UDP_ENCAP_RXRPC 6
45#define TCP_ENCAP_ESPINTCP 7 /* Yikes, this is really xfrm encap types. */
45 46
46#endif /* _UAPI_LINUX_UDP_H */47#endif /* _UAPI_LINUX_UDP_H */