World Cryptologic Competition 2023

Reference Implementation Standard

The reference implementation standard differs slightly between the three entry categories. In the below table, "EN" is the unique Entry Name of your entry, without spaces.
RequirementCategoryRequirement
A.1Category A (Block Ciphers)#define ENTRY_EN_[whatever is needed]
A.2Category A (Block Ciphers)struct entry_EN_state member uint64_t key[8]
A.3Category A (Block Ciphers)struct entry_EN_state member uint64_t nonce[3]
A.4Category A (Block Ciphers)struct entry_EN_state member uint64_t plaintext[8]
A.5Category A (Block Ciphers)struct entry_EN_state member uint64_t ciphertext[8]
A.6Category A (Block Ciphers)void entry_EN_ENC(struct entry_EN_state * const state)
A.7Category A (Block Ciphers)void entry_EN_DEC(struct entry_EN_state * const state)

B.1Category B (Digest Functions)#define ENTRY_EN_[whatever is needed]
B.2Category B (Digest Functions)struct entry_EN_state member uint64_t key[8]
B.3Category B (Digest Functions)struct entry_EN_state member uint64_t nonce[3]
B.4Category B (Digest Functions)struct entry_EN_state member char * rawInput
B.5Category B (Digest Functions)struct entry_EN_state member uint64_t numberOfInputBits
B.6Category B (Digest Functions)struct entry_EN_state member uint64_t output[8]
B.7Category B (Digest Functions)void entry_EN_produceDigest(struct entry_EN_state * const state)

C.1Category C (Stream Ciphers)#define ENTRY_EN_[whatever is needed]
C.2Category C (Stream Ciphers)struct entry_EN_state member uint64_t key[8]
C.3Category C (Stream Ciphers)struct entry_EN_state member uint64_t nonce[3]
C.4Category C (Stream Ciphers)struct entry_EN_state member uint64_t outputStreamLengthInBits
C.5Category C (Stream Ciphers)struct entry_EN_state member uint64_t *outputStream
C.6Category C (Stream Ciphers)void entry_EN_produceStream(struct entry_EN_state * const state)

Examples

ExampleLink
"ToyBlockCipher" as a Category A Entry in WCC 2023examples/ToyBlockCipher.h
SHA-2-512 as a Category B Entry in WCC 2023examples/SHA512.h
"ToyStreamCipher" as a Category C Entry in WCC 2023examples/ToyStreamCipher.h