summaryrefslogtreecommitdiff
path: root/usr.bin/doas
diff options
context:
space:
mode:
authorTed Unangst <tedu@cvs.openbsd.org>2017-05-27 09:51:08 +0000
committerTed Unangst <tedu@cvs.openbsd.org>2017-05-27 09:51:08 +0000
commitd0932bdf89103318f7100aac21f63673c65709b4 (patch)
tree60f61bd4148f757967b0fd79fa156e1e489b8928 /usr.bin/doas
parenta7c474d1b0c7225dcba5c8445629b1e97cfc82fd (diff)
for password failure, print Authorization failed instead of EPERM.
will make things less confusing with commands rejected by config file.
Diffstat (limited to 'usr.bin/doas')
-rw-r--r--usr.bin/doas/doas.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/doas/doas.c b/usr.bin/doas/doas.c
index 038e4cb4b7c..9ec4257dffd 100644
--- a/usr.bin/doas/doas.c
+++ b/usr.bin/doas/doas.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: doas.c,v 1.71 2017/04/06 21:14:12 tedu Exp $ */
+/* $OpenBSD: doas.c,v 1.72 2017/05/27 09:51:07 tedu Exp $ */
/*
* Copyright (c) 2015 Ted Unangst <tedu@openbsd.org>
*
@@ -228,7 +228,7 @@ authuser(char *myname, char *login_style, int persist)
if (!auth_userresponse(as, response, 0)) {
syslog(LOG_AUTHPRIV | LOG_NOTICE,
"failed auth for %s", myname);
- errc(1, EPERM, NULL);
+ errx(1, "Authorization failed");
}
explicit_bzero(rbuf, sizeof(rbuf));
good: