Test: unix socket: test credential passing
authorJérémie Galarneau <jeremie.galarneau@efficios.com>
Thu, 15 Jul 2021 00:44:44 +0000 (20:44 -0400)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Fri, 16 Jul 2021 17:36:29 +0000 (13:36 -0400)
commit707602aa577ce7ed59b860971dfc51450cfeee80
tree40ae6b64286e6f26fc0cf206799359f927cfd0d0
parent4dc766fa8a92a9862c3f9d560751a941b4599380
Test: unix socket: test credential passing

Since the credential passing over UNIX sockets now makes use of the pid,
the compatiblity wrappers have become more complex as each platform
appears to define its own way of accessing this information.

This new test:
  - creates a named unix socket,
  - forks,
  - gets the parents and child to connect,
  - sends the child's credentials as a data payload and as credentials
    verified by the kernel
  - the parent checks that the two sets of credentials are equal.

This is more of a sanity check for the compatibility wrappers used on
non-Linux platforms.

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
Change-Id: Ic0a6213afca7cc95a00617b052e7a145fc88625c
tests/unit/test_unix_socket.c
This page took 0.025187 seconds and 4 git commands to generate.