Skip to content
KitploitKITPLOIT
ToolsExploitsBlog
Log in
Submit
ToolsExploitsBlog
Submit

Hacking, PenTest, and Cybersecurity Tools for Your Security Arsenal!

Kitploit is a directory of hacking, cybersecurity, and pentesting tools. Discover the latest project updates to find vulnerabilities, analyze systems, automate testing, and strengthen your security.

FeedsContactPrivacy© 2026 Kitploit

Tool Directory

Categories

View all categories
Loading categories
Tools/GitHubGitHub/googlesky/cve-2026-131852
ExploitationWeb Application ExploitationWeb SecurityCryptographyPapers & ResearchLabs & Practice
GitHubgooglesky/cve-2026-131852

CVE-2026-131852

PoC and lab for CVE-2026-131852: stored format-string in OwnTracks Recorder's json_response() leaks pointers via %p and crashes the daemon with %n, tested on 1.0.4 vs fixed 1.0.5.

View Repository
1 day agoNot yet reviewed
Website
Share

CVE-2026-131852 — OwnTracks Recorder: stored format-string vulnerability via location tid (unauthenticated)

License: MIT Research status: validated

CVECVE-2026-131852
ComponentOwnTracks Recorder — json_response() in http.c (bundled mongoose)
AffectedRecorder before 1.0.5
Fixed in1.0.5 (genuine vendor fix, commit 64a86050)
CWECWE-134 (Use of Externally-Controlled Format String)
ImpactUnauthenticated stored format string: an attacker publishes a location whose tid holds printf specifiers, then reads it back through the HTTP API — the response expands %p into live stack/libc pointers (ASLR defeat) and %n writes through pointers popped from the stack, crashing the daemon (SIGSEGV) and, as measured in this lab, leaving the storage corrupted so every subsequent startup crash-loops — a persistent DoS
VectorNetwork, unauthenticated — POST /pub (HTTP) or MQTT publish, then GET /api/0/last
Triggerone stored location with tid: "%p.%p.%p" (leak) or "%n.%n…" (crash/write)

json_response() passes the freshly serialized JSON — which embeds attacker-controlled fields verbatim — as the format string of mg_printf_data():

// http.c @ 1.0.4, json_response()
char *js = json_stringify(json, ...);
...
mg_printf_data(conn, js);          // js = attacker data as FORMAT

The vendor fix (1.0.5) passes it as data, the way it always should have been:

mg_printf_data(conn, "%s", js);

The same commit hardened the sibling sinks emit_xml_line, emit_csv_line, send_status and fixed an ns_avprintf 8192-byte truncation bug (> → >=). This laboratory runs the real Recorder 1.0.4 vs the vendor-fixed 1.0.5 over plain HTTP.


1. Root cause

Any user-controlled string that reaches the JSON response body becomes a printf format. The location tid (tracker ID) is the cleanest carrier: it is stored by the publish path and echoed verbatim by /api/0/last. No authentication is required to publish (POST /pub?u=<user>&d=<device>) or to read the API by default. mg_printf_data feeds the string into vsnprintf, so %p pops and prints stack arguments (pointer disclosure) and %n writes through them (memory write / crash). Because the value is stored, a single publish poisons every later read.

2. Reproduction environment

serviceimagerole
otr-vulncve-2026-131852:vulnot-recorder built from upstream tag 1.0.4
otr-fixedcve-2026-131852:fixedot-recorder built from upstream tag 1.0.5 (vendor fix)
poccve-2026-131852-poc:localstdlib-only Python driver

Both sides run with the same flags (-A 8083 --http-host 0.0.0.0, filesystem storage, MQTT disabled — the HTTP path is the CVE vector and MQTT shares the same sink). The recorder runs under a small supervisor that restarts it after a crash and logs the exit code to /work/crash.log, so the %n SIGSEGV is observable and captured (evidence/probe-vuln-crash.log).

3. Running the environment

./run-lab.sh build     # builds ot-recorder 1.0.4 / 1.0.5 from source
./run-lab.sh up        # cve131852lab network: otr-vuln, otr-fixed
./run-lab.sh sweep     # check / exploit / probe / mitigation on both sides
./run-lab.sh down

4. The PoC

A standalone full-chain exploit script ships at exploit/exploit.py (python3 exploit/exploit.py --host=<target>; exit 1 on confirmed exploitation, 0 on a safe target).

