llamaCVEVulnerability Intelligence
/
Advisory · GitHub · npm · @strapi/plugin-users-permissions

GHSA-XV3Q-JRMM-4FXV

Authentication Bypass in @strapi/plugin-users-permissions

Parche disponible
Descargar PNG JSON
CVSS
—
high
Fuente: —
ExplotaciónSin evidenciaNo figura en CISA KEV
Exploits públicos0Ninguno conocido
Parche2 versionesPrimer parche a 1171 d de la divulgación
Exposición1.311 dDesde la divulgación, 18 abr 2023, 5:28 p. m.
Detección1.308 dDesde la divulgación hasta su ingreso al índice
Timeline

Ciclo de vida de la vulnerabilidad

Hoy
Divulgación
Publicada
Explotación
Remediación
Parche 5.50.0
Monitoreo
Detectada
18 abr 23
2 jul 26
17 nov 26
20 nov 26
18 abr 23
11 mar 24
2 feb 25
27 dic 25
20 nov 26
FechaFaseEventoDetalle
Divulgación Publicada GHSA-XV3Q-JRMM-4FXV divulgada
Remediación Parche 5.50.0 @strapi/plugin-users-permissions · 1171 d desde divulgación
Monitoreo Detectada Ingresó al índice
Resumen
Descripción del advisory
Texto original · GitHub · en inglés
Summary

Strapi through 4.5.6 does not verify the access or ID tokens issued during the OAuth flow when the AWS Cognito login provider is used for authentication.

Details

Strapi through 4.5.6 does not verify the access or ID tokens issued during the OAuth flow when the AWS Cognito login provider is used for authentication. A remote attacker could forge an ID token that is signed using the 'None' type algorithm to bypass authentication and impersonate any user that use AWS Cognito for authentication.

IoC

Reviewing of application logs is recommended to detect any suspicious activity. Running the following regex pattern will extract all ID tokens sent to `/api/auth/cognito/callback`.

`/\/api\/auth\/cognito\/callback\?[\s\S]*id_token=\s*([\S]*)/`

Once you have a list of the ID tokens, you will need to verify each token using the public key file for your AWS Cognito user pool that you can download from `https://cognito-idp.{region}.amazonaws.com/{userPoolId}/.well-known/jwks.json`. If there are any JWT tokens that cannot be verified using the correct public key, then you need to inspect the JWT body and see if it contains the `email` and `cognito:username` claims (example below).

{
  "cognito:username": "auth-bypass-example",
  "email": "user@example.com"
}

If there are any JWTs that have this body, verify when the account with the email address was created. If the account was created earlier than the request to `/api/auth/cognito/callback` with the invalid JWT token, then you need to contact the user to inform them their account has been breached!

After upgrading to Strapi v4.6.0 or greater you will need to reconfigure your AWS Cognito provider to include the JWKS URL for it to work properly. If you do not reconfigure your provider you will receive an error message when attempting to login.

Impact

Any Strapi user using the users-permissions AWS Cognito provider before 4.6.0

Versiones

Rangos afectados

Afectada Corregida Última
@strapi/plugin-users-permissions≥ 3.2.1 < 4.6.0
3.2.1
4.6.0
5.62.0
Remediación

Estado del parche por paquete

Paquete / productoEstadoCorregida enDesde divulgaciónÚltima versión
npm@strapi/plugin-users-permissions
Corregida 5.50.0 1171 d 5.62.0 no afectada
Versiones corregidas4.6.05.50.0
Explotación

Arsenal público

Sin exploits, módulos ni PoC públicos conocidos a la fecha de verificación.

Referencias
Otrahttps://github.com/strapi/strapi/security/advisories/GHSA-xv3q-jrmm-4fxv
Otrahttps://github.com/strapi/strapi/pull/15382
Otrahttps://github.com/strapi/strapi/commit/d0edd25ceb49d275d710bf8d59999a2c07072893
Otrahttps://github.com/strapi/strapi
Otrahttps://github.com/strapi/strapi/releases/tag/v4.6.0

Las referencias externas se muestran para copiar: cve.llama.ec no lo redirige a otros sitios.