[Bug 14962] Temp Shelving Location / On Display Module
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14962 --- Comment #650 from Martin Renvoize (ashimema) <martin.renvoize@openfifth.co.uk> --- Created attachment 211872 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=211872&action=edit Bug 14962: (QA follow-up) Enforce library restrictions on display items, check before writing, tighten public embeds Display items - None of the Display::Items endpoints applied the library-group restrictions that Displays enforces, so a user limited to one group could list, read, add, change and remove items on another group's displays, directly or through the batch endpoints. Add Koha::Display-> can_be_accessed_by and use it everywhere. Managing a display's items requires being able to edit the display. - The URL identifies a display item on update, but the body's display_id and itemnumber were applied, so a row could be re-pointed at another display. - batch_delete accepted an optional display_id but the job always failed without one. It is now required. - The public list rendered 404 with the module off while /public/displays rendered an empty list. Make them agree. Displays - PUT checked manage_display_items after saving the display, and checked the library only against the current value, so a restricted user could move a display to a library outside their group. Check both before and after the change, before storing, and store the display and its items in one transaction (add() likewise). - Strip the embedded objects a client sends back. The read-only active and display_id are already refused by the OpenAPI validation. - Qualify the columns of the public queries. Public embeds - display_items was accepted as an anonymous embed and returned every row, including items hidden or suppressed in the OPAC, bypassing the filter the public items endpoint applies. library does not exist on Koha::Display and gave a 500. Allow display_library, home_library and holding_library only. Swagger: document the 403 on GET display and display item, and the bad_parameter error on POST display item. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org