aboutsummaryrefslogtreecommitdiffstats
path: root/lib/public_key/src/pubkey_cert.erl
diff options
context:
space:
mode:
authorHans Nilsson <[email protected]>2014-03-07 11:04:42 +0100
committerHans Nilsson <[email protected]>2014-03-26 10:13:56 +0100
commit8c8999af805265704ce0a3029c85a33f4d42c145 (patch)
tree3ffc2f9fca6e27aea7eeb6d418be9ac63ffed0f7 /lib/public_key/src/pubkey_cert.erl
parent9756dcd97cd819c9b2d64c35dd36550f99600e92 (diff)
downloadotp-8c8999af805265704ce0a3029c85a33f4d42c145.tar.gz
otp-8c8999af805265704ce0a3029c85a33f4d42c145.tar.bz2
otp-8c8999af805265704ce0a3029c85a33f4d42c145.zip
ssl, pubkey: Code and test adjustments
Diffstat (limited to 'lib/public_key/src/pubkey_cert.erl')
-rw-r--r--lib/public_key/src/pubkey_cert.erl7
1 files changed, 5 insertions, 2 deletions
diff --git a/lib/public_key/src/pubkey_cert.erl b/lib/public_key/src/pubkey_cert.erl
index 6272fae91b..ae517ca642 100644
--- a/lib/public_key/src/pubkey_cert.erl
+++ b/lib/public_key/src/pubkey_cert.erl
@@ -344,8 +344,11 @@ match_name(uniformResourceIdentifier, URI, [PermittedName | Rest]) ->
incomplete ->
false;
{_, _, Host, _, _} ->
- match_name(fun is_valid_host_or_domain/2, Host,
- PermittedName, Rest)
+ PN = case split_uri(PermittedName) of
+ {_, _, PNhost, _, _} -> PNhost;
+ _X -> PermittedName
+ end,
+ match_name(fun is_valid_host_or_domain/2, Host, PN, Rest)
end;
match_name(emailAddress, Name, [PermittedName | Rest]) ->