• Filippo Valsorda's avatar
    crypto/tls: implement TLS 1.3 server handshake (base) · c21ba09b
    Filippo Valsorda authored
    Implement a basic TLS 1.3 server handshake, only enabled if explicitly
    requested with MaxVersion.
    
    This CL intentionally leaves for future CLs:
      - PSK modes and resumption
      - client authentication
      - compatibility mode ChangeCipherSpecs
      - early data skipping
      - post-handshake messages
      - downgrade protection
      - KeyLogWriter support
      - TLS_FALLBACK_SCSV processing
    
    It also leaves a few areas up for a wider refactor (maybe in Go 1.13):
      - the certificate selection logic can be significantly improved,
        including supporting and surfacing signature_algorithms_cert, but
        this isn't new in TLS 1.3 (see comment in processClientHello)
      - handshake_server_tls13.go can be dried up and broken into more
        meaningful, smaller functions, but it felt premature to do before
        PSK and client auth support
      - the monstrous ClientHello equality check in doHelloRetryRequest can
        get both cleaner and more complete with collaboration from the
        parsing layer, which can come at the same time as extension
        duplicates detection
    
    Updates #9671
    
    Change-Id: Id9db2b6ecc2eea21bf9b59b6d1d9c84a7435151c
    Reviewed-on: https://go-review.googlesource.com/c/147017
    Run-TryBot: Filippo Valsorda <filippo@golang.org>
    TryBot-Result: Gobot Gobot <gobot@golang.org>
    Reviewed-by: 's avatarAdam Langley <agl@golang.org>
    c21ba09b
Name
Last commit
Last update
.github Loading commit data...
api Loading commit data...
doc Loading commit data...
lib/time Loading commit data...
misc Loading commit data...
src Loading commit data...
test Loading commit data...
.gitattributes Loading commit data...
.gitignore Loading commit data...
AUTHORS Loading commit data...
CONTRIBUTING.md Loading commit data...
CONTRIBUTORS Loading commit data...
LICENSE Loading commit data...
PATENTS Loading commit data...
README.md Loading commit data...
favicon.ico Loading commit data...
robots.txt Loading commit data...