fix: add ability to call external endpoints without explicitly allowing them in non webWorker storage modes
#274
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Purpose
This pull request introduces several important updates across the SDKs, focusing on improving security around external API requests and simplifying documentation for better developer experience. The most significant changes are the introduction of the
allowedExternalUrlsconfiguration option (replacingresourceServerURLs) for controlling where access tokens can be sent, and the removal of verbose quick start and installation instructions from multiple SDK README files.Security and Configuration Updates
resourceServerURLsconfiguration property withallowedExternalUrlsinSPAConfigand related interfaces, clarifying its purpose and improving naming consistency. This restricts which external URLs can receive access tokens, especially when using WebWorker storage. (packages/browser/src/__legacy__/models/client-config.ts,packages/javascript/src/models/config.ts) [1] [2]authentication-helper.tsto useallowedExternalUrlsinstead ofresourceServerURLs, ensuring that token attachment and endpoint validation only occur for explicitly allowed URLs when using WebWorker storage. (packages/browser/src/__legacy__/helpers/authentication-helper.ts) [1] [2] [3] [4] [5] [6] [7] [8]Documentation Simplification
@asgardeo/javascript,@asgardeo/node,@asgardeo/express,@asgardeo/nextjs, and@asgardeo/nuxtSDKs. Instead, these now direct users to official guides or warn against direct usage, emphasizing the use of framework-specific SDKs for integrations. (packages/javascript/README.md,packages/node/README.md,packages/express/README.md,packages/nextjs/README.md,packages/nuxt/README.md) [1] [2] [3] [4] [5]License Notice Update
LICENSEfile. (packages/browser/README.md,packages/javascript/README.md,packages/node/README.md,packages/express/README.md,packages/nextjs/README.md,packages/nuxt/README.md) [1] [2] [3] [4] [5] [6]These changes enhance the security of token handling, make configuration clearer, and streamline the documentation for easier onboarding and correct usage.
Related Issues
resourceServerURLseven when the storage is notwebWorker#270Related PRs
Checklist
Security checks