diff options
author | Mike Pall <mike> | 2019-12-08 19:01:06 +0100 |
---|---|---|
committer | Mike Pall <mike> | 2019-12-08 19:01:06 +0100 |
commit | a75d13c63a118ab501affe6fb0baab1d692a3df9 (patch) | |
tree | 6e4030a9dad79d1a15d64fdc4449757f52fb3794 | |
parent | c6c6e3b416635a528a711ed1986b054287a7c491 (diff) | |
download | luajit-a75d13c63a118ab501affe6fb0baab1d692a3df9.tar.gz luajit-a75d13c63a118ab501affe6fb0baab1d692a3df9.tar.bz2 luajit-a75d13c63a118ab501affe6fb0baab1d692a3df9.zip |
Add note about the unsuitabilty of math.random() for crypto.
-rw-r--r-- | doc/extensions.html | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/doc/extensions.html b/doc/extensions.html index fa412e0e..9da38359 100644 --- a/doc/extensions.html +++ b/doc/extensions.html | |||
@@ -212,6 +212,10 @@ for every call. The result is uniformly distributed between 0.0 and 1.0. | |||
212 | It's correctly scaled up and rounded for <tt>math.random(n [,m])</tt> to | 212 | It's correctly scaled up and rounded for <tt>math.random(n [,m])</tt> to |
213 | preserve uniformity. | 213 | preserve uniformity. |
214 | </p> | 214 | </p> |
215 | <p> | ||
216 | Important: Neither this nor any other PRNG based on the simplistic | ||
217 | <tt>math.random()</tt> API is suitable for cryptographic use. | ||
218 | </p> | ||
215 | 219 | ||
216 | <h3 id="io"><tt>io.*</tt> functions handle 64 bit file offsets</h3> | 220 | <h3 id="io"><tt>io.*</tt> functions handle 64 bit file offsets</h3> |
217 | <p> | 221 | <p> |