Commit Graph

5558 Commits

Author SHA1 Message Date
Nguyễn Hồng Quân
7f08983240 Merge branch 'master' into gnuk
Conflicts:
	src/tools/openpgp-tool.c
2014-12-09 02:40:33 +08:00
Frank Morgner
ec2eb86bec don't reimplement output of status words
Closes #326
2014-12-07 23:54:32 +01:00
Etienne Cordonnier
9cbec38cfa Fix bug in verbose flag handling.
Using the verbose flag was causing cardos-tool to return as if an error
had occured.
2014-12-07 23:54:09 +01:00
germanblanco
1408e25e4b Removal of cache, fixing a compiler warning and removing recursive functions. 2014-12-07 23:34:15 +01:00
Frank Morgner
fce847bf25 Merge pull request #318 from sschutte/master
Added ATR for ItalianCNS - Prov. BZ
2014-12-06 23:32:31 +01:00
Frank Morgner
a2ba4d3bae Merge pull request #319 from CardContact/add-sec-k-curves
sc-hsm: Add support for Koblitz curves secp192k1 and secp256k1 (Bitcoin)
2014-12-06 23:22:43 +01:00
Frank Morgner
b18c86e646 Merge pull request #320 from frankmorgner/tools-pin
Optimize util_get_pin from #289
2014-12-06 23:21:39 +01:00
Frank Morgner
8188b8acac Merge pull request #322 from frankmorgner/iso-ext
adjust send/receive size accoriding to card capabilities
2014-12-06 23:16:21 +01:00
Doug Engert
cd01a73caf C_Digest does not check if buffer too small before update. Issue #327
C_Digest will now query for the buffer size using sc_pkcs15_md_final
before calling sc_pkcs15_md_update. This avoids doing a double update
when the user passes in a buffer to small, then gets the buffer and calls
C_Digest again.
2014-12-02 11:15:24 +01:00
Frank Morgner
8aadbbd678 Merge pull request #332 from Ecordonnier-theobroma/westcos-tool
Translate French to English.
2014-11-26 20:16:37 +01:00
Etienne Cordonnier
0c0b2145ac Translate French to English. 2014-11-26 19:00:38 +01:00
Frank Morgner
3f442c5608 adjust send/receive size accoriding to card capabilities 2014-11-17 21:16:13 +01:00
Nguyễn Hồng Quân
4ab317ad2f Merge pull request #3 from Nitrokey/gnuk
hardcode->defines for DO's
2014-11-12 01:33:58 +08:00
george
8d21cea7fc hardcode->defines for DO's 2014-11-11 16:16:15 +01:00
Nguyễn Hồng Quân
901c7952c1 Replace hardcode. 2014-11-09 15:58:40 +07:00
Martin Paljak
67fcda1636 Merge pull request #308 from martinpaljak/yosemite
Building on newer OSX versions without xcode command line tools
2014-11-08 18:30:40 +02:00
Doug Engert
57cd22e586 Merge pull request #324 from dengert/piv-gzip-cert
Use correct bit when writing PIV certificate object with gzipped certifi...
2014-11-07 20:01:52 -06:00
Doug Engert
4dbfba3102 Use correct bit when writing PIV certificate object with gzipped certificate
NIST 800-73 clarified the CertInfo flag for gzipped certificate is 0x01
piv-tool was writting 0x80.
OpenSC card-piv.c continues to accept both.
2014-11-07 19:49:36 -06:00
Frank Morgner
d00d7b3498 Merge pull request #276 from asmw/fix_return
openpgp-tool: Return EXIT_SUCCESS if no error occurs
2014-11-05 10:57:26 +01:00
Frank Morgner
ea55c19439 Merge pull request #195 from rainermetsvahi/master
Add AzeDIT 3.5 card support
2014-11-05 10:56:01 +01:00
Frank Morgner
cb7f40a40d Merge pull request #260 from frankmorgner/iso-ext
iso7816: allow extended length APDUs
2014-11-05 10:40:11 +01:00
Frank Morgner
ef94c6b875 Merge pull request #311 from frankmorgner/const-data
changed sc_apdu_t.data back to const unsigned char *
2014-11-05 10:39:05 +01:00
Frank Morgner
8672291a73 Merge pull request #312 from frankmorgner/fix-p15
fixed type of pkcs15init_initialize
2014-11-05 10:38:42 +01:00
Frank Morgner
aa45685e0b fixed documentation of dnie-tool 2014-11-04 22:23:01 +01:00
Frank Morgner
4459e146c4 use util_get_pin in tools 2014-11-04 22:07:07 +01:00
Sumedha Widyadharma
e63f40c2d3 tools: Add util_get_pin helper function
Using this helper PINs can be passed via the command line, stdin and an
environment variable.

For now only used in the openpgp tool.

