diff options
author | Ingela Anderton Andin <[email protected]> | 2016-04-25 11:44:07 +0200 |
---|---|---|
committer | Ingela Anderton Andin <[email protected]> | 2016-04-25 11:44:07 +0200 |
commit | 5f67ca5b3d0c13dfbe936fcfa08621eef00d53cf (patch) | |
tree | 40ed1c7ace8863dcd3662d2390b1e9195fa848cd /lib/public_key | |
parent | 79f3e0ef07eff9d22fb1735d77813142da493bfc (diff) | |
parent | 09bd54f2d28cb2981028f55dc93279a98021e8d1 (diff) | |
download | otp-5f67ca5b3d0c13dfbe936fcfa08621eef00d53cf.tar.gz otp-5f67ca5b3d0c13dfbe936fcfa08621eef00d53cf.tar.bz2 otp-5f67ca5b3d0c13dfbe936fcfa08621eef00d53cf.zip |
Merge branch 'ingela/otp/deprecated-rand_bytes/OTP-13214'
* ingela/otp/deprecated-rand_bytes/OTP-13214:
stdlib: Remove use of crypto:rand_bytes/1
compiler: Remove use of crypto:rand_bytes/1
ssh: Remove use of crypto:rand_bytes/1
public_key: Remove use of crypto:rand_bytes/1
ssl: Remove use of crypto:rand_bytes/1
crypto: Deprecate rand_bytes/1
Diffstat (limited to 'lib/public_key')
-rw-r--r-- | lib/public_key/doc/src/public_key.xml | 2 | ||||
-rw-r--r-- | lib/public_key/test/public_key_SUITE.erl | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/lib/public_key/doc/src/public_key.xml b/lib/public_key/doc/src/public_key.xml index 6923066da7..04daee460f 100644 --- a/lib/public_key/doc/src/public_key.xml +++ b/lib/public_key/doc/src/public_key.xml @@ -118,7 +118,7 @@ <p><c> not_encrypted | cipher_info()}</c></p></item> <tag><c>cipher_info() = </c></tag> - <item><p><c>{"RC2-CBC" | "DES-CBC" | "DES-EDE3-CBC", crypto:rand_bytes(8)</c></p> + <item><p><c>{"RC2-CBC" | "DES-CBC" | "DES-EDE3-CBC", crypto:strong_rand_bytes(8)</c></p> <p><c>| {#'PBEParameter{}, digest_type()} | #'PBES2-params'{}}</c></p> </item> diff --git a/lib/public_key/test/public_key_SUITE.erl b/lib/public_key/test/public_key_SUITE.erl index be1a4472e9..51050c4480 100644 --- a/lib/public_key/test/public_key_SUITE.erl +++ b/lib/public_key/test/public_key_SUITE.erl @@ -199,7 +199,7 @@ encrypted_pem(Config) when is_list(Config) -> RSAKey = public_key:der_decode('RSAPrivateKey', DerRSAKey), - Salt0 = crypto:rand_bytes(8), + Salt0 = crypto:strong_rand_bytes(8), Entry0 = public_key:pem_entry_encode('RSAPrivateKey', RSAKey, {{"DES-EDE3-CBC", Salt0}, "1234abcd"}), RSAKey = public_key:pem_entry_decode(Entry0,"1234abcd"), @@ -208,7 +208,7 @@ encrypted_pem(Config) when is_list(Config) -> [{'RSAPrivateKey', _, {"DES-EDE3-CBC", Salt0}}] = erl_make_certs:pem_to_der(Des3KeyFile), - Salt1 = crypto:rand_bytes(8), + Salt1 = crypto:strong_rand_bytes(8), Entry1 = public_key:pem_entry_encode('RSAPrivateKey', RSAKey, {{"DES-CBC", Salt1}, "4567efgh"}), DesKeyFile = filename:join(Datadir, "des_client_key.pem"), |