Ambimat GroupAmbimatAmbiSecureeSIM InitiativeEngineering BlogAhmedabad · India · Est. 1981
Crypto

CMAC Length Calculator

Compute the number of CMAC blocks, the padded length, and standard output truncations for AES-128 / AES-192 / AES-256 / TDES. Practical reference when wiring SCP03, DESFire EV2/EV3 secure messaging, or EMV CDA.

Input

Result

Enter input length and pick a cipher.
All decoding runs locally.

About CMAC

CMAC (NIST SP 800-38B) is a Cipher-based MAC built on a block cipher. It uses two derived subkeys (K1, K2) selected by message length to handle padding without ambiguity. Common deployments truncate the 16-byte output to 8 bytes for transport efficiency.

Spec

NIST SP 800-38B; ISO/IEC 9797-1.