api-manager
api-manager copied to clipboard
Intermittent Hanging When Generating Access Tokens With Scopes
Description
Generating access tokens with scopes hangs indefinitely. generate-token request is not sent, only the oauth-keys request is sent. oauth-keys request status is 200 and following is the reference. Also a screenshot is attached below.
{
"count": 1,
"list": [
{
"keyMappingId": "fc5f3249-8844-4041-920f-7d19752608f4",
"keyManager": "Resident Key Manager",
"consumerKey": "xcr7uosPLedFby9BMSfwFsEM7TEa",
"consumerSecret": "86ZkoGtesVHWCNGk8QBTtsU9uMoa",
"supportedGrantTypes": [
"password",
"client_credentials"
],
"callbackUrl": "",
"keyState": "COMPLETED",
"keyType": "PRODUCTION",
"mode": "CREATED",
"groupId": null,
"token": {
"accessToken": null,
"tokenScopes": [],
"validityTime": 0
},
"additionalProperties": {
"id_token_expiry_time": 3600,
"application_access_token_expiry_time": 3600,
"user_access_token_expiry_time": 3600,
"bypassClientCredentials": false,
"pkceMandatory": false,
"pkceSupportPlain": false,
"refresh_token_expiry_time": 86400
}
}
]
}
Steps to Reproduce
- Subscribe to an API an try to generate an access token with scopes.
Version
4.5.0-alpha
Environment Details (with versions)
No response
Attempted to reproduce the issue in the 4.5.0 pack (using Resident KM) but was unable to replicate the reported bug.
Upon reviewing the code, clicking the "Generate Access Token" button triggers generateAccessToken() in ViewKeys.jsx, which internally calls application.generateToken(). This is likely where the inconsistent behavior occurs.
Additionally, the issue could be related to network instability.