NewApp Monitoring is liveSign up free
AgentbeamBeta
Open-source package vulnerability · npm

CVE-2026-105863: Payload authentication token field handling issue

criticalCVSS 4.0 9.2GHSA-66wr-7vmr-p5jq

Payload CMS (npm package payload) can put unintended values into the login token when a field maps itself to a reserved authentication claim name. That can let user-controlled data override claims such as the user id. Payload 3.90.0 and 4.0.0-canary.34 fix it. No complete workaround exists.

Published Oct 7, 2026 · Analysis Oct 25, 2026

What an attacker can do

Payload lets you copy chosen user fields into the JWT with the saveToJWT field option, which can also rename the key. Before the fix, a field could use a reserved claim name and replace the value Payload itself had set. The fix's tests cover id, collection, email, sid, iat, exp and authVersion.

If a user can write to such a field, for example through a profile update, the next token they get at login can carry a forged id, email or collection. The result is a token that names another account. Whether that works depends on your field configuration and access rules, so the advisory marks it as conditional on a custom field option. It scores 9.2 under CVSS 4.0, with attack-requirements set because the configuration must exist.

A project with no saveToJWT mapping to a reserved name is not exposed through this path.

Who is affected

Affected: payload from 3.0.0 up to but not including 3.90.0, and 4.0.0-canary.0 up to but not including 4.0.0-canary.34. You are at risk if a field in an auth collection uses saveToJWT with a key that equals a reserved claim name. Search your collection configs for saveToJWT.

npm ls payload

payload

Ecosystem
npm
Affected
>= 3.0.0, < 3.90.0
Fixed in
3.90.0
Check
npm ls payload

payload

Ecosystem
npm
Affected
>= 4.0.0-canary.0, < 4.0.0-canary.34
Fixed in
4.0.0-canary.34
Check
npm ls payload

How to fix it

Upgrade to payload 3.90.0, or 4.0.0-canary.34 on the v4 canary line, and move the other Payload packages to match.

npm install [email protected]

The fix in getFieldsToSign.ts drops collection, email, exp, iat, id and sid from field-derived values, then sets id, collection, email and sid from trusted data. It also writes authVersion: 1 into the token header. Tokens issued before the upgrade lack that marker, so users and integrations holding stored bearer tokens must sign in again. The advisory says there is no complete workaround.

How to tell if you were hit

Review your collection configs for saveToJWT fields whose names match reserved claims. Decode a few recent tokens (the payload is base64 JSON) and check that id, email and collection match the user who signed in. Look in auth logs for sessions whose user id differs from the account that logged in. The sources publish no other indicators.

Original advisory

From the GitHub Advisory Database (CC BY 4.0).

Impact

Under certain field configurations, Payload could include unintended values in the authentication token issued at login.

You are affected if:

  • You use an affected Payload version and have configured a custom field option that maps a field to a reserved authentication claim name.

Patches

Payload now restricts which field configuration options can influence the contents of the authentication token.

Users should upgrade payload packages to >= 3.90.0 or >= 4.0.0-canary.34.

Workarounds

There is no complete workaround. Users should upgrade payload packages to >= 3.90.0 or >= 4.0.0-canary.34.

Credited to Zerotistic.

Questions

Do I need to log everyone out after upgrading?

Tokens issued before the fix lack the authVersion header marker, per the commit's docs. They must be replaced by signing in again, so stored bearer tokens in integrations need reissuing.

Which setting triggers CVE-2026-105863?

A custom field option that maps a field to a reserved authentication claim name. In the fix this is the saveToJWT option with names like id, email, collection or sid.

Is there a workaround?

The advisory says there is no complete workaround and tells users to upgrade. Removing reserved-name mappings from saveToJWT fields reduces exposure, but the vendor does not list it as a fix.

References

How this page is made: the data panel comes from the GitHub Advisory Database, CISA’s KEV catalog, the NVD and FIRST EPSS, and updates twice a day. The analysis is written by an AI model from the sources listed above and checked by automated rules before it is published. Check versions against the vendor's advisory before you act. Methodology

More npm vulnerabilities

All npm entries