Re: Did the in-kernel Camellia or CMAC crypto implementation break?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Herbert Xu <herbert@xxxxxxxxxxxxxxxxxxx> wrote:

> Now that you have it working, perhaps you could convert some of
> your test vectors into crypto API test vectors?

Actually, I was wondering about that.  I see that all the testing data seems
to be statically loaded in testmgr.[ch], even if the algorithms to be tested
are resident in modules that aren't loaded yet (so it's kind of test "on
demand").  I guess it can't be split up amongst the algorithm modules as some
of the tests require stuff from multiple modules (eg. aes + cbs + cts).

If I'm going to do that, I presume I'd need to create an API akin to the
skcipher API or the hash API, say, to do autoload/create krb5 crypto.  Maybe
loading with something like:

	struct crypto_krb5 *alg;

	alg = crypto_alloc_krb5("aes256-cts-hmac-sha384-192", 0,
				CRYPTO_ALG_ASYNC);

and split the algorithms into separate modules?  Much of the code would still
end up in a common module, though.

Note that each algorithm can be asked to do four different things and has four
different types of test:

 - PRF calculation
 - Key derivation
 - Encryption/decryption
 - Checksum generation/verification

David




[Index of Archives]     [Linux Filesystem Development]     [Linux USB Development]     [Linux Media Development]     [Video for Linux]     [Linux NILFS]     [Linux Audio Users]     [Yosemite Info]     [Linux SCSI]

  Powered by Linux