AF KTLS a Linux Kernel TLS/DTLS Module

AF KTLS a Linux Kernel TLS/DTLS Module

AF_KTLS A Linux kernel TLS/DTLS module Fridolín Pokorný [email protected] fridex What is TLS/DTLS? ● (Datagram) Transport Layer Security ○ Secured Sockets Layer (SSL) ● version 1.2, draft 1.3 ● GnuTLS, OpenSSL TLS/DTLS Protocols ● Control layer and Record layer ● TLS ○ reliable underlying protocol (e.g. TCP) ● DTLS ○ unreliable underlying protocol (e.g. UDP) ○ additional information about state TLS/DTLS Usage ● HTTPS, e-mail ● HAProxy ● SSL based VPNs ○ OpenConnect ○ CISCO AnyConnect LAN OpenConnect VPN Server WAN Client LAN OpenConnect VPN Server WAN Client LAN OpenConnect VPN Server WAN Client encrypt() LAN OpenConnect VPN Server WAN Client encrypt() kernel write() kernel LAN OpenConnect VPN Server decrypt() read() WAN Client encrypt() kernel write() kernel LAN OpenConnect VPN Server decrypt() write() read() WAN Client encrypt() kernel write() kernel LAN OpenConnect VPN Server decrypt() write() read() WAN Client encrypt() kernel write() kernel LAN OpenConnect VPN Server WAN Client encrypt() decrypt()kernel write() kernel Optimization ● saved 2 context switches, 2 copies Server Server decrypt() write() read() Vs. decrypt()kernel kernel AF_KTLS LAN OpenConnect VPN Server WAN Client encrypt() decrypt()kernel write() kernel AF_KTLS ● new socket type AF_KTLS ● TLS/DTLS record layer ● handshake in user space ● AES GCM ● socket operations ○ socket(2), bind(2), send(2), recv(2), ... Optimization ● 2 context switch ○ ideally, not possible ○ sendfile(2), splice(2) ? ■ data in a pipe (kernel) ● 2 copies ○ data only in kernel space ● issues with padding TLS Record - AEAD ciphers DTLS Record - AEAD ciphers Optimization Results AF_KTLS usages ● OpenConnect VPN - TUN/TAP device support ● KCM ● Access raw data in kernel ○ Linux Socket Filtering ○ BCC ● NIC offloading TLS in kernel ● Solaris ○ ktls ● Netflix ○ BSD’s sendfile(2) optimization ● Red Hat/Facebook ○ AF_KTLS AF_KTLS https://github.com/ktls AF_KTLS Questions? ● https://github.com/ktls ● http://tinyurl.com/af-ktls ● http://netdevconf.org/1.2/session.html?dave-watson.

View Full Text

Details

  • File Type
    pdf
  • Upload Time
    -
  • Content Languages
    English
  • Upload User
    Anonymous/Not logged-in
  • File Pages
    24 Page
  • File Size
    -

Download

Channel Download Status
Express Download Enable

Copyright

We respect the copyrights and intellectual property rights of all users. All uploaded documents are either original works of the uploader or authorized works of the rightful owners.

  • Not to be reproduced or distributed without explicit permission.
  • Not used for commercial purposes outside of approved use cases.
  • Not used to infringe on the rights of the original creators.
  • If you believe any content infringes your copyright, please contact us immediately.

Support

For help with questions, suggestions, or problems, please contact us