diff options
| author | sD <stoned@derpymail.org> | 2019-12-31 00:34:46 +0100 |
|---|---|---|
| committer | sD <stoned@derpymail.org> | 2019-12-31 00:34:46 +0100 |
| commit | ddec46497e13ca577e3b8e238d00174b2617635c (patch) | |
| tree | bc1b739aba3f913b5aca914d50ef1566757cb091 /webAO | |
| parent | 88f41707fbe74433ca27a351697095ac09613963 (diff) | |
don't read the ID from the cookie, as people easily change it
Diffstat (limited to 'webAO')
| -rw-r--r-- | webAO/client.js | 9 | ||||
| -rw-r--r-- | webAO/master.js | 8 |
2 files changed, 9 insertions, 8 deletions
diff --git a/webAO/client.js b/webAO/client.js index dc4aca5..ee6bad7 100644 --- a/webAO/client.js +++ b/webAO/client.js @@ -54,12 +54,13 @@ const fp = new Fingerprint({ /** An emulated, semi-unique HDID that is generally safe for HDID bans. */ const cookieid = getCookie("fingerprint"); let hdid; -if (cookieid) { - hdid = cookieid; -} else { + + + + hdid = fp.get(); setCookie("fingerprint",hdid); -} + console.log(`Your emulated HDID is ${hdid}`); let lastICMessageTime = new Date(0); diff --git a/webAO/master.js b/webAO/master.js index 863c311..5d51d24 100644 --- a/webAO/master.js +++ b/webAO/master.js @@ -11,12 +11,12 @@ const fp = new Fingerprint({ /** An emulated, semi-unique HDID that is generally safe for HDID bans. */ const cookieid = getCookie("fingerprint"); let hdid; -if (cookieid) { - hdid = cookieid; -} else { + + + hdid = fp.get(); setCookie("fingerprint",hdid); -} + console.log(`Your emulated HDID is ${hdid}`); let oldLoading = false; |