poc/poc.py (stdlib only):

  • check — publish a benign tid (persistence sanity), then a %p tid; poll /api/0/last until visible (the filesystem backend lands writes asynchronously); pointer-shaped hex in the response means the format-string path fired. Exit 1 vulnerable, 0 safe, 3 no worker, 2 unreachable.
  • exploit — narrated leak with the pointer values printed.
  • probe — benign / %p leak / %n crash with supervisor-restart observation.
  • mitigation — the vendor fix is 1.0.5.

5. Expected results

runotr-vuln (1.0.4)otr-fixed (1.0.5)
check%p expands → 3 live pointers leaked, exit 1tid echoed literally, exit 0
exploitpointer list printed(no expansion)
probe leak rowleak: 0x…literal
probe %n rowdaemon SIGSEGV (rc=139), crash-loops on the corrupted storen/a (no leak to build on)

Captured runs: evidence/check-*-run.txt, evidence/exploit-*-run.txt, evidence/probe-*-run.txt, evidence/mitigation-*-run.txt, evidence/probe-vuln-crash.log (the rc=139 sequence), evidence/versions.txt, evidence/0day-sweep.txt.

6. Environment preconditions

  • Podman (or Docker); containers bounded on the isolated cve131852lab network.
  • Outbound HTTPS at image build (GitHub: recorder tags; debian mirrors).
  • The probe's crash test intentionally corrupts the vuln container's storage; the sweep recreates each container before every mode, so each evidence file reflects a clean state.

7. Additional findings (0-day sweep on the fixed line)

evidence/0day-sweep.txt and evidence/probe-vuln-crash.log record two things the advisory does not spell out:

  1. Persistent DoS — after the %n SIGSEGV, the storage the daemon wrote through the corrupted in-memory state is poisoned: every subsequent startup dies with rc=139 again. Recovery requires clearing the store; a single unauthenticated publish thus knocks a Recorder instance out permanently.
  2. Sibling sinks closed by the same patch — emit_xml_line, emit_csv_line, send_status and the mongoose ns_avprintf 8192-byte truncation path share the flaw class; the ?format=xml|csv variants of the read API were equally exploitable on 1.0.4.

On the fixed 1.0.5 build every specifier is echoed literally and no second bypass form was found.

8. Repository layout

README.md             this write-up
run-lab.sh            environment driver (build / up / sweep / down)
Makefile              convenience targets
exploit/exploit.py    standalone full-chain exploit
poc/poc.py            the PoC (check / exploit / probe / mitigation)
poc/Dockerfile        runner image (python:3.12-alpine)
lab/lab.Dockerfile    multi-stage build (ot-recorder 1.0.4 / 1.0.5)
lab/supervisord.sh    crash supervisor (restart loop + crash.log)
evidence/             captured runs of every mode on both sides
TRACKING.md           excluded (working record)

9. References

  • CVE record — https://www.cve.org/CVERecord?id=CVE-2026-131852
  • Vendor fix commit — https://github.com/owntracks/recorder/commit/64a86050a1ac6cb5f704e296ec9182f750d143c8
  • Pull request — https://github.com/owntracks/recorder/pull/589
  • Release 1.0.5 — https://github.com/owntracks/recorder/releases/tag/1.0.5
  • Vulnerable code @ 1.0.4 — https://github.com/owntracks/recorder/blob/1.0.4/http.c#L369-L410
Download Tool

Most Popular

View all →

Discover the most used tools by our community.

  • 1

    OsintHunter

    letox4/osinthunter

    🎯 The ultimate OSINT toolkit: investigation graph, confidence scoring, alias families, map, timeline and reports. 49 modules, 400+ sites, no API keys required.

    936
  • 2

    ghostlock-app

    yukonga/ghostlock-app

    GhostLock One-Tap Execution App (CVE-2026-43499)

    555
  • 3

    redforge

    cybersecurity91/redforge

    Browser-side red team toolkit with 102 offline tools for recon, payload generation, credential attacks, crypto, encoding and engagement reporting.

    353
  • 4

    ARTEX

    baarai/artex

    LLM multi-agent autonomous penetration testing platform with planner/worker agents, asset and exploration graphs, MITM traffic recording, and vulnerability retesting.

    348
  • 5

    looking-glass

    anonghosty/looking-glass

    CSIRT platform that ingests Shadowserver reports into MongoDB and replays them as interactive maps, analysis, findings, advisories and executive dashboards.

    336
  • 6

    CyberStrikeAI

    ed1s0nz/cyberstrikeai

    The system of action for AI-native cybersecurity—where intent becomes governed execution, evidence becomes operational memory, and every operation improves the next.

    288

Explore all tools

Browse our collection of tools

View all tools →