vtarasov
5e50a14b3f
libopensc: introduce 'key-params' data type that contains pointer, size and 'free' handler ...
...
http://www.opensc-project.org/pipermail/opensc-devel/2011-April/016441.html
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5413 c6295689-39f2-0310-b995-f0e70906c6a9
2011-05-01 19:18:14 +00:00
vtarasov
08c9328e62
piv-tool: remove the Oberthur's specific features of the PIV card
...
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5412 c6295689-39f2-0310-b995-f0e70906c6a9
2011-05-01 18:44:53 +00:00
vtarasov
c70e0ae982
iasecc: use atr mask to accept the Gemalto's IAS/ECC card without MF
...
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5411 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-30 17:51:43 +00:00
martin
3637d60242
manpages: unify the look and feel of "See also" sections, removing references to missing manual pages.
...
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5410 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-29 12:15:54 +00:00
martin
23bbe9e203
PreReleases: update NEWS file for 0.12.1-rc1
...
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5409 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-29 09:47:06 +00:00
martin
e477d66d07
NightlyBuilds: prepare for OpenSC 0.12.1-rc1 PreReleases
...
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5408 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-29 09:02:09 +00:00
vtarasov
e93dd598c2
doc: describe the 'verify-pin' option in pkcs15-tool documentation ...
...
Thanks to Juan Antonio.
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5407 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-27 15:01:38 +00:00
vtarasov
49fb08f923
pkcs15init: use macro for the maximal number of linked ACL for one operation ...
...
Thanks to NdK.
http://www.opensc-project.org/pipermail/opensc-devel/2011-April/016448.html
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5406 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-27 14:45:23 +00:00
vtarasov
8098e82b16
libopensc: in 'READ BINARY' ignore the 'FILE_END_REACHED' error ...
...
see discussion
http://www.opensc-project.org/pipermail/opensc-devel/2011-April/016413.html
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5405 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-27 14:37:57 +00:00
vtarasov
5471aea023
libopensc: new error code macros -- 'corrupted data' and 'file end reached'
...
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5404 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-27 14:28:03 +00:00
vtarasov
670942a0b4
iasecc: when preparing data to update PRIVATE KEY SDO use index to enumerate the SDO components
...
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5403 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-27 14:12:40 +00:00
vtarasov
ad478eb9cc
iasecc: write 'compulsorily use' data for the new key slot ...
...
Once written the 'compulsorily use' data cannot be changed.
Write this data immediately after a new key slot has been created.
It helps to avoid further confusion between 'use new key slot' and 'reuse existing slot'.
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5402 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-27 14:06:58 +00:00
vtarasov
6c3b43f636
iasecc: when signing short data sequence with PSO_DST ...
...
... 'last-hash-step' APDU do not includes the 'pre-hash' and 'counter' data -- only the 'last-data-block'.
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5401 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-27 13:56:31 +00:00
vtarasov
06347f3a44
iasecc pkcs15init: when creating key slot, there is no needs to write zero value components
...
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5400 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-27 13:45:27 +00:00
vtarasov
81e1676122
iasecc pkcs15init: create/delete SDO private/public RSA key
...
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5399 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-26 17:32:34 +00:00
vtarasov
c9bf9bc22c
iasecc: 'DELETE SDO' card ctl ...
...
to be used by Obertbur's IAS/ECC card.
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5398 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-26 17:29:08 +00:00
vtarasov
346490b953
iasecc: 'CREATE SDO' card ctl ...
...
; static function dedicated to emulate FCP data of application DF when it's not returned by card
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5397 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-26 16:42:48 +00:00
vtarasov
3b9f5b94ae
iasecc: encode data for the SDO creation, ...
...
; dedicated function to parse ACLs from DOCP data;
; when converting ACL chack and parse ACLs;
; change prototype of the internal static functions.
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5396 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-26 16:34:44 +00:00
vtarasov
5e6d310491
iasecc: pkcs15init profiles: add 'CREATE' acl for the Oberthur's application DF ...
...
Obertbur's card do not returns FCP for selected application DF.
Newly introduced option will supply the missing ACL when creating new objects or files.
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5395 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-26 16:27:42 +00:00
martin
1cdb3fa971
APDU parsing: switch to Frank Morgner's implementation
...
Patch by Frank Morgner, proposed in
http://www.opensc-project.org/pipermail/opensc-devel/2011-April/016419.html and
http://www.opensc-project.org/pipermail/opensc-devel/2011-April/016420.html :
* replace partly incorrect extended APU parsing implementation
with one factored-out in function sc_bytes2apdu() in apdu.c
* re-factor APDU parsing functions in
- opensc-explorer
- opensc-tool
- piv-tool
to make use of sc_bytes2apdu()
Thanks to Peter Marschall and Frank Morgner
This fixes #260 and #351 .
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5394 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-26 07:29:53 +00:00
alonbl
7d5ba618e0
maintainer-clean cleanup, thanks to JONSITO
...
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5393 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-25 09:45:25 +00:00
vtarasov
27cd40629e
iasecc: Oberthur's card strictly follows specification in 'IO buffer size' ...
...
Most of the card producers interpret 'send' values in 'IO buffer size' data as "maximum APDU data size" .
The last Oberthur's card strictly follows specification and interpret these values as "maximum APDU command size".
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5392 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-24 17:57:49 +00:00
vtarasov
a14bbe7e32
opensc-explorer: DF_NAME type path value should not be appended by the file ID ...
...
When composing path to file (for ex. to be read), if the type of parent DF is DF_NAME,
the value of the parent path is moved to the aid path member and
file ID takes place of the path value.
; 'cd ..' command takes into account the parent can be presented by DF_NAME
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5391 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-23 06:32:53 +00:00
vtarasov
54f3e8c423
pkcs15init: little correction of r5386
...
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5390 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-22 14:02:45 +00:00
vtarasov
6b04ab7650
pkcs15init: in 'change-attribute' procedure use card specific 'update DF' handler ...
...
... when it's available.
'Change-attribute' is used by pkcs15 framework for PKCS#11.
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5389 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-22 14:00:47 +00:00
vtarasov
4fa9679463
pkcs15init: use dedicated function to fix the EC parameters ...
...
; use pointQ data to calculate intrinsic ID for the EC keys/certs
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5388 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-22 13:50:01 +00:00
vtarasov
9376b73d14
EC support: new exported function to fill up the EC parameters data ...
...
for ex. with the given named curve fills the 'OID' and 'encoded OID' members
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5387 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-22 13:35:57 +00:00
vtarasov
78d90c4765
EC support: introduce data type dedicated to EC parameters ...
...
EC parameters can be presented in a three forms: namedCurve, OID and implicit data.
This new data type will facilitate manipulation of ec-parameters in the OpenSC tools and library.
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5386 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-22 13:08:45 +00:00
vtarasov
3e9b88d6d6
pkcs15init iasecc: old syntax in the profile of the Oberthur's generic application
...
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5385 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-21 17:20:39 +00:00
vtarasov
7db9532f00
pkcs11 framework-pkcs15: add EC key generation mechanism
...
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5384 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-21 16:29:13 +00:00
vtarasov
e430fe9d87
pkcs11-tool: add test procedure for EC keys ...
...
... for a while it includes key generation and data signing.
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5383 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-21 16:18:23 +00:00
vtarasov
9758bb28bf
pkcs11: copy&past issue in r5356
...
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5382 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-21 16:14:36 +00:00
vtarasov
c2a87ae2b1
pkcs11-tool: prepare 'gen_keypair' procedure to generate also the EC keys ...
...
... 'prime256v1' and 'secp384r1'
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5381 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-21 14:29:51 +00:00
vtarasov
38103c64cf
pkcs15: new function to encode an OID in DER format
...
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5380 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-21 14:12:03 +00:00
vtarasov
669a10572a
asn1: now sc_der_copy() returns int value
...
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5379 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-21 13:46:28 +00:00
martin
df7d560c35
WindowsInstaller: Use OpenSC version information in Windows file version resource.
...
* Fix license information in file info (GPL->LGPL)
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5378 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-20 14:53:07 +00:00
martin
9b4f1369c4
MacInstaller: fix 10.5 build script, broken with previous change.
...
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5377 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-20 13:41:04 +00:00
martin
a7934b307e
MacInstaller: use autoconf to write the correct version to ReadMe files of installers.
...
* Better version tagging of generated files
* Bundle files necessary for OS X installer generation to the distribution targzip
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5376 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-20 12:14:44 +00:00
andre
094eb8697c
opensc-tool.c: Fixes literal names in 'const id2str_t alg_type_names[]'.
...
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5375 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-19 13:45:30 +00:00
andre
9026ea6f3f
pkcs11-tool.c: Avoid warning:
...
pkcs11-tool.c:1978: warning: ‘getPUBLIC_EXPONENT’ defined but not used
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5374 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-19 13:03:49 +00:00
andre
ff7bb8fbf4
profile.c: Avoid warning:
...
profile.c:1212: warning: comparison between signed and unsigned
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5373 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-19 12:59:23 +00:00
andre
fa8fd1602d
types.h: Avoid warning:
...
opensc-tool.c:356: warning: comparison between signed and unsigned
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5372 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-19 12:34:16 +00:00
martin
f8665b4405
manpages: add a rudimentary manual page for eidenv command. Fixes #339
...
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5371 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-19 11:19:47 +00:00
martin
8f0ba374f3
Add reminders to bytes2apdu style code blocks.
...
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5370 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-19 10:51:27 +00:00
martin
1932ce861f
opensc-{explorer,tool}: allow sending extended APDUs
...
In do_apdu() resp send_apdu/(, flexibilize parsing the APDU string passed
so that extended APDUs are accepted a valid APDUs too.
While at it, fix a bug where more data than available would have been copied,
potentially leading to a SIGSEGV.
Signed-off-by: Peter Marschall <peter@adpm.de>
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5369 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-19 10:51:22 +00:00
martin
9dc233163a
opensc-tool: convert print_file() to using tables
...
Use ID<->name tables in print_file() innstead of arrays of strings where
the index was treated like some "magic" constant. With the new mapping tables,
the meaning is obvious.
While on it, fix a bug with ac_ops_df[]: before the conversion, it was a list
of pointers to strings but was in one case treated like it was a mapping table.
With the conversion to a mapping table, and the adaption of other code parts
this bug got fixed "automagically" ;-)
Signed-off-by: Peter Marschall <peter@adpm.de>
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5368 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-19 10:51:16 +00:00
martin
be5456d3ca
opensc-tool: make list_algorithms() table driven
...
Use easily extensible tables instead of explicit coding to display
algorithm names and options in list_algorithms.
Leverage the new tables to add more RSA hashes.
Signed-off-by: Peter Marschall <peter@adpm.de>
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5367 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-19 10:51:11 +00:00
martin
e5a133d00c
Fix a crash on Windows, where pkcs15-tool -E would always crash in sc_pkcs15_free_card()
...
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5366 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-19 10:51:06 +00:00
martin
4f768fcdc5
WindowsInstaller: Fix warning CNDL1069 about deprecated attribute
...
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5365 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-19 10:51:01 +00:00
martin
404d84ae48
WindowsInstaller: Fix Wix warning:
...
Z:\opensc\win32\OpenSC.wxs(22) : warning CNDL1121 : Package/@InstallerVersion must be 200 or greater for a 64-bit package.
The value will be changed to 200. Please specify a value of 200 or greater in order to eliminate this warning.
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5364 c6295689-39f2-0310-b995-f0e70906c6a9
2011-04-19 10:50:52 +00:00