Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

[CRYPTO] doc: Update api-intro.txt

This patch updates the list of transforms we support and clarifies that
the Block Ciphers interface in fact supports all ciphers including stream
ciphers.

It also removes the obsolete Configuration Notes section and adds the
linux-crypto mailing list as the primary bug reporting address.

Finally it documents the fact that setkey should only be called from
user context.

Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>

+16 -25
+16 -25
Documentation/crypto/api-intro.txt
··· 33 33 very simple, while hiding the core logic from both. Many good ideas 34 34 from existing APIs such as Cryptoapi and Nettle have been adapted for this. 35 35 36 - The API currently supports three types of transforms: Ciphers, Digests and 37 - Compressors. The compression algorithms especially seem to be performing 38 - very well so far. 36 + The API currently supports five main types of transforms: AEAD (Authenticated 37 + Encryption with Associated Data), Block Ciphers, Ciphers, Compressors and 38 + Hashes. 39 + 40 + Please note that Block Ciphers is somewhat of a misnomer. It is in fact 41 + meant to support all ciphers including stream ciphers. The difference 42 + between Block Ciphers and Ciphers is that the latter operates on exactly 43 + one block while the former can operate on an arbitrary amount of data, 44 + subject to block size requirements (i.e., non-stream ciphers can only 45 + process multiples of blocks). 39 46 40 47 Support for hardware crypto devices via an asynchronous interface is 41 48 under development. ··· 76 69 Many real examples are available in the regression test module (tcrypt.c). 77 70 78 71 79 - CONFIGURATION NOTES 80 - 81 - As Triple DES is part of the DES module, for those using modular builds, 82 - add the following line to /etc/modprobe.conf: 83 - 84 - alias des3_ede des 85 - 86 - The Null algorithms reside in the crypto_null module, so these lines 87 - should also be added: 88 - 89 - alias cipher_null crypto_null 90 - alias digest_null crypto_null 91 - alias compress_null crypto_null 92 - 93 - The SHA384 algorithm shares code within the SHA512 module, so you'll 94 - also need: 95 - alias sha384 sha512 96 - 97 - 98 72 DEVELOPER NOTES 99 73 100 74 Transforms may only be allocated in user context, and cryptographic 101 - methods may only be called from softirq and user contexts. 75 + methods may only be called from softirq and user contexts. For 76 + transforms with a setkey method it too should only be called from 77 + user context. 102 78 103 79 When using the API for ciphers, performance will be optimal if each 104 80 scatterlist contains data which is a multiple of the cipher's block ··· 120 130 BUGS 121 131 122 132 Send bug reports to: 123 - Herbert Xu <herbert@gondor.apana.org.au> 124 - Cc: David S. Miller <davem@redhat.com> 133 + linux-crypto@vger.kernel.org 134 + Cc: Herbert Xu <herbert@gondor.apana.org.au>, 135 + David S. Miller <davem@redhat.com> 125 136 126 137 127 138 FURTHER INFORMATION