import type { ColdCode } from "../core/types.js"; import { Matter, type MatterInit } from "./matter.js"; interface DigerOptions { strict?: boolean; } type DigestFn = (ser: Uint8Array) => Uint8Array; /** * Digest primitive family. * * KERIpy substance: `Diger` encapsulates self-addressing digest material and * optionally constrains codes to digest codex membership (`strict=true`). * * Maintainer note: * `DigDex` remains the canonical namespace of supported digest codes, but this * class is the runtime authority for "code -> hash implementation" dispatch. * Keep new digest algorithms centralized here so `Saider`, `Serder`, and app * flows do not grow their own private digest switches. */ export declare class Diger extends Matter { /** Shared KERIpy-style digest registry keyed by canonical `DigDex` values. */ static readonly Digests: Map; constructor(init: Matter | MatterInit, options?: DigerOptions); get digest(): Uint8Array; get algorithm(): string; /** Compute raw digest bytes for `ser` using the digest family selected by `code`. */ static digest(ser: Uint8Array, code: string): Uint8Array; verify(ser: Uint8Array): boolean; /** Compare `ser` against either the instance digest or an override digest. */ compare(ser: Uint8Array, dig?: Uint8Array): boolean; /** Constant-shape byte comparison helper used by higher-level SAID/serder verification. */ static compare(ser: Uint8Array, code: string, dig: Uint8Array): boolean; } /** Parse and hydrate `Diger` from txt/qb2 bytes. */ export declare function parseDiger(input: Uint8Array, cold: Extract): Diger; export {}; //# sourceMappingURL=diger.d.ts.map