From 'Just a Cache' to Full Takeover: The Redis Chain in Six Steps

Site Admin · 24 Nov 2026 · Data & Messaging

From an open port 6379 to full host takeover in six steps — two chains, no application involvement required.

Parts 6–8 named the pieces. This is the whole machine, end to end — the paths

by which "literally just a cache" becomes "the attacker owns the host".


Chain A — the classic file-write path (no bug required)

This is the oldest, most-repeated Redis takeover, and it works entirely with

legitimate commands:

  1. Reach port 6379. Internet-facing, VPN-jumped, or a compromised app
  2. server that already had a client.
  3. No password. Empty requirepass — or the password from a .env in the
  4. compromise that got you here.
  5. CONFIG SET dir — point persistence at something Redis can write:
  6. a cron directory, an SSH key directory, a web root.
  7. CONFIG SET dbfilename — name the file you want created (e.g. root in
  8. cron.d).
  9. SAVE — Redis writes your payload as a "database dump" into that
  10. directory, with the name you chose.
  11. Execute — cron runs your file; SSH trusts your key; the web server
  12. serves your script. Then harvest: sessions, tokens, queue contents, other
  13. credentials Redis was trusted with.

No CVE. No memory corruption. Just an open door and a persistence feature

wearing a weapon. This is why the industry treats an exposed Redis as already

compromised.

Chain B — the 2026 memory-safety shortcut

The new batch compresses the chain:

  1. Reach the server as above.
  2. CVE-2026-25243 — a crafted RESTORE key 0 <payload> deserializes with
  3. insufficient validation → invalid memory access → possible RCE.
  4. CVE-2026-23479 — block-then-evict a client → use-after-free → heap
  5. groomed into code execution (7.7 High).

Where Chain A needs write permissions to a useful directory, the memory path

works against the process itself — and against every pre-6.2.19 install

(Part 8).

The blast radius, stated without drama

When Redis is taken, what dies with it?

  1. Sessions — every logged-in user, no application involvement needed.
  2. Cached credentials and tokens — API keys, short-lived tokens, cached
  3. auth material.
  4. Queues — jobs can be injected as easily as read.
  5. Locks and coordination — the exact primitives other services trust to
  6. serialize work.
  7. The host — via Chain A's file write, or Chain B's process compromise.

And because Redis sits in front of the real database (Part 4), the attacker

does not need the database. They stand on the fastest access layer in the

stack and harvest what flows through it.

Detection: mostly silence

The honest detection picture is grim:

  1. Visible: unusual CONFIG commands are sometimes logged in slow-log; a
  2. spike in SAVE/BGSAVE can show in monitoring — if anyone watches Redis
  3. statistics, which almost nobody does.
  4. Silent: memory-safety exploitation leaves no protocol artefact at all; an
  5. RCE through RESTORE looks like an ordinary write. The file-write chain
  6. leaves new files on disk — visible only to host-level file monitoring, which
  7. cache nodes rarely have.

The race is not detection vs attacker. The race is the attacker's scan vs

your upgrade — and the attacker's scan runs every day.

Next: Part 10 — the way out: the five lines that close the door, the upgrade

matrix, and the honest residual risk.


The attack chainThe attack chain

The door was never locked