Worth a looka fix or feature you may want
Win64 ABI fix in cryptographic block mixing
Today brings a single but important fix for Windows x64 applications using mORMot2 cryptography. A low-level assembly routine was violating the calling convention by not preserving certain XMM registers, which could cause unpredictable behaviour in the calling code.
TL;DR
- SBlockMix assembly now correctly preserves XMM8-XMM11 registers on Win64.
Upgrade advice
Teams running Win64 backends that utilize mORMot's cryptography (such as scrypt or specific block algorithms) should pull this update to prevent potential register corruption.
1 of 1 entries · 1 commits upstream
1
Medium
Assembly routine corrupted XMM registers on Win64
The inline assembly for SBlockMix in mormot.crypt.other was modified for the ABIWINX64 target. It now subtracts 72 bytes from the stack pointer and uses movaps to save registers xmm8, xmm9, xmm10, and xmm11 before execution, restoring them afterwards.
Fixes
mormot.crypt.other
2c1daf90+12-2
crypt: fixed SBlockMix Win64 asm
Impact
Previously, invoking SBlockMix on Win64 would overwrite non-volatile XMM registers without restoring them, violating the Windows x64 calling convention. This could lead to unpredictable bugs or access violations in the caller's state.
Upgrade recommended
Recompile and deploy Win64 binaries if your application relies on cryptographic functions utilizing SBlockMix.