Posted 27 March 2012 - 02:31 AM
The New addition I'm adding to my basic operating system is a changepassword program. since I don't know much lua, I have no idea how to do this. (but I know it is possible to do). When starting the program, it should look like this:
This is the program that it edits the password from:
Thanks for helping, i'll add whoever helps with this' name to the credits.
Current Password: (after putting in the correct password, it prints out the next line) New Password: Comfirm New Password: (If any of these are incorrect, it should reboot the computer.)
This is the program that it edits the password from:
term.clear()
term.setCursorPos(1,1)
write("---------------------------------------------")
print("Welcome to RampageIndustries operating system V1.2 beta")
print("---------------------------------------------")
print("")
print("Password:")
correctpass = "admin"
pass = read("*")
if pass == (correctpass)
then term.clear()
term.setCursorPos(1,1)
print("Welcome!")
else print("")
write("Incorrect! Rebooting!")
sleep(2)
os.reboot() end if correctpass == "admin" then
term.clear()
term.setCursorPos(1,1)
print("It appears that you have the default password. Type changepass to change it. else sleep(1) end
Thanks for helping, i'll add whoever helps with this' name to the credits.
Edited on 27 March 2012 - 12:35 AM