X-Git-Url: https://git.armaanb.net/?p=opendoas.git;a=blobdiff_plain;f=doas.c;h=2cd227d1adf322e846b616524e1c11afdad2d7ef;hp=a99b964105e3465adb2c947bc974a0610cb87f70;hb=22203dec632c0a030e3c83c39ae59feff8d4f8b0;hpb=b5d211d5d75b031f70e12565e704e7a9c817df83 diff --git a/doas.c b/doas.c index a99b964..2cd227d 100644 --- a/doas.c +++ b/doas.c @@ -362,7 +362,6 @@ main(int argc, char **argv) errc(1, EPERM, NULL); } -#if defined(USE_SHADOW) if (!(rule->options & NOPASS)) { if (nflag) errx(1, "Authentication required"); @@ -371,12 +370,6 @@ main(int argc, char **argv) if (ret == 5) authfail(rule->options & INSULT); } -#elif !defined(USE_PAM) - /* no authentication provider, only allow NOPASS rules */ - (void) nflag; - if (!(rule->options & NOPASS)) - errx(1, "Authentication required"); -#endif if ((p = getenv("PATH")) != NULL) formerpath = strdup(p); @@ -394,11 +387,6 @@ main(int argc, char **argv) if (targpw == NULL) errx(1, "no passwd entry for target"); -#if defined(USE_PAM) - pamauth(targpw->pw_name, mypw->pw_name, !nflag, rule->options & NOPASS, - rule->options & PERSIST); -#endif - #ifdef HAVE_LOGIN_CAP_H if (setusercontext(NULL, targpw, target, LOGIN_SETGROUP | LOGIN_SETPATH |