Require TLS 1.2 or higher

This commit is contained in:
2021-04-10 11:44:38 +02:00
parent 58127ef03c
commit 76de4ad82c
2 changed files with 3 additions and 1 deletions

View File

@@ -2,6 +2,7 @@ package web
import (
"context"
"crypto/tls"
"encoding/json"
"fmt"
"io"
@@ -59,6 +60,7 @@ func NewServer(cfg config.FrontendConfig, hs *honeypot.HoneypotServer, store sto
}
tlsConfig := certManager.TLSConfig()
tlsConfig.MinVersion = tls.VersionTLS12
s.TLSConfig = tlsConfig
s.RegisterOnShutdown(func() {
timeoutCtx, cancel := context.WithTimeout(context.Background(), 3*time.Second)