-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathfinish_script.js
27 lines (26 loc) · 970 Bytes
/
finish_script.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
function final_code() {
var password =
document.getElementById("password0").value +
document.getElementById("password1").value +
document.getElementById("password2").value +
document.getElementById("password3").value +
document.getElementById("password4").value +
document.getElementById("password5").value +
document.getElementById("password6").value +
document.getElementById("password7").value +
document.getElementById("password8").value +
document.getElementById("password9").value;
var sha_password = SHA256(
password.replace(/ /g, "")
);
var user_code = sha_password.substring(0, 8).toUpperCase();
if (
SHA256(user_code) ==
"3f7c824b21af8694d89f3af96fe9210812b31bee1651e3ed433a18bf8c66affd"
) {
document.getElementById("finish-code").innerHTML =
'Finish code: <span id="code">' + user_code + "</span>";
} else {
document.getElementById("finish-code").innerHTML = "";
}
}