@@ -62,18 +62,19 @@ <h1 style="margin-bottom:20px;">Zero Bot Gate</h1>
6262 "0zv0ja7ZCbBF3EdC0a+lYH/sHXXrceh3uNKC9VW/SIM=" // 'this is a test'
6363 ]
6464
65- async function hash ( pass ) {
65+ function hash ( pass ) {
6666 var hash = CryptoJS . SHA256 ( pass + "noAI" ) ;
6767 hash = hash . toString ( CryptoJS . enc . Base64 ) ;
68- console . log ( " > hashed " + pass + " into " + hash ) ;
68+ console . log ( " hashed " + pass + " into " + hash ) ;
6969 return hash ;
7070 }
7171
72- async function check ( pass ) {
72+ function check ( pass ) {
7373
7474 for ( const stored of data ) {
7575 const match = ( pass === stored ) ;
76- console . log ( "checking " + pass + " against " + stored ) ;
76+ console . log ( " checking " + pass + " against " + stored ) ;
77+ console . log ( " > returned " + match ) ;
7778 if ( match ) return true ;
7879 }
7980 return false ;
@@ -84,8 +85,9 @@ <h1 style="margin-bottom:20px;">Zero Bot Gate</h1>
8485 const input = await document . getElementById ( "in" ) ;
8586 const pass = input . value ;
8687 console . log ( "password: " + pass ) ;
87- console . log ( "hashed: " + await hash ( pass ) ) ;
88- if ( check ( await hash ( pass ) ) ) {
88+ console . log ( "hashed: " + hash ( pass ) ) ;
89+ console . log ( "checkign against data" ) ;
90+ if ( check ( hash ( pass ) ) ) {
8991 console . log ( "APROVED" ) ;
9092 } else {
9193 console . log ( "DENIED" ) ;
0 commit comments