From f1de8e8c76e612943d77ac887acdd35e1904445f Mon Sep 17 00:00:00 2001 From: Shay Nehmad Date: Sat, 11 Apr 2020 12:45:12 +0300 Subject: [PATCH] openssl needs to be able to read the .rnd file --- monkey/monkey_island/linux/create_certificate.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/monkey/monkey_island/linux/create_certificate.sh b/monkey/monkey_island/linux/create_certificate.sh index 5aea0b310..78d1b8712 100644 --- a/monkey/monkey_island/linux/create_certificate.sh +++ b/monkey/monkey_island/linux/create_certificate.sh @@ -8,7 +8,11 @@ server_root=${1:-"./cc"} # https://github.com/openssl/openssl/commit/0f58220973a02248ca5c69db59e615378467b9c8#diff-8ce6aaad88b10ed2b3b4592fd5c8e03a # for more details. dd bs=1024 count=2 ~/.rnd +chmod 666 ~/.rnd openssl genrsa -out "$server_root"/server.key 2048 openssl req -new -key "$server_root"/server.key -out "$server_root"/server.csr -subj "/C=GB/ST=London/L=London/O=Global Security/OU=Monkey Department/CN=monkey.com" openssl x509 -req -days 366 -in "$server_root"/server.csr -signkey "$server_root"/server.key -out $server_root/server.crt + +# Shove some new random data into the file to override the original seed. +dd bs=1024 count=2 ~/.rnd