Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Can this script be reverse-engineered to find the random seed?

Asked by 7 years ago

local digits = {'1', '2', '3', '4', '5', '6', '8', '9'} math.randomseed(os.time()) local result = digits[math.random(8)] for i = 2, 50 do result = result..digits[math.random(8)] end print(result)

--> 88854243421464255299891111895292628431988589634664

My end goal is to find what os.time() returned when this script was run. Is that feasible?

0
This script uses broken math.random(). Tested. When you declare result, digits[math.random(8)] will keep returning the same number. Solution: math.randomseed(os.time()) ;math.random();math.random();math.random() Programical 653 — 7y
0
I recommend asking this on https://crypto.stackexchange.com Programical 653 — 7y

Answer this question