gramineproject / graphene

Graphene / Graphene-SGX - a library OS for Linux multi-process applications, with Intel SGX support
https://grapheneproject.io
GNU Lesser General Public License v3.0
771 stars 260 forks source link

[LibOS] Relax check on UNIX domain socket's `addrlen` in `bind` #2620

Closed dimakuv closed 3 years ago

dimakuv commented 3 years ago

Description of the changes

Previously, LibOS expected addrlen for UNIX domain sockets to be exactly the same as the size of sockaddr_un struct. This is not true in the common case: addrlen may be less, see man unix.

Fixes #2609.

How to test this PR?

Added a test case in our existing unix.c LibOS regression test.


This change is Reviewable