aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorRaimo Niskanen <[email protected]>2017-11-29 08:39:48 +0100
committerRaimo Niskanen <[email protected]>2017-12-04 14:48:35 +0100
commit78a9a09af9216a2dea454f561e0774e67a15c361 (patch)
tree93de57300b798a655532efb85930beaabcc7327c /lib
parentad548db90d739a5fa5498d2b9b227bc6b01e9e73 (diff)
downloadotp-78a9a09af9216a2dea454f561e0774e67a15c361.tar.gz
otp-78a9a09af9216a2dea454f561e0774e67a15c361.tar.bz2
otp-78a9a09af9216a2dea454f561e0774e67a15c361.zip
Stop checking DNS name for SNI
Diffstat (limited to 'lib')
-rw-r--r--lib/ssl/src/ssl.erl20
1 files changed, 12 insertions, 8 deletions
diff --git a/lib/ssl/src/ssl.erl b/lib/ssl/src/ssl.erl
index 4007e44a83..4bff9fdf39 100644
--- a/lib/ssl/src/ssl.erl
+++ b/lib/ssl/src/ssl.erl
@@ -992,17 +992,21 @@ validate_option(next_protocols_advertised, Value) when is_list(Value) ->
Value;
validate_option(next_protocols_advertised, undefined) ->
undefined;
-validate_option(server_name_indication = Opt, Value) when is_list(Value) ->
+validate_option(server_name_indication, Value) when is_list(Value) ->
%% RFC 6066, Section 3: Currently, the only server names supported are
%% DNS hostnames
- case inet_parse:domain(Value) of
- false ->
- throw({error, {options, {{Opt, Value}}}});
- true ->
- Value
- end;
-validate_option(server_name_indication, undefined = Value) ->
+ %% case inet_parse:domain(Value) of
+ %% false ->
+ %% throw({error, {options, {{Opt, Value}}}});
+ %% true ->
+ %% Value
+ %% end;
+ %%
+ %% But the definition seems very diffuse, so let all strings through
+ %% and leave it up to public_key to decide...
Value;
+validate_option(server_name_indication, undefined) ->
+ undefined;
validate_option(server_name_indication, disable) ->
disable;