summaryrefslogtreecommitdiff
path: root/crypto/asymmetric_keys/rsa.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
* keys: change asymmetric keys to use common hash definitionsDmitry Kasatkin2013-10-251-7/+7
| | | | | | | | | | | | This patch makes use of the newly defined common hash algorithm info, replacing, for example, PKEY_HASH with HASH_ALGO. Changelog: - Lindent fixes - Mimi CC: David Howells <dhowells@redhat.com> Signed-off-by: Dmitry Kasatkin <d.kasatkin@samsung.com> Signed-off-by: Mimi Zohar <zohar@linux.vnet.ibm.com>
* RSA: Fix signature verification for shorter signaturesDavid Howells2012-10-081-3/+11
| | | | | | | | | | | | | | | gpg can produce a signature file where length of signature is less than the modulus size because the amount of space an MPI takes up is kept as low as possible by discarding leading zeros. This regularly happens for several modules during the build. Fix it by relaxing check in RSA verification code. Thanks to Tomas Mraz and Miloslav Trmac for help. Signed-off-by: Milan Broz <mbroz@redhat.com> Signed-off-by: David Howells <dhowells@redhat.com> Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
* RSA: Implement signature verification algorithm [PKCS#1 / RFC3447]David Howells2012-10-081-0/+269
Implement RSA public key cryptography [PKCS#1 / RFC3447]. At this time, only the signature verification algorithm is supported. This uses the asymmetric public key subtype to hold its key data. Signed-off-by: David Howells <dhowells@redhat.com> Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>