GCMMultiplier8kTable.multiply

Multiply x by H and store result in x.

struct GCMMultiplier8kTable
nothrow @nogc
void
multiply
(
ubyte[] x
)
in { assert (x.length == 16, "x: invalid length."); }

Parameters

x
Type: ubyte[]

16 byte block

Examples

test multiplication using 8k table

1 t {
2 		
3 		immutable ubyte[16] H = cast(immutable ubyte[16]) x"66e94bd4ef8a2c3b884cfa59ca342b2e";
4 		ubyte[16] X1 = cast(immutable ubyte[16]) x"0388dace60b6a392f328c2b971b2fe78";
5 		
6 		GCMMultiplier8kTable mult = GCMMultiplier8kTable(H);
7 		
8 		mult.multiply(X1);
9 		
10 		assert(X1 == x"5e2ec746917062882c85b0685353deb7", "GF128 multiplication with 8k table failed!")

Meta