Hi,
I'm trying to use Domain strict in order to make 1 of several domain available only for specific people.
I work with a fresh Drupal 7.8 install, I only activated devel for debugging, phpfilter, domain access (2.14) and domain strict.
I created three domain : main.exemple.com, site2.exemple.com, specific.example.com.
Content creation settings set on " only show on selected sites".
User defaults : set "add default roles dynamically", anonymous and registered users are set part of main.example. and site2.example.com, and I created another role "specific" which is the only one to be part of specific.example.com.
But there is no difference with or without Domain Strict activated : content is viewable by every role.
Domain access work : content is not viewable outside of the domain. But Domain strict doesn't work : specific content is viewable by registered and anonymous, and specific.
Devel show me that everyone has a node access. I thought Domain Strict was granting access, so I deactivated the view published content permission, but no content is viewable then, despite the fact that roles are part of a domain.
I don't undertand where the matter lie. This single deactivation make devel to show that there is no more granted permission to view. So domain strict doesn't grant extra permission when activated, but doesn't block user to view specific content. So I think I made an error when installing it but all tests I found on the web to check works fine.
| Comment | File | Size | Author |
|---|---|---|---|
| #7 | Screen shot 2011-09-25 at 4.17.22 PM.png | 53.62 KB | agentrickard |
| #1 | 1288770-strict-update.patch | 464 bytes | agentrickard |
Comments
Comment #1
agentrickardWell, it looks like hook_domaingrants() has been deprecated and the module not updated. I thought we had covered that.
Here's a patch. Apply the patch and then clear the site cache (including the {cache_bootstrap} table).
Comment #2
agentrickardAlso needs a test....
Comment #3
Shimegi commentedIt works fine now .. thinking a spend some our to be sure I wasn't making mistake.
Thanks a lot. I'm not very at ease with development stuff so I let you change the status.
Comment #4
Shimegi commentedI forgot yesterday,
I applied the patch manually, and there is only one line to replace where the patch replace one with several :
In fact the three last line are already there, we have to replace
function domain_strict_domaingrants(&$grants, $account, $op) {by
function domain_strict_node_grants_alter(&$grants, $account, $op) {only.
Comment #5
agentrickardYes. See http://drupal.org/patch/apply. Only lines prefixed with + or - are actual changed. This patch is correct.
Marking "needs work" for the test.
Comment #6
agentrickardPatch has been committed to both 7.x.2 and 7.x.3. Writing the test now.
Comment #7
agentrickardNow with tests.
Thanks for the quick review, @Shimegi.
Comment #9
Madhuri A commentedComment #10
agentrickardReopening an issue without comment or detail is just plain rude.