[gnutls-devel] GnuTLS | gnutls_buffer_append_data: avoid use-after-free in the callers (!1399)
Read-only notification of GnuTLS library development activities
gnutls-devel at lists.gnutls.org
Tue Mar 9 16:56:13 CET 2021
Daiki Ueno commented on a discussion on lib/str.c: https://gitlab.com/gnutls/gnutls/-/merge_requests/1399#note_525353833
> if (unlikely(dest->data != NULL && dest->allocd == NULL))
> return gnutls_assert_val(GNUTLS_E_INVALID_REQUEST);
>
> + /* When running under valgrind, use a simpler logic for reallocation;
> + * i.e., always call gnutls_realloc_fast() and do not reclaim the
> + * no-longer-used area which has been removed from the beginning of
> + * buffer with _gnutls_buffer_pop_datum().
> + */
> +#ifdef HAVE_VALGRIND_MEMCHECK_H
Yes; that makes the issue happen more reliably.
--
Reply to this email directly or view it on GitLab: https://gitlab.com/gnutls/gnutls/-/merge_requests/1399#note_525353833
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/20210309/f37005fd/attachment.html>
More information about the Gnutls-devel
mailing list