Ciphers And Templates
Prev | Chapter 2. Kernel Crypto API Architecture | Next

## Ciphers And Templates

The kernel crypto API provides implementations of single block ciphers and message digests. In addition, the kernel crypto API provides numerous "templates" that can be used in conjunction with the single block ciphers and message digests. Templates include all types of block chaining mode, the HMAC mechanism, etc.

Single block ciphers and message digests can either be directly used by a caller or invoked together with a template to form multi-block ciphers or keyed message digests.

A single block cipher may even be called with multiple templates. However, templates cannot be used without a single cipher.

See /proc/crypto and search for "name". For example:

- aes

- ecb(aes)

- cmac(aes)

- ccm(aes)

- rfc4106(gcm(aes))

- sha1

- hmac(sha1)

- authenc(hmac(sha1),cbc(aes))

In these examples, "aes" and "sha1" are the ciphers and all others are the templates.

Prev | Up | Next
Chapter 2. Kernel Crypto API Architecture | Home | Synchronous And Asynchronous Operation