feat: Misc renaming.
This commit is contained in:
1 parent
3d0add35e3
commit
5c44b990c2
1 file changed
+3
-3
@@ -55,7 +55,7 @@ var generateClientCertCmd = &cobra.Command{
|
|||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
certKey := pki.NewKey()
|
crtKey := pki.NewKey()
|
||||||
clientCrtTmpl := &x509.Certificate{
|
clientCrtTmpl := &x509.Certificate{
|
||||||
SerialNumber: pki.NewCertSerialNumber(),
|
SerialNumber: pki.NewCertSerialNumber(),
|
||||||
Subject: pkix.Name{
|
Subject: pkix.Name{
|
||||||
@@ -78,7 +78,7 @@ var generateClientCertCmd = &cobra.Command{
|
|||||||
// CA is the parent.
|
// CA is the parent.
|
||||||
ca,
|
ca,
|
||||||
// The cert embeds its own public key.
|
// The cert embeds its own public key.
|
||||||
&certKey.PublicKey,
|
&crtKey.PublicKey,
|
||||||
// The CA's private key is the one signing the leaf cert.
|
// The CA's private key is the one signing the leaf cert.
|
||||||
caKey,
|
caKey,
|
||||||
)
|
)
|
||||||
@@ -95,7 +95,7 @@ var generateClientCertCmd = &cobra.Command{
|
|||||||
}
|
}
|
||||||
// Write cert private key to disk.
|
// Write cert private key to disk.
|
||||||
keyfn := path.Join(OutDir, Name+".key")
|
keyfn := path.Join(OutDir, Name+".key")
|
||||||
err = createFileWith(keyfn, pki.MarshalKeyToPEM(certKey), pki.PrivateKeyFilePerms)
|
err = createFileWith(keyfn, pki.MarshalKeyToPEM(crtKey), pki.PrivateKeyFilePerms)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user