std.crypto.core.keccak.KeccakF
pub fn KeccakF(comptime f: u11) type
The Keccak-f permutation.
- Kind
- type function
- Module
std.crypto.core.keccak
Source: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
The entries of std.crypto.core.keccak in the Zig reference. This page has 24 cards.
pub fn KeccakF(comptime f: u11) type
The Keccak-f permutation.
std.crypto.core.keccakSource: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn addByte(self: *Self, byte: u8, offset: usize) void
XOR a byte into the state at a given offset.
std.crypto.core.keccakSource: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn addBytes(self: *Self, bytes: []const u8) void
XOR bytes into the beginning of the state.
std.crypto.core.keccakSource: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn asBytes(self: *Self) *[block_bytes]u8
A representation of the state as bytes.
std.crypto.core.keccakSource: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
Number of bytes in the state.
std.crypto.core.keccakSource: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn clear(self: *Self, from: usize, to: usize) void
Set the words storing the bytes of a given range to zero.
std.crypto.core.keccakSource: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn endianSwap(self: *Self) void
Byte-swap the entire state if the architecture doesn't match the required endianness.
std.crypto.core.keccakSource: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn extractBytes(self: *Self, out: []u8) void
Extract the first bytes of the state.
std.crypto.core.keccakSource: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn init(bytes: [block_bytes]u8) Self
Initialize the state from a slice of bytes.
std.crypto.core.keccakSource: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
Maximum number of rounds for the given f parameter.
std.crypto.core.keccakSource: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn permute(self: *Self) void
Apply a full-round permutation to the state.
std.crypto.core.keccakSource: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn permuteR(self: *Self, comptime rounds: u5) void
Apply a (possibly) reduced-round permutation to the state.
std.crypto.core.keccakSource: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn secureZero(self: *Self) void
Clear the entire state, disabling compiler optimizations.
std.crypto.core.keccakSource: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn setBytes(self: *Self, bytes: []const u8) void
Set bytes starting at the beginning of the state.
std.crypto.core.keccakSource: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn xorBytes(self: *Self, out: []u8, in: []const u8) void
XOR the first bytes of the state into a slice of bytes.
std.crypto.core.keccakSource: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn State(comptime f: u11, comptime capacity: u11, comptime rounds: u5) type
A generic Keccak-P state.
std.crypto.core.keccakSource: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn absorb(self: *Self, bytes: []const u8) void
Absorb a slice of bytes into the sponge.
std.crypto.core.keccakSource: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn fillBlock(self: *Self) void
Align the input to the rate boundary and permute.
std.crypto.core.keccakSource: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn init(bytes: [f / 8]u8, delim: u8) Self
Initialize the state from a slice of bytes.
std.crypto.core.keccakSource: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
Keccak does not have any options.
std.crypto.core.keccakSource: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn pad(self: *Self) void
Mark the end of the input.
std.crypto.core.keccakSource: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn permute(self: *Self) void
Permute the state.
std.crypto.core.keccakSource: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
The block length, or rate, in bytes.
std.crypto.core.keccakSource: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.
pub fn squeeze(self: *Self, out: []u8) void
Squeeze a slice of bytes from the sponge.
std.crypto.core.keccakSource: codeberg.org, ziglang.org. JSON record. This entry is a card. Help write this page.