can anyone tell a way how to parse a BER encoded string an then decode it to ASN1?i've tried: [code] unsigned char* buffer; buffer=new unsigned char[strlen("0x304913214D617374657220646520736563757269746174656120696E666F726D6174696569301E170D3039313030313030303030305A170D3130303331353030303030305A020103010101")];
strcpy((char*)buffer,"0x304913214D617374657220646520736563757269746174656120696E666F726D6174696569301E170D3039313030313030303030305A170D3130303331353030303030305A020103010101"); BIO * outfile; outfile=BIO_new_file("out.txt","w+"); ASN1_parse(outfile,buffer,150,0);//strlen("0x304913214D617374657220646520736563757269746174656120696E666F726D6174696569301E170D3039313030313030303030305A170D3130303331353030303030305A020103010101"),0); BIO_free(outfile); [/code] but an error occured inthe outfile: 0:d=0 hl=2 l= 120 cons: SEQUENCE 2:d=1 hl=2 l= 48 cons: PRINTABLESTRING Error in encoding thanks -- View this message in context: http://old.nabble.com/parse-a-BER-encoded-string-and-decode-it-tp31711021p31711021.html Sent from the OpenSSL - User mailing list archive at Nabble.com. ______________________________________________________________________ OpenSSL Project http://www.openssl.org User Support Mailing List openssl-users@openssl.org Automated List Manager majord...@openssl.org