REDIVIVUS

Proposals / #1343

Mac SRP_HashBigNumToU32: void __cdecl (D2Srp* pSrp, void** ppBigNum, uint32_t* pHashOut)

checked · by KierTaylor · submitted 2026-11-06

The Mac body reads [EBP+0xc] (a pointer to the big number, dereferenced and exported as 0x20 bytes, then SHA1-hashed) and [EBP+0x10] (the out pointer that receives the first hash dword, at 0x002f8f5f), then a plain RET. [EBP+8] is the unread self slot. The caller SRP_ClientComputeSharedSecret 0x002f8fd1 stores [ESP+4]=EBX and [ESP+8]=LEA [EBP-0x10], then reads [EBP-0x10]. Matches the Windows twin 0x00528030 (void; pSrp this unread, ppBigNum, pdwOut). BigData is not in the Mac DB and the pdw prefix is refused, hence void** and pHashOut.

Changes 1, applied together

  1. Set prototype mac 0x002f8ed2

    signatureundefined SRP_HashBigNumToU32(void)→void SRP_HashBigNumToU32(D2Srp* pSrp, void** ppBigNum, uint32_t* pHashOut)
    conventionunknown→__cdecl