XF 1.2 Random Permission Error

Divvens

Well-known member
Hello,

I seem to have a weird problem coming up. One of my members informed me that they cannot access any part of my site all of a sudden (note, it worked fine just 10 minutes back) they get a error regarding permission on ALL pages of the forum.

Error
You do not have the permission to view this page or perform this action.

Untitled.webp

I checked the permissions for the user, everything seems fine. They can also see the board while not logged in. I ran the permission analyzer and it seems to give me a report that the permissions are fine.

Problem.webp

So what exactly is the problem here? When I use the "Test Permissions" tool for that user even I get the same error everywhere.
 
Last edited:
Unfortunately, if the issue happens consistently, database access would be needed to debug it. Adding the user to a group and then removing them from it may resolve it; alternatively, rebuilding user caches can help. Add-ons can (and bugs in them definitely have) interfered with permission rebuilds. Disabling the add-on afterwards doesn't resolve the issue because the data was already corrupted.
 
Unfortunately, if the issue happens consistently, database access would be needed to debug it. Adding the user to a group and then removing them from it may resolve it; alternatively, rebuilding user caches can help. Add-ons can (and bugs in them definitely have) interfered with permission rebuilds. Disabling the add-on afterwards doesn't resolve the issue because the data was already corrupted.
It has only been reported once and it has happened only once, but would you be able to get any information from the database afterwards? If so, I can open a ticket and let you know the details required to take a look, because I'm completely unaware of which add-on is causing this problem, since I don't use the Steam Auth add-on that the others are using which they think is causing the problem.

Or if you want I could open a ticket the next time such an issue occurs (if it occurs). The member that had this problem had me on skype an informed me asap, but some may not even know how to contact us since even the "contact form" is not accessible when they get this permission error.
 
I think the data within table "xf_permission_combination" may have been corrupted/incorrectly rebuilt at some point. However, as @Eoj Nawoh reported in his thread, the problem randomly come back after a few minutes without permission changes in AdminCP so it may be a caching issue. Do you happen to use a Cache (as instructed here)? Also worth noting that the permission data is prepared within XenForo_Model_User so an add-on extending that class may be the problem too. Lots of potential causes here.

If @Divvens or @Eoj Nawoh need my help, you can start a conversation with me when it's happening with an user. Please do not change anything when that happens though, to investigate the root cause.
 
I think the data within table "xf_permission_combination" may have been corrupted/incorrectly rebuilt at some point. However, as @Eoj Nawoh reported in his thread, the problem randomly come back after a few minutes without permission changes in AdminCP so it may be a caching issue. Do you happen to use a Cache (as instructed here)? Also worth noting that the permission data is prepared within XenForo_Model_User so an add-on extending that class may be the problem too. Lots of potential causes here.

If @Divvens or @Eoj Nawoh need my help, you can start a conversation with me when it's happening with an user. Please do not change anything when that happens though, to investigate the root cause.
Hey, thanks for helping out! :) Hmm, I'll go through the add-on files and look at how many add-ons extend the Model_User class. Then maybe we can figure it out which add-on is causing this/likely to cause this.

And the next time this happens I'll let you know, thankfully for us it hasn't repeated again, but it's scary since if it repeats with someone who has no means to contact me (or the other admin off-site) they cannot even use the contact form to let us know of the issue.
 
Last edited:
I think the data within table "xf_permission_combination" may have been corrupted/incorrectly rebuilt at some point. However, as @Eoj Nawoh reported in his thread, the problem randomly come back after a few minutes without permission changes in AdminCP so it may be a caching issue. Do you happen to use a Cache (as instructed here)? Also worth noting that the permission data is prepared within XenForo_Model_User so an add-on extending that class may be the problem too. Lots of potential causes here.

If @Divvens or @Eoj Nawoh need my help, you can start a conversation with me when it's happening with an user. Please do not change anything when that happens though, to investigate the root cause.
I'm not sure how exactly can I find if a add-on is extended XenForo_Model_User, but from the add-ons I have installed
- Nodes As Tabs
- Double Post Merger
- Widget Framework

