This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
justync7's profile picture

[LUA]Decrypting a string.dump?

Started by justync7, 13 October 2012 - 04:43 PM
justync7 #1
Posted 13 October 2012 - 06:43 PM
Im wondering how you can decrypt a string.dump and i cant seem to figure out how. Any help?
Kingdaro #2
Posted 13 October 2012 - 06:50 PM
I'm pretty sure you could just loadstring() a dump.
Kolpa #3
Posted 13 October 2012 - 06:52 PM
Im wondering how you can decrypt a string.dump and i cant seem to figure out how. Any help?

you use

local func_str = string.dump(function)
local func = loadstring(func_str)
justync7 #4
Posted 13 October 2012 - 06:59 PM
i want to get the code not run it.
Xfel #5
Posted 13 October 2012 - 07:00 PM
It depends on what you want. The dump function simply writes down the compiled code, which can be loaded again, however, you will not be able to decrypt this code to get the original lua code.
PixelToast #6
Posted 13 October 2012 - 08:53 PM
unless you have read deeply into the lua compiler :3
its a bit confusing though because i dont know c++ :C
sorry but its kind of a secret >_>