mirror of
https://github.com/wekan/wekan.git
synced 2026-11-24 09:59:47 -05:00
POST /api/boards/:boardId/lists/:listId/cards and its bulk sibling wrote the URL's listId and the body's swimlaneId onto the new card without checking either against the board. A list or swimlane id of ANOTHER board gave a card that pointed at a list and a swimlane its own board does not have - the #6572 shape, a card that shows on neither board - and the list permission check was evaluated against the wrong board's rules. The PUT route has refused this since #6572; the create routes now do the same with a 400 that names the field, and the bulk route reports it per entry. An id that is not a string (such as { $ne: null }) is refused rather than looked up. The linked-card branch was already checked by createLinkedCardFor. tests/restCardPlacement.test.cjs pins both routes and fails on any REST handler in server/ that inserts a card without the check. This was in CHANGELOG TODO Later as needing a maintainer decision; the PUT route's #6572 rule already decided it. Thanks to xet7 !