summaryrefslogtreecommitdiffstats
path: root/usr.sbin/ctld/login.c
diff options
context:
space:
mode:
authortrasz <trasz@FreeBSD.org>2014-02-11 11:32:36 +0000
committertrasz <trasz@FreeBSD.org>2014-02-11 11:32:36 +0000
commitd2233667737fd4f8c08b7bd91b42dd5394f0f3c7 (patch)
tree63f71965ca64222f76bc030b2b9f04a88925c322 /usr.sbin/ctld/login.c
parent7f7fd0dbc0e0dff0202586fa4aa864c47f28bfd2 (diff)
downloadFreeBSD-src-d2233667737fd4f8c08b7bd91b42dd5394f0f3c7.zip
FreeBSD-src-d2233667737fd4f8c08b7bd91b42dd5394f0f3c7.tar.gz
Use new auth-type "deny" instead of using "chap" with no chap entries;
it's cleaner this way, and gives better feedback to the user. Sponsored by: The FreeBSD Foundation
Diffstat (limited to 'usr.sbin/ctld/login.c')
-rw-r--r--usr.sbin/ctld/login.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/usr.sbin/ctld/login.c b/usr.sbin/ctld/login.c
index 9dea58e..ceabd92 100644
--- a/usr.sbin/ctld/login.c
+++ b/usr.sbin/ctld/login.c
@@ -1030,6 +1030,11 @@ login(struct connection *conn)
return;
}
+ if (ag->ag_type == AG_TYPE_DENY) {
+ login_send_error(request, 0x02, 0x01);
+ log_errx(1, "auth-group type is \"deny\"");
+ }
+
if (ag->ag_type == AG_TYPE_UNKNOWN) {
/*
* This can happen with empty auth-group.
OpenPOWER on IntegriCloud