External Hashers — Descriptor

Field Type / Allowed Required Purpose
func `async (Uint8Array) → Uint8Array string` yes*
output `‘bytes’ ‘hex’ ‘base64’`
size integer (bits) optional Enforces digest length at runtime
cdn string (URL) optional Auto-loads and registers the hasher

* Either func or cdn must be provided. Supplying both is fine.

Error behavior

  • Missing hasher → Hasher <id> not registered
  • Wrong length → Hasher <id> size mismatch
  • Unsupported output → Unsupported output <fmt>