AbsoluteJS

@absolutejs/secure-transfer-local

@absolutejs/secure-transfer-localv0.2.2betaPlatform & Infra

Atomic local-filesystem storage adapter for @absolutejs/secure-transfer.

#Installation

BASH
bun add @absolutejs/secure-transfer-local

#Capabilities

Overview

Local-filesystem SecureTransferLifecycleStore for development, tests, and single-host deployments.

Records are atomically installed with a same-filesystem hard link. Existing records are never overwritten. Each record carries a private binary expiry header so an interrupted write cannot leave ciphertext without cleanup data.

Run sweepExpired() on a schedule and repeat while truncated is true. The adapter validates transfer IDs and never follows caller-controlled paths. Expiry-stamped temporary writes are swept too, including partial files left by a process crash before the atomic link.

Show 2 more

The receipt store persists only bytes already protected by a SecureTransferReceiptProtector. It uses cross-process lock directories, lease expiry, version checks, and atomic rename. Run sweepExpiredReceipts() for abandoned resumable-upload state.

The revocation store creates immutable SHA-256 descriptor tombstones without placing transfer IDs in paths or plaintext files. Use a policy root protected from ciphertext-storage credentials. Run sweepExpiredRevocations() repeatedly with its cursor only after each tombstone's required retention has ended.

Outcomes

What you can build

Build on the supported package contract

Use @absolutejs/secure-transfer-local through its supported public entry points.

Hardening checklist

Production guidance

Make every external boundary explicitPin the deployed @absolutejs/secure-transfer-local version, replace example or memory-backed dependencies with durable implementations, bound external calls, protect credentials, and emit enough evidence to retry or recover safely.

Follow in order

Troubleshooting path

1
Trace from the first failed boundary
Reproduce the smallest canonical @absolutejs/secure-transfer-local example, confirm the supported entry point and version in the API explorer, then inspect the first boundary that did not produce its documented result.

#@absolutejs/secure-transfer-local quick start

Partial snippet

# @absolutejs/secure-transfer-local

TS
import {
  localProtectedReceiptStore,
  localSecureTransferRevocationStore,
  localSecureTransferStore,
} from "@absolutejs/secure-transfer-local";

const store = localSecureTransferStore({ root: "/srv/private/ciphertext" });
const receiptStore = localProtectedReceiptStore({
  root: "/srv/private/ciphertext",
});
const revocations = localSecureTransferRevocationStore({
  root: "/srv/private/policy",
});

#Public entry points

Supported entry points declared by this package manifest.

Package entry point declared in package.json.

@absolutejs/secure-transfer-local@absolutejs/secure-transfer-local/manifest@absolutejs/secure-transfer-local/manifest.json

#Package commands

Scripts declared by this package manifest.

bun run buildrm -rf dist && bun build src/index.ts src/manifest.ts --outdir dist --root src --sourcemap --target=bun --external @absolutejs/secure-transfer --external @absolutejs/manifest --external @sinclair/typebox && tsc --project tsconfig.build.json && absolute-manifest emit
bun run check:packagebun run format:check && bun run typecheck && bun run test && bun run build && bun run verify-package
bun run format:checkprettier --check "./**/*.{ts,json,md}"
bun run testbun test tests/
bun run typechecktsc --noEmit

#API reference

Search the declarations exported by the current package type files. Expand a symbol to inspect its source-backed signature.

6 symbols
localProtectedReceiptStoreexportPermalinkSource
TS
localProtectedReceiptStore
Exported from @absolutejs/secure-transfer-local