Skip to main content
Version: 5.7.x.x Java 8 ELS

Random object methods

MethodDescriptionSample
randByte = random:getBytes(bytes)bytes: Specify how many random bytes you needreturn: Specified number of random bytes as Lua string (note: this can be binary data).random = nevis.crypto.random.new()randBytes = random:getBytes(29)assert(randBytes.len() == 29)