arXiv:2610.33748cs.PLOct 2026

Manuscript Offprint

arXiv:2610.33748

A Rowhammer attack on Fil-C's software capabilities

Amir Naseredini, Suhas Viswanath, Martin Berger

Amir Naseredini

Suhas Viswanath

Martin Berger

Independent Researcher, Cambridge, UK Independent Researcher, Cambridge, UK University of Sussex & Montanarius Ltd

sahnaseredini@gmail.com

suhaskv0111@gmail.com

Brighton & London, UK

contact@martinfriedrichberger.net

Abstract—Fil-C retrofits spatial and temporal memory safety onto C/C++ using software capabilities (bounds that are checked at every pointer dereference). Fil-C's guarantee rests on an unstated hardware assumption: that DRAM preserves the capabilities. We show that Rowhammer breaks it. In Fil-C 0.679 a part of each heap pointer's capability lives in a 16-byte header stored inline in ordinary DRAM immediately before the object pointed to, with no mechanism to prevent capabilities from corruption. A single 0→10 \rightarrow 1 bit flip in the capability's upper-bound expands the pointer's permitted range by 2k2^k bytes and is invisible to the runtime, raising no panic or signal. We demonstrate this by using Fil-C to convert existing Rowhammer attacks into concrete attacks against a heterogeneous collection of victim software. To aid reproducibility (not everybody has DRAM vulnerable to Rowhammer) we split our demonstration into two paths. First, along a deterministic path, we isolate Fil-C as a novel attack vector using a deterministic, Rowhammer-like fault-injection model. Across four case studies, this model corrupts the upper-bound word of a pointer, permitting previously out-of-bounds reads and writes. We use this to achieve a bounded read/write window, secret disclosure, privilege escalation by flipping an adjacent is_admin field, and the leakage of a tenant API key in a multi-tenant credential service backed by SQLite (compiled under Fil-C). Second, along a physical end-to-end path, we demonstrate all four attacks on real hardware equipped with DDR3 memory, and with Target Row Refresh (TRR) equipped DDR4, proving the exploits are physically realisable. The latter attack shows that the TRR defence does not close the Fil-C delivery channel. We close with a discussion of Fil-C-specific mitigations.

Index Terms—Rowhammer, Fil-C, InvisiCaps, DRAM, Memory Safety, Capability Integrity, Hardware Fault Injection

I. INTRODUCTION

Memory-safety violations in C/C++ remain the dominant root cause of critical security vulnerabilities: Because rewriting the vast deployed base of C/C++ software is impractical, a major line of defence therefore retrofits spatial and temporal memory-safety protections onto existing code. These approaches include compiler instrumentation as in SoftBound/CETS [1] and AddressSanitizer [2], hardware-assisted capabilities as in CHERI [3], and memory tagging as in Arm Memory Tagging Extension (MTE) [4]. Fil-C [5] is a recent and unusually complete point in this space: it instruments every pointer operation at compile time and enforces complete spatial and temporal bounds checking at runtime through software capabilities, with high C/C++ compatibility to build large real-world programs unmodified. A tacit assumption underlies such systems: that the hardware faithfully preserves the metadata on which every check depends.

The Rowhammer vulnerability [6], [7] invalidates exactly this assumption for commodity DRAM. By repeatedly activating adjacent memory rows, an attacker induces controlled bit flips in victim rows without ever directly accessing them. Rowhammer has corrupted OS page tables [8], cryptographic keys [9], deduplication and allocator state of co-located VMs [9], [10], and JavaScript sandboxes [11], [12]. Rowhammer reads secrets it never touches [13] and survives across DRAM generations and defences [14]–[17]. Yet compiler-managed bounds metadata, the very state on which software-defined memory safety rests, has, to our knowledge, received no systematic analysis as a Rowhammer target. This paper fills that gap with an explicitly conditional thesis:

Wherever Rowhammer can land a usable bit flip in a suitable part of the stored metadata associated with a pointer, Fil-C cannot hold its spatial-safety promise for that pointer.

