Re: Question about IMPLICIT Tagging .

2004-09-29 Thread Frank Balluffi
Abdou, I will try to answer at least some of your questions ... If the sixth most significant bit of the identifier octet is 1, the encoding is constructed. Otherwise, the encoding is primitive. You can control the default tagging method at the top of your ASN.1 module. IMPLICIT changes the ta

Re: How to convert internal ASN1_INTEGER into little endian content octets

2004-02-11 Thread Frank Balluffi
Andrzej, Call i2d_ASN1_INTEGER to DER-encode an ASN.1 INTEGER. Pass 0 or NULL as the second argument to i2d_ASN1_INTEGER to determine the length of the DER-encoded INTEGER. If you pass a non-zero value as the second argument to i2d_ASN1_INTEGER, the function will DER-encode the INTEGER and increm

Re: RSA signature interoperability

2003-09-24 Thread Frank Balluffi
Andreas, Regarding Java S/MIME, check out http://www.bouncycastle.org/, which claims, "Generators for S/MIME and CMS (PKCS7)." I have used Bouncy Castle's crypto APIs, but not their S/MIME APIs, so I am not sure about the details of their S/MIME APIs and whether they will satisfy your needs.

Re: Need to know how to compile a debug version of OpenSSL...

2002-07-31 Thread Frank Balluffi
Vinay, Read Install.w32. For example, you could add the following to ms\do_ms.bat: perl util\mk1mf.pl debug no-asm VC-WIN32 >ms\nt-static-debug.mak and then run: ms\do_ms.bat nmake -f ms\nt-static-debug.mak to build a debug static version of OpenSSL without the use of an assembler. Frank

Re: Compilation problem using OpenSSL with STL

2002-07-27 Thread Frank Balluffi
Ed, To the best of my knowledge STL uses the namespace std. Have you tried explicitly referencing the STL templates using the namespace std::. For example, std::string, std::vector, etc. Frank

Re: Read private key

2002-06-11 Thread Frank Balluffi
Julien, You could modify the code to read from something other than a file, which may not matter to you. Frank Message History From: julien Bournelle <[EMAIL PROTECTED]>@openssl.org on 06/11/2002 06:00 PM

Re: Read private key

2002-06-11 Thread Frank Balluffi
Julien, Not sure about PEM_read_RSAPublicKey, but the following call to PEM_read_bio_RSAPublicKey works for me: BIO * bio = NULL; RSA * rsa = NULL; bio = BIO_new (BIO_s_file ()); if (!bio) { // Handle error here. } if (BIO_read_filename (bio, publicKeyF

Re: rsa_st copy function

2002-06-04 Thread Frank Balluffi
Federico, You can either encode and decode CopyKey (i.e., call i2d followed by d2i) or increment the rsa_st's references element using CRYPTO_add. For example: CRYPTO_add (&CopyKey->references, 1, CRYPTO_LOCK_RSA); See crypto/threads/mttest.c for setting up mutexes for a multithreaded applica