1 /* |
1 /* |
2 * Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved. |
2 * Copyright (c) 1996, 2014, Oracle and/or its affiliates. All rights reserved. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 * |
4 * |
5 * This code is free software; you can redistribute it and/or modify it |
5 * This code is free software; you can redistribute it and/or modify it |
6 * under the terms of the GNU General Public License version 2 only, as |
6 * under the terms of the GNU General Public License version 2 only, as |
7 * published by the Free Software Foundation. Oracle designates this |
7 * published by the Free Software Foundation. Oracle designates this |
37 * This class provides a cryptographically strong random number |
37 * This class provides a cryptographically strong random number |
38 * generator (RNG). |
38 * generator (RNG). |
39 * |
39 * |
40 * <p>A cryptographically strong random number |
40 * <p>A cryptographically strong random number |
41 * minimally complies with the statistical random number generator tests |
41 * minimally complies with the statistical random number generator tests |
42 * specified in <a href="http://csrc.nist.gov/cryptval/140-2.htm"> |
42 * specified in |
|
43 * <a href="http://csrc.nist.gov/publications/fips/fips140-2/fips1402.pdf"> |
43 * <i>FIPS 140-2, Security Requirements for Cryptographic Modules</i></a>, |
44 * <i>FIPS 140-2, Security Requirements for Cryptographic Modules</i></a>, |
44 * section 4.9.1. |
45 * section 4.9.1. |
45 * Additionally, SecureRandom must produce non-deterministic output. |
46 * Additionally, SecureRandom must produce non-deterministic output. |
46 * Therefore any seed material passed to a SecureRandom object must be |
47 * Therefore any seed material passed to a SecureRandom object must be |
47 * unpredictable, and all SecureRandom output sequences must be |
48 * unpredictable, and all SecureRandom output sequences must be |
48 * cryptographically strong, as described in |
49 * cryptographically strong, as described in |
49 * <a href="http://www.ietf.org/rfc/rfc1750.txt"> |
50 * <a href="http://tools.ietf.org/html/rfc4086"> |
50 * <i>RFC 1750: Randomness Recommendations for Security</i></a>. |
51 * <i>RFC 4086: Randomness Requirements for Security</i></a>. |
51 * |
52 * |
52 * <p>A caller obtains a SecureRandom instance via the |
53 * <p>A caller obtains a SecureRandom instance via the |
53 * no-argument constructor or one of the {@code getInstance} methods: |
54 * no-argument constructor or one of the {@code getInstance} methods: |
54 * |
55 * |
55 * <pre> |
56 * <pre> |