Have you try to initialize cert to NULL before use? Francesco Petruzzi
[EMAIL PROTECTED] -------- The information contained in this electronic message and any attachments (the "Message") is intended for one or more specific individuals or entities, and may be confidential, proprietary, privileged or otherwise protected by law. If you are not the intended recipient, please notify the sender immediately, delete this Message and do not disclose, distribute, or copy it to any third party or otherwise use this Message. Electronic messages are not secure or error free and can contain viruses or may be delayed, and the sender is not liable for any of these occurrences. The sender reserves the right to monitor, record and retain electronic messages. -------- Le informazioni contenute in questo messaggio e gli eventuali allegati (il "Messaggio") si intendono inviate a uno o piú specifici destinatari. Il contenuto del Messaggio puó essere confidenziale, riservato e comunque protetto dalla legge applicabile. Se non siete i destinatari del Messaggio, siete pregati di informare immediatamente il mittente, cancellare questo Messaggio, non rivelarlo, non distribuirlo ne' inoltrarlo a terzi, non copiarlo né farne alcun uso. I messaggi di posta elettronica non sono sicuri e sono soggetti ad alterazioni, possono essere trasmettitori di Virus informatici o soggetti a ritardi nella distribuzione. Il mittente del Messaggio non puó essere in alcun modo considerato responsabile per queste evenienze. Il mittente si riserva il diritto di archiviare, ritenere e controllare i messaggi di posta elettronica. ----- Original Message ----- From: "BiGNoRm6969" <[EMAIL PROTECTED]> To: <openssl-users@openssl.org> Sent: Monday, December 08, 2008 7:01 PM Subject: [?? Probable Spam] PEM_read_bio_X509 - Segmentation fault > > Hi, > > The function PEM_read_bio_X509 always create a Segmentatio Fault. > > Code: > string certificateFile = > "/home/norm/Desktop/tmp/SSLServer_RootCertificate.pem"; > X509* cert; > BIO* bio_cert = BIO_new_file(certificateFile.c_str(), "rb"); > PEM_read_bio_X509(bio_cert, &cert, NULL, NULL); > > Any idea whats causing the problem ? I tryed it on linux and also on > windows xp...same problem. > > > -- > View this message in context: http://www.nabble.com/PEM_read_bio_X509---Segmentation-fault-tp20900358p20900358.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 [EMAIL PROTECTED] ______________________________________________________________________ OpenSSL Project http://www.openssl.org User Support Mailing List openssl-users@openssl.org Automated List Manager [EMAIL PROTECTED]