Davis Geometric
SCJ / Inside the representation

From a sink
to a solver question.

A visual reading of the v0.4r architecture: represent the context of a vulnerable operation, retrieve related families, and test whether the patch’s safety conditions hold in a candidate.

01 / A concrete starting point

Enough data to overflow. Enough context to explain why.

Teaching example: 40 bytes, a 24-byte destination, and the length bound that prevents the unsafe copy.
Teaching example: 40 bytes, a 24-byte destination, and the length bound that prevents the unsafe copy.

The operation is only the starting point

A sink is the operation whose safety is being examined—here, a memory copy. Copying is ordinary and useful. The relevant question is whether the amount being copied fits the destination, and which path establishes that condition.

The patch supplies a question

A bound added by a patch can be expressed as a predicate: copy_length ≤ capacity. SCJ’s patch-intent extraction identifies the added conditions, then asks whether related implementations enforce them too. The drawing is a teaching example, not a disclosed vulnerability.

02 / The geometric representation

A fingerprint of operations and relationships.

Specified embedding architecture: 256 P-code dimensions, 128 graph dimensions and 64 engineered dimensions, compressed to 128. Strands and ticks show dimension counts, not feature values.
Specified embedding architecture: 256 P-code dimensions, 128 graph dimensions and 64 engineered dimensions, compressed to 128. Strands and ticks show dimension counts, not feature values.
What the v0.4r specification represents
Channel Representation Role
Instruction structure 256-dimensional IR2Vec-style representation of P-code n-grams Describe operations in an intermediate representation.
Graph neighborhood 128-dimensional GraphSAGE representation over two-hop neighborhoods Retain relationships around the function.
Engineered features 64-dimensional feature vector Include selected structural and safety-relevant properties.
Compressed embedding 448 concatenated dimensions → 128 by PCA Support approximate-neighbor retrieval.
Cross-module family Sink identity + callsite signature Group candidates using caller/callee context, argument shape and local control-flow shape.

Similarity scoring combines vector proximity with sink overlap, semantic parity and binary-diff evidence. The geometry helps prioritize where to look. A similar embedding does not itself determine whether a candidate is vulnerable.

03 / The semantic question

Can these conditions hold while the protection fails?

SPES builds bounded slices of the relevant paths and compares candidate predicates with the conditions introduced by the patch. In the small model below, the question is whether candidate conditions ∧ ¬patch condition is satisfiable. Z3 computes the three results retained with this page.

Missing bound: Z3 returns SAT. Length 40 and capacity 24 provide a violating assignment in the bounded model.
Missing bound: Z3 returns SAT. Length 40 and capacity 24 provide a violating assignment in the bounded model.
Equivalent protection: Z3 returns UNSAT. No assignment in this model both satisfies the length bound and violates it.
Equivalent protection: Z3 returns UNSAT. No assignment in this model both satisfies the length bound and violates it.
Wrong quantity checked: Z3 returns SAT. Checking other_length = 16 against capacity = 24 does not protect a copy_length of 40.
Wrong quantity checked: Z3 returns SAT. Checking other_length = 16 against capacity = 24 does not protect a copy_length of 40.

Read the result precisely

SAT supplies a violating assignment within the encoded model. UNSAT means none exists within that model. Neither conclusion extends automatically to unmodeled program behavior.

The specification also allows partial and inconclusive outcomes. A timeout or ambiguous mapping does not establish either protection or vulnerability.

What is bounded?

This example uses integer lengths from 0 to 64. It is a direct constraint exercise, not the full SPES implementation. The specification’s program slices have a default depth of three, conditional extension to four, and explicit solver budgets.

The fingerprint drawing and this integer model explain two connected representations. The embedding vector is not simply passed to Z3 as a safety proof.

04 / Keep the records connected

The architecture and the contributions.

This study draws on Shadow Clone Jutsu v0.4r, especially pages 2–4, 14 and 15. It illustrates that specification rather than claiming every specified subsystem was used in the later F Prime investigations. The June source-code report and the later anomaly-scan contribution have their own methods and evidence.