[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Tomás Cohen Arazi changed: What|Removed |Added Status|Failed QA |ASSIGNED -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Tomás Cohen Arazi changed: What|Removed |Added URL||https://wiki.koha-community ||.org/wiki/Patrons_password_ ||endpoint_RFC Assignee|lari.task...@jns.fi |tomasco...@gmail.com --- Comment #47 from Tomás Cohen Arazi --- I'm taking over this one with Lari's agreement. I will add a RFC proposal to be voted. -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Tomás Cohen Arazi changed: What|Removed |Added Status|Signed Off |Failed QA --- Comment #46 from Tomás Cohen Arazi --- This should be implemented on top of bug 19784. Also, I see no reason to require the 'old password'. Conceptually, I would say we are updating the password "object". This means we need to PUT a new password. If we changed the password by hitting the patron/patron_id endpoint, then PATCH would be advised. But on this implementation we should def use PUT. -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Tomás Cohen Arazi changed: What|Removed |Added CC||tomasco...@gmail.com Depends on||19784 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=19784 [Bug 19784] Adapt /v1/patrons to new naming guidelines -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 --- Comment #45 from Josef Moravec --- Rebased on master -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 --- Comment #41 from Josef Moravec --- Created attachment 70261 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=70261&action=edit Bug 17006: Respect system preference "OpacPasswordChange" Allow patron to change their own password without borrowers-flag only if OpacPasswordChange system preference is enabled. To test: 1. Apply patch 2. Run t/db_dependent/api/v1/patrons.t 3. Set OpacPasswordChange system preference to "Don't allow". 4. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber for a borrower that does not have any permissions 5. Observe permission error. 6. Set OpacPasswordChange system preference to "Allow". 7. Repeat step 4 and make sure that password was changed. Signed-off-by: Aleisha Amohia Signed-off-by: Josef Moravec -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 --- Comment #43 from Josef Moravec --- Created attachment 70263 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=70263&action=edit Bug 17006: (follow-up) Let librarians change patron's passwords This should obviously be part of this feature but was left unnoticed in the first patch. If user has "borrowers"-flag, they should be able to change patron's password without providing old password. To test: 1. Run t/db_dependent/api/v1/patrons.t 2. Observe failing test 3. Apply patch 4. Run t/db_dependent/api/v1/patrons.t 5. Observe passing test 6. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber (borrowers flag required) and where YYY is not the same borrowernumber as your logged-in user's borrowernumber 7. Make sure that password was changed for YYY. You may find this useful for testing: curl -X PATCH http://library/api/v1/patrons/123/password \ --data '{"new_password":"1234"}' \ --cookie 'CGISESSID=055ca5a9a3ad3fb5052143bd015c1c10' Signed-off-by: Josef Moravec -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 --- Comment #42 from Josef Moravec --- Created attachment 70262 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=70262&action=edit Bug 17006: (follow-up) Test for changing another user's password The previous patches work for changing your own password, but the tests are lacking a case where librarian attempts to change patron's password. This feature was unnoticed and not implemented. To test: 1. Run t/db_dependent/api/v1/patrons.t 2. Observe failing test 3. Proceed to next patch to fix the failing test Signed-off-by: Josef Moravec -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Josef Moravec changed: What|Removed |Added Attachment #67128|0 |1 is obsolete|| Attachment #67129|0 |1 is obsolete|| Attachment #67130|0 |1 is obsolete|| Attachment #67131|0 |1 is obsolete|| Attachment #67132|0 |1 is obsolete|| --- Comment #40 from Josef Moravec --- Created attachment 70260 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=70260&action=edit Bug 17006: Add API route for changing patron's password PATCH /patrons/{borrowernumber}/password (change password) Required body params: - current_password - new_password To test: 1. Apply patch 2. Run t/db_dependent/api/v1/patrons.t 3. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber (borrowers flag required) 4. Make sure that password was changed. 5. Try also too short password, and wrong current password and observe that errors are displayed appropriately. You may find this useful for testing: curl -X PATCH http://library/api/v1/patrons/123/password --data '{"current_password":"123456", "new_password":"1234"}' --cookie 'CGISESSID=055ca5a9a3ad3fb5052143bd015c1c10' Signed-off-by: Aleisha Amohia Signed-off-by: Josef Moravec -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 --- Comment #44 from Josef Moravec --- Created attachment 70264 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=70264&action=edit Bug 17006: (follow-up) Use Koha::Exceptions for change password endpoint Koha::Exceptions are a nice way to handle erros and they should be used much more than they are now. This patch adds Koha::Exceptions into Koha::Patron->change_password_to sub and catches the exceptions in the controller. 1. Apply patch 2. Run t/db_dependent/api/v1/patrons.t 3. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber (borrowers flag required) 4. Make sure that password was changed. 5. Try also too short password, and wrong current password and observe that errors are displayed appropriately. curl -X PATCH http://library/api/v1/patrons/123/password \ --data '{"current_password":"123", "new_password":"1234"}' \ --cookie 'CGISESSID=055ca5a9a3ad3fb5052143bd015c1c10' Signed-off-by: Josef Moravec -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Josef Moravec changed: What|Removed |Added Status|Patch doesn't apply |Signed Off -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Katrin Fischer changed: What|Removed |Added CC||katrin.fisc...@bsz-bw.de Status|Signed Off |Patch doesn't apply --- Comment #39 from Katrin Fischer --- Patch doesn't apply, please also take a look at comment#38. Apply? [(y)es, (n)o, (i)nteractive] y Applying: Bug 17006: Add API route for changing patron's password Using index info to reconstruct a base tree... M Koha/Patron.pm M Koha/REST/V1/Patron.pm M api/v1/swagger/paths.json M api/v1/swagger/paths/patrons.json M t/db_dependent/api/v1/patrons.t Falling back to patching base and 3-way merge... Auto-merging t/db_dependent/api/v1/patrons.t Auto-merging api/v1/swagger/paths/patrons.json Auto-merging api/v1/swagger/paths.json CONFLICT (content): Merge conflict in api/v1/swagger/paths.json Auto-merging Koha/REST/V1/Patron.pm Auto-merging Koha/Patron.pm error: Failed to merge in the changes. Patch failed at 0001 Bug 17006: Add API route for changing patron's password The copy of the patch that failed is found in: .git/rebase-apply/patch When you have resolved this problem run "git bz apply --continue". If you would prefer to skip this patch, instead run "git bz apply --skip". To restore the original branch and stop patching run "git bz apply --abort". Patch left in /tmp/Bug-17006-Add-API-route-for-changing-patrons-passw-7eNHth.patch -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 --- Comment #38 from Jonathan Druart --- Note for QA: I think Koha::Patron->change_password_to must call Koha::AuthUtils::is_password_valid (from bug 18298). -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Jonathan Druart changed: What|Removed |Added Component|Web services|REST api QA Contact|testo...@bugs.koha-communit | |y.org | -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Josef Moravec changed: What|Removed |Added Status|Patch doesn't apply |Signed Off --- Comment #37 from Josef Moravec --- Rebased on master -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 --- Comment #34 from Josef Moravec --- Created attachment 67130 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=67130&action=edit Bug 17006: (follow-up) Test for changing another user's password The previous patches work for changing your own password, but the tests are lacking a case where librarian attempts to change patron's password. This feature was unnoticed and not implemented. To test: 1. Run t/db_dependent/api/v1/patrons.t 2. Observe failing test 3. Proceed to next patch to fix the failing test Signed-off-by: Josef Moravec -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 --- Comment #33 from Josef Moravec --- Created attachment 67129 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=67129&action=edit Bug 17006: Respect system preference "OpacPasswordChange" Allow patron to change their own password without borrowers-flag only if OpacPasswordChange system preference is enabled. To test: 1. Apply patch 2. Run t/db_dependent/api/v1/patrons.t 3. Set OpacPasswordChange system preference to "Don't allow". 4. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber for a borrower that does not have any permissions 5. Observe permission error. 6. Set OpacPasswordChange system preference to "Allow". 7. Repeat step 4 and make sure that password was changed. Signed-off-by: Aleisha Amohia Signed-off-by: Josef Moravec -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 --- Comment #35 from Josef Moravec --- Created attachment 67131 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=67131&action=edit Bug 17006: (follow-up) Let librarians change patron's passwords This should obviously be part of this feature but was left unnoticed in the first patch. If user has "borrowers"-flag, they should be able to change patron's password without providing old password. To test: 1. Run t/db_dependent/api/v1/patrons.t 2. Observe failing test 3. Apply patch 4. Run t/db_dependent/api/v1/patrons.t 5. Observe passing test 6. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber (borrowers flag required) and where YYY is not the same borrowernumber as your logged-in user's borrowernumber 7. Make sure that password was changed for YYY. You may find this useful for testing: curl -X PATCH http://library/api/v1/patrons/123/password \ --data '{"new_password":"1234"}' \ --cookie 'CGISESSID=055ca5a9a3ad3fb5052143bd015c1c10' Signed-off-by: Josef Moravec -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 --- Comment #36 from Josef Moravec --- Created attachment 67132 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=67132&action=edit Bug 17006: (follow-up) Use Koha::Exceptions for change password endpoint Koha::Exceptions are a nice way to handle erros and they should be used much more than they are now. This patch adds Koha::Exceptions into Koha::Patron->change_password_to sub and catches the exceptions in the controller. 1. Apply patch 2. Run t/db_dependent/api/v1/patrons.t 3. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber (borrowers flag required) 4. Make sure that password was changed. 5. Try also too short password, and wrong current password and observe that errors are displayed appropriately. curl -X PATCH http://library/api/v1/patrons/123/password \ --data '{"current_password":"123", "new_password":"1234"}' \ --cookie 'CGISESSID=055ca5a9a3ad3fb5052143bd015c1c10' Signed-off-by: Josef Moravec -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Josef Moravec changed: What|Removed |Added Attachment #63329|0 |1 is obsolete|| Attachment #63330|0 |1 is obsolete|| Attachment #63331|0 |1 is obsolete|| Attachment #63332|0 |1 is obsolete|| Attachment #6|0 |1 is obsolete|| --- Comment #32 from Josef Moravec --- Created attachment 67128 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=67128&action=edit Bug 17006: Add API route for changing patron's password PATCH /patrons/{borrowernumber}/password (change password) Required body params: - current_password - new_password To test: 1. Apply patch 2. Run t/db_dependent/api/v1/patrons.t 3. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber (borrowers flag required) 4. Make sure that password was changed. 5. Try also too short password, and wrong current password and observe that errors are displayed appropriately. You may find this useful for testing: curl -X PATCH http://library/api/v1/patrons/123/password --data '{"current_password":"123456", "new_password":"1234"}' --cookie 'CGISESSID=055ca5a9a3ad3fb5052143bd015c1c10' Signed-off-by: Aleisha Amohia Signed-off-by: Josef Moravec -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Marcel de Rooy changed: What|Removed |Added Status|Signed Off |Patch doesn't apply CC||m.de.r...@rijksmuseum.nl -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Jonathan Druart changed: What|Removed |Added See Also||https://bugs.koha-community ||.org/bugzilla3/show_bug.cgi ||?id=18298 CC||jonathan.dru...@bugs.koha-c ||ommunity.org -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Josef Moravec changed: What|Removed |Added Status|Failed QA |Signed Off --- Comment #31 from Josef Moravec --- (In reply to Mirko Tietgen from comment #25) > I can't apply the last patch. > > Wende an: Bug 17006: (follow-up) Use Koha::Exceptions for change password > endpoint > fatal: sha1 information is lacking or useless (Koha/REST/V1/Patron.pm). > Dem Repository fehlen notwendige Blobs um auf einen 3-Wege-Merge > zurückzufallen. > Kann nicht zu 3-Wege-Merge zurückfallen. > Anwendung des Patches fehlgeschlagen bei 0001 Bug 17006: (follow-up) Use > Koha::Exceptions for change password endpoint Rebased on master -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Josef Moravec changed: What|Removed |Added Attachment #57356|0 |1 is obsolete|| Attachment #57357|0 |1 is obsolete|| Attachment #57358|0 |1 is obsolete|| Attachment #57359|0 |1 is obsolete|| Attachment #57360|0 |1 is obsolete|| --- Comment #26 from Josef Moravec --- Created attachment 63329 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=63329&action=edit Bug 17006: Add API route for changing patron's password PATCH /patrons/{borrowernumber}/password (change password) Required body params: - current_password - new_password To test: 1. Apply patch 2. Run t/db_dependent/api/v1/patrons.t 3. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber (borrowers flag required) 4. Make sure that password was changed. 5. Try also too short password, and wrong current password and observe that errors are displayed appropriately. You may find this useful for testing: curl -X PATCH http://library/api/v1/patrons/123/password --data '{"current_password":"123456", "new_password":"1234"}' --cookie 'CGISESSID=055ca5a9a3ad3fb5052143bd015c1c10' Signed-off-by: Aleisha Amohia Signed-off-by: Josef Moravec -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 --- Comment #30 from Josef Moravec --- Created attachment 6 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=6&action=edit Bug 17006: (follow-up) Use Koha::Exceptions for change password endpoint Koha::Exceptions are a nice way to handle erros and they should be used much more than they are now. This patch adds Koha::Exceptions into Koha::Patron->change_password_to sub and catches the exceptions in the controller. 1. Apply patch 2. Run t/db_dependent/api/v1/patrons.t 3. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber (borrowers flag required) 4. Make sure that password was changed. 5. Try also too short password, and wrong current password and observe that errors are displayed appropriately. curl -X PATCH http://library/api/v1/patrons/123/password \ --data '{"current_password":"123", "new_password":"1234"}' \ --cookie 'CGISESSID=055ca5a9a3ad3fb5052143bd015c1c10' Signed-off-by: Josef Moravec -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 --- Comment #27 from Josef Moravec --- Created attachment 63330 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=63330&action=edit Bug 17006: Respect system preference "OpacPasswordChange" Allow patron to change their own password without borrowers-flag only if OpacPasswordChange system preference is enabled. To test: 1. Apply patch 2. Run t/db_dependent/api/v1/patrons.t 3. Set OpacPasswordChange system preference to "Don't allow". 4. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber for a borrower that does not have any permissions 5. Observe permission error. 6. Set OpacPasswordChange system preference to "Allow". 7. Repeat step 4 and make sure that password was changed. Signed-off-by: Aleisha Amohia Signed-off-by: Josef Moravec -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 --- Comment #29 from Josef Moravec --- Created attachment 63332 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=63332&action=edit Bug 17006: (follow-up) Let librarians change patron's passwords This should obviously be part of this feature but was left unnoticed in the first patch. If user has "borrowers"-flag, they should be able to change patron's password without providing old password. To test: 1. Run t/db_dependent/api/v1/patrons.t 2. Observe failing test 3. Apply patch 4. Run t/db_dependent/api/v1/patrons.t 5. Observe passing test 6. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber (borrowers flag required) and where YYY is not the same borrowernumber as your logged-in user's borrowernumber 7. Make sure that password was changed for YYY. You may find this useful for testing: curl -X PATCH http://library/api/v1/patrons/123/password \ --data '{"new_password":"1234"}' \ --cookie 'CGISESSID=055ca5a9a3ad3fb5052143bd015c1c10' Signed-off-by: Josef Moravec -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 --- Comment #28 from Josef Moravec --- Created attachment 63331 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=63331&action=edit Bug 17006: (follow-up) Test for changing another user's password The previous patches work for changing your own password, but the tests are lacking a case where librarian attempts to change patron's password. This feature was unnoticed and not implemented. To test: 1. Run t/db_dependent/api/v1/patrons.t 2. Observe failing test 3. Proceed to next patch to fix the failing test Signed-off-by: Josef Moravec -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Mirko Tietgen changed: What|Removed |Added CC||mi...@abunchofthings.net Status|Signed Off |Failed QA --- Comment #25 from Mirko Tietgen --- I can't apply the last patch. Wende an: Bug 17006: (follow-up) Use Koha::Exceptions for change password endpoint fatal: sha1 information is lacking or useless (Koha/REST/V1/Patron.pm). Dem Repository fehlen notwendige Blobs um auf einen 3-Wege-Merge zurückzufallen. Kann nicht zu 3-Wege-Merge zurückfallen. Anwendung des Patches fehlgeschlagen bei 0001 Bug 17006: (follow-up) Use Koha::Exceptions for change password endpoint -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Marcel de Rooy changed: What|Removed |Added Assignee|koha-b...@lists.koha-commun |lari.task...@jns.fi |ity.org | -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 --- Comment #24 from Josef Moravec --- Created attachment 57360 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=57360&action=edit [SIGNED-OFF] Bug 17006: (follow-up) Use Koha::Exceptions for change password endpoint Koha::Exceptions are a nice way to handle erros and they should be used much more than they are now. This patch adds Koha::Exceptions into Koha::Patron->change_password_to sub and catches the exceptions in the controller. 1. Apply patch 2. Run t/db_dependent/api/v1/patrons.t 3. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber (borrowers flag required) 4. Make sure that password was changed. 5. Try also too short password, and wrong current password and observe that errors are displayed appropriately. curl -X PATCH http://library/api/v1/patrons/123/password \ --data '{"current_password":"123", "new_password":"1234"}' \ --cookie 'CGISESSID=055ca5a9a3ad3fb5052143bd015c1c10' Signed-off-by: Josef Moravec -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 --- Comment #22 from Josef Moravec --- Created attachment 57358 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=57358&action=edit [SIGNED-OFF] Bug 17006: (follow-up) Test for changing another user's password The previous patches work for changing your own password, but the tests are lacking a case where librarian attempts to change patron's password. This feature was unnoticed and not implemented. To test: 1. Run t/db_dependent/api/v1/patrons.t 2. Observe failing test 3. Proceed to next patch to fix the failing test Signed-off-by: Josef Moravec -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 --- Comment #23 from Josef Moravec --- Created attachment 57359 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=57359&action=edit [SIGNED-OFF] Bug 17006: (follow-up) Let librarians change patron's passwords This should obviously be part of this feature but was left unnoticed in the first patch. If user has "borrowers"-flag, they should be able to change patron's password without providing old password. To test: 1. Run t/db_dependent/api/v1/patrons.t 2. Observe failing test 3. Apply patch 4. Run t/db_dependent/api/v1/patrons.t 5. Observe passing test 6. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber (borrowers flag required) and where YYY is not the same borrowernumber as your logged-in user's borrowernumber 7. Make sure that password was changed for YYY. You may find this useful for testing: curl -X PATCH http://library/api/v1/patrons/123/password \ --data '{"new_password":"1234"}' \ --cookie 'CGISESSID=055ca5a9a3ad3fb5052143bd015c1c10' Signed-off-by: Josef Moravec -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 --- Comment #21 from Josef Moravec --- Created attachment 57357 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=57357&action=edit [SIGNED-OFF] Bug 17006: Respect system preference "OpacPasswordChange" Allow patron to change their own password without borrowers-flag only if OpacPasswordChange system preference is enabled. To test: 1. Apply patch 2. Run t/db_dependent/api/v1/patrons.t 3. Set OpacPasswordChange system preference to "Don't allow". 4. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber for a borrower that does not have any permissions 5. Observe permission error. 6. Set OpacPasswordChange system preference to "Allow". 7. Repeat step 4 and make sure that password was changed. Signed-off-by: Aleisha Amohia Signed-off-by: Josef Moravec -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Josef Moravec changed: What|Removed |Added Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Josef Moravec changed: What|Removed |Added Attachment #56283|0 |1 is obsolete|| Attachment #56284|0 |1 is obsolete|| Attachment #56399|0 |1 is obsolete|| Attachment #56400|0 |1 is obsolete|| Attachment #56409|0 |1 is obsolete|| --- Comment #20 from Josef Moravec --- Created attachment 57356 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=57356&action=edit [SIGNED-OFF] Bug 17006: Add API route for changing patron's password PATCH /patrons/{borrowernumber}/password (change password) Required body params: - current_password - new_password To test: 1. Apply patch 2. Run t/db_dependent/api/v1/patrons.t 3. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber (borrowers flag required) 4. Make sure that password was changed. 5. Try also too short password, and wrong current password and observe that errors are displayed appropriately. You may find this useful for testing: curl -X PATCH http://library/api/v1/patrons/123/password --data '{"current_password":"123456", "new_password":"1234"}' --cookie 'CGISESSID=055ca5a9a3ad3fb5052143bd015c1c10' Signed-off-by: Aleisha Amohia Signed-off-by: Josef Moravec -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Lari Taskula changed: What|Removed |Added Attachment #56401|0 |1 is obsolete|| --- Comment #19 from Lari Taskula --- Created attachment 56409 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=56409&action=edit Bug 17006: (follow-up) Use Koha::Exceptions for change password endpoint -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 --- Comment #17 from Lari Taskula --- Created attachment 56400 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=56400&action=edit Bug 17006: (follow-up) Let librarians change patron's passwords This should obviously be part of this feature but was left unnoticed in the first patch. If user has "borrowers"-flag, they should be able to change patron's password without providing old password. To test: 1. Run t/db_dependent/api/v1/patrons.t 2. Observe failing test 3. Apply patch 4. Run t/db_dependent/api/v1/patrons.t 5. Observe passing test 6. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber (borrowers flag required) and where YYY is not the same borrowernumber as your logged-in user's borrowernumber 7. Make sure that password was changed for YYY. You may find this useful for testing: curl -X PATCH http://library/api/v1/patrons/123/password \ --data '{"new_password":"1234"}' \ --cookie 'CGISESSID=055ca5a9a3ad3fb5052143bd015c1c10' -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 --- Comment #18 from Lari Taskula --- Created attachment 56401 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=56401&action=edit Bug 17006: (follow-up) Use Koha::Exceptions for change password endpoint Koha::Exceptions are a nice way to handle erros and they should be used much more than they are now. This patch adds Koha::Exceptions into Koha::Patron->change_password_to sub and catches the exceptions in the controller. 1. Apply patch 2. Run t/db_dependent/api/v1/patrons.t 3. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber (borrowers flag required) 4. Make sure that password was changed. 5. Try also too short password, and wrong current password and observe that errors are displayed appropriately. curl -X PATCH http://library/api/v1/patrons/123/password \ --data '{"current_password":"123", "new_password":"1234"}' \ --cookie 'CGISESSID=055ca5a9a3ad3fb5052143bd015c1c10' -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 --- Comment #16 from Lari Taskula --- Created attachment 56399 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=56399&action=edit Bug 17006: (follow-up) Test for changing another user's password The previous patches work for changing your own password, but the tests are lacking a case where librarian attempts to change patron's password. This feature was unnoticed and not implemented. To test: 1. Run t/db_dependent/api/v1/patrons.t 2. Observe failing test 3. Proceed to next patch to fix the failing test -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Lari Taskula changed: What|Removed |Added Status|Signed Off |Needs Signoff -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 --- Comment #15 from Lari Taskula --- Removed minification step from test plan after Bug 17432 was pushed to master. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Lari Taskula changed: What|Removed |Added Attachment #56158|0 |1 is obsolete|| --- Comment #14 from Lari Taskula --- Created attachment 56284 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=56284&action=edit [SIGNED-OFF] Bug 17006: Respect system preference "OpacPasswordChange" Allow patron to change their own password without borrowers-flag only if OpacPasswordChange system preference is enabled. To test: 1. Apply patch 2. Run t/db_dependent/api/v1/patrons.t 3. Set OpacPasswordChange system preference to "Don't allow". 4. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber for a borrower that does not have any permissions 5. Observe permission error. 6. Set OpacPasswordChange system preference to "Allow". 7. Repeat step 4 and make sure that password was changed. Signed-off-by: Aleisha Amohia -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Lari Taskula changed: What|Removed |Added Attachment #56157|0 |1 is obsolete|| --- Comment #13 from Lari Taskula --- Created attachment 56283 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=56283&action=edit [SIGNED-OFF] Bug 17006: Add API route for changing patron's password PATCH /patrons/{borrowernumber}/password (change password) Required body params: - current_password - new_password To test: 1. Apply patch 2. Run t/db_dependent/api/v1/patrons.t 3. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber (borrowers flag required) 4. Make sure that password was changed. 5. Try also too short password, and wrong current password and observe that errors are displayed appropriately. You may find this useful for testing: curl -X PATCH http://library/api/v1/patrons/123/password --data '{"current_password":"123456", "new_password":"1234"}' --cookie 'CGISESSID=055ca5a9a3ad3fb5052143bd015c1c10' Signed-off-by: Aleisha Amohia -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Lari Taskula changed: What|Removed |Added Attachment #56156|0 |1 is obsolete|| --- Comment #11 from Lari Taskula --- Created attachment 56158 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=56158&action=edit [SIGNED-OFF] Bug 17006: Respect system preference "OpacPasswordChange" Signed-off-by: Aleisha Amohia -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 --- Comment #12 from Lari Taskula --- Rebased on top of master. -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Lari Taskula changed: What|Removed |Added Attachment #56155|0 |1 is obsolete|| --- Comment #10 from Lari Taskula --- Created attachment 56157 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=56157&action=edit [SIGNED-OFF] Bug 17006: Add API route for changing patron's password Signed-off-by: Aleisha Amohia -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Lari Taskula changed: What|Removed |Added Attachment #54718|0 |1 is obsolete|| --- Comment #9 from Lari Taskula --- Created attachment 56156 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=56156&action=edit [SIGNED-OFF] Bug 17006: Respect system preference "OpacPasswordChange" Allow patron to change their own password without borrowers-flag only if OpacPasswordChange system preference is enabled. To test: 1. Apply patch 2. Run t/db_dependent/api/v1/patrons.t 3. Set OpacPasswordChange system preference to "Don't allow". 4. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber for a borrower that does not have any permissions 5. Observe permission error. 6. Set OpacPasswordChange system preference to "Allow". 7. Repeat step 4 and make sure that password was changed. Signed-off-by: Aleisha Amohia -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Lari Taskula changed: What|Removed |Added Attachment #54717|0 |1 is obsolete|| --- Comment #8 from Lari Taskula --- Created attachment 56155 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=56155&action=edit [SIGNED-OFF] Bug 17006: Add API route for changing patron's password PATCH /patrons/{borrowernumber}/password (change password) Required body params: - current_password - new_password To test: 1. Apply patch and minify swagger.json perl misc/devel/minifySwagger.pl -s api/v1/swagger/swagger.json -d api/v1/swagger/swagger.min.json 2. Run t/db_dependent/api/v1/patrons.t 3. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber (borrowers flag required) 4. Make sure that password was changed. 5. Try also too short password, and wrong current password and observe that errors are displayed appropriately. You may find this useful for testing: curl -X PATCH http://library/api/v1/patrons/123/password --data '{"current_password":"123456", "new_password":"1234"}' --cookie 'CGISESSID=055ca5a9a3ad3fb5052143bd015c1c10' Signed-off-by: Aleisha Amohia -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 --- Comment #7 from Aleisha Amohia --- Created attachment 54718 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=54718&action=edit [SIGNED-OFF] Bug 17006: Respect system preference "OpacPasswordChange" Allow patron to change their own password without borrowers-flag only if OpacPasswordChange system preference is enabled. To test: 1. Apply patch 2. Run t/db_dependent/api/v1/patrons.t 3. Set OpacPasswordChange system preference to "Don't allow". 4. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber for a borrower that does not have any permissions 5. Observe permission error. 6. Set OpacPasswordChange system preference to "Allow". 7. Repeat step 4 and make sure that password was changed. Signed-off-by: Aleisha Amohia -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Aleisha Amohia changed: What|Removed |Added Attachment #54716|0 |1 is obsolete|| --- Comment #6 from Aleisha Amohia --- Created attachment 54717 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=54717&action=edit [SIGNED-OFF] Bug 17006: Add API route for changing patron's password PATCH /patrons/{borrowernumber}/password (change password) Required body params: - current_password - new_password To test: 1. Apply patch 2. Run t/db_dependent/api/v1/patrons.t 3. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber (borrowers flag required) 4. Make sure that password was changed. 5. Try also too short password, and wrong current password and observe that errors are displayed appropriately. You may find this useful for testing: curl -X PATCH http://library/api/v1/patrons/123/password --data '{"current_password":"123456", "new_password":"1234"}' --cookie 'CGISESSID=055ca5a9a3ad3fb5052143bd015c1c10' Signed-off-by: Aleisha Amohia -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Aleisha Amohia changed: What|Removed |Added Attachment #54629|0 |1 is obsolete|| Attachment #54630|0 |1 is obsolete|| --- Comment #5 from Aleisha Amohia --- Created attachment 54716 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=54716&action=edit [SIGNED-OFF] Bug 17006: Add API route for changing patron's password PATCH /patrons/{borrowernumber}/password (change password) Required body params: - current_password - new_password To test: 1. Apply patch 2. Run t/db_dependent/api/v1/patrons.t 3. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber (borrowers flag required) 4. Make sure that password was changed. 5. Try also too short password, and wrong current password and observe that errors are displayed appropriately. You may find this useful for testing: curl -X PATCH http://library/api/v1/patrons/123/password --data '{"current_password":"123456", "new_password":"1234"}' --cookie 'CGISESSID=055ca5a9a3ad3fb5052143bd015c1c10' Signed-off-by: Aleisha Amohia -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Aleisha Amohia changed: What|Removed |Added Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Lari Taskula changed: What|Removed |Added Attachment #54576|0 |1 is obsolete|| --- Comment #4 from Lari Taskula --- Created attachment 54630 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=54630&action=edit Bug 17006: Respect system preference "OpacPasswordChange" -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Lari Taskula changed: What|Removed |Added Attachment #54575|0 |1 is obsolete|| --- Comment #3 from Lari Taskula --- Created attachment 54629 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=54629&action=edit Bug 17006: Add API route for changing patron's password Fixed trailing whitespace -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 --- Comment #2 from Lari Taskula --- Created attachment 54576 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=54576&action=edit Bug 17006: Respect system preference "OpacPasswordChange" Allow patron to change their own password without borrowers-flag only if OpacPasswordChange system preference is enabled. To test: 1. Apply patch 2. Run t/db_dependent/api/v1/patrons.t 3. Set OpacPasswordChange system preference to "Don't allow". 4. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber for a borrower that does not have any permissions 5. Observe permission error. 6. Set OpacPasswordChange system preference to "Allow". 7. Repeat step 4 and make sure that password was changed. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 --- Comment #1 from Lari Taskula --- Created attachment 54575 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=54575&action=edit Bug 17006: Add API route for changing patron's password PATCH /patrons/{borrowernumber}/password (change password) Required body params: - current_password - new_password To test: 1. Apply patch 2. Run t/db_dependent/api/v1/patrons.t 3. Send PATCH request to http://library/api/v1/patrons/YYY/password where YYY is existing borrowernumber (borrowers flag required) 4. Make sure that password was changed. 5. Try also too short password, and wrong current password and observe that errors are displayed appropriately. You may find this useful for testing: curl -X PATCH http://library/api/v1/patrons/123/password --data '{"current_password":"123456", "new_password":"1234"}' --cookie 'CGISESSID=055ca5a9a3ad3fb5052143bd015c1c10' -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Lari Taskula changed: What|Removed |Added Status|NEW |Needs Signoff -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Lari Taskula changed: What|Removed |Added CC||la...@student.uef.fi -- You are receiving this mail because: You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Jiří Kozlovský changed: What|Removed |Added Blocks||16652 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=16652 [Bug 16652] Omnibus: RestfulAPI supporting services for Vufind and for xnciptoolkit drivers -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Mike changed: What|Removed |Added Text to go in the|Minucipal Libray Ceska |Municipal Libray Ceska release notes|Trebova |Trebova -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Mike changed: What|Removed |Added Text to go in the|Sposored by Ministry of |Minucipal Libray Ceska release notes|Culture Czech |Trebova |Republic/Minucipal Libray | |Ceska Trebova | -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Mike changed: What|Removed |Added Text to go in the||Sposored by Ministry of release notes||Culture Czech ||Republic/Minucipal Libray ||Ceska Trebova -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
[Koha-bugs] [Bug 17006] REST API: add route to change patron's password
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17006 Mike changed: What|Removed |Added Change sponsored?|--- |Sponsored CC||blac...@gmail.com, ||josef.mora...@gmail.com -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes. ___ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/