]> git.koha-community.org Git - koha.git/commit
Bug 34513: Set auth state correctly when changing auth sessions
authorDavid Cook <dcook@prosentient.com.au>
Fri, 11 Aug 2023 03:03:01 +0000 (03:03 +0000)
committerFridolin Somers <fridolin.somers@biblibre.com>
Wed, 27 Sep 2023 07:25:13 +0000 (21:25 -1000)
commit6fc8ea422a2cb6a1f2a8c3b7a54112037fe863bf
treef43b30497c8a47e300f6dce95e616f28ad9f3e34
parent392edc1a2fe1f84f94b03bd569a10adb60dbc6fe
Bug 34513: Set auth state correctly when changing auth sessions

This patch sets the $auth_state to failed when changing auth sessions,
so that the new login attempt gets processed correctly (instead
of skipping the authorization step).

Test plan:
0. Apply the patch
1. koha-plack --reload kohadev
2. Go to
http://localhost:8081/cgi-bin/koha/admin/preferences.pl?tab=&op=search&searchfield=baseurl
3. Log in as an OPAC user with 0 permissions
4. Note the auth screen "Error: You do not have permission to access this page"
5. Click "Log in"
6. Note that you're still shown a login screen (and that you've been logged out of
your previous authenticated session)

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 16da12cbbc200d9ef07a87ee7f9bdf8e61ae06f3)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
C4/Auth.pm