Hello Douglas,

for problem you tried to solve with r4901 there is a more general
solution. That solution would involve the mapping of the ASN1 type
ObjectValue to the corresponding C-structures.

In the case related to r4901, the hook would be
sc_pkcs15_pubkey_info_t->path. The underlying ASN1 type of that variable
is ObjectValue. Which is defined by PKCS#15 as a CHOICE between PATH,
RAW and SubjectPublicKeyInfo. Only the PATH choice is supported yet.

In the long term that should be completed and 'path' should be replaced
by 'value' with a type capable to hold one of PATH, RAW or
SubjectPublicKeyInfo.

I could implement that. But not before 0.12 is out. Because it requires
some changes on asn1-decoders. In the mean time it's better to place the
variable 'emulated' on sc_pkcs15_pubkey_info_t. Then the function
sc_pkcs15_read_pubkey could be modified to handle the two cases (path or
emulated) transparently.

Regards
Andre

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

Reply via email to