OpenSC fork, with some Italian healthcare smart card utils
Go to file
Doug Engert d48f438581 PKCS#11 does not define a CKA_VALUE for public keys and is missused
OpenSC opennssl.c in sc_pkcs11_verify_data assumes that it can
retieve the CKA_VALUE for a public key object, and expect it to
be usable as RSA.

But internally sc_pkcs15_pubkey can have a "raw" or "spki"
version of the public key as defined by PKCS#15.  Card drivers
or pkcs15-<card> routines may store either the "raw" or "spki"
versions. A get attribute request for CKA_VALUE for a public key
will return either the raw, spki or will derived rsa verison of the
pubkey.

This commit will test if the CKA_VALUE is a spki and use d2i_PUBKEY
which takes a spki version and returns an EVP_KEY. If it not an spki
the current method, d21_PublicKey(EVP_PKEY_RSA,...) is used which
only works for RSA.

The problem was found while testing pkcs11-tool -t -l  where
the  verify tests would fail with a CKR_GENERAL_ERROR because
the card driver stored the public key as a spki.

On branch verify-pubkey-as-spki-2
 Changes to be committed:
	modified:   src/pkcs11/openssl.c

Date:      Fri Apr 07 07:50:00 2017 -0600
2017-04-26 13:08:49 +02:00
MacOSX Use $(xcrun --sdk macosx --show-sdk-path) to parse SDK_PATH 2017-03-03 09:11:08 +01:00
doc pkcs15-tool: documentated `--clear-cache` 2017-03-28 14:24:13 +02:00
etc reader-pcsc: removed cardmod driver 2017-04-20 10:29:30 +02:00
m4 correctly include pthread flags 2017-03-14 22:44:19 +01:00
packaging/debian.templates fix LGPL version 2013-09-29 20:55:41 +02:00
solaris Thomas Uhle: modify Makefile so configure finds the include files 2009-12-03 07:05:15 +00:00
src PKCS#11 does not define a CKA_VALUE for public keys and is missused 2017-04-26 13:08:49 +02:00
win32 win32 installer: skip license agreement 2017-03-28 14:24:30 +02:00
.gitignore Added (external) card driver for German ID card 2017-03-20 21:28:48 +01:00
.travis.yml Added (external) card driver for German ID card 2017-03-20 21:28:48 +01:00
CONTRIBUTING.md Create CONTRIBUTING.md 2015-02-13 16:52:10 +02:00
COPYING - changed license to LGPL 2001-11-06 18:34:19 +00:00
ISSUE_TEMPLATE.md Added information about debugging 2017-03-27 10:43:49 +02:00
Makefile.am build: bootstrap script has expected content 2014-05-11 09:15:27 +02:00
Makefile.mak fixed and cleaned up nmake Makefiles 2016-06-23 07:35:53 +02:00
NEWS fix NEWS, few debug messages more 2016-05-26 10:59:58 +02:00
README link README to README.md 2015-11-02 23:54:36 +01:00
README.md Use "native" badges 2016-01-22 18:42:10 +02:00
appveyor.yml AppVeyor: use Github as zlib download mirror 2016-10-07 14:17:40 +02:00
bootstrap build: bootstrap script has expected content 2014-05-11 09:15:27 +02:00
bootstrap.ci tools: print package revision 2016-03-04 14:16:06 +01:00
configure.ac macOS: added support for access via CryptoTokenKit 2017-04-03 12:30:03 +02:00
version.m4 package: update RC version 2016-05-16 11:55:36 +02:00

README.md

OpenSC documentation

Wiki is available online

Please take a look at the documentation before trying to use OpenSC.

Travis CI Build Status AppVeyor CI Build Status Coverity Scan Status