On Wed, Apr 07, 2010 at 10:23:00AM +0200, Sebastian Andrzej Siewior wrote: > > So arc4_setup_iv() should do what the internal arc4_ivsetup() does and > we change void to int and check the keysize in there right? The problem > here is that we are bounded to *this* implementation of the algorithm > and are not able to replace it with a different implementation. Not that > this is likely to happen for RC4 but it may be true for other stream > ciphers. By setting an IV we're already requiring the other implementations use the IV format used by our arc4. So they would always work with this arc4_ivsetup anyway. If and when we do have a piece of hardware that cannot do this (which I doubt would ever happen, considering how fast arc4 is already), then we can talk about changing this. > >I'm pretty sure testmgr will call setkey even for keylen == 0, no? > Prior patch #3 it has no test case so it should not test it at all. > Patch #3 adds a flag in order to distinguish it. You want to look at > patch #3 now :) I see. But still we should at least not crash when crypto_blkcipher_setkey is called. This might happen in future when we get a user-space API. Cheers, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} <herbert@xxxxxxxxxxxxxxxxxxx> Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt -- To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html