[gnutls-devel] GnuTLS | TLS 1.3: ignore "early_data" extension (!706)

Development of GNU's TLS library gnutls-devel at lists.gnutls.org
Wed Jul 25 17:26:27 CEST 2018


Daiki Ueno commented on a discussion on lib/record.c:

>  				  "Discarded message[%u] due to invalid decryption\n",
>  				  (unsigned int)
>  				  _gnutls_uint64touint32(packet_sequence));
> +
> +		/* as 0-RTT is not implemented yet, when early data is
> +		 * indicated, skip decryption failure up to
> +		 * max_early_data_size. */
> +		if (session->internals.early_data_indicated &&
> +		    record.type == GNUTLS_APPLICATION_DATA) {
> +			if (record.length > session->security_parameters.max_early_data_size - session->internals.early_data_received) {

I am not sure why using addition is safer here; I followed the general guidance on writing such conditions:
http://www.enyo.de/fw/notes/style-guide-conditions.html
(`record.length` won't be that large, though).

-- 
Reply to this email directly or view it on GitLab: https://gitlab.com/gnutls/gnutls/merge_requests/706#note_90332802
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/20180725/b96de4c2/attachment.html>


More information about the Gnutls-devel mailing list