Skip to content

Commit

Permalink
fix(certificate): properly throw errors when parsing certificate from…
Browse files Browse the repository at this point in the history
… the

vault

`get_certificate` was not handling certificate parsing errors after a
vault update. This fixes it.
  • Loading branch information
ms2008 committed Jan 22, 2025
1 parent d80ff4b commit d71566d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion kong/runloop/certificate.lua
Original file line number Diff line number Diff line change
Expand Up @@ -261,7 +261,7 @@ local function get_certificate(pk, sni_name, ws_id)
pk, sni_name, ws_id)

if certificate and hit_level ~= 3 and certificate["$refs"] then
certificate = parse_key_and_cert(kong.vault.update(certificate))
certificate, err = parse_key_and_cert(kong.vault.update(certificate))
end

return certificate, err
Expand Down

0 comments on commit d71566d

Please sign in to comment.