I'm using the prebuilt Aliro stack (libaliro.a, nRF52840), when a session fails inside the library we have no way to get the resulting AliroErrorCode. The stack entry points return void, and HandleTermination carries no code — so internal errors (APDU status, TLV, decryption, invalid state) are invisible to us. We only see "session terminated", with no reason to log or report to our server.
Could you expose the session's AliroErrorCode to the application on session end? Since we already implement HandleTermination, the simplest option for us would be to add the error code there, e.g.:
void HandleTermination(ConnectionHandle handle, AliroError error);
Thanks.