help-gnutls
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Help-gnutls] Sending a client certificate


From: Martin Lambers
Subject: [Help-gnutls] Sending a client certificate
Date: Sat, 5 Feb 2005 16:26:21 +0100
User-agent: Mutt/1.5.6i

I'm trying to send a client certificate when starting a TLS handshake
with a server. 
Currently, I use the following steps (plus error checking, of course):

gnutls_init(&session, GNUTLS_CLIENT);
gnutls_set_default_priority(session);
gnutls_certificate_allocate_credentials(&cred);
gnutls_certificate_set_x509_key_file(cred, 
    "cert_file.pem", "key_file.pem", GNUTLS_X509_FMT_PEM);
gnutls_credentials_set(session, GNUTLS_CRD_CERTIFICATE, cred);
gnutls_transport_set_ptr(session, fd);
gnutls_handshake(session);

But this does not work; no client certificate is send. Are there more
steps necessary? Am I missing something?

I used both GnuTLS 1.0.17 and 1.2.0.

Martin




reply via email to

[Prev in Thread] Current Thread [Next in Thread]