gemsafeV1: set 'auth-method' for the emulated PIN PKCS#15 object
pkcs15-tool: for public key show the presence of 'direct' value
opensc: new card operation 'read-public-key'

In PukDF of PKCS#15 the public key value can be presented by 'direct value', by path or by path and reference.
For the different cards the public key can be stored in EF, internal EF or in card specific SDO (security data objects).
A new card handle allows to read out the public key from the card specific SDOs.
pkcs15-crypt tool: set HASH_NONE crypto flags when the hash do not asked

without this for the cards that have only RAW mechanism
it's not possible to compute signature with PKCS1 padding and without hash.
build MSI: add openpgp.profile
sc-hsm: Added sc-hsm-tool with DKEK support and key wrap / unwrap
sc-hsm: Added code to prevent CV certificates being listed as X.509 certificates
sc-hsm: Fixed bug decoding CVCs without domain parameter
build sc-hsm-tool: link with OpenSSL libs
libopensc iso7816: retry SELECT with FCI if SELECT without FCI fails

t457 (https://www.opensc-project.org/opensc/ticket/457)
For some cards that currently use the common iso-7816 operations
only SELECT with return of FCI/FCP can be applied.

In iso-7816 'select-file' handle, if 'SELECT without FCI' fails with error code 6A86,
then retry 'SELECT with FCI'. Other error code can be added.

Sorry for the 'coding style' noise.
libopensc: check data returned by 'read-public-key'

fix error message
t447: return value from init() in reader driver not checked
t455: check validity of RSA/DSA public key components

Segmentation fault happened when reading SSH key with the non-initilized public key components.
pkcs11: check arguments in get_bignum_bits() procedure

t451: segmentation fault when getting public key bits number
sc-hsm: Now saving the internal CSR in place of the certificate and decoding the public key at initialization (RSA only)
sc-hsm: Fixed bug with memory released to early
sc-hsm: Improved checking in sc-hsm-tool
tools: check return value after each call.

It seems that this suffered some copy and paste damage at some point.
Change so that we check each return value immediately after the API
call.

Signed-Off-By: Anthony Foiani <anthony.foiani@gmail.com>
pcks11: trivial: fix debug output for CKA_PRIME_1 and CKA_PRIME_2

Without this patch, debugging output issues these as unknown
attributes:

  ... C_CreateObject(): CKA_PRIVATE_EXPONENT = 97F798...
  ... C_CreateObject(): Attribute 0x124 = EFE5AD...
  ... C_CreateObject(): Attribute 0x125 = D4D3F6...
  ... C_CreateObject(): CKA_EXPONENT_1 = 5815FD...

With this patch, we see:

  ... C_CreateObject(): CKA_PRIVATE_EXPONENT = 97F798...
  ... C_CreateObject(): CKA_PRIME_1 = EFE5AD...
  ... C_CreateObject(): CKA_PRIME_2 = D4D3F6...
  ... C_CreateObject(): CKA_EXPONENT_1 = 5815FD...

Signed-Off-By: Anthony Foiani <anthony.foiani@gmail.com>
card-gemsafeV1: Add a GemSafe V1 ATR

Thanks to Lukas Wunner for the patch