/** * LocalSecret Formatter * * Formats LocalSecrets for human-readable display and parses them back. * Uses an unambiguous character set (no 0, 1, I, O) for easy transcription. * * Format: A7K2M9-X4P8N3-B5J1L6-Q9W2R8-T3Y7U0-V6Z4C1-... * * Issue #1649 */ import type { FormattedLocalSecret } from "./types"; /** * Format a LocalSecret for human-readable display * * @param secret - The 32-byte LocalSecret * @returns Formatted LocalSecret with grouped characters */ export declare function formatLocalSecret(secret: Uint8Array): FormattedLocalSecret; /** * Parse a formatted LocalSecret back to bytes * * Handles various input formats: * - With dashes: A7K2M9-X4P8N3-... * - Without dashes: A7K2M9X4P8N3... * - With spaces: A7K2M9 X4P8N3 ... * - Lowercase: a7k2m9-x4p8n3-... * * @param formatted - The formatted LocalSecret string * @returns The 32-byte LocalSecret */ export declare function parseLocalSecret(formatted: string): Uint8Array; /** * Validate a formatted LocalSecret string * * @param formatted - The formatted LocalSecret string * @returns true if valid, false otherwise */ export declare function isValidFormattedLocalSecret(formatted: string): boolean; /** * Mask a LocalSecret for partial display * * Shows only the first and last groups, masking the middle. * Example: A7K2M9-******-******-******-******-V6Z4C1 * * @param formatted - The formatted LocalSecret * @returns Masked version for display */ export declare function maskLocalSecret(formatted: string): string;