PKCS11 and DER

M

MadDruid

Hi all,

I'm using a pkcs11 library to get some information from a smartcard.

In particular, the C_GetAttributeValue function returns the certificate
serial number in DER format:

CKA_SERIAL_NUMBER
Byte array
DER-encoding of the certificate serial number

I'm trying to convert it to a string using libtasn1 library
(http://www.gnu.org/software/gnutls/manual/libtasn1/libtasn1.html#DER-functions)
but without success.

Does anyone knows that library and give me an hint about this topic? Or
suggest me an alternative?

Thanks.

Regards,
Alessandro
 
M

MadDruid

Hi Victor,
the problem is not with the pkcs11 library but with the DER->string
conversion in libtasn1 library, that is not OS-specific as stated in the
documentation:

"libtasn1 is portable. It should work on all Unix like operating
systems, including Windows. The library itself should be portable to any
C89 system, not even POSIX is required. "

I already googled about this topic but I didn't found nothing useful.

Alessandro.


Victor Bazarov ha scritto:
MadDruid said:
I'm using a pkcs11 library [..] but without success.

Does anyone knows that library and give me an hint about this topic?
Or suggest me an alternative?

GIYF. Also, consider that hardware interaction is OS-specific, so you
will likely find more relevant response in the newsgroup for your OS.

V
 
G

Giovanni

Hi Victor,
the problem is not with the pkcs11 library but with the DER->string
conversion in libtasn1 library, that is not OS-specific as stated in the
documentation:

"libtasn1 is portable. It should work on all Unix like operating
systems, including Windows. The library itself should be portable to any
C89 system, not even POSIX is required. "

I already googled about this topic but I didn't found nothing useful.

Alessandro.

Victor Bazarov ha scritto:


MadDruidwrote:
I'm using a pkcs11 library [..] but without success.
Does anyone knows that library and give me an hint about this topic?
Or suggest me an alternative?
GIYF.  Also, consider that hardware interaction is OS-specific, so you
will likely find more relevant response in the newsgroup for your OS.
V- Nascondi testo citato

- Mostra testo citato -

Ciao, ho problemi anche io con pkcs#11, volevo migrare da java a c+
+ ..
Tu hai esperienza in questo ambito??
Ti prego di contattarmi per mail cosi' vediamo di scambiarci alcuni
pareri.
Grazie
Giovanni
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,743
Messages
2,569,478
Members
44,899
Latest member
RodneyMcAu

Latest Threads

Top