WowConnection::SetEncryption
function · net · orchestration
- Address
0x5b73c0· 68 bytes, up to0x5b7403- Signature
void __thiscall (WowConnection *this, uint8_t enable)- Meaning
- Turns the header cipher on or off and resets both directions to key index 0 and previous byte 0
- Confidence
- verified, proof one
- Finding
- net/wire#header-cipher
Finding: Header cipher in net: the wire
Once armed, the connection ciphers the first h + 4 bytes of every packet it sends and the
first h + 2 bytes of every packet it receives, h being that packet's size-header length:
the size header and the opcode. Bodies stay in clear. With a 40-byte key K, an index j
and a feedback byte f, one state per direction:
- send:
c = (K[j] ^ p) + f, thenf = c; - receive:
p = K[j] ^ (c − f), thenf = c; - after each byte,
j = (j + 1) mod 40. Arithmetic is modulo 256.
The index and feedback carry over from packet to packet. Arming zeroes both states.
The derivation is in the doc.
Callers 2
- NetClient::Connect net
- NetClient::Send net
Callees 2
- SCritSect::Enter storm
- SCritSect::Leave storm
Calls and jumps by a bare address, from tables/calls.tsv.