As far as I understand it, the server will not ask the client for a certificate unless you explicitly tell the server to do so:
e.g. SSL_CTX_set_verify() with the SSL_VERIFY_PEER flag set. Pascal ----- Original Message ----- From: "Shlomi" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Tuesday, December 11, 2001 11:26 AM Subject: Server cannot get my client certificate > Hi all, > > I wrote a client which should exchange its cert with the server during the SSL handshake. > My client gets the server certificate but the server doesn't get the client crtificate. > > Can someone help me to fix the problem at the following source lines ? > > > The client side: > > ... > ssl = SSL_new(ctx); > err = SSL_use_PrivateKey_file(ssl, keyFile, SSL_FILETYPE_PEM); > if (err == -1) > error... > err = SSL_use_certificate_file(ssl, certFile, SSL_FILETYPE_PEM); > if (err == -1) > error... > if (!SSL_check_private_key(ssl)) > error... > SSL_set_fd(ssl, sd); > err = SSL_connect(ssl); > if (err == -1) > error... > ... > > And the server side: > > ... > err = SSL_accept(ssl); > if (err == -1) > error... > x509 = SSL_get_peer_certificate(ssl); > but x509 is always NULL. > What should I do to fix this problem ? > > Thank you in advance, > > Shlomi > > ______________________________________________________________________ > 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]