[gnutls-devel] GnuTLS | WIP: AIA callback to retrieve missing chain certificates (!1262)

Development of GNU's TLS library gnutls-devel at lists.gnutls.org
Sat May 30 12:04:42 CEST 2020




Sahana Prasad commented on a discussion on lib/x509/verify.c: https://gitlab.com/gnutls/gnutls/-/merge_requests/1262#note_352270717

>  		issuer = find_issuer(cert, trusted_cas, tcas_size);
>  
> +	if (issuer == NULL) {
> +                if (tlist != NULL && tlist->issuer_callback != NULL) {
> +                        _gnutls_debug_log("Missing issuer callback set.\n");
> +                        ret = gnutls_x509_crt_init(&issuer);
> +	                if (ret < 0) {
> +		                _gnutls_debug_log("gnutls_x509_crt_init: %s\n", gnutls_strerror(ret));
> +                                gnutls_assert();
> +                                issuer = NULL;
> +	                }
> +
> +                        /* missing issuer is populated by the callback */
> +                        ret = tlist->issuer_callback(tlist, cert, issuer);
> +                        if (ret < 0) {
> +                        /* if the callback fails, continue as though the callback

I can fix the spaces into tabs. (but I would have to align with spaces towards the end, like in the patch)But unlike the patch I do prefer that the next function parameter starts after the parentheses and not exactly under it.

What do you think?

(a
 b

over

(a
b

-- 
Reply to this email directly or view it on GitLab: https://gitlab.com/gnutls/gnutls/-/merge_requests/1262#note_352270717
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/20200530/0acffbe8/attachment-0001.html>


More information about the Gnutls-devel mailing list