Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local function crypt(key, msg)
- local res = {}
- math.randomseed(key)
- for i = 1, #msg do
- res[i] = bit32.bxor(math.random(0, 255), msg:byte(i))
- end
- return string.char(unpack(res))
- end
- return {crypt = crypt}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement