CVE-2026-27626
JSON

10.0critical

OliveTin vulnerable to OS Command Injection via `password` argument type and webhook JSON extraction bypasses shell safety checks

Severity
10.0critical CVSS:3.1 by GitHub_M
Exploit likelihood
0.63% (higher than 51% of CVEs; EPSS, by FIRST)
Published
Last changed
Assigned by
GitHub_M
Also known as
GHSA-49gm-hh7w-wfvfGO-2026-4547

Description

OliveTin gives access to predefined shell commands from a web interface. In versions up to and including 3000.10.0, OliveTin's shell mode safety check (`checkShellArgumentSafety`) blocks several dangerous argument types but not `password`. A user supplying a `password`-typed argument can inject shell metacharacters that execute arbitrary OS commands. A second independent vector allows unauthenticated RCE via webhook-extracted JSON values that skip type safety checks entirely before reaching `sh -c`. When exploiting vector 1, any authenticated user (registration enabled by default, `authType: none` by default) can execute arbitrary OS commands on the OliveTin host with the permissions of the OliveTin process. When exploiting vector 2, an unauthenticated attacker can achieve the same if the instance receives webhooks from external sources, which is a primary OliveTin use case. When an attacker exploits both vectors, this results in unauthenticated RCE on any OliveTin instance using Shell mode with webhook-triggered actions. As of time of publication, a patched version is not available.

Affected

Product or packageVersionsReported by
OliveTin OliveTin<= 3000.10.0, up to 3000.10.0CVE List, NVD
github.com/OliveTin/OliveTin (Go)before 0.0.0-20260222101908-4bbd2eab1532, all versionsGitHub Advisory Database, Go Vulnerability Database

All scores

GitHub_M10.0critical CVSS:3.1CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H
GitHub9.9critical CVSS:3.1CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H

Classification

CWE-78

SSVC (CISA-ADP): exploitation poc, automatable no, technical impact total.

What each source says

CVE List

OliveTin gives access to predefined shell commands from a web interface. In versions up to and including 3000.10.0, OliveTin's shell mode safety check (`checkShellArgumentSafety`) blocks several dangerous argument types but not `password`. A user supplying a `password`-typed argument can inject shell metacharacters that execute arbitrary OS commands. A second independent vector allows unauthenticated RCE via webhook-extracted JSON values that skip type safety checks entirely before reaching `sh -c`. When exploiting vector 1, any authenticated user (registration enabled by default, `authType: none` by default) can execute arbitrary OS commands on the OliveTin host with the permissions of the OliveTin process. When exploiting vector 2, an unauthenticated attacker can achieve the same if the instance receives webhooks from external sources, which is a primary OliveTin use case. When an attacker exploits both vectors, this results in unauthenticated RCE on any OliveTin instance using Shell mode with webhook-triggered actions. As of time of publication, a patched version is not available.

GitHub Advisory Database
Summary

OliveTin's shell mode safety check (checkShellArgumentSafety) blocks several dangerous argument types but not password. A user supplying a password-typed argument can inject shell metacharacters that execute arbitrary OS commands. A second independent vector allows unauthenticated RCE via webhook-extracted JSON values that skip type safety checks entirely before reaching sh -c.

Details

Vector 1 — password type bypasses shell safety check (PR:L)

service/internal/executor/arguments.go has two gaps:

// Line 198-199 — TypeSafetyCheck returns nil (no error) for password type
case "password":
    return nil  // accepts ANY string including ; | ` $()

// Line 313 — checkShellArgumentSafety blocks dangerous types but not password
unsafe := map[string]bool{
    "url":                      true,
    "email":                    true,
    "raw_string_multiline":     true,
    "very_dangerous_raw_string": true,
    // "password" is absent — not blocked
}

Shell execution at service/internal/executor/executor_unix.go:18:

exec.CommandContext(ctx, "sh", "-c", finalParsedCommand)

A user supplies a password argument value of '; id; echo ' → sh -c interprets the shell metacharacters → arbitrary command execution.

