Snyk has a proof-of-concept or detailed explanation of how to exploit this vulnerability.
The probability is the direct output of the EPSS model, and conveys an overall sense of the threat of exploitation in the wild. The percentile measures the EPSS probability relative to all known EPSS scores. Note: This data is updated daily, relying on the latest available EPSS model version. Check out the EPSS documentation for more details.
In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.
Test your applicationsLearn about Incorrect Authorization vulnerabilities in an interactive lesson.
Start learningUpgrade @better-auth/oauth-provider to version 1.7.0-beta.4 or higher.
@better-auth/oauth-provider is an An oauth provider plugin for Better Auth
Affected versions of this package are vulnerable to Incorrect Authorization due to the OAuth token and refresh flows in packages/oauth-provider/src/token.ts, packages/oauth-provider/src/authorize.ts, and packages/oauth-provider/src/consent.ts. An attacker can obtain an access token for an allow-listed audience that the authorization grant never covered by supplying a different resource value at the token endpoint, or widen a refresh token to another audience by redeeming it with a new resource value. This lets a client use a token at a resource server that the user did not authorize, causing unauthorized access to resource-specific APIs and data when those servers trust the token’s aud or resource claim.
Workarounds
validAudiences to a single audience, or leave it unset so it defaults to your base URL; this prevents clients from choosing a different allow-listed resource at the token endpoint.aud, and reject tokens whose aud is an array that also lists other audiences; this limits use of tokens minted for multiple resources.resource indicator as an authorization boundary until you upgrade to a release that includes the fix; this avoids treating an unbound audience as proof of user authorization.