Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --Created with Packager by CrazedProgrammer
- b='ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/' function frombase64(data) data = string.gsub(data, '[^'..b..'=]', '') return (data:gsub('.', function(x) if (x == '=') then return '' end local r,f='',(b:find(x)-1) for i=6,1,-1 do r=r..(f%2^i-f%2^(i-1)>0 and '1' or '0') end return r; end):gsub('%d%d%d?%d?%d?%d?%d?%d?', function(x) if (#x ~= 8) then return '' end local c=0 for i=1,8 do c=c+(x:sub(i,i)=='1' and 2^(8-i) or 0) end return string.char(c) end)) end function lzw_decode(s) local str = { } for i=1,#s/2,1 do table.insert(str, s:byte(i * 2 - 1) * 256 + s:byte(i * 2)) end local dict_size = 256 local dict = {} for i = 0, dict_size-1 do dict[i] = string.char(i) end local w = string.char(str[1]) local result = w for i = 2, #str do local k = str[i] local entry = '' if dict[k] then entry = dict[k] elseif k == dict_size then entry = w .. w:sub(1,1) else return nil end result = result .. entry dict[dict_size] = w .. entry:sub(1,1) dict_size = dict_size + 1 w = entry end return result end d = 'AA4vZ2VuZXJpY01vZGVybgEAELIACgAAAAkAUwBjAGgAZQBtAGEAdABpAGMABwAAAAYAQgBsAG8AYwBrAHMAAAAAACYAZAACARkBGgEbARwBHQEeAAIAxQC4ASEBIwEiASUBJAEnASYBKQEgALgBKwEtASEBGwEhARUBMgEzATMBLwEZAS8BOAEsARoBMQE0AT0AAAE5AS4BLAE2ATcAuAE+AT0BQwFAAUMBKwFGATQBSQFCAU8BMAFFAUwBMgE5AAMBVgFXAAMBOwEpASgBXAFbASoBIQADAAUBYgFiAVkBRAFBAWcBTgErAWEBYwAFAWUBaAFQAWkBVQFsAW0BWgFBAWABVwFtASgBeAFsAW4BTgFrAXMBgAF8AXUBOQEhAYEBhgFkAYMBTwGFAAUAIQGHAXMBfQFwASUBYgGNAY4BYwGQAXYAuAGTAZUBlgGJASsBmwFYAVcBnQFgAZUAAwFdAWAB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AgBpAGQDvwBDAQUAcwB0AAAH3QffARUAEwfiB+QAAAABB+YFjwfoB+oH7AfuAAAH8AfyAAUH9AfZB/cH+QEyABYH/QEVAAYH5QWYB+8H8QV6AEQATABEAGUH6wBjAHQAbwByB/gH/wf6AAAAFwgRAQ0IFAWPCBYH8gAKCBkIGwgdCB8IIQgOARUIEAf/B+MIEggpAAAACwgrCBgIGggcAGUIHgggCCIH3gEyCCYINgf+CAABMgg7CAcIFwgtCD4IMAhCCDMAAAg1AAEINwgoB/8IAQYTCDwITggvCEAIMQhDCCQIRghVCEgIWQAMCFsILgg/CEEIMggjBZgIJwFtCFgH5wO/CAQAbQftATMIPAgKB/UIDQhsCDQIJwgTCHAIKghMCCwIaAhQCGsIRAEVCGIIVgh+CEkIgAgICD0IXQhqCGAH4Ah9CDkADggDB+sIdAgGCI0IeAgMCJEH+wiTCH8AAAiVCHIIlwh1B3EIgQfzCHkInQhTCJ8IiwihCGcITwheCFEIewglCKwIWQAOCK8IjwhfBiAABABuAG8H6wc6CIYAAAAVCCcAAgg5AA8IdwBNAHUAcwEKB/8GvAi9B+sABAhSABgIxAjGCMgIygjMCLsIzwBlCMAIJAjDCEcBFQjACFkIxwinAAUIyQjLAGMIzQi8CL4I2wjSCCcI4QEyCOMImgjmCMwIUgAKCG4IxgiWCAUIdgjkCAsH9gEBAAAACAfVB9cAaQfZBYYGHAAGAEwAZQBuAGcAdABoAAAAHAYoAAkAVwBFAE8CHgBzCBwAWADDAL8JGgkcAL4JEQkTCRUAZgkXAHQAWQEzCR8JFAVlAGcAaQBuAFoJHAkbALsH4QEBCSAJFggcAFoISgkHAEgAZQBpAGcAaAf3CPYJMgkoCTsJKwklARUAIAknAE8JKQkrCRkJGwkbALoAwwC2BhwABQBXB/EJDQAAABsAAA==' data = frombase64(d) print('Where do you want to extract pls?') dir = read() if dir:sub(1,1) ~= '/' then dir = '/'..fs.getDir(shell.getRunningProgram())..'/'..dir end fs.delete(dir) local i = 1 local path = '' while i <= #data do local c = data:byte(i) if c == 0 then i = i + 1 local l = data:byte(i) path = dir..'/'..data:sub(i + 1, i + l) i = i + l + 1 elseif c == 1 then i = i + 3 local l = data:byte(i - 2) * 65536 + data:byte(i - 1) * 256 + data:byte(i) local f = fs.open(path, 'w') f.write(lzw_decode(data:sub(i + 1, i + l))) f.close() i = i + l + 1 elseif c == 2 then fs.makeDir(path) i = i + 1 end end print('Extraced to '..dir..'.')
Add Comment
Please, Sign In to add comment