diff options
author | Steve Langasek <steve.langasek@ubuntu.com> | 2019-01-03 19:37:21 -0800 |
---|---|---|
committer | Steve Langasek <steve.langasek@ubuntu.com> | 2019-01-03 19:39:33 -0800 |
commit | b70316c593cbc8e5c9155e5c6597497090c6eb88 (patch) | |
tree | 389accb2f8d3f4830933235f54059df6d8f51132 /modules/pam_unix/support.h | |
parent | aa0448336a79d85579464f023ac87675be60abfc (diff) | |
parent | 08e55be772e8dabf62dc21010751a80ed905f750 (diff) | |
download | pam-b70316c593cbc8e5c9155e5c6597497090c6eb88.tar.gz pam-b70316c593cbc8e5c9155e5c6597497090c6eb88.tar.bz2 pam-b70316c593cbc8e5c9155e5c6597497090c6eb88.zip |
New 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); |