createSubkeys

Creates 16 subkeys all of them being 0x00.

They key parameter is unused.

pure
BitArray[16]
createSubkeys
(
const(ubyte)[] key
)

Parameters

key const(ubyte)[]

Ignored. Should be empty

Return Value

Type: BitArray[16]

16 BitArrays that contain the subkeys

Examples

const ubyte[] message = [0x48, 0x69, 0x67, 0x68, 0x20, 0x50, 0x72, 0x69, 0x65, 0x73, 0x74];
const ubyte[] encodingKey = [0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07];
const ubyte[] decodingKey = [0xA0, 0xA1, 0xA2, 0xA3, 0xA4, 0xA5, 0xA6, 0xA7];
const ubyte[] encoded = [0x4D, 0x7D, 0x36, 0x69, 0x30, 0x11, 0x26, 0x7D,
    0x61, 0x77, 0x65, 0x54, 0x54, 0x05, 0x50, 0x11];

const ubyte[] actualEncoded = encrypt(message, encodingKey);
const ubyte[] actualDecoded = decrypt(encoded, decodingKey, message.length);

assert(actualEncoded == encoded);
assert(actualDecoded == message);

Meta