[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Bug-wget] [PATCH] Added missing TLSV1_1 and TLSV1_2 code to gnutls.
From: |
Giuseppe Scrivano |
Subject: |
Re: [Bug-wget] [PATCH] Added missing TLSV1_1 and TLSV1_2 code to gnutls.c |
Date: |
Wed, 26 Nov 2014 12:13:41 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) |
Tim Ruehsen <address@hidden> writes:
> case secure_protocol_tlsv1:
> allowed_protocols[0] = GNUTLS_TLS1_0;
> allowed_protocols[1] = GNUTLS_TLS1_1;
> allowed_protocols[2] = GNUTLS_TLS1_2;
> err = gnutls_protocol_set_priority (session, allowed_protocols);
> break;
> -
> + case secure_protocol_tlsv1_1:
> + allowed_protocols[0] = GNUTLS_TLS1_1;
> + allowed_protocols[2] = GNUTLS_TLS1_2;
> + err = gnutls_protocol_set_priority (session, allowed_protocols);
> + break;
> + case secure_protocol_tlsv1_2:
> + allowed_protocols[2] = GNUTLS_TLS1_2;
> + err = gnutls_protocol_set_priority (session, allowed_protocols);
> + break;
> default:
allowed_protocols is a 0 terminated list. So this last chunk should be:
> case secure_protocol_tlsv1:
> allowed_protocols[0] = GNUTLS_TLS1_0;
> allowed_protocols[1] = GNUTLS_TLS1_1;
> allowed_protocols[2] = GNUTLS_TLS1_2;
> err = gnutls_protocol_set_priority (session, allowed_protocols);
> break;
>
> + case secure_protocol_tlsv1_1:
> + allowed_protocols[0] = GNUTLS_TLS1_1;
> + allowed_protocols[1] = GNUTLS_TLS1_2;
> + err = gnutls_protocol_set_priority (session, allowed_protocols);
> + break;
> +
> + case secure_protocol_tlsv1_2:
> + allowed_protocols[0] = GNUTLS_TLS1_2;
> + err = gnutls_protocol_set_priority (session, allowed_protocols);
> + break;
> default:
ACK with this change. I prefer if we leave an empty line between the
"break" and the next "case", what do you think?
Regards,
Giuseppe