# GHSA-vffh-c9pq-4crh: Uptime Kuma Server-side Template Injection (SSTI) in Notification Templates Allows Arbitrary File Read

- Severity: Medium 6.5 (CVSS:3.1, scored by GitHub) `CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Published: 2025-10-20T20:03:15.000Z
- Modified: 2026-04-02T13:29:23.867Z
- Related: CVE-2026-33130
- Weaknesses: CWE-36, CWE-1336

## Description

### Summary

In some Notification types (e.g., Webhook, Telegram), the `send()` function allows user-controlled renderTemplate input. This leads to a Server-side Template Injection (SSTI) vulnerability that can be exploited to read arbitrary files from the server.



### Details

The root cause is how Uptime Kuma renders user-controlled templates via `renderTemplate()`. The function instantiates a Liquid template engine and parses the `template` argument without sanitization:

```js
async renderTemplate(template, msg, monitorJSON, heartbeatJSON) {
    const engine = new Liquid();
    const parsedTpl = engine.parse(template);

    // ...
}
```

In some Notification flows, the `send()` implementation passes user-editable fields directly into `renderTemplate()`:
```js
// webhook.js
if (notification.webhookContentType === "form-data") {
    const formData = new FormData();
    formData.append("data", JSON.stringify(data));
    config.headers = formData.getHeaders();
    data = formData;
} else if (notification.webhookContentType === "custom") {
    data = await this.renderTemplate(notification.webhookCustomBody, msg, monitorJSON, heartbeatJSON); //<- this line cause SSTI
}
```

Because `notification` can be edited by users and is rendered by the Liquid engine without proper sandboxing or a whitelist of allowed operations, an attacker can supply a crafted template that causes the server to read arbitrary files. In particular, Liquid’s template tags (e.g. `{% render ... %}`) can be abused to include server-side files if the engine is not restricted, resulting in Server-side Template Injection (SSTI) that leaks sensitive file contents.



### PoC

1. Open Uptime Kuma → **Notifications** → **Add** or **Edit** an existing Webhook notification.
2. Set notification type to **Webhook** and set **Request Body**  to **Custom Body**.
3. Paste the following JSON into the custom request body:

```json
{
  "Title": {% render '/etc/passwd' %}
}
```

4. Click test.
5. Your webhook will receive the file content



### Impact

This is a post-authentication Server-side Template Injection (SSTI) vulnerability that allows an authenticated user to perform arbitrary file read on the server.

(As written by GitHub Advisory Database.)

## Affected

- uptime-kuma (npm): 2.0.0-dev.0

## References

- <https://github.com/louislam/uptime-kuma/security/advisories/GHSA-vffh-c9pq-4crh> (web)
- <https://github.com/louislam/uptime-kuma> (package)

## Sources

- GitHub Advisory Database: [GHSA-vffh-c9pq-4crh](https://github.com/advisories/GHSA-vffh-c9pq-4crh), CC-BY-4.0, modified 2026-04-02

---

Page: https://cve.day/GHSA-vffh-c9pq-4crh · Whole record: https://cve.day/GHSA-vffh-c9pq-4crh.json · Rebuilt by cve.day 2026-11-25T22:56:46.635Z
