[Swan-dev] sha2 support for klips with cryptoapi

Wolfgang Nothdurft wolfgang at linogate.de
Thu Sep 18 21:31:54 EEST 2014


Am 18.09.2014 18:26, schrieb Paul Wouters:
> On Thu, 18 Sep 2014, Wolfgang Nothdurft wrote:
>
>> I have added a ticket with an unfinished version.
>>
>> https://bugs.libreswan.org/show_bug.cgi?id=210
>
> Thanks. A quick peak shows:
>
> +    if (ixt->ixt_a_hmac_set_key==NULL && ixt->ixt_a_hmac_new_key == NULL)
> +        barf_out(KERN_ERR "a_hmac_set_key() or a_hmac_new_key() must be
> not NULL\n");
>
> I think you mean || and not && there?
>

no, thats correct, you may either have ixt_a_hmac_set_key or 
ixt->ixt_a_hmac_new_key for initialising the key.
The existing AES_HMAC uses the set_key function and I introduced the 
new_key function as I worte in the ticket.
I don't now, if this is the best way.

> Hopefully David can have a peek at the patch, he knows much more about
> cryptoapi than I do (and might want to get sha2 support in KLIPS as well :)
>
> Paul
>

Hopefully. I think it is only a bagatelle what is missing in my code to 
get sha2 working.

Wolfgang


More information about the Swan-dev mailing list