Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local h = http.get "https://pastebin.com/raw/Frv3xkB9"
- local fn, err = load(h.readAll(), "@yafss")
- h.close()
- if not fn then error(err) end
- local yafss = fn()
- local root = settings.get "farm.root" or "/persistent/potatOS"
- fs.makeDir(root)
- local function randbytes(len)
- local out = ""
- for i = 1, len do
- out = out .. string.char(math.random(0, 255))
- end
- return out
- end
- local function APIs()
- local ID = math.random(0, 65534)
- local label = randbytes(math.random(0, 256))
- return {
- os = {
- getComputerID = function()
- return ID
- end,
- getComputerLabel = function()
- return label
- end,
- setComputerLabel = function()
- return "no."
- end
- },
- _HOST = "Potato Farm on " .. _HOST,
- potatOS = potatOS
- }
- end
- fs.makeDir(root)
- local startup = fs.combine(root, "startup")
- if not fs.exists(startup) then
- local f = fs.open(startup, "w")
- f.write([[shell.run "pastebin run RM13UGFa"]])
- f.close()
- end
- yafss(
- root,
- {},
- APIs(i),
- { URL = "https://pastebin.com/raw/hvy03JuM" }
- )
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement