From 517878d102f7049831ca7a5c249ab496827f814b Mon Sep 17 00:00:00 2001 From: "viktor.tarasov" Date: Mon, 27 Sep 2010 07:50:14 +0000 Subject: [PATCH] myeid: applied patch for MyEID card profile provided by Tony (Aventra development), thanks. git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@4777 c6295689-39f2-0310-b995-f0e70906c6a9 --- src/pkcs15init/myeid.profile | 36 +++++++++++++++++------------------ src/pkcs15init/pkcs15-myeid.c | 2 +- 2 files changed, 19 insertions(+), 19 deletions(-) diff --git a/src/pkcs15init/myeid.profile b/src/pkcs15init/myeid.profile index e65ef7f9..846ae663 100644 --- a/src/pkcs15init/myeid.profile +++ b/src/pkcs15init/myeid.profile @@ -53,8 +53,8 @@ PIN user-pin { PIN user-puk { min-length = 4; max-length = 8; - attempts = 10; - flags = needs-padding; + attempts = 10; + flags = needs-padding; } PIN so-pin { @@ -80,7 +80,7 @@ filesystem { DF MF { path = 3F00; type = DF; - acl = CREATE=$SOPIN,DELETE=NONE; + acl = CREATE=$PIN, DELETE=$SOPIN; # This is the DIR file EF DIR { @@ -92,13 +92,13 @@ filesystem { DF PKCS15-AppDF { type = DF; file-id = 5015; - acl = DELETE=NONE, CREATE=$SOPIN; + acl = DELETE=$PIN, CREATE=$PIN; EF PKCS15-ODF { file-id = 5031; structure = transparent; size = $odf-size; - acl = READ=NONE, UPDATE=$SOPIN, DELETE=$SOPIN; + acl = READ=NONE, UPDATE=$PIN, DELETE=$SOPIN; } EF PKCS15-TokenInfo { @@ -125,67 +125,67 @@ filesystem { file-id = 4402; structure = transparent; size = $prkdf-size; - acl = READ=NONE, UPDATE=$PIN, DELETE=$SOPIN; + acl = *=NEVER, READ=NONE, UPDATE=$PIN, DELETE=$SOPIN; } EF PKCS15-PuKDF { file-id = 4403; structure = transparent; size = $pukdf-size; - acl = READ=NONE, UPDATE=$PIN, DELETE=$SOPIN; + acl = *=NEVER, READ=NONE, UPDATE=$PIN, DELETE=$SOPIN; } EF PKCS15-CDF { file-id = 4404; structure = transparent; size = $cdf-size; - acl = READ=NONE, UPDATE=$PIN, DELETE=$SOPIN; + acl = *=NEVER, READ=NONE, UPDATE=$PIN, DELETE=$SOPIN; } EF PKCS15-DODF { file-id = 4405; structure = transparent; size = $dodf-size; - acl = READ=NONE, UPDATE=$PIN, DELETE=$SOPIN; + acl = *=NEVER, READ=NONE, UPDATE=$PIN, DELETE=$SOPIN; } EF template-private-key { type = internal-ef; file-id = 4B01; - acl = CRYPTO=$PIN, UPDATE=$PIN, DELETE=$SOPIN, GENERATE=$PIN; + acl = CRYPTO=$PIN, UPDATE=$PIN, DELETE=$PIN, GENERATE=$PIN; } EF template-public-key { structure = transparent; file-id = 5501; - acl = READ=NONE, UPDATE=$PIN, DELETE=$SOPIN, GENERATE=$PIN; + acl = READ=NONE, UPDATE=$PIN, DELETE=$PIN, GENERATE=$PIN; } EF template-certificate { file-id = 4301; structure = transparent; - acl = READ=NONE, UPDATE=$PIN, DELETE=$SOPIN; + acl = READ=NONE, UPDATE=$PIN, DELETE=$PIN; } template key-domain { # This is a dummy entry - pkcs15-init insists that # this is present EF private-key { - file-id = 4B00; + file-id = 4B01; type = internal-ef; - acl = READ=NONE, UPDATE=$PIN, DELETE=$SOPIN, GENERATE=$PIN; + acl = READ=NONE, UPDATE=$PIN, DELETE=$PIN, GENERATE=$PIN; } EF public-key { - file-id = 5500; + file-id = 5501; structure = transparent; - acl = READ=NONE, UPDATE=$PIN, DELETE=$SOPIN, GENERATE=$PIN; + acl = READ=NONE, UPDATE=$PIN, DELETE=$PIN, GENERATE=$PIN; } # Certificate template EF certificate { - file-id = 4300; + file-id = 4301; structure = transparent; - acl = READ=NONE, UPDATE=$PIN, DELETE=$SOPIN; + acl = READ=NONE, UPDATE=$PIN, DELETE=$PIN; } } } diff --git a/src/pkcs15init/pkcs15-myeid.c b/src/pkcs15init/pkcs15-myeid.c index b9d199e3..ab20ac1a 100644 --- a/src/pkcs15init/pkcs15-myeid.c +++ b/src/pkcs15init/pkcs15-myeid.c @@ -31,7 +31,7 @@ #include "pkcs15-init.h" #include "profile.h" -#define KEEP_AC_NONE_FOR_INIT_APPLET +#undef KEEP_AC_NONE_FOR_INIT_APPLET #define MYEID_MAX_PINS 14