Perhaps if you could use gdb to display a stack trace, it would be
easier to locate the error.


-----Original Message-----
From: Jeff Fulmer <[EMAIL PROTECTED]>
Sent: May 13, 2004 8:24 AM
To: [EMAIL PROTECTED]
Subject: Re: X509_get_subject_name

It didn't. It still core dumps on Red Hat systems.

On Tue, May 11, 2004 at 11:58:36AM -0600, Bommareddy, Satish (Satish) wrote:
> I think the X509_NAME_oneline takes a buffer and length for arguments 2 and 3.
> try
> buf[256];
> str       = X509_NAME_oneline(X509_get_subject_name(C->cert), buf, 256);
> 
> see if that helps
> 
> 
> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] Behalf Of Jeff Fulmer
> Sent: Tuesday, May 11, 2004 10:52 AM
> To: [EMAIL PROTECTED]
> Subject: X509_get_subject_name
> 
> 
> Hello,
> 
> I'm the author of siege.  That program is dumping core on Red Hat
> systems in the following function: X509_get_subject_name  
> 
> Here's the function which calls it:
> 
> BOOLEAN
> SSL_initialize(CONN *C)
> {
> #ifdef HAVE_SSL
>   int  serr;
>   char *str;
> 
>   C->ssl    = NULL;
>   C->ctx    = NULL;
>   C->method = NULL;
>   C->cert   = NULL;
> 
>   SSL_load_error_strings();
>   SSLeay_add_ssl_algorithms();
>   C->method = SSLv2_client_method();
>   C->ctx    = SSL_CTX_new(C->method);
>   C->ssl    = SSL_new(C->ctx);
>   SSL_set_fd(C->ssl, C->sock);
>   serr = SSL_connect(C->ssl);
>   C->cert   = SSL_get_peer_certificate(C->ssl);
>   str       = X509_NAME_oneline(X509_get_subject_name(C->cert), 0, 0);
>   if(my.debug){printf("X509 subject: %s\n", str); fflush(stdout); }
>   str       = X509_NAME_oneline(X509_get_issuer_name(C->cert), 0, 0);
>   if(my.debug){printf("X509 issuer:  %s\n", str); fflush(stdout); }
>   X509_free(C->cert);
>   return TRUE;
> #else
>   return FALSE;
> #endif/*HAVE_SSL*/
> }
> 
> Any thoughts?
> 
> 
> -- 
> #include <stdio.h>
> int main(){int a[]={74,117,115,116,32,97,110,111,116,104,101,114,32, \
> 67,32,104,97,99,107,101,114,10,0}; int *b=a;while(*b>0)putchar(*b++);}
> ______________________________________________________________________
> OpenSSL Project                                 http://www.openssl.org
> User Support Mailing List                    [EMAIL PROTECTED]
> Automated List Manager                           [EMAIL PROTECTED]
> ______________________________________________________________________
> OpenSSL Project                                 http://www.openssl.org
> User Support Mailing List                    [EMAIL PROTECTED]
> Automated List Manager                           [EMAIL PROTECTED]
> 

-- 
#include <stdio.h>
int main(){int a[]={74,117,115,116,32,97,110,111,116,104,101,114,32, \
67,32,104,97,99,107,101,114,10,0}; int *b=a;while(*b>0)putchar(*b++);}
______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    [EMAIL PROTECTED]
Automated List Manager                           [EMAIL PROTECTED]
______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    [EMAIL PROTECTED]
Automated List Manager                           [EMAIL PROTECTED]

Reply via email to