lkml.org 
[lkml]   [2015]   [Jun]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH RFC v5 2/4] crypto: add PKE API
On Mon, Jun 15, 2015 at 07:21:48PM -0700, Tadeusz Struk wrote:
>
> I thought that the ctx needs to be available for implementations to store private data.
> This way we can allocate and store any type of key in the <alg>_parse_key() helper and still have the cxt
> available for implementations to use for their stuff (e.g. HW context).

No for symmetric key algorithms we always store the key in the
context and never in the tfm proper.

Think about it, the generic tfm doesn't have any idea on what
the key contains so how can it store it? Only the implementation
knows the key format and can store it in a useful way.

Cheers,
--
Email: Herbert Xu <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt


\
 
 \ /
  Last update: 2015-06-16 04:41    [W:0.060 / U:0.060 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site