From 2aa8d8ccf0e3e82bd462d17dbfb44e4f58e3ba20 Mon Sep 17 00:00:00 2001 From: kx Date: Wed, 28 Sep 2022 19:30:56 +0300 Subject: Use full path to system's commands instead of set PATH for priv-admin users --- src/shell.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/shell.c b/src/shell.c index c5b8332..af5d649 100644 --- a/src/shell.c +++ b/src/shell.c @@ -156,6 +156,6 @@ int com_poweroff( char *arg ) if( !arg ) arg = ""; - sprintf( syscom, "poweroff %s", arg ); + sprintf( syscom, "/sbin/poweroff %s", arg ); return( system( syscom ) ); } -- cgit v1.2.3