Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(admin-ui): large header issue #1398

Closed
moabu opened this issue Oct 18, 2023 · 5 comments · Fixed by #1415
Closed

fix(admin-ui): large header issue #1398

moabu opened this issue Oct 18, 2023 · 5 comments · Fixed by #1415
Assignees
Labels
bug Something isn't working comp-admin-ui Component affected by issue or PR kind-bug Issue or PR is a bug in existing functionality

Comments

@moabu
Copy link
Member

moabu commented Oct 18, 2023

Describe the bug

Looks like this is caused when a client has too many scopes stuffed in the jwt in the Authorization header, which causes the request header fields too large error

image003
image002

@moabu moabu added the bug Something isn't working label Oct 18, 2023
@mo-auto mo-auto added comp-admin-ui Component affected by issue or PR kind-bug Issue or PR is a bug in existing functionality labels Oct 18, 2023
@duttarnab
Copy link
Contributor

duttarnab commented Oct 18, 2023

Can the team please share the authorization header? I will check the scopes added.

We will make changes in admin-ui so that instead of adding all scopes to the auth token ... we will add scopes based on the requested config-api endpoint.

@nynymike
Copy link
Contributor

Please expedite this fix for the next release of Flex.

@duttarnab
Copy link
Contributor

sure, we are working on this.

@duttarnab
Copy link
Contributor

Backend changes Update: (JanssenProject/jans#6413)

We have drafted a PR. The /api-protection-token has been modified. We have added a parameter called permissionTag (an array) to the request body. The endpoint will only add permissions (scopes) to the config-api token whose tags are included in the permissionTag parameter. This will help in including only the permissions in the token that are required for making a request. Hence, it will reduce the length of the token.

Forntend changes required:

The front-end (FE) will retrieve tags from a request-tag mapping configuration file and include them in the permissionTag parameter when making the request.

cc: @jv18creator

jv18creator added a commit that referenced this issue Oct 31, 2023
Signed-off-by: Jeet Viramgama <jviramgama5@gmail.com>
@jv18creator
Copy link
Contributor

Admin UI will check for individual access token with tag, based on it, FE will call /api-protection-token which will generate access_token for specific permission. If there's already an access_token for that permission then we'll reuse that access token from redux store.

duttarnab added a commit that referenced this issue Oct 31, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working comp-admin-ui Component affected by issue or PR kind-bug Issue or PR is a bug in existing functionality
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants