Merge pull request #49 from guilhermebr/master

adding crypto/tls sessioncache
pull/56/head
Matt Holt 2015-05-04 23:15:13 -06:00
commit a3b853dd47
1 changed files with 3 additions and 0 deletions

View File

@ -132,6 +132,9 @@ func ListenAndServeTLSWithSNI(srv *http.Server, tlsConfigs []TLSConfig) error {
}
config.BuildNameToCertificate()
// Add a session cache LRU algorithm with default capacity (64)
config.ClientSessionCache = tls.NewLRUClientSessionCache(0)
conn, err := net.Listen("tcp", addr)
if err != nil {
return err