Compared to the D5 version, I don't see any difference when I toggle the permissions of "Edit posts" or "Delete posts" in D6. D6 is using the information of "User management -> Permissions" which has been enhanced in D6 but Forum Access does not overwriting these permissions.

Additionally if I add moderators, I don't see more permissions for them. Maybe I overlooked something and I am happy for any hint.

Comments

salvis’s picture

There are not supposed to be any differences between the D5 and D6 versions.

FA has nothing to do with permissions.

Follow the directions that were displayed when you created the issue, create a post and look at the node_access entries to see what FA is doing.

netpat’s picture

Sorry about that. Here more details:

The following data has been catched in a forumboard where I have activated all access-options in FA for authenticated user:

node	realm	gid	view	update	delete	explained
Test 2	forum_access	1	1	0	0	anonymous user
Test 2	forum_access	2	1	1	1	authenticated user

But an authenticated user cannot edit or delete a message before I haven't activated "edit/delete any forum topic" under the D6 permissions. On the other way when I deny access in FA, the authenticated user can still edit / delete messages except I adjust the D6 permissions. It looks like these FA settings will be overwritten by the D6 internal permissions.

BTW: View and Create is working as expected.

BTW2: Thanks for the great modules.

salvis’s picture

Thank you for completing the picture. This is actually a bug in core.

See #153998: Access checks returning NULL is ugly. and try the patch in #91.

netpat’s picture

Thank you... great work. With your patch it seems to work.

Let's say when I don't use "Edit posts" and "Delete posts" then I don't need the core patch or even then it is suggested?

As a result of my tests I assume, that the moderators-feature is "only" permitting common access (view) to the forum. If a moderator can edit or delete posts has to be defined in the core permissions?

salvis’s picture

Well, it's a bug in core and it should be committed at some point. Node access control is just not working without it.

The moderator should have full access without needing any permissions at all, and it works for me (with the core patch). Does it not work for you?

If you want to investigate further, install the devel_node_access patch in http://drupal.org/node/241060#comment-797217 and you'll see much more detail about what's going on.

salvis’s picture

It turns out there were dumb bugs in my patch. Please undo the patch in $91 and apply this one: http://drupal.org/node/153998#comment-812767

salvis’s picture

Title: No function of "Edit posts", "Delete posts" and "Moderators"? » PLEASE REVIEW!!! — Bug in Drupal Core 6 silently disables half of the node access mechanism
Status: Active » Needs review

The patch is in #153998: Access checks returning NULL is ugly. #93 (or later).

Please review and comment, so the patch can get committed.

netpat’s picture

I found out that the moderator-feature is working when I rebuild the permissions after adding a moderator. Otherwise only newer messages created after defining the moderator(s) are working as supposed.

Thanks for your great support. Together with your core-patch it seems to work as it should.

salvis’s picture

Yes, the need to manually rebuild the permissions to enable the moderator for pre-existing nodes is a left-over from the D5 version that I will remove before releasing 6.x-1.0.

Thanks for your help with this!

salvis’s picture

Title: PLEASE REVIEW!!! — Bug in Drupal Core 6 silently disables half of the node access mechanism » Bug in Drupal Core 6.2 silently disables half of the node access mechanism
Status: Needs review » Active

I leave this open as a signpost until Drupal 6.3 is out.

deekayen’s picture

subscribing

nmashruwala’s picture

subscribing

Anonymous’s picture

Subscribing

raider.adam’s picture

Just to clarify, if I am just want to make public and private forums based on user roles, the module as is works sufficiently?

salvis’s picture

It's hard to say. Since D6 doesn't let any node access module supply any grants, FA can't grant access to anything.

CinemaSaville’s picture

So the question is, if I install this in 6.2 am I risking major disruption with my site? Also, as a relative novice, how do implement the patch referred to above? Basically this thing has become crucial as I'm having major issues with core Forum module not allowing access to anonymous users.

Thanks

salvis’s picture

@cinemasaville: No, please don't try this. As a "relative novice", you should install only modules with real (green) releases. Adding unreleased modules to a site that is already not functioning correctly, will not improve things.

See the Handbook or search for "patch" for information about patching.

Daitaka’s picture

Okay, it's all just a bit confusing so I'd like to ask for some clarification.

My site runs fine now (well, not 100% but those issues aren't related). I have a few forums and a few roles and I'd like to restrict some forums so that only some roles can post in them.

If I apply the patch from http://drupal.org/node/153998#comment-818688 and I install your 6.x-1.x-dev version, will it actually work? Or would that just be a waste of my time?

salvis’s picture

I *hope* it will work. However, 6.x-1.x-dev is a beta version — it's intended for testing (on a Drupal version that is not yet available!), and not for production use.

So, you can help to advance this by applying the patch, installing FA, and testing and providing feedback, but I cannot provide reasonable assurance of whether it will work.

naheemsays’s picture

Since drupal 6.3 is out, should this bug be marked fixed? (and the warning removed from the project page/modified to indicate that it only applied to older versions of drupal)

salvis’s picture

Good question — have you tried it?

naheemsays’s picture

The moderator should have full access without needing any permissions at all, and it works for me (with the core patch). Does it not work for you?

I just tried it again and it seems to work for nodes, but not for comments.

Just tried adding a user as an administrator for a forum, but not having admin comments permission in permissions. The user can only see quote and reply on comments, not edit or delete.

Not sure if this is the expected behaviour or not. If it is, the module works :P

Anonymous’s picture

Same here. The moderator can edit all nodes but only his own comments without a reply. As a moderator he should be able to edit all comments of all users with and without replies.

=> #206207: Moderators cannot delete or edit other user comments?

naheemsays’s picture

k, in that case, this bug is fixed - that is another bug.

salvis’s picture

Status: Active » Fixed

Great, now we can finally turn to testing FA for D6.

#206207: Moderators cannot delete or edit other user comments? is not a bug, but a missing feature. I agree that it's a highly desirable feature, but it's just not implemented yet...

Anonymous’s picture

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.