From 3dec2de3eecd475db69ec3746a631ec1591d08a5 Mon Sep 17 00:00:00 2001 From: paul Date: Wed, 21 May 2003 19:09:31 +0000 Subject: From: Paul Jakma Subject: [zebra 19125] vtysh bogus perms check vtysh checks that the zebra.vty socket uid is == to its own euid, this is bogus - let the kernel decide whether permissions match, vtysh shouldnt try second guess. (this becomes noticeable when neither zebra nor vtysh are run as root :) ) --- vtysh/vtysh.c | 8 -------- 1 file changed, 8 deletions(-) (limited to 'vtysh/vtysh.c') diff --git a/vtysh/vtysh.c b/vtysh/vtysh.c index d1a5c5fd..be1f03e4 100644 --- a/vtysh/vtysh.c +++ b/vtysh/vtysh.c @@ -1618,14 +1618,6 @@ vtysh_connect (struct vtysh_client *vclient, char *path) exit (1); } - if (euid != s_stat.st_uid - || !(s_stat.st_mode & S_IWUSR) - || !(s_stat.st_mode & S_IRUSR)) - { - fprintf (stderr, "vtysh_connect(%s): No permission to access socket\n", - path); - exit (1); - } } sock = socket (AF_UNIX, SOCK_STREAM, 0); -- cgit v1.2.1