Skip to content

Releases

v3.19.0

Choose a tag to compare

@kabiri-labs kabiri-labs released this 19 Nov 10:50

v3.19.0 — a method for template sinks, and a channel for one-bit answers

The last published release was 3.15.0, so this release carries 3.16.0,
3.17.0, 3.18.0, 3.18.1, 3.18.2 and 3.19.0. CHANGELOG.md has the full entry
for each; what follows is what changed for someone running the tool.

New: --methods syntax (3.18.0)

A template sink answers malformed syntax differently from well-formed syntax,
and nothing is rendered either way — the shape of the response is the only
signal there is. syntax sends each delimiter form twice, once well-formed and
once with its closing delimiter removed, on two rounds of fresh operands, and
reports syntax-sink when the two rounds agree on what each half looked
like.

syntax-sink is a lead, not a finding. It says a parser is behind the value; it
does not say the input executed, and it is never promoted to confirmed. A
filter that refuses only the malformed half is reported inconclusive, and both
halves refused is blocked — neither reads as clean.

Verified against Flask 1.1.1 on Jinja2 in the bench suite, with a
class-attribution control.

New: boolean reads one bit of a JSON answer (3.19.0)

response_shape drops every scalar a document carries, which is what keeps a
request id or a timestamp from making two identical answers look different — and
which also made {"allowed":true} and {"allowed":false} the same shape. A
rules engine, a filter-expression evaluator and an authorisation endpoint all
have that shape, and the one method built for predicate sinks could not see
them.

The scalar channel reads those values back at identical JSON paths off the
series already fired
, so it costs no extra request unless it finds something,
and it runs only where the shape channel said nothing.

Its floors are measured rather than chosen: against a body carrying a scalar
that flips on its own, screening then confirming on four pairs gives 0 of
20000
false claims while still reading a real evaluator 20000 of 20000.
Four further guards exclude a confound structurally rather than by name. Because
four pairs per connective is the floor, this channel does not answer at
--probe-depth quick
and says so in the evidence rather than letting the run
read as clean. JSON only, deliberately: a path is a stable identity for "the
same value" and a plain-text body has none.

The ceiling is unchanged — evaluation-sink, a lead rather than a finding.

Fixes that change what a run reports

  • A refused request whose effect landed anyway now says so (3.16.0). A probe
    answered with a refusal whose side effect still happened was previously lost.
  • oob, lookup and deser findings carried no HTTP status (3.16.0).
  • A timeout the payload-free control did not share is no longer an error
    (3.17.0) — it is attributable, and attributable is a reading.
  • A write that landed while its own request hung was reported as error
    (3.17.0).
  • A syntax form its context cannot carry is no longer negative (3.18.1).
    A form whose broken half is closed by the context's own suffix is disclosed as
    not tested.
  • An observed endpoint behind a login no longer reads as one that was read
    (3.18.1), and a refused read no longer counts as a read (3.18.2).
  • A syntax pair voided by its own transport encoding is no longer judged
    (3.18.2).

Every one of these is the same rule in a different place: a run that could not
test something must not report it as clean.

Coverage

All 12 detection methods now have a bench case. python tests/bench/runner.py --all is green at 18/18 in 1h21m42s, every case with its negative control,
against real vulnerable software under Docker. tests/bench/README.md has the
table and the measurements.

Install

pip install rcekit==3.19.0

Python 3.8+, standard library only, no third-party dependencies.

RCEKit is for authorised testing only. See the responsible-use statement in the
README.

v3.15.0

Choose a tag to compare

@kabiri-labs kabiri-labs released this 08 Nov 06:53

RCEKit's verdicts were always careful. Reading them on a real terminal was not:
a run printed nothing for the minutes it was working, its own settings were
printed at the weight of a finding, nothing was coloured, and it never said what
it had decided. This release is almost entirely about that — and about one
vulnerability in which the target could forge a confirmation in the operator's
own terminal.

Four versions are folded into this tag (3.12.2, 3.13.0, 3.14.0, 3.15.0); none of
the intermediate ones were published.

Security

A target could forge a confirmation in your terminal. When a probe never
arrived, the delivery error became the reported detail — and
http.client.BadStatusLine carries the server's raw bytes, so a target replying
with an erase-line sequence followed by a forged EXECUTED row wiped the line
saying nothing had reached it and printed a confirmation in its place, for a run
that tested nothing.

The tier rule is the claim this project rests on, and this was that claim being
forged by the target it is supposed to describe. It needed no authentication and
no special position: any host you point RCEKit at could do it.

Every report row now renders through one escaping function, so what arrived
stays visible as \x1b instead of acting. Display only — --detect-json keeps
the bytes verbatim and is byte-identical to before.

