mirror of https://github.com/kubernetes/kops.git
Include serial number in Subject of created keypairs
This commit is contained in:
parent
86c9ee5506
commit
95665f45c6
|
@ -169,10 +169,11 @@ func RunCreateKeypair(ctx context.Context, f *util.Factory, out io.Writer, optio
|
|||
}
|
||||
}
|
||||
|
||||
serial := pki.BuildPKISerial(time.Now().UnixNano())
|
||||
req := pki.IssueCertRequest{
|
||||
Type: "ca",
|
||||
Subject: pkix.Name{CommonName: options.Keyset},
|
||||
Serial: pki.BuildPKISerial(time.Now().UnixNano()),
|
||||
Subject: pkix.Name{CommonName: options.Keyset, SerialNumber: serial.String()},
|
||||
Serial: serial,
|
||||
PrivateKey: privateKey,
|
||||
}
|
||||
cert, _, _, err = pki.IssueCert(&req, nil)
|
||||
|
|
Loading…
Reference in New Issue