Fixed auth response bug that caused crash

Modified auth library, was previously causing a malformed
AuthResponse message to be sent when a user's session was expired.
Added code to fix it.