1
0
Fork 0
mirror of https://github.com/Luzifer/vault-openvpn.git synced 2024-11-09 16:50:04 +00:00

Fix: Don't panic on non existent PKI path

Signed-off-by: Knut Ahlers <knut@ahlers.me>
This commit is contained in:
Knut Ahlers 2017-10-10 10:17:19 +02:00
parent 4d62cd0789
commit 3fef524e3d
Signed by: luzifer
GPG key ID: DC2729FDD34BE99E

View file

@ -327,6 +327,10 @@ func fetchValidCertificatesFromVault() ([]*x509.Certificate, error) {
return res, err
}
if secret == nil {
return nil, errors.New("Was not able to read list of certificates")
}
if secret.Data == nil {
return res, errors.New("Got no data from backend")
}