From be672f8a37667683bb5d14e61fbd5e759b8750c5 Mon Sep 17 00:00:00 2001 From: Kim Alvefur Date: Thu, 26 Sep 2013 16:55:39 +0200 Subject: util.x509: Only compare identity with oid-on-xmppAddr for XMPP services --- util/x509.lua | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/util/x509.lua b/util/x509.lua index 19d4ec6d..857f02a4 100644 --- a/util/x509.lua +++ b/util/x509.lua @@ -161,7 +161,9 @@ function verify_identity(host, service, cert) if sans[oid_xmppaddr] then had_supported_altnames = true - if compare_xmppaddr(host, sans[oid_xmppaddr]) then return true end + if service == "_xmpp-client" or service == "_xmpp-server" then + if compare_xmppaddr(host, sans[oid_xmppaddr]) then return true end + end end if sans[oid_dnssrv] then -- cgit v1.2.3