Skip to content
Success

Changes

Summary

  1. msgb: msgb_copy_resize_c: Fix validation check to avoid memcpy buffer overflow (details)
Commit 6b7c13a8b1cc7f8cd48904c3c089f084c126b4f5 by Pau Espin Pedrol
msgb: msgb_copy_resize_c: Fix validation check to avoid memcpy buffer overflow

If msg->data pointer is not allocated at the start of the msgb, (eg.
because it was pull()ed or had some headroom), the existing check
wouldn't catch it and memcpy() would write passed the allocated chunk
(msg->data - msg->_data) bytes.

Change-Id: If4c84162a4e5b44b82813fb58029fae04bd38230
The file was modifiedsrc/core/msgb.c