This is not the "admin already has access" pattern: OliveTin explicitly enforces an admin/user boundary where admins define commands and users only supply argument values. The password type is the documented, intended mechanism for user-supplied sensitive values. The safety check exists precisely to prevent users from escaping this boundary — password is the one type it fails to block.

Vector 2 — Webhook JSON extraction skips TypeSafetyCheck entirely (PR:N)

service/internal/executor/handler.go:153-157 extracts arbitrary key-value pairs from webhook JSON payloads and injects them into ExecutionRequest.Arguments. These webhook-extracted arguments have no corresponding config-defined ActionArgument entry, so parseActionArguments() in arguments.go finds no type to check against and skips TypeSafetyCheck entirely. The values are templated directly into the shell command and passed to sh -c.

Example: an admin command template git pull && echo {{ git_message }} with Shell mode enabled. A webhook POST with {"git_message": "x; id"} injects id into the shell command. The webhook endpoint is unauthenticated by default (authType: none in default config).

PoC
# Vector 1 — authenticated user with password-type argument
curl -X POST http://localhost:1337/api/StartAction \
  -H "Content-Type: application/json" \
  -d '{"actionId": "run-command", "arguments": [{"name": "pass", "value": "'; id; echo '"}]}'

# Vector 2 — unauthenticated webhook
curl -X POST http://localhost:1337/webhook/git-deploy \
  -H "Content-Type: application/json" \
  -d '{"git_message": "x; id #", "git_author": "attacker"}'

Confirmed on jamesread/olivetin:latest (3000.10.0), 3/3 runs. Both vectors produced uid=1000(olivetin) output and arbitrary file write to /tmp/pwned.

Impact
  • Vector 1: Any authenticated user (registration enabled by default, authType: none by default) can execute arbitrary OS commands on the OliveTin host with the permissions of the OliveTin process.
  • Vector 2: Unauthenticated attacker can achieve the same if the instance receives webhooks from external sources, which is a primary OliveTin use case.

Combined: unauthenticated RCE on any OliveTin instance using Shell mode with webhook-triggered actions.

Go Vulnerability Database

OliveTin: OS Command Injection via password argument type and webhook JSON extraction bypasses shell safety checks in github.com/OliveTin/OliveTin

NVD (es)

OliveTin da acceso a comandos de shell predefinidos desde una interfaz web. En versiones hasta la 3000.10.0 inclusive, la comprobación de seguridad del modo shell de OliveTin ('checkShellArgumentSafety') bloquea varios tipos de argumentos peligrosos, pero no 'password'. Un usuario que proporciona un argumento de tipo 'password' puede inyectar metacaracteres de shell que ejecutan comandos arbitrarios del sistema operativo. Un segundo vector independiente permite RCE no autenticada a través de valores JSON extraídos de webhooks que omiten por completo las comprobaciones de seguridad de tipo antes de llegar a 'sh -c'. Al explotar el vector 1, cualquier usuario autenticado (registro habilitado por defecto, 'authType: none' por defecto) puede ejecutar comandos arbitrarios del sistema operativo en el host de OliveTin con los permisos del proceso de OliveTin. Al explotar el vector 2, un atacante no autenticado puede lograr lo mismo si la instancia recibe webhooks de fuentes externas, lo cual es un caso de uso principal de OliveTin. Cuando un atacante explota ambos vectores, esto resulta en RCE no autenticada en cualquier instancia de OliveTin que utiliza el modo Shell con acciones activadas por webhook. En el momento de la publicación, no hay disponible una versión parcheada.

References

Sources

SourceRecordLicence
CVE ListCVE-2026-27626 changed 2026-02-27CVE Terms of Use
GitHub Advisory DatabaseGHSA-49gm-hh7w-wfvf changed 2026-02-28CC-BY-4.0
Go Vulnerability DatabaseGO-2026-4547 changed 2026-02-25CC-BY-4.0
NVDCVE-2026-27626 changed 2026-06-17Public domain