import type { ObjectStore } from "./objectStore.ts"; import type { Blob } from "../objects/types.ts"; export declare function redactedStub(reason: string, redactionOid: string): Blob; /** * The same eviction for a LOCAL `undo --purge` (issue #91), with a different provenance * pointer. `redacted` is the flag that marks the sanctioned oid≠content mismatch which the * store and `fsck` already understand, so an undo-purged blob is not reported as bit-rot; * `undoOid` names the {@link Undo} that ordered it. No Redaction exists for such a blob, so * `applyRedactions` below never touches it — an undo is never propagated, by construction. */ export declare function purgedStub(reason: string, undoOid: string): Blob; /** Whether `blob` is a LOCAL `undo --purge` tombstone — the one stub that must never reach a * file, as opposed to {@link redactedStub}, which a replica is supposed to project. `undoOid` * is the discriminator; `redacted` is NOT, because both stubs set it (issue #97). */ export declare function purgeTombstoneOf(blob: Blob | null | undefined): string | null; /** * A {@link purgedStub} was about to be treated as file CONTENT (issue #97). * * Blobs are content-addressed, so re-adding the file `undo --purge` deliberately left on disk * resolves to the very oid that now holds the tombstone. The eviction still holds — the secret * bytes do not come back, and content-addressing is what guarantees that — but the derivation * is broken: a source file would be silently replaced by a sentinel string. Producing a tree * that looks fine is worse than stopping, so `commit` and the materialize-to-bytes boundary * raise this instead of succeeding. * * Typed, and carrying `path`/`oid`/`undoOid`, for the same reason `CorruptObjectError` carries * `oid` (F1, docs/13): a failure deep inside `materialize` has to be actionable, which means * naming the file to fix and the record that ordered the purge — never an opaque throw. */ export declare class PurgedBlobError extends Error { readonly path: string; readonly oid: string; readonly undoOid: string; constructor(message: string, where: { path: string; oid: string; undoOid: string; }); } /** * Materialize every Redaction's stub AT its blob oid. A redacted blob's content no * longer hashes to its oid, so it can't propagate through content-addressed `put` * (which would re-address it). Instead the receiver syncs the (tiny) Redaction object * and writes the deterministic stub in place — evicting plaintext it already had, or * creating the stub on a fresh clone that never received the original. Idempotent. * * When governance is active (memberships exist), only redactions validly signed by an * admin member are applied — a forged redaction can't be used to evict (DoS) someone * else's blob. With no governance, all redactions apply (legacy/trust-all). */ export declare function applyRedactions(store: ObjectStore): Promise; //# sourceMappingURL=applyRedactions.d.ts.map