2.2.17.8 has now been released. This patch includes some reorganization of the code, but also some important API changes. Or rather, the interface is now defined :-). The encrypt/decrypt functions are allowed to sleep, and they have to tackle all input/output sizes. This is the new interface as defined in crypto.h: /* * Encrypt the plaintext pointed to by "in". Write output to * "out". Size of plaintext is "size". Output buffer must be * able to hold "size" bytes plus padding necessary to make it * a multiple of the cipher blocksize. size <= 0 is * undefined. Returns 0 on success, non-zero on * failure. Function might sleep. * */ int (*encrypt)(struct cipher_context *cx, const u8 *in, u8 *out, int size); /* * Decrypt the ciphertext pointed to by "in". Write output to * "out". Size of plaintext is "size". Input buffer is "size" * bytes plus padding necessary to make it a multiple of the * cipher blocksize. size <= 0 is undefined. Returns 0 on * success, non-zero on failure. Function might sleep. * */ int (*decrypt)(struct cipher_context *cx, const u8 *in, u8 *out, int size); ChangeLog: 2000-10-14 Alexander Kjeldaas <astor@xxxxxxx> * International kernel patch 2.2.17.8 released. * Configure.help updates with the AES results. Patch from Marc Mutz <marc@xxxxxxxx> * Cipher list in config organized according to block-size with AES at the top. Patch from Marc Mutz <marc@xxxxxxxx> * The set of allowed key-sizes for a cipher is now exported as a mask in /proc. Constants for allowed key-sizes are defined in crypto.h. Patch from Marc Mutz <marc@xxxxxxxx> * Ability to build cryptoapi.c as a module was missing from Config.in. Fixed. * DEFINE_{DIGEST,CIPHER} et. al. removed and replaced by explicit struct {digest,cipher}_implementation initializations making the code more readable. * API change. Encryp/Decrypt now accepts any input/output byte count. * gen-cbc.h changed to allow any input-size for encryption, or output-size for decryption. When encrypting large blocks, gen-cbc.h will now sleep (you can play music while using an encrypted file-system). Added gen-ecb.h which implements the same for ECB mode. All ciphers changed to use gen-ecb.h to implement their ECB mode. * Removed old cruft (crypto/cipherapi.c crypto/digestapi.c) * crypto/cryptoapi.c implementation made simpler. * Crypto API functions are documented in kernel-doc style. * crypto/testing updates. digesttest now compiles. A lot of duplicated functions are now available in misc.c. None of the programs include glibc headers any more, all necessary functions are declared in libcfuncs.h. New program "testapi" for testing that a cipher deals with the new API. astor -- Alexander Kjeldaas Mail: astor@xxxxxxx finger astor@xxxxxxxxxxxxxxxxx for OpenPGP key. Linux-crypto: cryptography in and on the Linux system Archive: http://mail.nl.linux.org/linux-crypto/