Skip to content

Commit 0cfe46c

Browse files
committed
[release-branch.go1.12] crypto/tls, runtime: document GODEBUG TLS 1.3 option
Change-Id: I6801676335924414ce50249df2b7bea08886b203 Reviewed-on: https://go-review.googlesource.com/c/162360 Reviewed-by: Filippo Valsorda <[email protected]> (cherry picked from commit 48bb611) Reviewed-on: https://go-review.googlesource.com/c/162497
1 parent 74f0f69 commit 0cfe46c

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

src/crypto/tls/tls.go

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,15 @@
44

55
// Package tls partially implements TLS 1.2, as specified in RFC 5246,
66
// and TLS 1.3, as specified in RFC 8446.
7+
//
8+
// TLS 1.3 is available only on an opt-in basis in Go 1.12. To enable
9+
// it, set the GODEBUG environment variable (comma-separated key=value
10+
// options) such that it includes "tls13=1". To enable it from within
11+
// the process, set the environment variable before any use of TLS:
12+
//
13+
// func init() {
14+
// os.Setenv("GODEBUG", os.Getenv("GODEBUG")+",tls13=1")
15+
// }
716
package tls
817

918
// BUG(agl): The crypto/tls package only implements some countermeasures

src/runtime/extern.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ It is a comma-separated list of name=val pairs setting these named variables:
127127
IDs will refer to the ID of the goroutine at the time of creation; it's possible for this
128128
ID to be reused for another goroutine. Setting N to 0 will report no ancestry information.
129129
130-
The net and net/http packages also refer to debugging variables in GODEBUG.
130+
The net, net/http, and crypto/tls packages also refer to debugging variables in GODEBUG.
131131
See the documentation for those packages for details.
132132
133133
The GOMAXPROCS variable limits the number of operating system threads that

0 commit comments

Comments
 (0)