We need the session key K(40byte) from a real session to validate the formula for 0x0512's digest
11:12 10 Dec 2025

I'm trying to integrate https://github.com/fjaros/wowchat (is an app that runs on a VPS or any computer, and can connect to wow private servers in order to relay discord and guild chat back and forth) into another custom client but their login protocol must have been changed. We're being kicked out after the 0x0512 packet which is tied to the login session.

w.g.GamePacketEncoder - SEND PACKET: 0512 - 5A 49 56 4F 57 45 4F 35 32 47 00 00 00 00 00 00 00 00 00 00 DF EC F5 59 E4 08 9D B0 7F A6 8C 04 8E 1F E0 C5 42 79 52 60
00:14:21.644 DEBUG w.c.ReconnectDelay - GET RECONNECT DELAY 10
00:14:21.644 INFO w.WoWChat$ - Disconnected from server! Reconnecting in 10 seconds...

My current plan is to reverse engineer the login protocol somehow around the 0x0512 knowing my real client's SRP values to then create a proper 0x0512 digest for the bot's login.

Knowing the value of A,B, s(salt), M1, M2 and our login/pass i'm trying to search for a private a and K for the same real login session.

Is this the right approach? Anyone knows about the best way to find the K(40byte) knowing these values? Or maybe I can attach a gdb hook to the real client's session that extracts K by itself.

scala encryption discord reverse-engineering