Koha-clms/t/db_dependent/SIP
Martin Renvoize f3f6f15938
Bug 42847: (QA follow-up) Clear session state on all login_core exit paths
login_core only cleared leftover session state on the failed-auth
branch. The earlier 'SIP access not authorized' return (unknown
terminal id) left any account/ils/institution/policy/credentials from
a prior connection on a reused prefork worker in place.

Move the reset to the top of login_core so every non-success exit path
leaves clean state, and only a successful api_auth re-establishes the
session. This keeps the no-authenticated-state-until-auth invariant in
a single place rather than duplicating the key list per branch.

Also extend the unit test to cover the unknown-terminal path on a
reused worker.

Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk>
Signed-off-by: Pedro Amorim <pedro.amorim@openfifth.co.uk>
2026-08-11 12:39:45 +00:00
..
ILS.t Bug 40163: (follow-up) Fix wrong GNU links and update test 2025-09-24 09:25:04 -06:00
Message.t Bug 41649: Fix SIP Message tests for magnetic media 2026-08-06 16:07:34 +00:00
MsgType.t Bug 42847: (QA follow-up) Clear session state on all login_core exit paths 2026-08-11 12:39:45 +00:00
Patron.t Bug 38944: Add Test::NoWarnings to tests no producing warnings 2025-03-13 17:25:03 +01:00
SIPServer.t Bug 42664: Unit tests 2026-06-29 15:38:52 +00:00
Transaction.t Bug 41649: Unit tests for magnetic media 2026-08-06 16:07:33 +00:00