summaryrefslogtreecommitdiffstats
path: root/lib/libutil/login_cap.3
diff options
context:
space:
mode:
authorgreen <green@FreeBSD.org>2000-08-22 02:15:54 +0000
committergreen <green@FreeBSD.org>2000-08-22 02:15:54 +0000
commit67c40ef892e23a375a1eeec51d343ef6be31f5d8 (patch)
tree7fd6719b0a54565971e388646c8ae7f62b08674b /lib/libutil/login_cap.3
parent219e29595a8d293c1e81f0136a866f25a69d648e (diff)
downloadFreeBSD-src-67c40ef892e23a375a1eeec51d343ef6be31f5d8.zip
FreeBSD-src-67c40ef892e23a375a1eeec51d343ef6be31f5d8.tar.gz
Add working and easy crypt(3)-switching. Yes, we need a whole new API
for crypt(3) by now. In any case: Add crypt_set_format(3) + documentation to -lcrypt. Add login_setcryptfmt(3) + documentation to -lutil. Support for switching crypt formats in passwd(8). Support for switching crypt formats in pw(8). The simple synopsis is: edit login.conf; add a passwd_format field set to "des" or "md5"; go nuts :) Reviewed by: peter
Diffstat (limited to 'lib/libutil/login_cap.3')
-rw-r--r--lib/libutil/login_cap.322
1 files changed, 21 insertions, 1 deletions
diff --git a/lib/libutil/login_cap.3 b/lib/libutil/login_cap.3
index 44ccd64..4bdf54f 100644
--- a/lib/libutil/login_cap.3
+++ b/lib/libutil/login_cap.3
@@ -34,7 +34,8 @@
.Nm login_getclassbyname ,
.Nm login_getpwclass ,
.Nm login_getstyle ,
-.Nm login_getuserclass
+.Nm login_getuserclass ,
+.Nm login_setcryptfmt
.Nd functions for accessing the login class capabilities database.
.Sh LIBRARY
.Lb libutil
@@ -67,6 +68,8 @@
.Fn login_getcapbool "login_cap_t *lc" "const char *cap" "int def"
.Ft char *
.Fn login_getstyle "login_cap_t *lc" "char *style" "const char *auth"
+.Ft const char *
+.Fn login_setcryptfmt "login_cap_t *lc" "const char *def" "const char *error"
.Sh DESCRIPTION
These functions represent a programming interface to the login
classes database provided in
@@ -396,8 +399,25 @@ the authentication method used for access to the system via the
network, and standard methods via direct dialup or console
logins, significantly reducing the risk of password discovery
by "snooping" network packets.
+.It Fn login_setcryptfmt
+The
+.Fn login_setcryptfmt
+function is used to set the
+.Xr crypt 3
+format using the
+.Ql passwd_format
+configuration entry.
+If no entry is found,
+.Fa def
+is taken to be used as the fallback.
+If calling
+.Xr crypt_set_format 3
+on the specifier fails,
+.Fa error
+is returned to indicate this.
.El
.Sh SEE ALSO
+.Xr crypt 3 ,
.Xr getcap 3 ,
.Xr login_class 3 ,
.Xr login.conf 5 ,
OpenPOWER on IntegriCloud