closes #289
2014-11-04 21:54:41 +01:00
Andreas Schwier
d014056f1d sc-hsm: Add support for Koblitz curves secp192k1 and secp256k1 (Bitcoin) 2014-11-04 17:11:34 +01:00
Doug Engert
7a5f9b2a16 Merge pull request #315 from dengert/privateObjects
Public certs and pubkeys with an auth_id are treated as private (See #291)
2014-11-04 07:28:37 -06:00
Shaun Schutte
ccd87e7c0c Added ATR for ItalianCNS - Prov. BZ 2014-11-04 09:01:36 +01:00
Martin Paljak
0154ee07e0 Merge pull request #317 from CardContact/fix-Lc-in-PINblock
sc-hsm: Fix Lc byte in VERIFY PIN block for PC/SC PIN PAD reader
2014-11-03 19:22:01 +02:00
Andreas Schwier
b2dcae34ca Fix Lc byte in VERIFY PIN block for PC/SC PIN PAD reader 2014-11-03 16:11:29 +01:00
Doug Engert
fd22098e19 Public certs and pubkeys with an auth_id are treated as private (See #291)
Code to test for an auth_id for certs and pubkeys was removed.
See: PKCS#15 section 4.1.3 Access methods

This is conseritive change and all objects could be treaded the same.
2014-11-01 14:02:39 -05:00
Frank Morgner
d3c8fbcf1d fixed type of pkcs15init_initialize
regression from 95b6b4cc
2014-10-27 23:22:40 +01:00
Frank Morgner
3d9118a870 changed sc_apdu_t.data back to const unsigned char * 2014-10-27 22:48:34 +01:00
Martin Paljak
5448901160 macosx: update the minimal building instructions. 2014-10-26 11:48:57 +02:00
Martin Paljak
82624a98b7 macosx: locate and target the latest SDK to build against. 2014-10-25 20:07:36 +03:00
Martin Paljak
1145bed320 macosx: locate the best newest SDK present on the computer.
With recent versions of XCode, PC/SC headers are hidden inside
the SDK folder inside XCode app, and the global path is not
guaranteed to be present. This allows to build easily from source
without depending on a specific XCode/OSX version.
2014-10-25 20:01:38 +03:00
Frank Morgner
8ed4db76c8 Merge pull request #238 from eighthave/master
generate bash completion scripts from XML doc files
2014-10-22 16:15:29 +02:00
Doug Engert
73a150352b Merge pull request #298 from dengert/pkcs11Hashes
PKCS#11 hashes for cards without RAW (see #241)
2014-10-16 08:48:32 -05:00
Doug Engert
0dfb45b420 Merge pull request #279 from dengert/master
pkcs11-tool sets CKA_DECRYPT=true rather then CKA_DERIVE=true when gener...
2014-10-13 21:51:41 -05:00
Doug Engert
189e998486 PKCS#11 hashes for cards without RAW (see #241)
The framework-pkcs15.c did not add hashes correctly if the card did not support RSA RAW.
    This change fixes that and only adds hashes if the card did not specify a list of hashes.
    It also will not add hashes done in software if ENABLE_OPENSSL is not specified.
    Some error conditions are also tested for EC mechanisms.

    See bug report #241 for more information.
2014-10-13 10:29:27 -05:00
Doug Engert
9a82a95132 Merge branch 'master' of github.com:OpenSC/OpenSC 2014-10-03 06:50:04 -05:00
Hans-Christoph Steiner
d72324ddf5 generate bash completion scripts from XML doc files
This generates the scripts that lets bash do completion per specific tool.
It gets the options from the documentation XML files that are also the
source for the man pages and HTML.
2014-10-01 20:53:30 -04:00
Ludovic Rousseau
34587eac9c Fix compiler warning
p15card-helper.c:23:5: warning: 'ENABLE_OPENSSL' is not defined, evaluates to 0
      [-Wundef]
    ^
2014-10-01 22:11:38 +02:00
Ludovic Rousseau
09c2847b7e Fix compiler warning
pkcs15-dnie.c:242:13: warning: function declaration isn't a prototype [-Wstrict-prototypes]
 const char *sc_driver_version()
             ^
2014-10-01 22:11:38 +02:00
Ludovic Rousseau
fb7bbf1e80 build: disable Secure Messaging if OpenSSL is not used
If OpenSSL is not present or --disable-openssl then Secure Messaging is
disabled.

The problem was that some Secure Messaging code is missing if OpenSSL is
absent. The build/link failed with some missing symbols.

Fix issue #293
2014-10-01 22:11:38 +02:00
Ludovic Rousseau
c8545baf90 pkcs15-dnie: fix compilation when OpenSSL is not used
If OpenSSL is not used then the functions from card-dnie.c are not
defined and in particular dnie_match_card() is not defined.
In that case we use a fake dnie_match_card() that just returns false.
2014-10-01 22:11:38 +02:00
Philip Wendland
955a339148 Merge PR#288 from philipWendland:upstream-ecc-fix
add the possibility to store public ECC keys encoded according to SPKI
EC pubkey storing: Check if params are available before copying.
pkcs15-lib.c / sc_pkcs15init_store_public_key may be called with keyargs->key.u.ec.params.value == NULL. In this case, allocating and copying the parameters will fail. Add a check to prevent this.
2014-10-01 15:27:26 +02:00
Dirk-Willem van Gulik
4e73d0e36f Merge PR#280 from dirkx/master: --no-prompt flag
Add a --no-prompt flag to pkcs15-tool (i.e. the equivalent of the --no-prompt flag of pkcs15-init). As to aid readers with keypads (as commonly used in the medical space).
2014-10-01 14:36:52 +02:00
Ludovic Rousseau
ea712bfd56 Fix compiler warning
The same function iasecc_sm_external_authentication() was declared in
two different .h files.

In file included from ../../src/libopensc/iasecc.h:27:0,
                 from sm-card-iasecc.c:44:
../../src/libopensc/iasecc-sdo.h:324:5: warning: redundant redeclaration of `iasecc_sm_external_authentication' [-Wredundant-decls]
In file included from ../../src/libopensc/opensc.h:44:0,
                 from sm-card-iasecc.c:40:
../../src/libopensc/sm.h:352:5: note: previous declaration of `iasecc_sm_external_authentication' was here
2014-09-29 16:08:33 +02:00