Le 11/04/2011 15:25, Martin Paljak a écrit :
> Hello,
>
> On Mon, Apr 11, 2011 at 16:07,<webmas...@opensc-project.org>  wrote:
>> Revision: 5326
>> Author:   vtarasov
>> +++ trunk/src/tools/pkcs15-tool.c       2011-04-11 13:07:34 UTC (rev 5326)
>> +       const char *types[] = { "", "RSA", "DSA", "GOSTR3410", "EC", "", "", 
>> "" };
>> +       printf("Private %s Key [%s]\n", types[7&  obj->type], obj->label);
> This looks kind of non-obvious, why the magic 7 and why empty type names?

It's an extension of the previously existing logic.

Type SC_PKCS15_TYPE_PRKEY_EC (0x104) is not covered by (3 & type),
so it's changed to (7 & type).

> Martin
> _______________________________________________
> opensc-devel mailing list
> opensc-devel@lists.opensc-project.org
> http://www.opensc-project.org/mailman/listinfo/opensc-devel


-- 
Viktor Tarasov  <viktor.tara...@opentrust.com>

_______________________________________________
opensc-devel mailing list
opensc-devel@lists.opensc-project.org
http://www.opensc-project.org/mailman/listinfo/opensc-devel

Reply via email to