After updating from 19.11.21 to 19.11.22, API access to our Koha instance failed. The reason was that the installer/data/mysql/atomicupdate/bug_28772_api_keys.pl was not executed, likely due to the fact that installer/data/mysql/updatedatabase.pl only executes files that end in .perl or .sql, while the new one ends in .pl. Manually executing the equivalent code (hashing the API-keys) fixes the problem.
Just renaming installer/data/mysql/atomicupdate/bug_28772_api_keys.pl to installer/data/mysql/atomicupdate/bug_28772_api_keys.perl is not enough to fix this. I did that, built local packages and now at least I get "DEV atomic update: bug_28772_api_keys.perl" when I install the updated package, but the API key secrets still remain unhashed. As I wrote earlier extracting the relevant parts from that installer/data/mysql/atomicupdate/bug_28772_api_keys.pl and executing them in a short wrapper script (mainly for getting att C4::Context->dbh) works for me.
Wainui, did you see this bug report? You forgot to move the atomicupdate to the updatedatabase.pl script.
Created attachment 127946 [details] [review] Bug 28772: DBRev 19.11.23.001 Note that this added back the following patch: "Bug 28772: Do not hash secrets twice"
Wainui, this patch is moving the dbrev to the updatedatabase.pl script. Note that it also added back a commit you reverted. Do you remember why?
Tomas, can you have a look please?
Created attachment 127948 [details] [review] Bug 28772: DBRev 19.11.23.001 Note that this added back the following patch: "Bug 28772: Do not hash secrets twice" https://bugs.koha-community.org/show_bug.cgi?id=29132 Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Tested before the 28772 patches then the upgrade and then this patch. All works as expected.
Sorry about this everyone, I do not remember why the patch reverted. Thanks so much!!
Created attachment 127967 [details] [review] Bug 28772: DBRev 19.11.23.001 Note that this added back the following patch: "Bug 28772: Do not hash secrets twice" https://bugs.koha-community.org/show_bug.cgi?id=29132 Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Wainui Witika-Park <wainuiwitikapark@catalyst.net.nz>
I have added this patch to the 19.11.x branch, however I am unsure if I should release this this month as it is the only new patch. 19.11.x is LTS, so only really backporting security patches.
(In reply to wainuiwitikapark from comment #10) > I have added this patch to the 19.11.x branch, however I am unsure if I > should release this this month as it is the only new patch. 19.11.x is LTS, > so only really backporting security patches. ...and important fixes, in my opinion. If a feature got broken, and doesn't introduce new strings, I'd release even out of schedule.
I see the commit has been pushed to 19.11.x I propose we set status to revolved.
I built local packages from the latest 19.11.x and installed them on our test server. All works as expected (already hashed secrets remained untouched and plain ones I created for testing where hashed afterwards). Setting status to resolved now - many thanks to all involved!
Cool, yes this will be in 19.11.24. Thanks everyone.