1
0
mirror of https://passt.top/passt synced 2024-06-30 23:12:39 +00:00

passt: Make UNIX domain socket world-writable and world-readable

...save a chmod every time passt is started.

Signed-off-by: Stefano Brivio <sbrivio@redhat.com>
This commit is contained in:
Stefano Brivio 2021-04-13 22:09:37 +02:00
parent 4aa8e54a30
commit 0abec0eb60

View File

@ -42,6 +42,7 @@
#include <linux/rtnetlink.h>
#include <time.h>
#include <syslog.h>
#include <sys/stat.h>
#include "passt.h"
#include "arp.h"
@ -80,6 +81,10 @@ static int sock_unix(void)
perror("UNIX socket bind");
exit(EXIT_FAILURE);
}
chmod(UNIX_SOCK_PATH,
S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH);
return fd;
}