aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/kernel/doc/src/logger_chapter.xml37
-rw-r--r--lib/kernel/src/Makefile2
-rw-r--r--lib/kernel/test/heart_SUITE.erl13
-rw-r--r--lib/ssl/doc/src/notes.xml16
-rw-r--r--lib/ssl/src/ssl.appup.src2
-rw-r--r--lib/ssl/test/ssl_basic_SUITE.erl7
-rw-r--r--lib/ssl/test/ssl_test_lib.erl5
-rw-r--r--lib/ssl/vsn.mk2
8 files changed, 44 insertions, 40 deletions
diff --git a/lib/kernel/doc/src/logger_chapter.xml b/lib/kernel/doc/src/logger_chapter.xml
index 0bc3b37476..88dcfbe8d9 100644
--- a/lib/kernel/doc/src/logger_chapter.xml
+++ b/lib/kernel/doc/src/logger_chapter.xml
@@ -539,12 +539,8 @@ changing_config(logger:handler_id(),logger:config(),logger:config()) -> {ok,logg
-module(myhandler).
-export([log/2]).
-log(#{msg:={report,R}},_) ->
- io:format("~p~n",[R]);
-log(#{msg:={string,S}},_) ->
- io:put_chars(S);
-log(#{msg:={F,A}},_) ->
- io:format(F,A).
+log(Log,#{formatter:={FModule,FConfig}) ->
+ io:put_chars(FModule:format(Log,FConfig)).
</code>
<p>A simple handler which prints to file could be implemented like
@@ -562,18 +558,13 @@ removing_handler(Id,#{myhandler_fd:=Fd}) ->
_ = file:close(Fd),
ok.
-log(#{msg:={report,R}},#{myhandler_fd:=Fd}) ->
- io:format(Fd,"~p~n",[R]);
-log(#{msg:={string,S}},#{myhandler_fd:=Fd}) ->
- io:put_chars(Fd,S);
-log(#{msg:={F,A}},#{myhandler_fd:=Fd}) ->
- io:format(Fd,F,A).
+log(Log,#{myhandler_fd:=Fd,formatter:={FModule,FConfig}}) ->
+ io:put_chars(Fd,FModule:format(Log,FConfig)).
</code>
- <p>Note that none of the above handlers have any overload
+ <note><p>The above handlers do not have any overload
protection, and all log events are printed directly from the
- client process. Neither do the handlers use the formatter or
- in any way add time or other metadata to the printed events.</p>
+ client process.</p></note>
<p>For examples of overload protection, please refer to the
implementation
@@ -582,14 +573,7 @@ log(#{msg:={F,A}},#{myhandler_fd:=Fd}) ->
</seealso>.</p>
<p>Below is a simpler example of a handler which logs through one
- single process, and uses the default formatter to gain a common
- look of the log events.</p>
- <p>It also uses the metadata field <c>report_cb</c>, if it exists,
- to print reports in the way the event issuer suggests. The
- formatter will normally do this, but if the handler either has
- an own default (as in this example) or if the
- given <c>report_cb</c> should not be used at all, then the
- handler must take care of this itself.</p>
+ single process.</p>
<code>
-module(myhandler).
-export([adding_handler/2, removing_handler/1, log/2]).
@@ -620,16 +604,9 @@ terminate(Reason,#{fd:=Fd}) ->
_ = file:close(Fd),
ok.
-do_log(Fd,#{msg:={report,R}} = Log, Config) ->
- Fun = maps:get(report_cb,Config,fun my_report_cb/1,
- {F,A} = Fun(R),
- do_log(Fd,Log#{msg=>{F,A},Config);
do_log(Fd,Log,#{formatter:={FModule,FConfig}}) ->
String = FModule:format(Log,FConfig),
io:put_chars(Fd,String).
-
-my_report_cb(R) ->
- {"~p",[R]}.
</code>
</section>
diff --git a/lib/kernel/src/Makefile b/lib/kernel/src/Makefile
index 702845512c..eeb8c6ab2f 100644
--- a/lib/kernel/src/Makefile
+++ b/lib/kernel/src/Makefile
@@ -146,7 +146,7 @@ HRL_FILES= ../include/file.hrl ../include/inet.hrl ../include/inet_sctp.hrl \
../include/net_address.hrl ../include/logger.hrl
INTERNAL_HRL_FILES= application_master.hrl disk_log.hrl \
- erl_epmd.hrl hipe_ext_format.hrl \
+ erl_epmd.hrl file_int.hrl hipe_ext_format.hrl \
inet_dns.hrl inet_res.hrl \
inet_boot.hrl inet_config.hrl inet_int.hrl \
inet_dns_record_adts.hrl \
diff --git a/lib/kernel/test/heart_SUITE.erl b/lib/kernel/test/heart_SUITE.erl
index 45032faf6d..22db24de5f 100644
--- a/lib/kernel/test/heart_SUITE.erl
+++ b/lib/kernel/test/heart_SUITE.erl
@@ -346,9 +346,16 @@ clear_cmd(Config) when is_list(Config) ->
get_cmd(Config) when is_list(Config) ->
{ok, Node} = start_check(slave, ?UNIQ_NODE_NAME),
- Cmd = "test",
- ok = rpc:call(Node, heart, set_cmd, [Cmd]),
- {ok, Cmd} = rpc:call(Node, heart, get_cmd, []),
+
+ ShortCmd = "test",
+ ok = rpc:call(Node, heart, set_cmd, [ShortCmd]),
+ {ok, ShortCmd} = rpc:call(Node, heart, get_cmd, []),
+
+ %% This would hang prior to OTP-15024 being fixed.
+ LongCmd = [$a || _ <- lists:seq(1, 160)],
+ ok = rpc:call(Node, heart, set_cmd, [LongCmd]),
+ {ok, LongCmd} = rpc:call(Node, heart, get_cmd, []),
+
stop_node(Node),
ok.
diff --git a/lib/ssl/doc/src/notes.xml b/lib/ssl/doc/src/notes.xml
index 4ad7da9486..34fe352d08 100644
--- a/lib/ssl/doc/src/notes.xml
+++ b/lib/ssl/doc/src/notes.xml
@@ -27,6 +27,22 @@
</header>
<p>This document describes the changes made to the SSL application.</p>
+<section><title>SSL 8.2.6</title>
+
+ <section><title>Fixed Bugs and Malfunctions</title>
+ <list>
+ <item>
+ <p>
+ Proper handling of clients that choose to send an empty
+ answer to a certificate request</p>
+ <p>
+ Own Id: OTP-15050</p>
+ </item>
+ </list>
+ </section>
+
+</section>
+
<section><title>SSL 8.2.5</title>
<section><title>Fixed Bugs and Malfunctions</title>
diff --git a/lib/ssl/src/ssl.appup.src b/lib/ssl/src/ssl.appup.src
index 4ad2a2f1fd..bfdd0c205b 100644
--- a/lib/ssl/src/ssl.appup.src
+++ b/lib/ssl/src/ssl.appup.src
@@ -1,7 +1,6 @@
%% -*- erlang -*-
{"%VSN%",
[
- {<<"8.2.4">>, [{load_module, ssl_cipher, soft_purge, soft_purge, []}]},
{<<"8\\..*">>, [{restart_application, ssl}]},
{<<"7\\..*">>, [{restart_application, ssl}]},
{<<"6\\..*">>, [{restart_application, ssl}]},
@@ -10,7 +9,6 @@
{<<"3\\..*">>, [{restart_application, ssl}]}
],
[
- {<<"8.2.4">>, [{load_module, ssl_cipher, soft_purge, soft_purge, []}]},
{<<"8\\..*">>, [{restart_application, ssl}]},
{<<"7\\..*">>, [{restart_application, ssl}]},
{<<"6\\..*">>, [{restart_application, ssl}]},
diff --git a/lib/ssl/test/ssl_basic_SUITE.erl b/lib/ssl/test/ssl_basic_SUITE.erl
index fe4f02f100..d3b13050e3 100644
--- a/lib/ssl/test/ssl_basic_SUITE.erl
+++ b/lib/ssl/test/ssl_basic_SUITE.erl
@@ -273,7 +273,8 @@ init_per_suite(Config0) ->
proplists:get_value(priv_dir, Config0)),
Config1 = ssl_test_lib:make_dsa_cert(Config0),
Config2 = ssl_test_lib:make_ecdsa_cert(Config1),
- Config = ssl_test_lib:make_ecdh_rsa_cert(Config2),
+ Config3 = ssl_test_lib:make_rsa_cert(Config2),
+ Config = ssl_test_lib:make_ecdh_rsa_cert(Config3),
ssl_test_lib:cert_options(Config)
catch _:_ ->
{skip, "Crypto did not start"}
@@ -3180,10 +3181,10 @@ der_input(Config) when is_list(Config) ->
Size = ets:info(CADb, size),
- SeverVerifyOpts = ssl_test_lib:ssl_options(server_opts, Config),
+ SeverVerifyOpts = ssl_test_lib:ssl_options(server_rsa_opts, Config),
{ServerCert, ServerKey, ServerCaCerts, DHParams} = der_input_opts([{dhfile, DHParamFile} |
SeverVerifyOpts]),
- ClientVerifyOpts = ssl_test_lib:ssl_options(client_opts, Config),
+ ClientVerifyOpts = ssl_test_lib:ssl_options(client_rsa_opts, Config),
{ClientCert, ClientKey, ClientCaCerts, DHParams} = der_input_opts([{dhfile, DHParamFile} |
ClientVerifyOpts]),
ServerOpts = [{verify, verify_peer}, {fail_if_no_peer_cert, true},
diff --git a/lib/ssl/test/ssl_test_lib.erl b/lib/ssl/test/ssl_test_lib.erl
index 4022f49077..8c27571d64 100644
--- a/lib/ssl/test/ssl_test_lib.erl
+++ b/lib/ssl/test/ssl_test_lib.erl
@@ -1597,6 +1597,8 @@ openssl_sane_dtls() ->
false;
"OpenSSL 1.0.2n" ++ _ ->
false;
+ "OpenSSL 1.0.2m" ++ _ ->
+ false;
"OpenSSL 1.0.0" ++ _ ->
false;
"OpenSSL" ++ _ ->
@@ -1768,9 +1770,12 @@ supports_ssl_tls_version(sslv2 = Version) ->
VersionFlag = version_flag(Version),
Exe = "openssl",
Args = ["s_client", VersionFlag],
+ [{trap_exit, Trap}] = process_info(self(), [trap_exit]),
+ process_flag(trap_exit, true),
Port = ssl_test_lib:portable_open_port(Exe, Args),
Bool = do_supports_ssl_tls_version(Port, ""),
consume_port_exit(Port),
+ process_flag(trap_exit, Trap),
Bool
end;
diff --git a/lib/ssl/vsn.mk b/lib/ssl/vsn.mk
index 0ff22c5eab..eb85a55717 100644
--- a/lib/ssl/vsn.mk
+++ b/lib/ssl/vsn.mk
@@ -1 +1 @@
-SSL_VSN = 8.2.5
+SSL_VSN = 8.2.6