You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Policy decision resolve to 403 despite user being allowed to access specified resource #347
Describe the bug
Policy decision resolve to 403 forbidden despite usergroup (that current user belong to) are configured to allow access to affected URL.
Prerequisite
Configure OpenIG to be Policy Enforcement Point and OpenAM as Policy Decision Point.
Desktop (please complete the following information):
OS: Windows 10
Browser Chrome(88.0.4324.150), Firefox (85.0.2)
Additional context
If Subjects are updated to "subject": { "type": "AuthenticatedUsers" }
user1 are now able to access https://sample.app.io:443/AlarmList.html without encountering Forbidden page
We are still experiencing this issue with OpenAM 14.7.3. Through more trial-and-error, I noted that this authorization problem is not present if I either:
Allow all authenticated users.
Allow a specific user by user ID, rather than group ID.
Within the logs of OpenAM, it appears that the user's membership is not being evaluated properly:
amPolicy:09/22/2023 03:08:19:872 PM SGT: Thread[http-nio-9090-exec-3,5,main]: TransactionId[271a46e7-3501-44c6-9e6d-86bafaa95f04-114]
AMIndentitySubject.isMember(): entering with userDN = id=admin,ou=user,o=iot_platform,o=wisx,ou=services,dc=openam,dc=forgerock,dc=org
amPolicy:09/22/2023 03:08:19:873 PM SGT: Thread[http-nio-9090-exec-3,5,main]: TransactionId[271a46e7-3501-44c6-9e6d-86bafaa95f04-114]
AMIndentitySubject.isMember(): checking membership with userDN = id=admin,ou=user,o=iot_platform,o=wisx,ou=services,dc=openam,dc=forgerock,dc=org, subjectValue = id=admingroup,ou=group,o=IOT_Platform,o=WISX,ou=services,dc=openam,dc=forgerock,dc=org
amPolicy:09/22/2023 03:08:19:873 PM SGT: Thread[http-nio-9090-exec-3,5,main]: TransactionId[271a46e7-3501-44c6-9e6d-86bafaa95f04-114]
IdentitySubject:isMember():entry for id=admingroup,ou=group,o=IOT_Platform,o=WISX,ou=services,dc=openam,dc=forgerock,dc=org not in subject evaluation cache, so compute using IDRepo api
amPolicy:09/22/2023 03:08:19:873 PM SGT: Thread[http-nio-9090-exec-3,5,main]: TransactionId[271a46e7-3501-44c6-9e6d-86bafaa95f04-114]
IdentitySubject.isMember():user uuid = id=admin,ou=user,o=iot_platform,o=wisx,ou=services,dc=openam,dc=forgerock,dc=org, subject uuid = id=admingroup,ou=group,o=IOT_Platform,o=WISX,ou=services,dc=openam,dc=forgerock,dc=org
amPolicy:09/22/2023 03:08:19:873 PM SGT: Thread[http-nio-9090-exec-3,5,main]: TransactionId[271a46e7-3501-44c6-9e6d-86bafaa95f04-114]
IdentitySubject.isMember():userIdentity type IdType: user can be a member of subjectIdentityType IdType: group:membership=false
OpenAM's UI recognizes that the "admin" user is a member of "admingroup".
This is what works for me (not ideal for our usecases):
Does anyone have any hints for me, as to what might be wrong? I find it difficult to believe that something this essential, does not work in the open-source version of AM, so surely I must have overlooked something.
My config & user data store is opendj 4.5.6.
It would appear that the session user's realm has been transformed to lowercase, but the comparison is case-sensitive. I think it may be an unusual choice for comparing X.500 principals, but I do not know enough about AM's design to know if it is actually permissible. The relevant change might have been 500040f, which was made back in 2019.
If I started with 14.4.2 before attempting to upgrade to 14.5.1, this issue will appear after the upgrade. 14.4.2 was the last version before this commit was included in any releases.
Activity
sp193 commentedon Sep 22, 2023
We are still experiencing this issue with OpenAM 14.7.3. Through more trial-and-error, I noted that this authorization problem is not present if I either:
Within the logs of OpenAM, it appears that the user's membership is not being evaluated properly:
OpenAM's UI recognizes that the "admin" user is a member of "admingroup".

This is what @glchua2 tried:

This is what works for me (not ideal for our usecases):

Does anyone have any hints for me, as to what might be wrong? I find it difficult to believe that something this essential, does not work in the open-source version of AM, so surely I must have overlooked something.
My config & user data store is opendj 4.5.6.
sp193 commentedon Sep 22, 2023
I attached a remote debugger to it, to step through the code that evaluates the membership of the user & the user group.
From the point where the evaluation is made:
... which calls AMIdentity.isMember(), where there is:
At this point, if I print the two values:
It would appear that the session user's realm has been transformed to lowercase, but the comparison is case-sensitive. I think it may be an unusual choice for comparing X.500 principals, but I do not know enough about AM's design to know if it is actually permissible. The relevant change might have been 500040f, which was made back in 2019.
If I started with 14.4.2 before attempting to upgrade to 14.5.1, this issue will appear after the upgrade. 14.4.2 was the last version before this commit was included in any releases.
FIX prevent calculate AMIdentity.isMember across realms equalsIgnoreC…
FIX prevent calculate AMIdentity.isMember across realms equalsIgnoreC…
sp193 commentedon Oct 7, 2023
The fix appears to have solved the problem. So once it is made into a release, we can close this issue. Thanks @vharseko .
CVE-2026-86472 CVE-2026-110095 CVE-2026-110180 CVE-2026-110306 CVE-20…