For buildersStatus 27 Nov 2026

How hAppBucket splits custody from bytes

A small Holochain cell holds the rules, the signatures and the index of every file. A pluggable blob store holds the encrypted chunks. Standard S3 clients talk to the gateway that sits between them. Get started has every step to run it.

01Architecture

Every request is checked first, then split between 2 stores.

The gateway verifies the S3 signature before anything else happens. Rules and records then go to the Holochain cell, your own signed record inside the hAppBucket hApp (a Holochain app), which is the source of truth for who owns what and who may touch it. File bytes go to the blob store as encrypted chunks, so that store can live in your Cloudflare R2 bucket or on a local disk without ever seeing plaintext.

S3 clients send requests over HTTPS to the hAppBucket gateway. The gateway records manifests and grants in the Holochain cell and writes encrypted chunks to the blob store. S3 clients AWS CLI, Bun.s3 rclone, restic HTTPS hAppBucket gateway SigV4 check 4 MiB AES-GCM codec S3 router manifests, grants encrypted chunks Holochain cell BucketMeta ObjectManifest CapGrant GrantRevocation signed by your key Blob store R2 or local disk ciphertext only S3 clients send requests over HTTPS to the hAppBucket gateway. The gateway records manifests and grants in the Holochain cell and writes encrypted chunks to the blob store. S3 clients AWS CLI, Bun.s3, rclone, restic HTTPS hAppBucket gateway SigV4 check 4 MiB AES-GCM codec S3 router Holochain cell BucketMeta ObjectManifest CapGrant GrantRevocation signed by your key Blob store R2 or local disk ciphertext only
Mode B, the primary design. Ink paths carry custody; orange paths carry bytes.

What the Holochain cell holds

  • BucketMeta: bucket policy, versioning and retention defaults.
  • ObjectManifest, 1 private entry per object version: bucket, key, version ID, ETag, size, plaintext SHA-256, BLAKE3 root, content type, blob reference, chunk size, the wrapped data key and a timestamp.
  • Capability grants tagged happbucket-s3, and GrantRevocation entries.

Every mutation (an upload, a delete, or creating or completing a multipart upload) is designed to run through a valid capability grant and be signed by your Ed25519 key, held in your own lair keystore. Because the cell stores manifests rather than file bytes, it is designed to stay around 20⁠–⁠50 MB even with 100+ GB stored.

What the blob store holds

Ciphertext only: each object as a series of 4 MiB encrypted chunks under a content reference. The store needs no keys and no permissions of its own. Blob drivers are pluggable: local disk in the M1 core, Cloudflare R2 in M2, and a reserved hook for iroh-blobs.

02Storage modes

Anchored storage for large data, a pure chain vault for small.

Mode B is the primary design. Mode A serves people who want everything inside Holochain and keep the vault small.

Primary

Mode B: Holochain-anchored S3

The cell holds manifests and grants. Encrypted 4 MiB chunks live in R2 or on local disk. Built for multi-GB buckets.

  • Delete frees the chunks' space right away
  • The cell stays small, so cold starts stay short
  • Range reads fetch only the chunks they need

Under 500 MiB

Mode A: pure chain vault

Objects are stored as private ObjectPart entries of up to 1 MiB inside the Holochain cell, with no external blob store.

  • Range reads fetch only the intersecting 1 MiB parts
  • Suited to small vaults and configuration bundles
  • Space returns when a whole epoch clone cell retires
PropertyMode BMode A
File bytes liveIn R2 or on local disk, encryptedInside the Holochain cell
Recommended sizeMulti-GBUnder 500 MiB in total
Delete reclaims spaceImmediately, by reference countWhen an epoch clone cell is retired
External storeRequiredNone
StatusGateway core built and verified locally (M1)Zome functions built (M0); benchmark in M3

03Encryption and range reads

Every object is sealed in 4 MiB chunks, so a range read touches only what it asks for.

