From f191d62974da073dcf0c6c048b562a9bf27a30f5 Mon Sep 17 00:00:00 2001 From: Russell Branca Date: Tue, 26 Sep 2017 17:47:13 +0000 Subject: Ensure chttpd pids have a proper random seed --- src/chttpd/src/chttpd.erl | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/chttpd/src/chttpd.erl b/src/chttpd/src/chttpd.erl index 6be0d1848..fd7de8e21 100644 --- a/src/chttpd/src/chttpd.erl +++ b/src/chttpd/src/chttpd.erl @@ -154,6 +154,10 @@ handle_request_int(MochiReq) -> ok = mochiweb_socket:setopts(MochiReq:get(socket), SocketOpts) end, + % Set random seed + <> = crypto:rand_bytes(12), + random:seed({A,B,C}), + % for the path, use the raw path with the query string and fragment % removed, but URL quoting left intact RawUri = MochiReq:get(raw_path), -- cgit v1.2.1