Re: stable 3.18 backport: netlink: Trim skb to alloc size to avoid MSG_TRUNC

2019-02-04 Thread Mark Salyzyn
On 02/01/2019 11:41 AM, Mark Salyzyn wrote: if (alloc_size < nlk->max_recvmsg_len) { if (alloc_min_size < nlk->max_recvmgs_len) { -- Mark

stable 3.18 backport: netlink: Trim skb to alloc size to avoid MSG_TRUNC

2019-02-01 Thread Mark Salyzyn
Direct this upstream db65a3aaf29ecce2e34271d52e8d2336b97bd9fe sha to stable 3.18. This patch addresses a race condition where a call to nlk->max_recvmsg_len = max(nlk->max_recvmsg_len, len); nlk->max_recvmsg_len = min_t(size_t, nlk->max_recvmsg_len, one thread in-between another thread: skb