X-Git-Url: https://git.gag.com/?a=blobdiff_plain;f=common-src%2Fssh-security.c;h=19d60692792725905a82e3e4465555201db8fa1c;hb=fd48f3e498442f0cbff5f3606c7c403d0566150e;hp=229c4b40811b1d36ee3b36c88f2c7cd3286ab258;hpb=96f35b20267e8b1a1c846d476f27fcd330e0b018;p=debian%2Famanda diff --git a/common-src/ssh-security.c b/common-src/ssh-security.c index 229c4b4..19d6069 100644 --- a/common-src/ssh-security.c +++ b/common-src/ssh-security.c @@ -37,11 +37,9 @@ #include "util.h" #include "event.h" #include "packet.h" -#include "queue.h" #include "security.h" #include "security-util.h" #include "stream.h" -#include "version.h" /* * Number of seconds ssh has to start up @@ -225,11 +223,13 @@ runssh( return (0); } + /* drop root privs for good */ + set_root_privs(-1); + safe_fd(-1, 0); if(!xamandad_path || strlen(xamandad_path) <= 1) - xamandad_path = vstralloc(amlibexecdir, "/", "amandad", - versionsuffix(), NULL); + xamandad_path = vstralloc(amlibexecdir, "/", "amandad", NULL); if(!xclient_username || strlen(xclient_username) <= 1) xclient_username = CLIENT_LOGIN; if(!ssh_keys || strlen(ssh_keys) <= 1) {