[ 
https://issues.apache.org/jira/browse/RANGER-5892?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Ramachandran Krishnan updated RANGER-5892:
------------------------------------------
    Description: 
With header-based trusted-proxy authentication, the identity layer sends 
lowercase authz role names and often colon-scoped values (e.g. 
{{{}authz-role-admin{}}}, {{{}namespace:authz-role-admin{}}}). Ranger must map 
those to internal portal roles, apply them consistently for the logged-in user, 
and avoid breaking the Admin UI (Users list and profile).
h2. Ranger-side requirements

1.Lowercase external role names
 Accept {{{}authz-role-admin{}}}, {{{}authz-role-user{}}}, 
{{{}authz-role-auditor{}}}, etc. (not legacy {{AUTHZ_ROLE_ADMIN}} style only).

2.Colon-scoped (namespaced) role tokens
 For each comma-separated token in the configured roles header, if the value 
contains {{{}:{}}}, use the suffix after the first {{:}} as the lookup key.
 Examples:
 * 
 ** {{authz-role-admin}} → {{ROLE_SYS_ADMIN}}
 ** {{namespace:authz-role-admin}} → {{ROLE_SYS_ADMIN}}
 ** {{prefix:authz-role-user}} → {{ROLE_USER}}
 Unrecognized tokens (e.g. other global/platform roles) are ignored with a 
warning; they must not break parsing of valid authz roles.

3.End-to-end header auth behavior (beyond mapping only)
 * 
 ** Trusted-proxy roles reflected in session and profile for the logging-in 
user.
 ** Users/Groups module access for effective admin (so user list APIs do not 
mask {{userRoleList}} as {{{}*****{}}}).
 ** Profile API returns a single consolidated effective role when DB + header 
produced multiple entries.
 ** UI tolerates multi-role responses where consolidation is not applied 
(primary-role helper).

  was:
With header-based trusted-proxy authentication, the identity layer sends 
lowercase authz role names and often colon-scoped values (e.g. 
{{{}authz-role-admin{}}}, {{{}namespace:authz-role-admin{}}}). Ranger must map 
those to internal portal roles, apply them consistently for the logged-in user, 
and avoid breaking the Admin UI (Users list and profile).
h2. Ranger-side requirements
 # Lowercase external role names
 Accept {{{}authz-role-admin{}}}, {{{}authz-role-user{}}}, 
{{{}authz-role-auditor{}}}, etc. (not legacy {{AUTHZ_ROLE_ADMIN}} style only).

 # Colon-scoped (namespaced) role tokens
 For each comma-separated token in the configured roles header, if the value 
contains {{{}:{}}}, use the suffix after the first {{:}} as the lookup key.
 Examples:

 ** {{authz-role-admin}} → {{ROLE_SYS_ADMIN}}
 ** {{namespace:authz-role-admin}} → {{ROLE_SYS_ADMIN}}
 ** {{prefix:authz-role-user}} → {{ROLE_USER}}
 Unrecognized tokens (e.g. other global/platform roles) are ignored with a 
warning; they must not break parsing of valid authz roles.
 # End-to-end header auth behavior (beyond mapping only)

 ** Trusted-proxy roles reflected in session and profile for the logging-in 
user.
 ** Users/Groups module access for effective admin (so user list APIs do not 
mask {{userRoleList}} as {{{}*****{}}}).
 ** Profile API returns a single consolidated effective role when DB + header 
produced multiple entries.
 ** UI tolerates multi-role responses where consolidation is not applied 
(primary-role helper).


> Apply header roles on login and fix Users/Profile UI for multi-role profile
> ---------------------------------------------------------------------------
>
>                 Key: RANGER-5892
>                 URL: https://issues.apache.org/jira/browse/RANGER-5892
>             Project: Ranger
>          Issue Type: Improvement
>          Components: Ranger
>            Reporter: Ramachandran Krishnan
>            Assignee: Ramachandran Krishnan
>            Priority: Major
>             Fix For: 3.0.0
>
>
> With header-based trusted-proxy authentication, the identity layer sends 
> lowercase authz role names and often colon-scoped values (e.g. 
> {{{}authz-role-admin{}}}, {{{}namespace:authz-role-admin{}}}). Ranger must 
> map those to internal portal roles, apply them consistently for the logged-in 
> user, and avoid breaking the Admin UI (Users list and profile).
> h2. Ranger-side requirements
> 1.Lowercase external role names
>  Accept {{{}authz-role-admin{}}}, {{{}authz-role-user{}}}, 
> {{{}authz-role-auditor{}}}, etc. (not legacy {{AUTHZ_ROLE_ADMIN}} style only).
> 2.Colon-scoped (namespaced) role tokens
>  For each comma-separated token in the configured roles header, if the value 
> contains {{{}:{}}}, use the suffix after the first {{:}} as the lookup key.
>  Examples:
>  * 
>  ** {{authz-role-admin}} → {{ROLE_SYS_ADMIN}}
>  ** {{namespace:authz-role-admin}} → {{ROLE_SYS_ADMIN}}
>  ** {{prefix:authz-role-user}} → {{ROLE_USER}}
>  Unrecognized tokens (e.g. other global/platform roles) are ignored with a 
> warning; they must not break parsing of valid authz roles.
> 3.End-to-end header auth behavior (beyond mapping only)
>  * 
>  ** Trusted-proxy roles reflected in session and profile for the logging-in 
> user.
>  ** Users/Groups module access for effective admin (so user list APIs do not 
> mask {{userRoleList}} as {{{}*****{}}}).
>  ** Profile API returns a single consolidated effective role when DB + header 
> produced multiple entries.
>  ** UI tolerates multi-role responses where consolidation is not applied 
> (primary-role helper).



--
This message was sent by Atlassian Jira
(v10.3.26#10030026)

Reply via email to