[Top][All Lists]

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

Re: [libmicrohttpd] [possible feature request?] Loading key/cert from fi

From: Christian Grothoff
Subject: Re: [libmicrohttpd] [possible feature request?] Loading key/cert from file [gnutls_certificate_set_x509_key_file2()]
Date: Wed, 5 Sep 2018 11:42:25 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.8.0

Hi Silvio,

I don't like the proposed feature very much, it's something an
application developer can reasonably easily write themselves, it would
introduce a dependency on file system operations to MHD, and it would
include a lot of different possible error types (file not found, access
permissions wrong, etc.) that would have to be passed back to the

That said, adding a good _example_ (reference code) for how to do this
in the documentation would be totally fine.

My 2 cents!

Happy hacking!

p.s.: sorry for the delay, life's been very busy...

On 07/29/2018 05:39 AM, silvioprog wrote:
> Hello dudes.
> I tried to pass the key/cert files to the MHD library, however, it
> allows only passing via memory (using
> gnutls_certificate_set_x509_key_mem2()):
>   MHD_OPTION_HTTPS_MEM_KEY, "private key content",
>   MHD_OPTION_HTTPS_MEM_CERT, "certificate content"
> but it would be nice to use the GnuTLS's builtin functions to load the
> key/cert files: gnutls_certificate_set_x509_key_file2(). Advantage: the
> programmer just pass the path of the key/cert instead of writing own
> unsafe functions for file loading. So, what do you thing about
> to add those new options?:
> Thank you!
> -- 
> Silvio Clécio

Attachment: signature.asc
Description: OpenPGP digital signature

reply via email to

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