Commit a3b853dd authored by Matt Holt's avatar Matt Holt

Merge pull request #49 from guilhermebr/master

adding crypto/tls sessioncache
parents 2dbd14b6 da6a097d
...@@ -132,6 +132,9 @@ func ListenAndServeTLSWithSNI(srv *http.Server, tlsConfigs []TLSConfig) error { ...@@ -132,6 +132,9 @@ func ListenAndServeTLSWithSNI(srv *http.Server, tlsConfigs []TLSConfig) error {
} }
config.BuildNameToCertificate() config.BuildNameToCertificate()
// Add a session cache LRU algorithm with default capacity (64)
config.ClientSessionCache = tls.NewLRUClientSessionCache(0)
conn, err := net.Listen("tcp", addr) conn, err := net.Listen("tcp", addr)
if err != nil { if err != nil {
return err return err
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment