[Bug 9065] New: Upload local cover image permission implementation error
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9065 Priority: P5 - low Change sponsored?: --- Bug ID: 9065 Assignee: gmcharlt@gmail.com Summary: Upload local cover image permission implementation error Severity: blocker Classification: Unclassified OS: All Reporter: Andy@Andy.COM.PT Hardware: All Status: NEW Version: 3.8 Component: Tools Product: Koha If a staff user IS NOT "superlibrarian", even if having "upload_local_cover_images", trying to use the "Tools -> Upload local cover image" will fail with "You do not have permissions [...]". Bug is found in /usr/share/koha/intranet/cgi-bin/tools/upload-cover-image.pl The following line (64) must be changed:
flagsrequired => { tools => 'upload_cover_images' }, To: flagsrequired => { tools => 'upload_local_cover_images' },
This will solve the problem. This appears to be the only place "upload_cover_images" bug exists (please also confirm). -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9065 André Melancia <Andy@Andy.COM.PT> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |Andy@Andy.COM.PT -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9065 Chris Cormack <chris@bigballofwax.co.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |chris@bigballofwax.co.nz Severity|blocker |major -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9065 Fridolyn SOMERS <fridolyn.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff Assignee|gmcharlt@gmail.com |fridolyn.somers@biblibre.co | |m --- Comment #1 from Fridolyn SOMERS <fridolyn.somers@biblibre.com> --- Created attachment 14486 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=14486&action=edit Proposed patch You are right André, the permission is not correct in upload_cover_image.pl. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9065 Fridolyn SOMERS <fridolyn.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Patch complexity|--- |Trivial patch -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9065 Fridolyn SOMERS <fridolyn.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Version|3.8 |master -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9065 Galen Charlton <gmcharlt@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9065 Galen Charlton <gmcharlt@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #14486|0 |1 is obsolete| | --- Comment #2 from Galen Charlton <gmcharlt@gmail.com> --- Created attachment 14501 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=14501&action=edit Bug 9065 - set correct permission for upload local cover image This patch fixes a problem where if a staff user has the upload_local_cover_images permission (and is not a superlibrarian and does not have all of the tools permissions), trying to use the "Tools -> Upload local cover image" will fail with "You do not have permissions [...]". To test after applying the patch: - Create a staff uesr that has just the catalogue and upload_local_cover_images permission. - Log in as that staff user. - Go to "Tools -> Upload local cover image". - Verify that one is given the form to upload a cover image. - Without the patch, one will be presented with the login form instead. Signed-off-by: Galen Charlton <gmc@esilibrary.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9065 Galen Charlton <gmcharlt@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |gmcharlt@gmail.com --- Comment #3 from Galen Charlton <gmcharlt@gmail.com> --- Note that I reworded the commit message for clarity and added a test plan. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9065 --- Comment #4 from Fridolyn SOMERS <fridolyn.somers@biblibre.com> --- Thanks a lot Galen -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9065 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9065 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #14501|0 |1 is obsolete| | --- Comment #5 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 14520 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=14520&action=edit Bug 9065 - set correct permission for upload local cover image This patch fixes a problem where if a staff user has the upload_local_cover_images permission (and is not a superlibrarian and does not have all of the tools permissions), trying to use the "Tools -> Upload local cover image" will fail with "You do not have permissions [...]". To test after applying the patch: - Create a staff uesr that has just the catalogue and upload_local_cover_images permission. - Log in as that staff user. - Go to "Tools -> Upload local cover image". - Verify that one is given the form to upload a cover image. - Without the patch, one will be presented with the login form instead. Signed-off-by: Galen Charlton <gmc@esilibrary.com> Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> mysql> select * from permissions where code="upload_cover_images"; Empty set (0.00 sec) mysql> select * from permissions where code="upload_local_cover_images"; +------------+---------------------------+---------------------------+ | module_bit | code | description | +------------+---------------------------+---------------------------+ | 13 | upload_local_cover_images | Upload local cover images | +------------+---------------------------+---------------------------+ 1 row in set (0.00 sec) "git grep upload_cover_images" returns 0 result. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9065 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Signed Off CC| |jonathan.druart@biblibre.co | |m QA Contact| |jonathan.druart@biblibre.co | |m -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9065 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9065 Jared Camins-Esakov <jcamins@cpbibliography.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to Master --- Comment #6 from Jared Camins-Esakov <jcamins@cpbibliography.com> --- This patch has been pushed to master. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9065 Chris Cormack <chris@bigballofwax.co.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to Master |Pushed to Stable --- Comment #7 from Chris Cormack <chris@bigballofwax.co.nz> --- Pushed to 3.8.x and 3.10.x, will be in 3.8.9 and 3.10.2 -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org