3

java.security.SecureRandom besides others has two methods: generateSeed(int numBytes) and nextBytes(byte[] bytes). The former gets entropy from the external source and is less predictable but slower, the latter uses PRNG sequence and is more predictable but much faster.

I want to have a single java.security.SecureRandom to seed a number of MersenneTwisterFast PRNGs, and my question is whether it is secure enough to seed them with nextBytes as long as SecureRandom has been seeded in a secure manner in the first place?

shpikachu
  • 147
  • 1
  • 3
  • 12
  • 2
    You may get better answers to this question if you ask it at http://security.stackexchange.com/ – Jules Feb 26 '14 at 10:10
  • Also: secure enough for what application? – Jules Feb 26 '14 at 10:11
  • Oh, blimey, didn't know about that, thank you! The application is fun casino, no real money whatsoever. – shpikachu Feb 26 '14 at 10:14
  • In case anyone interested, here is the clone of this question: http://security.stackexchange.com/questions/52300/how-secure-is-to-seed-prngs-with-the-sequences-from-csprng – shpikachu Feb 26 '14 at 13:43
  • 1
    OP has asked the question on Security.SE instead: http://security.stackexchange.com/questions/52300/how-secure-is-to-seed-prngs-with-the-sequences-from-csprng – SilverlightFox Feb 28 '14 at 08:55

0 Answers0