help-gnutls
[Top][All Lists]
Advanced

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

Re: how to use gnutls_privkey_import_ext


From: Carolin Latze
Subject: Re: how to use gnutls_privkey_import_ext
Date: Sun, 10 Jun 2012 14:51:14 +0200
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.16) Gecko/20120506 Icedove/3.0.11

yay, that works ( I do it with a cert_callback now). I just need to restrict the hash algorithms to SHA-1 since the TPM refuses to sign an SHA256 hash :-/

need to figure out how to do this. If all is running fine I need to clean up the code and will send it to you.

On 06/10/2012 01:18 PM, Nikos Mavrogiannopoulos wrote:
On 06/10/2012 12:56 PM, Carolin Latze wrote:


gnutls_privkey_t key;
gnutls_privkey_init(&key);

and assigned a NULL privkey to the credentials of this session: (even if
I assign the&key here, it does not help)

gnutls_certificate_set_x509_key_mem(xcred,&ccert, NULL,
GNUTLS_X509_FMT_PEM);

Unfortunately you cannot call this. If you have a gnutls_privkey_t you
need to use gnutls_certificate_set_key(). That means that you'll have to
import the certificate and convert it to gnutls_pcert_st. A helper
function is indeed needed in that case.

regards,
Nikos




reply via email to

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