Changeset

6708:d2beb98ece29

util.x509: Tell LuaSec we want UTF-8 data
author Kim Alvefur <zash@zash.se>
date Mon, 18 May 2015 21:32:05 +0200
parents 6707:06cdd4afaaf9
children 6709:b6eff3ba13de
files util/x509.lua
diffstat 1 files changed, 3 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/util/x509.lua	Mon May 18 21:00:41 2015 +0200
+++ b/util/x509.lua	Mon May 18 21:32:05 2015 +0200
@@ -148,6 +148,9 @@
 end
 
 function verify_identity(host, service, cert)
+	if cert.setencode then
+		cert:setencode("utf8");
+	end
 	local ext = cert:extensions()
 	if ext[oid_subjectaltname] then
 		local sans = ext[oid_subjectaltname];