Commit 87e547d9 by Wolfgang Bumiller

seccomp: recvmsg with MSG_TRUNC

We only read the message without the cookie. For now assert that the sender also didn't try to send more by letting `recvmsg()` return the original size of the packet if it was longer. Signed-off-by: 's avatarWolfgang Bumiller <w.bumiller@proxmox.com>
parent 214008ee
......@@ -1466,7 +1466,8 @@ retry:
goto out;
}
bytes = lxc_recvmsg_nointr_iov(listener_proxy_fd, iov,iov_len, 0);
bytes = lxc_recvmsg_nointr_iov(listener_proxy_fd, iov,iov_len,
MSG_TRUNC);
if (bytes != (ssize_t)msg_base_size) {
SYSERROR("Failed to receive message from seccomp proxy");
seccomp_notify_default_answer(fd, req, resp, hdlr);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment