🔀Seeded RNG

by Ricardo Fernández Serrata

Version 7 (September 12, 2021)

Download (124 downloads)

Simple Pseudo-Random Number Generator based on MD5 and XOR. It uses XOR to truncate the MD5 digest to 32b/4B/8 hex-chars by "consuming" all Bytes to ensure that no data is discarded.

The period length is very likely to be 2^32 - 1 but I haven't tested it.

This PRNG is NOT cryptographically secure since MD5 is not secure. I only used MD5 because it's more random than CRC32.

All AM hash functions read input as UTF-8, but AM and Java use UTF-16 natively, this is the reason why I use `md5(hexEncode(s, "UTF-16BE"), "h")`, to make the hash correct, and to support All Unicode chars.

To get Truly Random numbers without a server, use: llamalab.com/automate/community/flows/39114

4.6 average rating from 5 reviews

5 stars
3
4 stars
2
3 stars
0
2 stars
0
1 star
0
Reports
0

Rate and review within the app in the Community section.