Software /
code /
prosody-modules
Diff
mod_client_certs/mod_client_certs.lua @ 712:227d48f927ff
mod_client_certs: Strip x509 data
author | Florian Zeitz <florob@babelmonkeys.de> |
---|---|
date | Tue, 12 Jun 2012 14:00:57 +0200 |
parent | 709:151743149f07 |
child | 713:88ef66a65b13 |
line wrap: on
line diff
--- a/mod_client_certs/mod_client_certs.lua Mon Jun 11 16:54:32 2012 +0200 +++ b/mod_client_certs/mod_client_certs.lua Tue Jun 12 14:00:57 2012 +0200 @@ -106,7 +106,7 @@ end local can_manage = key_info:get_child("no-cert-management", xmlns_saslcert) ~= nil; - local x509cert = key_info:get_child_text("x509cert"); + local x509cert = key_info:get_child_text("x509cert"):gsub("^%s*(.-)%s*$", "%1"); local cert = x509.cert_from_pem( "-----BEGIN CERTIFICATE-----\n"