Symmetric Encryption and Block Ciphers Questions

How symmetric-key primitives are constructed and why they work: block-cipher internals (Feistel networks vs substitution-permutation networks, the AES round structure and S-box design, key schedules and why a weak one degrades security), stream ciphers (ChaCha20 and CTR-mode keystream generation), and the internal mechanics of modes of operation (ECB, CBC, CTR, XTS, GCM), including why some are parallelizable, why ECB leaks structure, and why some require a unique nonce. Covers authenticated encryption construction internals (how GHASH and Poly1305 work, why nonce reuse breaks their security algebraically, formal security notions like IND-CPA and INT-CTXT), padding schemes and the mechanics of padding-oracle attacks, and cryptanalysis of block ciphers (differential and linear cryptanalysis, reduced-round attacks). This is the design and internals layer: how these primitives are built and proven secure, distinct from choosing which algorithm or mode to deploy, managing key lifecycle and rotation, or architecting data protection for a system, which belong to the applied cryptography layer.

HardTechnical
24 practiced

A protocol constructs a 96-bit nonce as 32-bit timestamp || 64-bit counter and uses AES-GCM. Describe an attacker strategy exploiting counter wraparound, clock rollback, or cloned devices, and show how nonce reuse might occur in practice. Propose a robust nonce construction and server-side checks to prevent exploitation.

EasyTechnical
25 practiced

Describe the high-level internal structure of the Advanced Encryption Standard (AES). Cover the following in your explanation: 1) round structure including SubBytes, ShiftRows, MixColumns, AddRoundKey; 2) key schedule basics for 128/192/256-bit keys; 3) the number of rounds and how they relate to key size; 4) why AES is designed as an SPN rather than a Feistel cipher. Keep the explanation high-level (no full code required).

EasyTechnical
25 practiced

Compare Cipher Block Chaining (CBC) and Counter (CTR) modes with respect to performance and parallelizability. Explain which parts of encryption and decryption are parallelizable for each mode, how random-access reading is supported, and implications for hardware acceleration and streaming workloads.

MediumTechnical
26 practiced

You are reviewing C code using OpenSSL EVP APIs that attempts to construct a 64-bit random prefix and a 64-bit counter to form a 128-bit IV but then passes that 16-byte IV to AES-GCM as though it were a correct nonce. Here is the snippet:

c
uint8_t iv[16];
memcpy(iv, random_prefix, 8);
memcpy(iv+8, &counter, 8); // counter is uint64_t
EVP_EncryptInit_ex(ctx, EVP_aes_128_gcm(), NULL, key, iv);

Identify the issues with this approach (including RFC guidance about IV length for GCM), possible attacks or inefficiencies, and propose a correct and robust IV derivation and management strategy compliant with standards.

MediumTechnical
28 practiced

Design a secure AEAD initialization and nonce generation strategy for an embedded device with limited entropy sources, intermittent connectivity, and power cycles. Your scheme must avoid GCM nonce reuse, limit persistent state writes (flash wear), and provide reasonable protection even if the device's RNG is weak at boot.

Unlock Full Question Bank

Get access to all 21 Symmetric Encryption and Block Ciphers interview questions and detailed answers.

Sign in to Continue

Join thousands of developers preparing for their dream job.