Added

  • A banner, two lines on stderr: the version, and the tier rule in the
    README's own words.
  • A progress line for the minutes a run used to spend in silence —
    elapsed time, method, carrier and probe count against the pre-flight's own
    estimate. One self-erasing line on a terminal; --progress plain writes a
    line every 25 probes for a CI log; --progress none turns it off.
  • A verdict line, the last thing every run prints:
    [detect] VERDICT: negative -- the probes reached the target and found nothing
  • Colour, tied to the tier and nothing else. executed bold red, the
    proven-but-not-execution tiers yellow, a run that tested nothing bold yellow,
    negative a neutral cyan. No green anywhere — green reads as "nothing
    here", and negative means the probes reached the target.
  • New flags: --color {auto,always,never}, --progress {auto,plain,none},
    -q / --quiet. NO_COLOR, FORCE_COLOR and TERM=dumb are honoured.

Fixed

  • A redirected run printed nothing until it exited. stdout was block-
    buffered and never flushed, so a run piped into tee, captured by script or
    watched in CI was silent for its whole duration — measured at 50.2s to the
    first line, now 0.2s. An operator watching a silent pipe cannot tell a working
    run from a hung one.
  • The run's own configuration read as findings. sink shell, sink shapes
    and the shape descriptions wore the same [detect] tag the findings wear.
    They are tagged [config] now.
  • RCEKit's log records went to stdout, duplicating the report with a
    timestamp in front. They go to stderr.
  • Colour could not render on a Windows console where virtual-terminal
    processing was off; RCEKit enables it for its own stdout, and where that
    fails colour stays off rather than printing escape sequences at you.
  • The README said a run that reached nothing exits non-zero. It exits 0:
    non-zero means a refusal to run. Branch on the verdict, not on $? —
    --detect-json carries it.
  • A payload containing a literal newline split its own finding row in two.
  • nothing-tested, the quietest way the tool can fail, was the one outcome that
    never announced its verdict.

Upgrading

No flag was removed or renamed, no verdict was added, renamed or widened, and
--detect-json and the -o exports are byte-identical. Nothing in the
detection path changed.

If you parse stdout, four things moved:

  • INFO - ... log records are no longer there (they are on stderr).
  • Configuration lines are tagged [config] instead of [detect].
  • A [detect] VERDICT: ... line is appended to every run.
  • stdout is line-buffered when redirected, so output arrives as it happens.

The banner and the progress line are on stderr and never touch stdout;
colour is never written to a redirected stdout. A run piped to a file produces
the same bytes it always did, plus the verdict line and the retagged
configuration.

Python 3.8 through 3.13. Still zero third-party dependencies.

v3.12.1 — argument injection, file inclusion, and a chain the oracles can drive

Choose a tag to compare

@kabiri-labs kabiri-labs released this 31 Oct 15:24

The first release since v3.6.1, and it carries eight versions of work —
3.7.0 through 3.12.1 — plus the documentation and benchmark changes that
correctly took no version of their own.

What executed means has not changed, and that is the point of the release.
It still rests on a value RCEKit generated at random for that probe, which
reflection cannot produce, arriving through one of three channels: computed in
the response and absent from a payload-free control, an out-of-band callback
carrying a token only the target held, or a value the target stored that RCEKit
fetched back in a second request. Weaker signals keep their own tiers and are
never promoted into it. A run that could not test something still never reports
it as clean.

Two new methods

argv — argument injection into a program spawned with no shell (3.7.0).
This class sat in the README's excluded list until then, and the reason it moved
is the reason it is worth having: it is not a weaker case of command injection,
it is the case where the application did the correct thing. escapeshellarg
quotes the value exactly as documented, every separator arrives inert, and no
shell ever sees them — but that argument can still be read as an option, and
an option can name a command the program runs. Measured against vulhub
gitlist/CVE-2018-1000533: --methods reflected at --probe-depth full sends
37 probes and reports negative on all 37, while --methods argv reports
executed on the same endpoint in one probe. The oracle did not change; the
option names a command, and the command is the same arithmetic core.