hAppBucket's chunk format, HBK1, encrypts each 4 MiB chunk with AES-256-GCM under its own subkey, derived with HKDF-SHA256 from the object key and the chunk index. Every chunk carries an independent nonce and its own authentication tag.

A 22 MiB object stored as 5 full chunks and 1 partial chunk of 2 MiB. A range request for bytes 9,000,000 to 13,000,000 fetches, verifies and decrypts chunks 2 and 3 only. Range: bytes=9000000-13000000 chunk 0 chunk 1 chunk 2 chunk 3 chunk 4 chunk 5 4 MiB 4 MiB 4 MiB 4 MiB 4 MiB 2 MiB fetched, verified, decrypted not read not read 22 MiB object: 5 full chunks and 1 partial chunk, each with its own nonce and tag A 22 MiB object stored as 5 full chunks and 1 partial chunk of 2 MiB. A range request for bytes 9,000,000 to 13,000,000 fetches, verifies and decrypts chunks 2 and 3 only. Range: bytes=9000000-13000000 chunk 0 chunk 1 chunk 2 chunk 3 chunk 4 chunk 5 4 MiB 4 MiB 4 MiB 4 MiB 4 MiB 2 MiB fetched, verified, decrypted not read not read 22 MiB object: 5 full chunks and 1 partial, each with its own nonce and tag
A range request maps to whole chunks; the gateway trims the edges after decryption.

A request with Range: bytes=X-Y maps to chunks floor(X / 4 MiB) through floor(Y / 4 MiB). The gateway fetches only those chunks, verifies and decrypts each, trims the edges and answers 206 Partial Content with a Content-Range header. A changed bit in any ciphertext, tag, nonce or key stops the read with an error, so a reader only ever receives verified bytes.

The manifest also records a plaintext SHA-256 and a BLAKE3 root for the whole object. The local test suite checks cross-chunk range reads, tamper detection on every chunk field, and BLAKE3 against the official test vectors.

04S3 compatibility

The S3 operations it speaks.

Path-style S3 over HTTPS, https://<endpoint>/<bucket>/<key>. Every operation below is implemented in the M1 gateway core. Its local tests cover uploads, full and range downloads, deletes, listing, multipart uploads, presigned URLs and revocation.

OperationRequestResult
Create a bucketPUT /<bucket>Bucket recorded in the cell
CheckHEAD /<bucket>, HEAD /<bucket>/<key>Headers only
UploadPUT /<bucket>/<key>Sealed into chunks; manifest recorded in the cell
DownloadGET /<bucket>/<key>Verified and decrypted
Partial downloadGET with Range: bytes=X-Y206 Partial Content with Content-Range
DeleteDELETE /<bucket>/<key>Manifest retired; its sealed data removed
Delete manyPOST /<bucket>?deleteBatch delete
ListGET /<bucket>?list-type=2ListObjectsV2 with prefix, delimiter, max-keys, continuation-token and CommonPrefixes
Multipart uploadPOST ?uploads, PUT ?partNumber=N&uploadId=…, POST ?uploadId=…, DELETE ?uploadId=…Create, upload parts, complete, abort

Authentication

  • AWS Signature Version 4 in the Authorization header (AWS4-HMAC-SHA256), with x-amz-date inside a 15-minute window either side, and either a signed payload hash or UNSIGNED-PAYLOAD over TLS.
  • Presigned URLs (X-Amz-Signature) with enforced expiry.
  • Constant-time signature comparison.
  • Several active access keys at once, so keys rotate without downtime.
  • A revoked key or presigned URL is refused with 403 on its next request.

Pointing a client at it

Your code keeps its S3 client and changes the endpoint and the access key. With Bun's built-in client, against the gateway running on your machine:

import { S3Client } from "bun";

const s3 = new S3Client({
  endpoint: "http://127.0.0.1:9000",
  bucket: "demo",
  region: "us-east-1",
  accessKeyId: process.env.AWS_ACCESS_KEY_ID,
  secretAccessKey: process.env.AWS_SECRET_ACCESS_KEY,
});

