/******************************************************************** * @author: Kaven * @email: kaven@wuwenkai.com * @website: http://blog.kaven.xyz * @file: [Kaven-Basic] /src/libs/hash/KavenSHA3.ts * @create: 2019-04-05 22:50:29.192 * @modify: 2025-10-14 22:39:26.164 * @version: 6.1.0 * @times: 198 * @lines: 771 * @copyright: Copyright © 2019-2025 Kaven. All Rights Reserved. * @description: [description] * @license: * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal * in the Software without restriction, including without limitation the rights * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell * copies of the Software, and to permit persons to whom the Software is * furnished to do so, subject to the following conditions: * * The above copyright notice and this permission notice shall be included in all * copies or substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. ********************************************************************/ import { KavenUInt64 } from "../class/KavenUInt64"; import { IAsyncDataAcquisition } from "../interface/IAsyncDataAcquisition"; import { ILoggingAgent } from "../interface/ILoggingAgent"; import { ISyncDataAcquisition } from "../interface/ISyncDataAcquisition"; import { TAsyncHashInput, TSyncHashInput } from "../type/advanced"; export declare class KavenSHA3 { /** * Round constants */ static readonly RC: KavenUInt64[]; /** * Rotation offsets */ static readonly r: number[][]; /** * Keccak-f[b] * @param b `b∈{25,50,100,200,400,800,1600}` is the width of the permutation. * * The width of the permutation is also the width of the state in the sponge construction. * @see https://keccak.team/keccak_specs_summary.html */ KeccakF(a: KavenUInt64[][], b?: 25 | 50 | 100 | 200 | 400 | 800 | 1600): KavenUInt64[][]; /** * Keccak[r,c] sponge function, with parameters capacity c and bitrate r. * @param data * @param r bitrate * @param c capacity * @param xof * @param len message digest output length in bits * @param b */ Keccak(data: ISyncDataAcquisition, r: number, c: number, xof?: boolean, len?: number, b?: 25 | 50 | 100 | 200 | 400 | 800 | 1600): string; /** * Keccak[r,c] sponge function, with parameters capacity c and bitrate r. * @param data * @param r bitrate * @param c capacity * @param xof * @param len message digest output length in bits * @param b */ KeccakAsync(data: IAsyncDataAcquisition, r: number, c: number, xof?: boolean, len?: number, b?: 25 | 50 | 100 | 200 | 400 | 800 | 1600): Promise; Compute224(input: TSyncHashInput): string; Compute224Async(input: TAsyncHashInput): Promise; Compute256(input: TSyncHashInput): string; Compute256Async(input: TAsyncHashInput): Promise; Compute384(input: TSyncHashInput): string; Compute384Async(input: TAsyncHashInput): Promise; Compute512(input: TSyncHashInput): string; Compute512Async(input: TAsyncHashInput): Promise; ComputeSHAKE128(input: TSyncHashInput, len: number): string; ComputeSHAKE128Async(input: TAsyncHashInput, len: number): Promise; ComputeSHAKE256(input: TSyncHashInput, len: number): string; ComputeSHAKE256Async(input: TAsyncHashInput, len: number): Promise; protected PrintState(state: KavenUInt64[][], logger: ILoggingAgent): void; protected Round(a: KavenUInt64[][], rc: KavenUInt64): KavenUInt64[][]; } //# sourceMappingURL=KavenSHA3.d.ts.map