Make use of permissions in some or the other way. Nodes As Tabs only respects current permissions, doesn't make permissions of its own.

I think if the problem re-occurs and if it's reported to me I'll open a support ticket and let the xF guys have a look at whats causing this, and in-case they aren't looking at it due to third party add-on causing an issue I'll get in touch with you @xfrocks
 
Hey @Divvens. Keep me in the loop of what you find if you could. @arms and @Eoj Nawoh have come to me about the SteamAuth addon causing this issue, but you don't have it installed and I can't replicate the problem on my dev site or my main site using my addon.

Nobody else that uses SteamAuth addon has reported this so I'm not sure if it's the cause or not.
 
Hey @Divvens. Keep me in the loop of what you find if you could. @arms and @Eoj Nawoh have come to me about the SteamAuth addon causing this issue, but you don't have it installed and I can't replicate the problem on my dev site or my main site using my addon.

Nobody else that uses SteamAuth addon has reported this so I'm not sure if it's the cause or not.
Will do :) If the problem replicates and if I come to know/am reported about the issue I'll inform you. Indeed, I don't have your add-on installed! And it's a problematic issue, seems that it can only be looked into when the problem is happening. So far after my first report by the user who was facing this issue, no other such report has come up. I think partially because I set all groups permissions for "view" and "view node" to yes or due to add-on upgrades rebuilding permissions/changes in usergroups rebuilding permissions.

If anything pops up I'll be sure to let you know :)

Edit: Just incase @arms or @Eoj Nawoh want to compare add-ons we are running and possibly try to see if any other add-on could also be causing an issue, here's a screenshot of add-ons being used on my board.
Addons.webp
 
Will do :) If the problem replicates and if I come to know/am reported about the issue I'll inform you. Indeed, I don't have your add-on installed! And it's a problematic issue, seems that it can only be looked into when the problem is happening. So far after my first report by the user who was facing this issue, no other such report has come up. I think partially because I set all groups permissions for "view" and "view node" to yes or due to add-on upgrades rebuilding permissions/changes in usergroups rebuilding permissions.

If anything pops up I'll be sure to let you know :)

Edit: Just incase @arms or @Eoj Nawoh want to compare add-ons we are running and possibly try to see if any other add-on could also be causing an issue, here's a screenshot of add-ons being used on my board.
View attachment 59702

We have Sitemap, Widget Framework and Nodes as Tabs in common. But if I've read your posts correctly, it seems your issue is a little different. Yours continue upon all addons being disabled. Not to mention, it happens for all pages and everything. While for our issue, it stops when all addons are disabled, or just Steam Auth. It only happens on the first page they click and refreshing removes the problem temporarily.

@arms @HowIChrgeLazer
 
We have Sitemap, Widget Framework and Nodes as Tabs in common. But if I've read your posts correctly, it seems your issue is a little different. Yours continue upon all addons being disabled. Not to mention, it happens for all pages and everything. While for our issue, it stops when all addons are disabled, or just Steam Auth. It only happens on the first page they click and refreshing removes the problem temporarily.

@arms @HowIChrgeLazer
Yes you are right, it happens on all pages and even contact form, and doesn't go away if add-ons are disabled. Refreshing doesn't help either in my case, so we both may have separate issues.
 
@Mike @HowIChrgeLazer @xfrocks

I'm having this permission error re-occur again, the user was just promoted via the user group promotion and the user gets an error saying on any page visited.
IMG_13112013_192838.webp

It hasn't occurred (or reported) to me since the last time and just happened now. The user was just promoted to a new group via the user-group promotion, no special permissions and all says yes in permission checks. @Mike should I open a support ticket so you can look into it?
 
Infact, the last time this occurred was also when a user was promoted and then visited the site 10/15 minutes later, when I look back the two incidents are very similar.
 
Top Bottom