Commit Graph

7635 Commits

Author SHA1 Message Date
Frank Morgner ba19a467e4
Rutoken Lite (#1728)
* card-rtecp: Add Rutoken Lite

* avoid seperate rutoken lite driver

* added rutoken lite to minidriver

closes #1722
2019-07-22 13:05:32 +02:00
programatix 130e9bb068 Update strings.c 2019-07-04 10:12:23 +02:00
programatix 6b97071bb3 Update strings.c
The check condition is obviously wrong. It should check for EQUAL. The original bitwise check caused any other language to turn into DE because as long as a bit is filtered, it will hit.
2019-07-04 10:12:23 +02:00
Dmitriy Fortinskiy 3c1624676d card-rtecp,card-rutoken: Set specific card types 2019-07-02 12:13:57 +02:00
Dmitriy Fortinskiy 60a2cf16c7 card-rtecp: Fix list_files on T0 cards
Rutoken ECP SC over T0 expects Get Response after SW1=61 which
is not called with zero le.
2019-07-02 12:13:57 +02:00
Frank Morgner 7fb72ccf7b pkcs11: fixed slotIDs when a new slot list is requested
fixes https://github.com/OpenSC/OpenSC/issues/1706

regression of 24b7507a69
2019-06-30 10:24:11 +02:00
Andreas Schwier e7a8c00566 sc-hsm: Use CHR in CSR based on device serial number 2019-06-21 15:08:14 +02:00
Peter Marschall 229dd32e3a opensc-explorer: fix APDU command
Do not ignore first parameter.
2019-06-21 14:34:38 +02:00
Timo Teräs 19711d0a13 myeid: fix EC key upload, and avoid data copying
Fixes regression from commit 3688dfe which did not consider that
the zero prefixing tests were too generic and matched EC keys too.

This simplifies the code even further and avoids data copying
when possible. Proper test is now included to do data value prefixing
only for the RSA keys it is needed.

Closes #1701.
2019-06-17 15:19:08 +02:00
Jakub Jelen 8c12835c9e Update the build status also in the readme 2019-06-17 12:49:11 +02:00
Jakub Jelen 368563ddd6 doc: Fix the description of switch in manual page (copy&paste error) 2019-06-17 12:49:11 +02:00
Jakub Jelen 1c0d26d0f0 .travis.yml Include the MyEID emulation using OsEID simulator in separate target
This also avoids running the make check in the simulation runs, which generates
a lot of output (from clang-tidy)
2019-06-17 12:49:11 +02:00
Jakub Jelen 9197dfe5ae myeid: Detect also OsEID card in the MyEID driver and difference them with separate types 2019-06-17 12:49:11 +02:00
Jakub Jelen 07c0a47b37 card-openpgp: Fix typo in the EC Key size 2019-06-17 12:49:11 +02:00
Jakub Jelen b65275d6f8 p11test: Improve error reporting on unknown EC groups 2019-06-17 12:49:11 +02:00
Jakub Jelen 87770df65b p11test: Implement simple derive tests 2019-06-17 12:49:11 +02:00
Jakub Jelen 852f057ce3 p11test: Add MD5 mechanisms pretty-print 2019-06-17 12:49:11 +02:00
Jakub Jelen 86fd200462 sc-hsm: Check the operation first 2019-06-17 12:49:11 +02:00
Jakub Jelen df0bbc110e pkcs11-spy: Dump EC Derive parameters 2019-06-17 12:49:11 +02:00
Jakub Jelen 10abef9206 pkcs15-sec: Drop unused code (copied from RSA decipher) 2019-06-17 12:49:11 +02:00
Jakub Jelen 272e380898 Set correctly flags for ECDH derive operations 2019-06-17 12:49:11 +02:00
Jakub Jelen 6d751e8b22 opensc.h: Add missing raw ecdh algorithm 2019-06-17 12:49:11 +02:00
Jakub Jelen 293760c0d0 Fix derive operation detection in MyEID and sc-hsm drivers 2019-06-17 12:49:11 +02:00
Andreas Schwier 58fa53ac91 sc-hsm: Add missing secp384r1 curve parameter 2019-06-14 14:29:58 +02:00
Frank Morgner 94388f9538 fixed more clang-tidy warnings 2019-06-05 13:48:51 +02:00
Nuno Goncalves 0322401aae gemsafeV1: remove redundant match card call to allow for opensc.conf match
At the point when gemsafe_match_card is called, the card type is already known,
either because of a previous match at card.c, or because it is forced at opensc.conf.

With this redundant match it's not possible to force selection on opensc.conf.

Signed-off-by: Nuno Goncalves <nunojpg@gmail.com>
2019-06-05 13:43:52 +02:00
Raul Metsma 3a192e2c87 pkcs11-tool: Add extractable option to key import
Signed-off-by: Raul Metsma <raul@metsma.ee>
2019-06-03 10:59:58 +02:00
Doug Engert a2dd500624 Fix pkcs11-tool encryption error Fix #1694
Make sure data being encrypted is less then the modulus.

 On branch pkcs11-tool-encryption
 Changes to be committed:
	modified:   ../tools/pkcs11-tool.c
2019-05-31 14:16:24 +02:00
Frank Morgner 278960bf88 AppVeyor: push build artifact in PRs as well 2019-05-31 14:15:37 +02:00
Frank Morgner 3a665f6479 allow single character strings with sc_hex_to_bin
fixes https://github.com/OpenSC/OpenSC/issues/1684
fixes https://github.com/OpenSC/OpenSC/issues/1669
2019-05-31 14:15:37 +02:00
Nuno Goncalves e3ff3be4fe pteid: add new ATRs
One ATR have been confirmed on my personal card and also added to the official middleware:

https://svn.gov.pt/projects/ccidadao/changeset/321/middleware-offline/trunk/_src/eidmw/minidriver/makemsi/pteidmdrv.inf

There is another ATR I am adding blind from the official middleware:

https://svn.gov.pt/projects/ccidadao/changeset/321/middleware-offline/trunk/_src/eidmw/minidriver/makemsi/pteidmdrv.inf

Signed-off-by: Nuno Goncalves <nunojpg@gmail.com>
2019-05-31 14:12:12 +02:00
Andreas Schwier be294d01be sc-hsm: Add configuration section for 4K 2019-05-31 14:11:49 +02:00
Andreas Schwier f2a6209c94 Add SmartCard-HSM 4K ATR (#1681) 2019-05-31 14:11:49 +02:00
Ludovic Rousseau 7afa74e049
Merge pull request #1693 from LudovicRousseau/fix
Add missing ulIvBits field to CK_GCM_PARAMS
2019-05-31 14:00:52 +02:00
Ludovic Rousseau cc189585c8 pkcs11-spy: display CK_GCM_PARAMS.ulIvBits field 2019-05-29 15:17:15 +02:00
Ludovic Rousseau 0fbd2663e6 Add missing ulIvBits to CK_GCM_PARAMS
The PKCS#11 specification text does not document the ulIvBits field.
But the header file defining CK_GCM_PARAMS uses it.
Since the header file is the normative version we need to add it.

See also https://github.com/Pkcs11Interop/Pkcs11Interop/issues/126o
and https://lists.oasis-open.org/archives/pkcs11-comment/201602/msg00001.html
and https://www.oasis-open.org/committees/document.php?document_id=58032&wg_abbrev=pkcs11
2019-05-29 15:17:15 +02:00
Frank Morgner 65a86b8331 travis: fixed PATH on macOS 2019-05-21 19:36:17 +02:00
Frank Morgner b7b501d0a5 fixed issues reported by clang-analyzer 2019-05-21 19:34:46 +02:00
Frank Morgner 3c83a80b57 fixed printing non primitive tag
fixes undefined bitshift
2019-05-21 19:34:46 +02:00
Frank Morgner 1423c6bb90 CI: integrate clang-tidy (disabled)
files that have warnings are currently excluded
2019-05-21 19:34:46 +02:00
Raul Metsma 1e59643caa Remove process_arr unused file argument and fix clang-tidy warnings
Signed-off-by: Raul Metsma <raul@metsma.ee>
2019-05-21 19:34:46 +02:00
Jakub Jelen e501c5ae81 Unbreak build without OpenSSL 2019-05-21 18:44:06 +02:00
Frank Morgner 65d607af66 fixed 325860 Dereference before null check 2019-05-14 14:50:17 +02:00
Frank Morgner 630bcbedd4 fixed 337490 Unchecked return value 2019-05-14 14:50:17 +02:00
Frank Morgner e275b34269 fixed 339157 Unused value 2019-05-14 14:50:17 +02:00
Martin Paljak a5f63fed0c
Merge pull request #1635 from OpenSC/esteid-2018
EstEID 2018+ driver
2019-05-02 12:54:21 +03:00
Martin Paljak 2829c5870f Address review comments
Change-Id: I9aa97c8a9878dddd3e6f1a2baa877d188b9d7fe5
2019-05-02 11:51:02 +03:00
Martin Paljak 5f5d40521e Avoid 6282 reply for a successful operation
Change-Id: I5d4d3103692fc6db51f13fc5338360289c26af9a
2019-05-02 11:51:02 +03:00
Martin Paljak fc8e9bf3f3 Address review comments and further reduce LOC
and make sure the card is always handled emulated card first

Change-Id: I60174c2793bb882fb73716f62a652d84e028382c
2019-05-02 11:51:02 +03:00
Martin Paljak b3d4a0d69a EstEID 2018+ driver
This adds support for a minimalistic, small and fast card profile based on IAS-ECC.

Based on information from https://installer.id.ee/media/id2019/TD-ID1-Chip-App.pdf
and proprietary driver snoops.

Thanks to @metsma and @frankmorgner.

Change-Id: I2e4b4914d8a3b991d9a639728695abf4a2362ca0
2019-05-02 11:47:31 +03:00