Module permutation

Module permutation 

Source
Expand description

Vision-6 hash permutation implementation.

Core permutation functions for the Vision-6 cryptographic hash, operating on 6-element states over GF(2^128). Each round applies: S-box → MDS → constants → S-box → MDS → constants.

Functions§

b_fwd_transform
Applies forward B-polynomial transformation to all elements in state.
b_inv_transform
Applies inverse B-polynomial transformation to all elements in state.
constants_add
Adds round constants to prevent slide attacks.
linearized_b_inv_transform_scalar
Applies linearized B⁻¹ transformation to a single field element using lookup tables.
linearized_transform_scalar
Applies linearized transformation using precomputed lookup tables for efficiency.
mds_mul
Applies MDS matrix multiplication for optimal diffusion using circulant structure.
permutation
Main Vision-6 permutation function operating on 6-element states.
sbox
S-box operation: batch inversion followed by polynomial transformation.