Closed (fixed)
Project:
Nodequeue
Version:
6.x-2.0
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
15 Mar 2009 at 16:10 UTC
Updated:
20 Apr 2009 at 22:50 UTC
Jump to comment: Most recent file
the ajax callback for adding a node to a node queue you can administer didn't work due to an error in the access function controling that functionality.
smartqueue_og_queue_access() has been corrected in this patch.
Together with my previous patch, I got smartqueue_og all working. You might consider releasing your 6.x-1 version.
cheers,
TUc
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | 402620.patch | 822 bytes | ezra-g |
| smartqueue_access.patch | 1004 bytes | TUc |
Comments
Comment #1
ezra-g commentedThanks for your attention here. Actually, I think this is a bug in Nodequeue.module. While your fix does in fact work, I believe it's not the proper place to change the permission checking.
"Manipulate all og nodequeues" is supposed to be used to control access to not only to manipulating og subqueues, but also for administering the queue that contains all og queues. The callback for the path admin/content/nodequeue/%nodequeue/add/%subqueue/%node (and the equivalent path for removing a node) should really call a "nodequeue_node_and_subqueue_access" function rather than the current "nodequeue_node_and_queue_access" since the smartqueue api allows users permission to manipulate a specific subqueue (such as an og or per-user subqueue) without being able to administer the whole queue.This should be a relatively straightforward fix.
Please note that this is not an access bypass or any kind of security issue, since if anything, this access check is overly restrictive.
Comment #2
ezra-g commentedActually, we don't need a new access checking function since nodequeue_queue_access accepts an optional subqueue parameter. This patch changes it so that subqueue_api access control is called and the result returned before queue access, so more granular access control is possible :D. Hooray, smartqueue API!
This is basically commitable, but I'll leave in the queue for testing for a little while.
Comment #3
ezra-g commentedComment #4
ezra-g commentedThis is applied.