lkml.org 
[lkml]   [2004]   [Feb]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH/proposal] dm-crypt: add digest-based iv generation mode
From
Date
Am Sa, den 28.02.2004 schrieb Matt Mackall um 01:39:

> > There's just one small difficulty with having some of the structures in
> > the context: Their size is variable. But known after the init function.
> > So the cra_ctxsize isn't sufficient to describe the length of a tfm
> > strucure. So we need another per-algorithm-category method that returns
> > the additional size required. They might just return iv_size or iv_size
> > + omac_pad_size for ciphers and hmac_pad_size for digests or something
> > like this.
>
> Hmmm, crypto_alloc_tfm does:
>
> tfm = kmalloc(sizeof(*tfm) + alg->cra_ctxsize, GFP_KERNEL);
>
> So I'm not clear on how the necessary size can be anything else at
> copy time?

Forget it, my mistake. cra_ctxsize is set by the algorithms themselves.


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 14:01    [W:0.066 / U:1.928 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site