Update #36 - Fix incorrect use of arithmetic shift, more capes

This commit is contained in:
lax1dude
2024-06-23 17:02:58 -07:00
parent 7425179b36
commit cc1fe13421
60 changed files with 421 additions and 210 deletions

View File

@ -191,12 +191,12 @@ public class ConnectionHandshake {
int passLen = password.length();
digest.update((byte)((passLen >> 8) & 0xFF));
digest.update((byte)((passLen >>> 8) & 0xFF));
digest.update((byte)(passLen & 0xFF));
for(int i = 0; i < passLen; ++i) {
char codePoint = password.charAt(i);
digest.update((byte)((codePoint >> 8) & 0xFF));
digest.update((byte)((codePoint >>> 8) & 0xFF));
digest.update((byte)(codePoint & 0xFF));
}