From: Todd C. Miller Date: Fri, 9 Sep 2011 13:57:39 +0000 (-0400) Subject: Honor NOPASSWD tag for denied commands too. X-Git-Tag: SUDO_1_8_3~47^2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=dacb1e47f3bb4a1ab0a4c3f66a517fdf08d5d327;p=sudo Honor NOPASSWD tag for denied commands too. --- diff --git a/plugins/sudoers/parse.c b/plugins/sudoers/parse.c index 303d13500..8ce68584b 100644 --- a/plugins/sudoers/parse.c +++ b/plugins/sudoers/parse.c @@ -250,6 +250,8 @@ sudo_file_lookup(struct sudo_nss *nss, int validated, int pwflag) } else if (match == DENY) { SET(validated, VALIDATE_NOT_OK); CLR(validated, VALIDATE_OK); + if (tags != NULL && tags->nopasswd != UNSPEC) + def_authenticate = !tags->nopasswd; } restore_perms(); return validated;