Added storing of adminpasswords. Still in cleartext, must be encrypted some way

This commit is contained in:
Kasper Rynning-Tønnesen
2015-04-22 12:08:19 +02:00
parent da4b56c926
commit 601b0c012b
2 changed files with 6 additions and 1 deletions

View File

@@ -49,7 +49,7 @@ socket.on("pw", function(msg)
refresh_scroll();
localStorage.setItem("passord_i_klartekst_lol", msg);
localStorage.setItem(chan.toLowerCase(), msg);
Materialize.toast("Correct password. You now have access to the sacred relam of The Admin.", 4000);
});

View File

@@ -114,6 +114,11 @@ $(document).ready(function()
firstScriptTag = document.getElementsByTagName('script')[0];
firstScriptTag.parentNode.insertBefore(tag, firstScriptTag);
if(localStorage[chan.toLowerCase()])
{
socket.emit("password", localStorage[chan.toLowerCase()]);
}
if($("#chan").html().toLowerCase() == "jazz")
{
//loadjsfile("static/js/jazzscript.js");