CBC-MAC implementation in C

1.2k Views Asked by At

I'm hoping to do some benchmarking of CBC-MAC in C. Does anyone know of a robust C implementation? I've looked around but CBC-MAC implementations (in almost any language) seem to be quite rare. Does anyone know why beside its rather restrictive (desired) use cases, e.g., fixed-length input.

Thanks

1

There are 1 best solutions below

1
On BEST ANSWER

If you encrypt a message with a block cipher in CBC mode with a zero Initialization Vector, then the last encrypted block, is the CBC-MAC.

So if you have a block cipher implementation that supports CBC mode, you basically have support for CBC-MAC.