1
0
mirror of https://github.com/kepler155c/opus synced 2024-11-05 00:16:16 +00:00
opus/sys/apps/password.lua
2019-06-27 21:08:46 -04:00

11 lines
283 B
Lua

local Security = require('security')
local SHA2 = require('crypto.sha2')
local Terminal = require('terminal')
local password = Terminal.readPassword('Enter new password: ')
if password then
Security.updatePassword(SHA2.digest(password):toHex())
print('Password updated')
end