OS-4606: lxbrand SCM_UCRED translation often causes MSG_CTRUNC

Details

Issue Type:Bug
Priority:4 - Normal
Status:Open
Created at:2015-08-05T22:44:32.000Z
Updated at:2019-08-28T17:38:22.744Z

People

Created by:Former user
Reported by:Former user

Labels

lxbrand

Description

When Linux applications pass a cmsg buffer expecting SCM_CREDENTIALS to recvmsg, it is often of a small size. Because struct ucred_s is not small, the internal socket_recvmsg call will often set the MSG_CTRUNC since the provided buffer is too small. This is problem since after translation, the truncation would not occur.

We probably need to inflate the cmsg buffer for cases where this might occur to prevent spurious CMSG_CTRUNC flags from being output.

Comments