<html><head></head><body><div style="color:#000; background-color:#fff; font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:14px"><div id="yui_3_16_0_ym19_1_1490209969888_4905">Ok, thanks but the key is not in DER but COER, there are ways to transform it in DER.</div><div id="yui_3_16_0_ym19_1_1490209969888_4935"><br></div><div>Thanks</div><div><br></div><div>Best regards</div><div><br></div><div id="yui_3_16_0_ym19_1_1490209969888_4936">Christian Adja<br></div><div id="yui_3_16_0_ym19_1_1490209969888_4775"><span></span></div> <div class="qtdSeparateBR"><br><br></div><div style="display: block;" class="yahoo_quoted"> <div style="font-family: HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif; font-size: 14px;"> <div style="font-family: HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif; font-size: 16px;"> <div dir="ltr"><font face="Arial" size="2"> Il Mercoledì 22 Marzo 2017 20:08, Richard Levitte <levitte@openssl.org> ha scritto:<br></font></div>  <br><br> <div class="y_msg_container"><div dir="ltr">In message <<a shape="rect" ymailto="mailto:787239451.2530096.1490206287248@mail.yahoo.com" href="mailto:787239451.2530096.1490206287248@mail.yahoo.com">787239451.2530096.1490206287248@mail.yahoo.com</a>> on Wed, 22 Mar 2017 18:11:27 +0000 (UTC), Christian Adja <<a shape="rect" ymailto="mailto:christian_adja@yahoo.it" href="mailto:christian_adja@yahoo.it">christian_adja@yahoo.it</a>> said:<br clear="none"><br clear="none">christian_adja> Thanks for the response, but haven't the evp_pkey struct of the public<br clear="none">christian_adja> key. I' ve only the an bytes string that i retrieved from IEEE cert<br clear="none">christian_adja> with "PEM_bytes_read_bio()". Now in want to form the ec_key struct and<br clear="none">christian_adja> then the evp_pkey struct.<br clear="none"><br clear="none">I'm not sure how IEEE certs differ from X.509 certs...  if they don't,<br clear="none">you're better off reading the cert with PEM_read_bio_X509() and<br clear="none">extracting the public key with X509_get0_pubkey() or X509_get0_pubkey().<br clear="none"><br clear="none">If IEEE certs differ in format, you must first know the exact byte<br clear="none">content, where the public key is in there, make sure it's encoded in<br clear="none">DER, and use d2i_EC_PUBKEY() to make a EC_KEY from those bytes.<div class="yqt0708328227" id="yqtfd36946"><br clear="none"><br clear="none">Cheers,</div><br clear="none">Richard<br clear="none"><br clear="none">-- <br clear="none">Richard Levitte         <a shape="rect" ymailto="mailto:levitte@openssl.org" href="mailto:levitte@openssl.org">levitte@openssl.org</a><br clear="none">OpenSSL Project         <a shape="rect" href="http://www.openssl.org/~levitte/" target="_blank">http://www.openssl.org/~levitte/</a><div class="yqt0708328227" id="yqtfd37596"><br clear="none"></div></div><br><br></div>  </div> </div>  </div></div></body></html>