diff options
author | Steve Langasek <vorlon@debian.org> | 2010-08-31 17:23:27 -0700 |
---|---|---|
committer | Steve Langasek <vorlon@debian.org> | 2019-01-08 21:47:21 -0800 |
commit | 6c6f451aff56e368041dd4076ad61d8f51635b7f (patch) | |
tree | ed1162733e6688167c56704ffbf4e63c602abf35 /modules/pam_unix/support.h | |
parent | 0b7e86d2422eb0ddabce5ffcd59ee31525a4e8af (diff) | |
parent | b70316c593cbc8e5c9155e5c6597497090c6eb88 (diff) | |
download | pam-6c6f451aff56e368041dd4076ad61d8f51635b7f.tar.gz pam-6c6f451aff56e368041dd4076ad61d8f51635b7f.tar.bz2 pam-6c6f451aff56e368041dd4076ad61d8f51635b7f.zip |
merge upstream version 1.1.2
Diffstat (limited to 'modules/pam_unix/support.h')
-rw-r--r-- | modules/pam_unix/support.h | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/modules/pam_unix/support.h b/modules/pam_unix/support.h index 7f0132eb..d02c8aee 100644 --- a/modules/pam_unix/support.h +++ b/modules/pam_unix/support.h @@ -1,5 +1,5 @@ /* - * $Id: support.h,v 1.17 2008/12/01 15:10:22 t8m Exp $ + * $Id: support.h,v 1.18 2010/08/17 11:15:33 kukuk Exp $ */ #ifndef _PAM_UNIX_SUPPORT_H @@ -86,11 +86,14 @@ typedef struct { * information during acct management */ #define UNIX_SHA256_PASS 23 /* new password hashes will use SHA256 */ #define UNIX_SHA512_PASS 24 /* new password hashes will use SHA512 */ -#define UNIX_ALGO_ROUNDS 25 /* optional number of rounds for new +#define UNIX_ALGO_ROUNDS 25 /* optional number of rounds for new password hash algorithms */ #define UNIX_BLOWFISH_PASS 26 /* new password hashes will use blowfish */ +#define UNIX_MIN_PASS_LEN 27 /* min length for password */ /* -------------- */ -#define UNIX_CTRLS_ 27 /* number of ctrl arguments defined */ +#define UNIX_CTRLS_ 28 /* number of ctrl arguments defined */ + +#define UNIX_DES_CRYPT(ctrl) (off(UNIX_MD5_PASS,ctrl)&&off(UNIX_BIGCRYPT,ctrl)&&off(UNIX_SHA256_PASS,ctrl)&&off(UNIX_SHA512_PASS,ctrl)&&off(UNIX_BLOWFISH_PASS,ctrl)) static const UNIX_Ctrls unix_args[UNIX_CTRLS_] = { @@ -124,6 +127,7 @@ static const UNIX_Ctrls unix_args[UNIX_CTRLS_] = /* UNIX_SHA512_PASS */ {"sha512", _ALL_ON_^(0260420000), 040000000}, /* UNIX_ALGO_ROUNDS */ {"rounds=", _ALL_ON_, 0100000000}, /* UNIX_BLOWFISH_PASS */ {"blowfish", _ALL_ON_^(0260420000), 0200000000}, +/* UNIX_MIN_PASS_LEN */ {"minlen=", _ALL_ON_, 0400000000}, }; #define UNIX_DEFAULTS (unix_args[UNIX__NONULL].flag) @@ -141,7 +145,7 @@ static const UNIX_Ctrls unix_args[UNIX_CTRLS_] = extern int _make_remark(pam_handle_t * pamh, unsigned int ctrl ,int type, const char *text); extern int _set_ctrl(pam_handle_t * pamh, int flags, int *remember, int *rounds, - int argc, const char **argv); + int *pass_min_len, int argc, const char **argv); extern int _unix_getpwnam (pam_handle_t *pamh, const char *name, int files, int nis, struct passwd **ret); |