mirror of
https://github.com/asmogo/nws.git
synced 2025-01-18 18:11:33 +00:00
Extend certificate validity to 10 years
This commit is contained in:
parent
e6d48a6422
commit
588b0ad645
@ -125,7 +125,7 @@ func (e *Exit) StartReverseProxy(httpTarget string, port int32) error {
|
||||
func (e *Exit) createAndStoreCertificateData(ctx context.Context) (*tls.Certificate, error) {
|
||||
priv, _ := rsa.GenerateKey(rand.Reader, 2048)
|
||||
notBefore := time.Now()
|
||||
notAfter := notBefore.Add(365 * 24 * time.Hour)
|
||||
notAfter := notBefore.Add(10 * 365 * 24 * time.Hour)
|
||||
serialNumberLimit := new(big.Int).Lsh(big.NewInt(1), 128)
|
||||
serialNumber, _ := rand.Int(rand.Reader, serialNumberLimit)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user