include — a path the request names (3.11.0, reaching execution in 3.12.0).
The reads report file-read and stop there, because the evidence is a signature
RCEKit knew in advance rather than a value the target computed. Given
--include-write-url it also writes a computed one-liner through the sink and
fetches the file back, which reaches executed — or file-write where the file
is served verbatim. A wrapper carrying code (data://, php://input) is not
that route: both need allow_url_include, off by default since PHP 5.2, and the
measured target said so in its own words.

RCEKit now confirms through 11 methods under one --methods flag.

Two new kinds of reach

A chain is a delivery the detection engine drives (3.9.0). There were two
engines: --verify-chain carried the session machinery — login, a CSRF token
read from one response and spent in the next, a payload in an upload's content —
and --methods carried the oracles, the payload-free control and the tier
vocabulary, and they shared nothing. --verify-chain --methods now runs the real
oracles through the chain's steps, with a control that is a whole chain run of
its own. time and boolean are refused there by name: both read the shape of a
response series, which a chain's setup steps change for reasons that have nothing
to do with the sink.

--observe-trigger, because second-order detection has three acts (3.10.0).
Inject then read is enough for a payload the target renders on its own next page
load. It is not enough for one waiting to be run — a queue a worker drains, a
report generated on demand, a "run now" button — where polling reads a page that
will never move and the run reports negative about a sink that would execute
the moment anything asked. Measured against a target that queues the value on
POST /store and executes it only when /run is asked: the same probes report
negative=19 without the trigger and executed=19 with it.

One new tier

file-read (3.11.0) — arbitrary file read, CWE-22 / CWE-98, proven by
content absent from the payload-free control. A vulnerability on its own terms,
not a weaker RCE, and what it is worth depends on which paths you can reach.
Thirteen verdicts now, still never collapsed into each other.

Three places a verdict was stronger than its evidence

Each of these narrowed what RCEKit will claim. None of them narrowed what it
sends.

  • --verify-chain's in-band verdict was executed on evidence the tier rule
    forbids
    (3.8.0). The oracle there is a static signature — uname matched by
    the word Linux appearing — and that path runs the chain once, with the
    payload, so there is no control to difference it against. Both halves of what
    executed requires were missing. It reports needs-review now. This is the
    one upgrade note that matters; see below.
  • The observed channel awarded execution to whatever reached it (3.12.0).
    The second-order channel assumed anything it could confirm proved execution,
    which held while every method that could reach it did. include broke that: a
    file's content signature is in no payload and is not computed either, so a page
    merely rendering the file reported second-order execution with nothing
    executed. The tier travels with the probe shape now.
  • include's traversal depths shared one filename and one product (3.12.0),
    so they shared one read-back URL, and a depth whose own include failed
    fetched the file an earlier depth had written and reported it as its own
    execution. The run's verdict about the target stayed right; the map of which
    shapes the sink accepts did not. Each probe draws its own operands and its own
    filename.

Fixes worth naming

  • A byte-order mark on a JSON response cost it its leaf channels and its
    shape reading
    (3.7.1). json.loads rejects a mark outright, so a marked body
    yielded no leaf channels and the shape reading fell to its word-count fallback.
    Both halves had to move together, because they are two readings of one body.
  • RCEKit died mid-report on a Windows console, and leaked its own path doing
    it
    (3.12.1). Three strings carried U+2192, which cp1252 cannot encode: two
    report section closings and time's evidence summary. The findings above the
    closing line had already printed, so the run looked like it crashed while its
    own verdicts scrolled past, and the traceback carried the module's absolute
    path. Any run reporting a non-execution tier reached it, as did any redirected
    pipe under a non-UTF-8 locale. CI runs on Linux under UTF-8 and had never seen
    it.

Benchmark

17 cases, each with a negative control, and both halves must pass for a case
to pass. Seven are new since v3.6.1: boolean against mongo-express,
injection-point enumeration against Webmin, time as the subject rather than a
control, argv against GitList, and three for include — the read, and
execution against both a bare include sink and a framework loader that appends
its own extension.

That figure is a count of the suite, not of one run. python tests/bench/runner.py --all was last green at 3.0.1 — 10/10 in 55m48s — and
the seven added since were each run on their own. The benchmark runs on a
cadence, not on every change, and the README says which rows rest on which kind
of claim.

Documentation

The coverage ledger carries 16 rows, each stating the tier the bench
actually reached rather than the tier the method could reach in principle.
Quick start gained a scenario for the two sinks that are not shells — argv and
include both reach executed, and neither answers anything on the "what can
you observe" axis the other scenarios are organised by. The field guide gained a
section for an inclusion sink and a row for include in its method-choice table,
and that table, the contents lists and the environment lists are now pinned to
the code by tests, which is what they were missing.

Upgrade notes

Only one thing changes for a command line that worked before.

A --verify-chain run without --methods that previously printed
EXECUTED for an in-band match now prints a NEEDS-REVIEW candidate(s) section
instead. Nothing about the chain's delivery changed — the same steps,
substitutions and payloads go to the target — so a finding you reported from an
earlier run is not retracted by this. It is reclassified as something to confirm
rather than something confirmed.

To confirm it, reproduce the sink through --verify-url or -r with
--methods, where the oracles that rest on a computed value and a payload-free
control live — or run the same chain with --methods, which is new in 3.9.0
and carries those oracles through the chain's own steps. Exit status is
unaffected: that path returned 0 regardless of outcome before and still does.

Nothing else was removed or renamed. Python 3.8+, MIT, and still zero
third-party dependencies.

Verified at this tag

  • python -m unittest discover -s tests — 1203 tests, OK, run twice on a
    checksummed tree: once under the native Windows console codec and once with the
    parent locale forced to UTF-8, which is the locale CI has. Both green.
  • python tools/embed_corpus.py --check clean, python rcekit.py --doctor OK.
  • The bench figures above are stated as measured, with the date and build each
    was measured against recorded in tests/bench/README.md.

v3.6.1 — where a payload can land

Choose a tag to compare

@kabiri-labs kabiri-labs released this 27 Oct 16:02

The last tagged release was v3.0.1. Nine versions have landed since, and they have one through-line: a payload cannot be proven in a place the tool cannot put it. 3.0.0 settled what a verdict means; this run of releases is about reach.

New injection-point kinds

--auto-params learned four surfaces it could not address before:

XML and SOAP bodies — element text, attribute values and CDATA sections, addressed by byte offset and spliced rather than re-serialised, so a whitespace-significant envelope survives. A signed envelope is reported as unreachable instead of being rewritten. Previously an envelope fell through to the form branch and yielded one point named after its prolog, which could confirm nothing.
Multipart filenames — the filename="…" parameter in the part header, quoted-string escaped, with the upload’s content left alone. A newline is never placed there: in a part header it forges a new part, which no notice afterwards can undo.
JSON booleans and nulls, the last scalars excluded, plus index addressing for repeated query and form keys — a=1&a=2 is two points now. Addressing by name alone rewrote the first occurrence for every candidate, so the later ones were counted as covered and probed nowhere.
Encoded blobs — the fields inside a base64 or base64url JSON document, or a JWT, named carrier>field (state>role, tok>sub), across query values, form values, JSON string leaves and cookie or header values. One layer deep, at most 64 fields. A JWT’s signature is invalid by construction: an application that accepts the rewritten token is not verifying it, which is the finding, and one that rejects it reports blocked rather than a clean negative.
A sink no probe could reach

reflected gained the Shellshock shape (() { :;}; echo; echo; echo …, CVE-2014-6271). Headers had been enumerated for years with Shellshock given as the reason, and no probe could confirm that sink: every other shape breaks out of a command the application built, and here there is no such command — the server copies the header into the environment and bash parses it on the way in.

It is the env rung of the sink-shape ladder, so --sink-shape env asks for it alone: 17 requests across a full sweep where the default sends 1094.

Scope stated rather than implied: this is CVE-2014-6271 and not the shapes that survive its patch (6277, 6278) or the parser-state shape (7169), and a cookie crumb cannot carry it, because HTTP_COOKIE is the whole header and an enumerated crumb keeps its name.

The pre-flight plan stopped disagreeing with the traffic

Two fixes to the one output an operator is told to read instead of inferring the run from the traffic:

A run narrowed to nothing (--sink-shape sq --sink-env windows) printed the plan of a full sweep while sending zero probes. An empty rung selection was read as “no selection given”.
The new empty-ladder line predicted NOTHING WAS TESTED for the whole run, when only four of the nine methods ride the ladder — so a mixed run sent probes under a plan that said it would send none.
Bench coverage

The suite goes from 10 cases to 13, and boolean is no longer the only method without one: MongoDB $where through mongo-express, reaching evaluation-sink, with a class-attribution control that moves the payload to a position Mongo compares literally instead of evaluating. time becomes the subject of a case rather than only the control half of two others, and -p all gets a case where the sink must be found rather than named.

What is measured: those three cases were each run individually (29.9s, 4m32s, 21m21s) and python tests/bench/runner.py --all was last green at 3.0.1, 10/10 in 55m48s. The coverage ledger says which, per row.

v3.0.1

Choose a tag to compare

@kabiri-labs kabiri-labs released this 01 Oct 21:55

v3.0.1 — reflected names only the shell it proved

A single patch release, and it narrows what RCEKit will call executed.

What was wrong

reflected built one probe shape whose expected value was the arithmetic result
and nothing else: a bare expr a + b, sent at --probe-depth full and matched
digit-fenced. Anything that evaluates arithmetic satisfied it — and an
expression evaluator is not a shell.

Groovy is the case that showed it. On a plain Gremlin endpoint it reads
expr 548286 + 675041 as the command expression expr(548286 + 675041):
it computes the sum, fails to resolve the method, and echoes the result in its
error. The run then printed this, against a target where no command ran:

[detect] EXECUTED (3):
  [reflected/unix/raw] ; expr 548286 + 675041
      (target computed '1223327' (random operands, absent from control))

The tier was never wrong. The target really did compute a value reflection
cannot forge, and --methods eval reaches executed on such an endpoint
honestly. What was wrong is the class: a finding filed under
reflected/<environment> asserts that a shell of that family ran the input. In
a client report, a correct proof under the wrong class is worse than a miss.

What changed

The shape is retired. Every remaining reflected probe requires the target to
place RCEKit's random tags around the value it computed — which an expression
evaluator handed the payload cannot do.

Measured on Apache HugeGraph 1.2.0 with every shape mapped
(--confirm-depth every):

Target tag-bracketed shapes the retired shape
the plain Gremlin endpoint — Groovy 0 of 36 3 of 6
the same build's ProcessBuilder body — a real sh -c 4 1

So the shape was never the only proof where a shell exists. A controlled
before/after against one executing sink: 1158 probes → 1114, with
executed=32 both times. 44 fewer requests per injection point, zero
confirmations lost.

It was removed rather than repaired because expr has no portable string
concatenation: bracketing its result in a tag means reintroducing the $( or
the echo keyword the shape existed to avoid. Reading Groovy's error text was
considered and rejected — deciding a verdict from response content is not a
pattern this project will take on.

What this costs

A sink that filters $(, backticks and awk at once is now out of
reflected's reach. It remains reachable through time, oob and file, and
docs/reference.md says so.

--probe-depth quick never sent the shape, so a quick run is unchanged.

One second-order effect to know about if you use --max-length. The retired
shape was also the shortest probe reflected built, so the shortest is now 41
characters rather than about 20. A --max-length below 41 leaves the method no
probe at all. That fails loudly rather than quietly:

[detect] sent 0 probes (0 result(s)): none
[!] No probes were built, so NOTHING WAS TESTED — this is not a negative result.
[!]   Every probe was longer than --max-length 40.

How it is held

Two guards sweep every environment, context and probe depth: no probe's
expected value may be the arithmetic alone, and none may match digit-fenced. A
new benchmark case, hugegraph-gremlin-reflected-class, runs the same request
against the same endpoint as the eval case and differs only in the method,
requiring reflected to come back negative.

All three were run against the retired shape put back, and all three fail on it
— the bench control reporting executed=30.

python tests/bench/runner.py --all is 10/10 green in 55m48s at 3.0.1.
That run is the gate that matters here: the risk this change carries is a false
negative on a genuine shell, and none appeared — Webmin's reflected and
file, Struts2's eval, OpenTSDB's oob, Tomcat's write and HugeGraph's
ProcessBuilder body all still reach executed.

Unit suite: 934 tests, offline, no dependencies.

Upgrading

pipx upgrade rcekit     # or: pip install -U rcekit

Nothing to change in how you invoke it. If a past run reported executed from
reflected against an endpoint you believed was an expression evaluator rather
than a shell, that finding is worth re-running — --methods eval is the one
that answers for it.

RCEKit 3.0.0

Choose a tag to compare

@kabiri-labs kabiri-labs released this 01 Oct 09:05

RCEKit 3.0.0

Every verdict is now named for what the target did, never for how sure RCEKit is.

This release covers everything since v2.45.3: four patch releases that were never tagged, plus the tier rework that gives this one its major number.


Breaking: the verdict vocabulary

confirmed was the only verdict describing RCEKit's own confidence while every sibling described the target's behaviour. Next to it, a lookup-sink — proven on a callback carrying a token only that probe held — read as something unconfirmed.

And needs-review had four reporters, three of which had already measured their answer.

Verdict Was What it says
executed confirmed the target executed the input
timing-sink needs-review the target honoured a delay RCEKit injected
file-write needs-review a file stored at a path RCEKit chose, read back uninterpreted
evaluation-sink needs-review an evaluator consumed the input; which one is not shown
needs-review unchanged deser's parser fingerprint — the one signal that really is a candidate

write was the clearest case: its evidence line opened with the words ARBITRARY FILE WRITE confirmed under a status of needs-review. The tool's prose contradicted the tool's tier.

Nothing was promoted. executed rests on exactly the three channels it did before — a computed result in the response, an out-of-band callback, or a value the target stored that RCEKit fetched back — and none of the five weaker tiers has a path into it. time stays out in particular: a delay honoured is not necessarily a shell honouring it, since a sandbox implementing sleep answers the regression the same way.

What changed is the direction of the reporting error. Three proven findings were being under-reported.

Migration

--detect-json changes values, not keys. verdict, the keys of counts, each probe's verdict and observe_status take the new names above. A consumer keyed on "confirmed" must read "executed"; one keyed on "needs-review" should decide which of the four it actually meant.

No CLI flag, no JSON key, no template-schema field and no exit code changed.

No backward-compatible alias ships. Two accepted spellings for one field is a second source of truth, and the point of this release is that there is one.

Also in the collapsed verdict

needs-review now ranks last rather than second. Its old place was argued from "a suspected RCE outranks a proven non-RCE in triage", which held while time, boolean and write's uninterpreted file all reported there. What is left under it is a suspected deserialization, so ranking it above deserialization-sink put the guess above the proof of the same thing.

Full order: executed, timing-sink, file-write, evaluation-sink, deserialization-sink, lookup-sink, needs-review.


Three defects the benchmark found that no fixture could

These shipped as 2.45.4 through 2.45.7 and were never tagged.

  • A compressed response body is a body the oracles cannot read. A target that gzipped its output read as clean for every method. Decompression is bounded, because compression is where a target chooses how much memory you spend.
  • The write probe carried whitespace, and some sinks tokenise before they interpret. Measured on RRDtool: <?= 7*6 ?> wrote no file, <?=7*6?> wrote 47 bytes.
  • The write product overflowed a 32-bit int. JSP and ASPX evaluate a*b as signed 32-bit while RCEKit computed it in Python, so the two disagreed and the run reported negative against a target that was fully exploitable — in 56% of runs on JVM and .NET targets. Operands are now bounded so the product cannot overflow.

Also fixed in that range: the deser shape differential answering from evidence it had not gathered, the pre-flight plan describing three payloads it no longer sent, and a negative evidence line describing a comparison it had not made.


Coverage you can re-run

The README's CVE table became a coverage ledger: 11 rows, every one with a bench case, each saying which build it was measured against and which negative control proves the result is not an over-eager scanner.

python tests/bench/runner.py --all — 9/9 cases, 55m50s, at 3.0.0, against the same vulhub builds. Every case's expected verdict changed in this release, so all nine ran; applying a rename to a stored result proves nothing about what the tool reports.

The two timing-sink controls carry the weight: on a Webmin 1.910 and an OpenTSDB 2.4.1 that are genuinely vulnerable, time reaches its own proven tier and still does not reach executed. That is the tier ceiling holding against real software rather than against a fixture.

Two of the new tiers are not in that run. file-write and evaluation-sink rest on unit tests only — the Tomcat write case reaches executed, and boolean has no bench case at all.


Notes

The four recordings in confirmation-gifs/ predate this release and show the old verdict names on screen. Only the words changed; what each run proves is the same. Their README says so rather than the repository claiming a coherence it does not have.

Python 3.8+, MIT, still zero third-party dependencies.

Full changelog: v2.45.3...v3.0.0

v2.45.3 — a probe that cannot call back is not a probe

Choose a tag to compare

@kabiri-labs kabiri-labs released this 24 Sep 13:50

Patch release. One defect, reached by three different routes, all in how
--methods deser decides whether an out-of-band callback is possible.

Fixed

deser sent DNS gadgets that nothing could receive. Three configurations
produced the same failure — real requests to the target from which no callback
could follow by construction, and a verdict capped at needs-review without
saying why:

configuration before after
--methods deser --oob-host <name>, alone no listener started at all listener starts
--methods deser --oob-host <IP> gadget aimed at <token>.<IP>, which resolves nowhere gadget not built; the run says which method an address stranded
--methods deser --deser-formats php notice blamed the address; listener bound for nothing neither — php, dotnet and python_pickle ship no DNS gadget, so there was never a callback to lose

The root cause was one attribute answering two questions: whether a run should
stop when no --oob-host is named, and whether it needs a listener. Every
method but deser answers both the same way — its shape oracle proves
something with no listener at all, while its DNS gadget does call back.

deser now reaches deserialization-sink when run on its own, which is how
the documentation presents it.

Also

  • Two notices said "only the HTTP shapes are live" in runs that have no HTTP
    shape. They now say "only the shapes that need no DNS are live", true of
    oob's HTTP probes and deser's shape oracle alike.
  • lookup with an address no longer binds ports it cannot use. It built no
    probes with one either way.

Upgrading

No flags, verdicts or output schemas changed. The effect on a run is fewer
requests to the target in the configurations above, plus one notice naming any
method an address stranded and the tier that puts out of reach.

If you script against --methods deser, note that a run narrowed to php,
dotnet or python_pickle now correctly reports that it cannot reach
deserialization-sink, rather than appearing to try.

Note on this tag: the previous published tag is v2.35.1. Upgrading from
there spans 17 versions — see CHANGELOG.md for everything in
between.

Verified: 806 tests, full suite, on Python 3.8–3.13.

v2.35.1 — four ways a run could end without a verdict

Choose a tag to compare

@kabiri-labs kabiri-labs released this 21 Aug 06:49

A patch release, and the first since RCEKit went to PyPI. Four ways a run could
end without a verdict — or with a verdict it had not earned — on input the tool
did not choose. No new capability.

If you installed from PyPI, 2.35.0 has the crash below. If you curl the
single file from main, you already have the fix.

The one that matters

A truncated error response ended the whole run. Reading an HTTPError's
body happens inside the except handler, where the sibling except Exception
cannot reach it — so an exception raised there escapes main() entirely. A
target that promised a Content-Length it never delivered was enough:

File "rcekit.py", line 2433, in run_detection
  _, control_body, control_channels, _ = self._fire_channels(
File "rcekit.py", line 2047, in _fire_channels
  text = exc.read().decode(errors="replace")
ConnectionResetError: [Errno 104] Connection reset by peer

It fired on the control request, so a run could die before sending a single
probe; mid-flight it took every probe already fired with it. That is precisely
the failure the verdict model exists to prevent: a run that ends without saying
what happened. A body that does arrive is still read in full, so the
500-stack-trace confirmations that branch exists for are untouched.

Three that misled rather than crashed

  • An unknown --environments or --encodings was silent. --environments linux — the corpus calls it unix — produced an empty file and exit 0,
    indistinguishable from a target with no payloads for it. Unknown contexts and
    categories already warned; these two did not. Both now name the value and list
    the ones that exist, and an empty result is no longer announced as
    "Successfully generated 0 payloads".
  • A --target-profile was used before it was checked. A profile is written
    by hand, so a typo in one is ordinary; it surfaced as a traceback thousands of
    payloads from its cause. Twelve inputs crashed — a top level that is not a
    JSON object, deny_chars that is not text, max_length that is not a number,
    selector fields given as numbers. Each is now an operator-readable [!]
    message and exit 1, the way the sink-shape fields already behaved.
  • A callback could rewrite the operator's terminal. The host and path of an
    OOB callback are chosen by the target, which in an engagement is hostile by
    definition. Printed raw, an ESC byte let it colour, erase and rewrite lines —
    hiding a genuine [HIT] behind \x1b[2K\r, or forging one that never
    arrived. Control characters are now escaped for display as \xNN; the
    recorded hit and the --listen-log JSONL keep the bytes verbatim.

Upgrading

No breaking changes. No flag was removed and nothing changed meaning. One
behaviour note if you keep target profiles:

  • A selector field given as a string now means one name, not one character
    each. "environments": "unix" used to be iterated u, n, i, x and
    matched nothing; it now means ["unix"], and "raw, html" means two names.
    This is not a compatibility break — the old behaviour matched nothing — and
    every profile in profiles/ uses lists.
  • A profile that was silently tolerated because a bad field was ignored will now
    be rejected with a message. That is the point, but it is worth a look before
    you run against a live target.

Verification

535 tests, standard library only, Python 3.8 – 3.13.

Each fix carries a regression test that fails without it — verified by
running the new tests against the unfixed module, where all fifteen behavioural
tests failed. Three more pass in both states by design; they guard against
over-correction ("a readable error body is still returned in full", "default
selectors never warn").

Detection behaviour is unchanged, measured rather than assumed: the same
injectable sink returns 844 probes: confirmed=446, negative=398 before and
after, and the negative control — an endpoint that reflects the payload verbatim
without executing it — still comes back negative on every probe.

Full changelog: v2.35.0...v2.35.1

v2.35.0 — RCEKit on PyPI

Choose a tag to compare

@kabiri-labs kabiri-labs released this 20 Aug 16:00

RCEKit is now on PyPI.

pipx install rcekit     # or: pip install rcekit
rcekit --doctor

Published through PyPI Trusted Publishing from this release — no API token, no
repository secret.

It is still one file

The distribution is a single module, not a package tree. rcekit.py has not
moved and still runs alone:

curl -O https://raw.githubusercontent.com/kabiri-labs/rcekit/main/rcekit.py
python rcekit.py --doctor

Installing is a second supported shape, not a replacement for the first. Running
with nothing installed is the point on a jump box or an air-gapped host, and both
paths run the same code and report the same verdicts.

Changed

  • import rcekit no longer has side effects. Logging was configured at module
    scope, and logging.FileHandler opens its file the moment it is constructed —
    so merely importing the module wrote rcekit.log into whatever directory the
    interpreter happened to be in. Handler setup moved into configure_logging(),
    called from main(). Running the CLI still writes rcekit.log exactly as
    before.

  • The built-in corpus is no longer reported as a missing file. With nothing
    but rcekit.py there is no templates/ directory, the embedded corpus is the
    corpus, and the run is now silent about it — --doctor names it
    built-in (embedded in rcekit.py) and reports OK. A templates/ directory that
    exists without its payloads.json still prints the notice, because that one
    is a real finding.

  • main() takes an optional argv and returns an explicit int, so the
    console-script entry point is a plain zero-argument call. Every exit code is
    unchanged.

  • The log file handler now runs at DEBUG while the console stays at INFO.

Unchanged, and verified so

Nothing about detection changed. Measured against v2.34.1 on a repo checkout:
--doctor output identical, exit codes identical across
--version / --doctor / --detection-only, and 252 generated payloads from
both. 77 of those lines differ — and running v2.34.1 twice against itself differs
on exactly the same 77, because payloads carry per-run random canary tokens.

A corpus that is present but corrupt, and an explicit --template-file that is
missing or corrupt, both still refuse to run and exit non-zero.

The one thing an existing user can observe: in the single-file layout the
[i] Using the built-in payload corpus line no longer prints. The information is
still there — --doctor reports the source.

Full changelog: v2.34.1...v2.35.0

v2.34.1 — seven methods, seven verdicts

Choose a tag to compare

@kabiri-labs kabiri-labs released this 18 Aug 07:28

Everything since v2.23.3 — eleven releases, two new detection methods, eighteen
new flags, and a detection engine that is considerably harder to fool into
reporting a clean negative.

The tagline changed too, because the old one overclaimed:

confirmed means the target executed the input. negative means the probes reached it.

Two new detection methods

--methods goes from five to seven.

Method Confirms Tier it can reach
write An upload or write primitive proven to be RCE by executing what it wrote — PUT-a-JSP, unchecked upload (CWE-434) confirmed, or needs-review for a write that is served but not interpreted
deser That the endpoint deserializes attacker data — via a non-executing DNS gadget or an error-shape differential deserialization-sink, never RCE

deser ships a URLDNS builder written against OpenJDK's own ObjectOutputStream
byte layout and verified on OpenJDK 21: the stream deserializes to
HashMap{http://<host>/=rk} and issues a DNS query for <host>, referencing no
class outside java.util/java.net — so the callback proves the object graph
was reconstructed and nothing more.

Sinks the engine can now reach

  • Windows cmd.exe and PowerShell (--sink-env). The shell dialect was
    inferred from the corpus environment alone, so every Windows carrier took the
    cmd core — including the one whose context is literally named powershell.
    Every shell method now has a PowerShell shape, each validated against pwsh 7.4.
  • Second-order execution (--observe-url, --observe-request). The payload
    lands on one request and runs on another: stored SSTI rendered on a profile
    page, a payload written to a log a template engine later renders, a queued job.
    Differenced against a snapshot of that endpoint taken before any probe was
    sent.
  • Query-language bridges (--bridges). COPY … FROM PROGRAM,
    xp_cmdshell, expect://. A carrier, not an oracle: it wraps the command the
    methods already build, so the same tier guarantees apply through it.
  • Any read-back path (--file-write-path, --file-read-url). file needed
    a writable web root; it now works through an LFI parameter, a download or
    export handler, a /tmp-backed preview. Measured against a target with a
    download handler and nothing serving the write directory: the web-root form
    confirms 0, the general form confirms 7.
  • Injection-point enumeration (-p all, --auto-params). Query, JSON
    leaves, form fields, cookies, headers and path segments, each encoded for
    where it lands, with the probe cost printed before anything fires.
  • The whole response as a confirmation channel — body, application headers,
    cookie values, the redirect target, the HTTP reason phrase, and each leaf of a
    JSON error envelope. The control differential is applied to every channel too.
  • The sink-shape ladder (--sink-shape) — quoted sinks, whole-command
    sinks, and $( )/backtick substitution reaching a quoted value without
    closing the quote.
  • Sandbox-resistant eval carriers (--eval-engines) for Freemarker,
    Velocity and Thymeleaf, whose output and syntax quirks made a genuinely
    evaluating target read as negative.

The verdict model

A new tier, deserialization-sink: proven, but about a different property.
It sits below both RCE tiers and can never become confirmed.

And the half that matters more than it looks — a run that tested nothing is
never reported as clean.
error and nothing-tested are first-class verdicts,
the run exits non-zero, and RCEKit says which happened and why.

Fixed — mostly one defect wearing different clothes

Every one of these was found while building the features above, and most belong
to the same family: a run that tested nothing reporting as "not vulnerable."

  • A deeply nested JSON body raised RecursionError and turned all 46 probes
    of a default reflected run into error: request never reached the target —
    an evasion vector.
  • The raw rung reached only reflected. Under --sink-shape raw, file,
    time and oob built zero probes, and an aggregate method with no samples
    returned negative.
  • A JSON key containing a . produced two candidates with the same address, and
    the literal key was never probed at all.
  • The read-back fetch went out without the run's credentials, so an
    authenticated download handler reported confirmed=0 on a target where the
    write had executed on every probe. Credentials now travel same-origin only.
  • --observe-timeout 0 is falsy, so or 60.0 turned a deliberate no-wait read
    into a full minute of polling a dead endpoint.
  • The observed channel was polled only after the whole batch, which confirms
    nothing on a store that overwrites — the shape that oracle most exists for.
  • Two benchmark controls passed while measuring nothing: one copied the
    vulnerable invocation, the other accepted error/nothing-tested as a pass.
  • The Postgres bridge without a leading DROP TABLE IF EXISTS aborted its own
    second statement, so a target that was executing read as no delay.
  • An aggregate method's result carried no cleanup line, so a stateful bridge on
    the one oracle that reliably proves a query-language sink never said how to
    clean up after itself.

Upgrading

No breaking changes — no flag was removed and nothing changed meaning. Worth
re-checking if you script around RCEKit:

  • --detect-json gained deserialization-sink as a possible verdict, and an
    observe_status key on every probe.
  • A default run sends a different probe mix: the sink-shape ladder adds the
    quoted, substitution and raw shapes; cmd.exe no longer gets the sq/dq/
    subshell carriers it could never execute; dotnet gains cmd and PowerShell
    carriers.
  • needs-review findings now print their cleanup line, and aggregate methods
    (time) carry one too.
  • PowerShell's separator sweep carries no pipe — measured: cmd | <cmdlet> is a
    parameter-binding error, not a fresh command with stdin attached.
  • The corpus grew three declarative sections — eval_carriers, bridges and
    deser_probes — so a custom --template-file from 2.23.x still loads, but
    will not carry the new coverage until those sections are added.

Verification

506 tests, standard library only, Python 3.8 – 3.13. tests/bench/ adds a
vulhub benchmark harness in which a negative control is a required key, not an
optional extra.

Full changelog: v2.23.3...v2.34.1