From: Herbert Xu <herbert@gondor.apana.org.au>
To: Tudor Ambarus <tudor-dan.ambarus@nxp.com>
Cc: linux-crypto@vger.kernel.org, tadeusz.struk@intel.com,
smueller@chronox.de, cristian.stoica@nxp.com,
horia.geanta@nxp.com
Subject: Re: [PATCH v3 1/3] crypto: rsa - generalize ASN.1 sequences
Date: Fri, 15 Apr 2016 21:52:45 +0800 [thread overview]
Message-ID: <20160415135245.GA334@gondor.apana.org.au> (raw)
In-Reply-To: <1459949826-11840-2-git-send-email-tudor-dan.ambarus@nxp.com>
On Wed, Apr 06, 2016 at 04:37:04PM +0300, Tudor Ambarus wrote:
> Use common ASN.1 sequences for all RSA implementations.
>
> Give hardware RSA implementations the chance to use
> the RSA's software implementation parser even if they
> are likely to want to use raw integers.
>
> The parser expects a context that contains at the first address
> a pointer to a struct rsa_asn1_action instance that has function
> pointers to specific parser actions (return MPI or raw integer keys),
> followed by a key representation structure (for MPI or raw integers).
>
> This approach has the advantage that users can select specific
> parser actions by using a general parser with function pointers
> to specific actions.
I don't understand why we need different parsing functions in the
first place. Can't they just return raw integers always?
You can then trivially convert the raw integers to MPI, no?
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
next prev parent reply other threads:[~2016-04-15 13:52 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-04-06 13:37 [PATCH v3 0/3] crypto: rsa - generalize ASN.1 sequences Tudor Ambarus
2016-04-06 13:37 ` [PATCH v3 1/3] " Tudor Ambarus
2016-04-15 13:52 ` Herbert Xu [this message]
2016-04-15 14:32 ` Tudor-Dan Ambarus
2016-04-15 14:38 ` Herbert Xu
2016-04-15 15:03 ` Tudor-Dan Ambarus
2016-04-25 5:54 ` Tudor-Dan Ambarus
2016-04-25 5:58 ` Herbert Xu
2016-04-06 13:37 ` [PATCH v3 2/3] crypto: rsa_helper - add raw integer parser actions Tudor Ambarus
2016-04-08 16:32 ` Stephan Mueller
2016-04-14 15:25 ` Tudor-Dan Ambarus
2016-04-14 15:38 ` Stephan Mueller
2016-04-15 5:58 ` Herbert Xu
2016-04-08 16:54 ` Jeffrey Walton
2016-04-08 16:55 ` Stephan Mueller
2016-04-08 17:09 ` Jeffrey Walton
2016-04-08 17:13 ` Stephan Mueller
2016-04-06 13:37 ` [PATCH v3 3/3] crypto: rsa_helper - export symbols for asn1 structures Tudor Ambarus
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20160415135245.GA334@gondor.apana.org.au \
--to=herbert@gondor.apana.org.au \
--cc=cristian.stoica@nxp.com \
--cc=horia.geanta@nxp.com \
--cc=linux-crypto@vger.kernel.org \
--cc=smueller@chronox.de \
--cc=tadeusz.struk@intel.com \
--cc=tudor-dan.ambarus@nxp.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox