mirror of
https://github.com/ribbybibby/ssl_exporter.git
synced 2025-02-19 19:59:47 +02:00
Fix private key decryption in tests
This commit is contained in:
parent
4c3308f819
commit
30c8ffb7c3
@ -31,9 +31,11 @@ func TestProbeHandler(t *testing.T) {
|
||||
t.Fatalf("Issue decrypting test client key")
|
||||
}
|
||||
|
||||
keyContent = pem.EncodeToMemory(&pem.Block{Type: keyBlock.Type, Bytes: keyBlockDecrypted})
|
||||
|
||||
emptyRootCAs := x509.NewCertPool()
|
||||
|
||||
certificate, _ := tls.X509KeyPair(certContent, keyBlockDecrypted)
|
||||
certificate, err := tls.X509KeyPair(certContent, keyContent)
|
||||
if err != nil {
|
||||
t.Fatalf(err.Error())
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user