[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.c++

PKCS11 and DER

MadDruid

11/11/2008 5:20:00 PM

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...)
but without success.

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

Thanks.

Regards,
Alessandro
3 Answers

Victor Bazarov

11/11/2008 5:30:00 PM

0

MadDruid wrote:
> 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
--
Please remove capital 'A's when replying by e-mail
I do not respond to top-posted replies, please don't ask

MadDruid

11/12/2008 9:01:00 AM

0

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 wrote:
>> 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

Giovanni

11/12/2008 12:11:00 PM

0

On 12 Nov, 10:00, MadDruid <emailfittizio_questotogl...@libero.it>
wrote:
> 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