this is going to sound crazy. but the ssedetect(); (line 92) in zms.cpp is causing a failure authenticating the user when auth_relay set to hashed(had it fail intermittently with plain also) and when auth_relay set to none then all works as expected..
stock 1.25.0.4 from wheezy does NOT exhibit this bug but this branch does and it was tracked to above empirically ie comment out and the bug does not manifest.. could the sse/simd routines of zoneminder be unbalancing the stack in this case(looked and saw a bunch of asm...)? original bug filed against fixxermet puppet script with all log evidence from same now closed to file here