All of lore.kernel.org
 help / color / mirror / Atom feed
From: Tadeusz Struk <tadeusz.struk@intel.com>
To: Marcel Holtmann <marcel@holtmann.org>,
	Stephan Mueller <smueller@chronox.de>
Cc: linux-crypto@vger.kernel.org
Subject: Re: Limited usefulness of RSA set key function
Date: Mon, 03 Aug 2015 10:11:17 -0700	[thread overview]
Message-ID: <55BFA0B5.6070107@intel.com> (raw)
In-Reply-To: <2726A091-A7A2-451F-BB11-A19A73DA3C36@holtmann.org>

Hi Marcel,
On 08/03/2015 12:30 AM, Marcel Holtmann wrote:
> as you can clearly see. There are two formats defined here. There is no single ASN.1 structure that can decode both of these.
> 
> It is what it is, RSA Public Key and RSA Private Key formats are two different key formats. And OpenSSL also treats it like this. You can extract the public key from a private key (same way you can extract it from a certificate), but you can not create a private key structure that only contains the public key.
> 
> For RSA we need to support the two formats as listed above. To make this really easy from an API point of view, I would have setkey and setpubkey function. And also expose them as ALG_SET_KEY and ALG_SET_PUBKEY socket options for AF_ALG.

I'll have a look what will be the easiest way to get the openSSL generated & unmodified private key working.
Thanks,
T

  reply	other threads:[~2015-08-03 17:12 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-08-03  4:16 Limited usefulness of RSA set key function Marcel Holtmann
2015-08-03  6:45 ` Stephan Mueller
2015-08-03  7:14   ` Marcel Holtmann
2015-08-03  7:18     ` Stephan Mueller
2015-08-03  7:30       ` Marcel Holtmann
2015-08-03 17:11         ` Tadeusz Struk [this message]
2015-08-03 17:39           ` Marcel Holtmann
2015-08-03 17:52             ` Tadeusz Struk
2015-08-03 18:20               ` Marcel Holtmann
2015-08-03 18:32                 ` Tadeusz Struk
2015-08-03 18:11             ` Marcel Holtmann

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=55BFA0B5.6070107@intel.com \
    --to=tadeusz.struk@intel.com \
    --cc=linux-crypto@vger.kernel.org \
    --cc=marcel@holtmann.org \
    --cc=smueller@chronox.de \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.