From: Todd C. Miller Date: Fri, 21 Jan 2011 15:10:47 +0000 (-0500) Subject: For "sudo -U user -l" if user is not authorized on the host, say so. X-Git-Tag: SUDO_1_7_5~58 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=4e3ebfaffbf5a96fa8e9ddbed301889445785a97;p=sudo For "sudo -U user -l" if user is not authorized on the host, say so. --HG-- branch : 1.7 --- diff --git a/sudo_nss.c b/sudo_nss.c index fb979a452..321390643 100644 --- a/sudo_nss.c +++ b/sudo_nss.c @@ -288,6 +288,9 @@ display_privs(snl, pw) if (count) { lbuf_print(&defs); lbuf_print(&privs); + } else { + printf("User %s is not allowed to run sudo on %s.\n", pw->pw_name, + user_shost); } lbuf_destroy(&defs);