Hallo,

Balaji S wrote:
hai,
i want to know how an integer(ex p=5) encoded as
der format.[ in openssl]
i study asn.1 in detail,
p=5 is ASN.1 INTEGER, so UNIVERSAL CLASS is 02,
so hex values seem to be, tag length value
02 01 05


how to encode this value in opnssl so that it
can converted to der an pem format and can be viewd by opnessl.

??? Sorry. I really don't know what you want to do.

I'm almost sure you don't want something like:
> cat >test.c
#include <stdio.h>
int main()
{
   printf("%c%c%c",2,1,5);
   return 0;
}
> gcc test.c
> ./a.out >test.der
> rm a.out
> openssl asn1parse -in test.der -inform der
    0:d=0  hl=2 l=   1 prim: INTEGER           :05
>


Bye

Goetz

--
Goetz Babin-Ebell, software designer,
TC TrustCenter AG, Sonninstr. 24-28, 20097 Hamburg, Germany
Office: +49-(0)40 80 80 26 -0,  Fax: +49-(0)40 80 80 26 -126
www.trustcenter.de www.betrusted.com

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature



Reply via email to