Skip to content

Commit

Permalink
Fix generateCertificate helper function (prober tests)
Browse files Browse the repository at this point in the history
Signed-off-by: Santiago Hernández <[email protected]>
  • Loading branch information
santihernandezc committed May 17, 2024
1 parent 6efcf0c commit b3bc308
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion prober/utils_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ func generateCertificateTemplate(expiry time.Time, IPAddressSAN bool) *x509.Cert
}

func generateCertificate(template, parent *x509.Certificate, publickey *rsa.PublicKey, privatekey *rsa.PrivateKey) (*x509.Certificate, []byte) {
derCert, err := x509.CreateCertificate(rand.Reader, template, template, publickey, privatekey)
derCert, err := x509.CreateCertificate(rand.Reader, template, parent, publickey, privatekey)
if err != nil {
panic(fmt.Sprintf("Error signing test-certificate: %s", err))
}
Expand Down

0 comments on commit b3bc308

Please sign in to comment.