await s3.write("notes/hello.txt", "hello");
console.log(await s3.file("notes/hello.txt").text()); // hello

Run on 27 Nov 2026 with Bun's S3 client and the AWS CLI v2 against happbucket dev. Get started has every step. Testing with unmodified rclone and restic is milestone M3.

05Where it runs

2 ways to run it, both on infrastructure you own.

Your own Linux server or Docker host

The gateway, a Holochain conductor and its lair keystore are designed to run side by side on 1 machine. The local-disk blob driver writes each object as 1 file of sealed 4 MiB chunks on that machine's storage and removes it on delete, so the disk space comes back at once. The M1 gateway core runs this way today in evaluation mode, with its index in memory; Get started shows every step. Connecting it to a live conductor is part of M2, and a Docker image ships with the v0.1.0 release.

Your own Cloudflare account Planned · M2

The 1-click deploy will create 4 pieces inside your account, billed to you by Cloudflare:

  • A Worker at the edge that will check every S3 signature before anything else runs.
  • A Durable Object with a SQLite cache of manifests and active grants, so cached reads (GET, Range, HEAD, ListObjectsV2) can be answered at the edge without waking the Holochain node.
  • A container running the Holochain node (Cloudflare's standard-1: 4 GiB RAM, 0.5 vCPU), which will wake for signed writes and grant changes, then checkpoint itself to R2 and sleep.
  • An R2 bucket holding the encrypted chunks and the encrypted node checkpoint.
Planned Cloudflare layout. A client reaches a Worker at the edge. Cached reads go straight from the Worker to R2. Signed writes wake the Holochain node container, which checkpoints to R2. PLANNED · M2 S3 client YOUR CLOUDFLARE EDGE Worker signature check manifest and grant cache (Durable Object) signed writes cached reads Holochain node a container that wakes for writes and grants checkpoint R2 bucket encrypted Planned Cloudflare layout. A client reaches a Worker at the edge. Cached reads go straight from the Worker to R2. Signed writes wake the Holochain node container, which checkpoints to R2. PLANNED · M2 S3 client YOUR CLOUDFLARE EDGE Worker signature check manifest and grant cache in a Durable Object signed writes cached reads Holochain node container, wakes for writes and grant changes R2 bucket encrypted checkpoint
The planned Cloudflare package. Reads that the cache can answer never wake the Holochain node.
KindWhatFigure
MeasuredUnauthorized requests refused at the edge, with no container started76.9⁠–⁠94.9 ms
MeasuredA compact Holochain cell woken from R2, over HTTPS5.51⁠–⁠5.93 s
TargetA cached range read answered at the edge, with no container wakeabout 50⁠–⁠100 ms
EstimateMonthly cost in your own account: Workers Paid at $5/mo, container time only while active, R2 with 10 GB free and no egress feesabout $5.50⁠–⁠$7/mo

06Measurements

What we measured running Holochain on Cloudflare containers.

On 27 Nov 2026 we ran holochain 0.7.1 (hdk 0.7.1, hdi 0.8.1) with lair-keystore inside Cloudflare Containers (standard-1: 4 GiB RAM, 0.5 vCPU, 8 GB ephemeral disk with about 7.32 GiB free), backed by real R2. The heavy runs used Granis's record store cell; the compact runs used a bare conductor. These results set hAppBucket's design rules.

MeasurementResultWhat it means for hAppBucket
Storage amplification53 MiB of objects across 3 epochs grew the encrypted databases to 151.06 MB, about 2.8×File bytes stay outside the chain
Compact cell cold wakeFresh start 4.65 s. Warm health check 227⁠–⁠280 ms. Cold wake from R2 4.22⁠–⁠4.66 s inside the container, 5.51⁠–⁠5.93 s over HTTPSA cell under 25 MB wakes in about 5⁠–⁠6 s
Heavy chain cold wakeWith a 53 MiB chain: checkpoint 10.84 s (150.70 MB, 18 parts), stream hydrate 3.60 s (120.32 MB), cold wake 10.02 s inside and 16.57 s over HTTPSWake time grows with chain size, so GBs in the chain would break fast wakes
Peak conductor memory281.2 MiB peak resident memory under active writes, under 7% of 4 GiB, with MALLOC_ARENA_MAX=2 and CALL_CONCURRENCY=2Holochain 0.7.1 fits a standard-1 container
Edge rejectionInvalid requests refused with 401 at the edge in 76.9⁠–⁠94.9 ms, with no container wakeInternet noise costs no container time
Epoch deleteRetiring 1 epoch cell shrank the R2 checkpoint from 150.70 MB to 120.32 MB, 30.38 MB lessWorks for append-and-expire records; random-access deletes need Mode B
Encrypted database backupssqlite3 .backup on the Holochain and lair databases (reserved_bytes = 80) stripped per-page HMACs and broke themBack up only after a clean SIGTERM, as a byte-exact copy
Swap reportingmemory.swap.max is unpopulated while /proc/meminfo reports SwapTotal: 0 kB; 7.32 GiB of root disk freeHealth checks accept either signal; the free-disk floor is 512 MiB or less

07Build status

Where the build stands on 27 Nov 2026.

Nothing is released yet. Each milestone below names what it proves; only M0 and M1 have been reached.

  1. M0 · Holochain app package

    Achieved

    Integrity and coordinator zomes (the hApp's validation rules and functions) on hdk 0.7.1 and hdi 0.8.1, packed deterministically into happbucket.happ. 8 Rust unit tests pass.

  2. M1 · S3 gateway core

    Built, verified locally

    Chunked AES-256-GCM codec with a pure-TypeScript BLAKE3, SigV4 header and presigned verification with key rotation and revocation, the local-disk blob driver with instant reclaim, in-memory and Holochain manifest stores, and the S3 router.

    13 tests with 89 assertions pass against the in-memory manifest store and local disk, and the TypeScript build reports 0 errors. On 27 Nov 2026 the happbucket dev command, which Get started walks through, served the real AWS CLI through create, upload, list, download, a range read, a presigned read and delete. The live conductor and R2 come in M2.

  3. M2 · Live Cloudflare package

    Next

    Worker, Durable Object cache, Holochain node container and R2 driver. M2 will prove a 200 MiB multipart upload, an edge range read in about 50⁠–⁠100 ms without a container wake, a cold write wake of about 5⁠–⁠6 s, immediate R2 reclaim on delete, and full revocation.

  4. M3 · rclone and restic conformance

    Planned

    M3 will run unmodified rclone sync and mount, and restic backup and restore, against live endpoints on both a Linux server and Cloudflare, and add the Mode A benchmark for vaults up to 500 MiB.

  5. M4 · Granis Personal integration

    Planned

    Granis Personal on Holochain will gain multi-GB files, native range reads, signed read links, immediate delete cleanup and 1-click Cloudflare setup.

  6. M5 · Open-source release v0.1.0

    Planned

    Dual MIT OR Apache-2.0 license, Wrangler and Docker templates, the v0.1.0 tag and a public source repository, listed on hAppRadar.

08Pinned build

A pinned, deterministic .happ.

The zomes build for wasm32-unknown-unknown with --remap-path-prefix applied to the Rust sysroot, the cargo home and the repository root, so builds are deterministic; the pinned DNA hash below identifies this build.

Holochain
holochain 0.7.1 · hdk 0.7.1 · hdi 0.8.1
Integrity zome
1,786,280 B
Coordinator zome
3,284,006 B
DNA hash
uhC0kXHvQWEXfVTv0aIwXciwoQoBJJYxx77RBxBAi8-xHatSOSpPk
Zome functions
create_bucket, get_bucket, put_manifest, get_manifest, list_manifests, retire_manifest, bucket_usage, put_part, get_part, revoke_grant, is_grant_revoked, attest