[gnutls-devel] GnuTLS | RFC7250 Raw public keys (!650)

Development of GNU's TLS library gnutls-devel at lists.gnutls.org
Thu Nov 29 00:26:07 CET 2018


Tom commented on a discussion on lib/cert-cred-rawpk.c:

> +
> +	// A complete key pair must be given
> +	if (rawpkfile == NULL || privkeyfile == NULL) {
> +		return gnutls_assert_val(GNUTLS_E_INSUFFICIENT_CREDENTIALS);
> +	}
> +
> +	/* Import our private key. This function does all the necessary
> +	 * inits, checks and imports. */
> +	ret = _gnutls_read_key_file(cred, privkeyfile, format, pass, flags, &privkey);
> +	if (ret < 0) {
> +		return gnutls_assert_val(ret);
> +	}
> +
> +	// TODO FUTURE: support URLs
> +	if (gnutls_url_is_supported(rawpkfile)) {
> +		return gnutls_assert_val(GNUTLS_E_INVALID_REQUEST);

I didn't know about this function. I'll incorporate it.

Why is it that the `*_file()` API handles URLs and we don't have a separate API for it?

-- 
Reply to this email directly or view it on GitLab: https://gitlab.com/gnutls/gnutls/merge_requests/650#note_120909586
You're receiving this email because of your account on gitlab.com.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.gnupg.org/pipermail/gnutls-devel/attachments/20181128/ba25b5e7/attachment.html>


More information about the Gnutls-devel mailing list