]> Cypherpunks repositories - gostls13.git/commit
crypto/tls: make ConnectionState.ExportKeyingMaterial a method
authorFilippo Valsorda <hi@filippo.io>
Tue, 21 Aug 2018 20:50:04 +0000 (14:50 -0600)
committerFilippo Valsorda <filippo@golang.org>
Wed, 22 Aug 2018 03:48:56 +0000 (03:48 +0000)
commitde16b3223375235a823658ab4e84716d7fb62dc4
tree38264df1bbee4b2dfcb46b9ef8cfbed6c9dd9ea1
parent90f2fa003738651b02eb0dcb957a6135772ff289
crypto/tls: make ConnectionState.ExportKeyingMaterial a method

The unexported field is hidden from reflect based marshalers, which
would break otherwise. Also, make it return an error, as there are
multiple reasons it might fail.

Fixes #27125

Change-Id: I92adade2fe456103d2d5c0315629ca0256953764
Reviewed-on: https://go-review.googlesource.com/130535
Run-TryBot: Filippo Valsorda <filippo@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
13 files changed:
api/go1.11.txt
doc/go1.11.html
src/crypto/tls/common.go
src/crypto/tls/conn.go
src/crypto/tls/handshake_client_test.go
src/crypto/tls/handshake_server_test.go
src/crypto/tls/prf.go
src/crypto/tls/prf_test.go
src/crypto/tls/testdata/Client-TLSv10-ExportKeyingMaterial [new file with mode: 0644]
src/crypto/tls/testdata/Client-TLSv12-ExportKeyingMaterial [new file with mode: 0644]
src/crypto/tls/testdata/Server-TLSv10-ExportKeyingMaterial [new file with mode: 0644]
src/crypto/tls/testdata/Server-TLSv12-ExportKeyingMaterial [new file with mode: 0644]
src/crypto/tls/tls_test.go