On Mon, Oct 05, 2009, Srirang Doddihal wrote: > Hi all, > > I have some base64 encoded data in my own buffer (a character array). > I want to decode this. > > >From the man pages it appeared to me that I should > 1) create a memory bio, > 2) populate it with my base64 encoded data. > 3) Create a base64 filter bio > 4) Create a chain like this: > > [base64_bio]-----[mem_bio] > > 5) Read from the chain > Sadly this does not work. Read always signals EOF/EOD. Read always > returns -1. BIO_should_retry() or BIO_should_read() is true after > every subsequent attempt to read from the chain. > > If I replace the [mem_bio] with a [fp_bio], it works fine, i.e if I > place the base64 encoded data in a file and create a chain like this: > > [base64_bio]-----[fp_bio] > and then read from the chain, the data is properly decoded, all in one > go. > > I read this posting : > http://marc.info/?l=openssl-users&m=123171064303018&w=2 > > and this : > http://markmail.org/message/cdndl7pofs7maixq#query:+page:1+mid:hts7ql...<http://markmail.org/message/cdndl7pofs7maixq#query:+page:1+mid:hts7qlqkz3yzsmz2+state:results> > > but they did not solve my problem. The first posting is large and > elaborate and I did understand parts of it. Probably its the parts > that I did not understand that are needed here. > Either ways, any help is really appreciated. >
Does this simpler version help: http://www.openssl.org/support/faq.html#PROG15 Steve. -- Dr Stephen N. Henson. OpenSSL project core developer. Commercial tech support now available see: http://www.openssl.org ______________________________________________________________________ OpenSSL Project http://www.openssl.org User Support Mailing List openssl-users@openssl.org Automated List Manager majord...@openssl.org