This commit is contained in:
Julian Brammer 2024-06-08 20:59:08 +02:00
parent 32a4b39c04
commit 2f48218363

View File

@ -11,12 +11,14 @@ end
local function createPwHash()
local inputConfirmed = false
while not inputConfirmed do
basic.clearDisplay()
write("Create a new password: ")
local input = read("*")
pwHash = hash.digestStr(input .. os.getComputerID())
write("Confirm new password: ")
local inputConfirmed = pwHash == hash.digestStr(read("*") .. os.getComputerID())
local inputConfirmation = read("*")
local inputConfirmed = pwHash == inputConfirmation
end
return pwHash
end