We are not proposing a new way to hammer DRAM. We show what an existing, widely demonstrated hardware fault means for a software defence that relies on the aforementioned tacit assumption. We exploit a design choice in Fil-C 0.679: part of each heap pointer's capability is stored as a 16-byte header inline in ordinary DRAM immediately before the object pointed to, with no mechanism to protect capabilities from corruption. Note that Rowhammer attack techniques do not let an attacker pick an arbitrary bit and force that cell to flip. They identify cells that are physically vulnerable to flipping, and then groom valuable victim data onto one of them [8], [9]. Most flips are unusable, ruled out by the cell's page offset, its position within the Fil-C metadata, the flip polarity, the bit's current value, or the requirement that the result remain a valid pointer ( §VI−F§VI-F). Our attack needs only one flip that survives all these filters. We show that such a flip silently defeats the Fil-C runtime with no panic, signal, or machine check to mark it.

Our attack pipeline consists of three main components:

• The underlying Rowhammer fault generation.

Figure

Fig. 1. The two experimental paths. Blue boxes run inside the Fil-C victim process. Red boxes run in the attacker's native (non-Fil-C) process. Both paths share the same start (a live InvisiCap in DRAM) and the same consequence (Phase 4: the runtime silently honours the corrupted bound). They differ only in delivery. The deterministic path lands the flip with a single out-of-band write to isolate the metadata-corruption consequence. The physical end-to-end path lands it by real Rowhammer through templating, grooming, and hammering (Phases 1–3). Neither delivery is mediated by a Fil-C check, which is why the corruption is invisible to the runtime.

• Grooming the victim software to align Fil-C’s unprotected software capabilities with vulnerable memory cells.

• Silently circumventing Fil-C’s runtime checks once the capability’s upper bound is expanded by a bit flip.

To aid reproducibility and cleanly separate these components, our paper proceeds along two complementary paths (Figure 1). First, a deterministic path isolates the circumvention stage using a deterministic, Rowhammer-like fault-injection model. This allows us to study the impact of targeted bit flips on Fil-C binaries independently of the underlying hardware, yielding four concrete case studies: a bounded out-of-bounds (OOB) read/write window, secret disclosure, privilege escalation by flipping an adjacent is_admin field, and cross-tenant API key leakage in a multi-tenant credential service backed by SQLite. Second, a physical end-to-end path proves that the necessary fault generation and grooming are physically realisable by executing these attacks end-to-end on commodity hardware. Our evaluation uses both older DDR3 memory (exploited in 2 minutes) and modern, Target Row Refresh (TRR) protected DDR4 modules (exploited in 10–35 minutes), demonstrating that the TRR defence does not close this Fil-C delivery channel.

We emphasise that mitigating Rowhammer is not Fil-C's responsibility: it is a hardware-level defect for DRAM vendors and platform designers to address. However, it is widely and incorrectly believed that Rowhammer is a solved problem, so it is worth stating plainly that a software safety system such as Fil-C remains exposed to it, and that this exposure is invisible to the runtime. We close with a discussion of Fil-C-specific mitigations: while we contribute no new class of defence, the Message Authentication Code (MAC) protection we recommend is PT-Guard's [18], transported to a new target.

In summary, our contributions are as follows.

• We present the first Rowhammer attack on Fil-C. We characterise the Fil-C 0.679 capability layout and show

Figure

Fig. 2. Visualisation of a Fil-C pointer and capability layout.

that its bounds checks rely on the integrity of inline metadata stored in ordinary DRAM ( §II−A§II-A, §III−B§III-B, §VIII§VIII).

  • Through deterministic single-bit fault injection, we show that corrupting software capabilities silently bypasses Fil-C's runtime checks. Four case studies demonstrate consequences including privilege escalation and cross-tenant information disclosure ( §V§V, §VI§VI).

• We develop a capability-aware Rowhammer delivery method combining flip selection with allocator- and offset-aware physical-frame grooming. We use it to realise the attacks end-to-end on DDR3 and the tested TRR-equipped DDR4 system, demonstrating that TRR did not prevent delivery on that platform ( §IV§IV, §VI−F§VI-F, §VI−G§VI-G).

• We compare Fil-C’s exposure with hardware-tagged capability systems such as CHERI and propose Fil-C-specific mitigations ( §VIII§VIII, §IX§IX).

References (41)