changeset d80b226e7f77 in /srv/hg/libpwquality
details:
http://hg.fedorahosted.org/hg/srv/hg/libpwquality?cmd=changeset;node=d80b...
summary: Drop the difignore setting, it makes no sense.
diffstat:
src/pam_pwquality.c | 2 ++
src/pwqprivate.h | 15 ++++++---------
src/pwquality.h | 1 -
src/settings.c | 8 --------
4 files changed, 8 insertions(+), 18 deletions(-)
diffs (96 lines):
diff -r 12a9e626fadb -r d80b226e7f77 src/pam_pwquality.c
--- a/src/pam_pwquality.c Tue Nov 01 14:13:48 2011 +0100
+++ b/src/pam_pwquality.c Mon Nov 07 11:58:40 2011 +0100
@@ -79,6 +79,8 @@
opt->retry_times = strtol(*argv+6, &ep, 10);
if (!ep || (opt->retry_times < 1))
opt->retry_times = CO_RETRY_TIMES;
+ } else if (!strncmp(*argv, "difignore=", 10)) {
+ /* ignored for compatibility with pam_cracklib */
} else if (!strncmp(*argv, "reject_username", 15)) {
/* ignored for compatibility with pam_cracklib */
} else if (!strncmp(*argv, "authtok_type", 12)) {
diff -r 12a9e626fadb -r d80b226e7f77 src/pwqprivate.h
--- a/src/pwqprivate.h Tue Nov 01 14:13:48 2011 +0100
+++ b/src/pwqprivate.h Mon Nov 07 11:58:40 2011 +0100
@@ -14,16 +14,14 @@
struct pwquality_settings {
int diff_ok;
- int diff_ignore;
- int min_length;
- int dig_credit;
- int up_credit;
- int low_credit;
- int oth_credit;
+ int min_length;
+ int dig_credit;
+ int up_credit;
+ int low_credit;
+ int oth_credit;
int min_class;
- int max_repeat;
+ int max_repeat;
char *dict_path;
-
};
struct setting_mapping {
@@ -33,7 +31,6 @@
};
#define PWQ_DEFAULT_DIFF_OK 5
-#define PWQ_DEFAULT_DIFF_IGNORE 23
#define PWQ_DEFAULT_MIN_LENGTH 9
#define PWQ_DEFAULT_DIG_CREDIT 1
#define PWQ_DEFAULT_UP_CREDIT 1
diff -r 12a9e626fadb -r d80b226e7f77 src/pwquality.h
--- a/src/pwquality.h Tue Nov 01 14:13:48 2011 +0100
+++ b/src/pwquality.h Mon Nov 07 11:58:40 2011 +0100
@@ -11,7 +11,6 @@
#define PWQUALITY_H
#define PWQ_SETTING_DIFF_OK 1
-#define PWQ_SETTING_DIFF_IGNORE 2
#define PWQ_SETTING_MIN_LENGTH 3
#define PWQ_SETTING_DIG_CREDIT 4
#define PWQ_SETTING_UP_CREDIT 5
diff -r 12a9e626fadb -r d80b226e7f77 src/settings.c
--- a/src/settings.c Tue Nov 01 14:13:48 2011 +0100
+++ b/src/settings.c Mon Nov 07 11:58:40 2011 +0100
@@ -27,7 +27,6 @@
return NULL;
pwq->diff_ok = PWQ_DEFAULT_DIFF_OK;
- pwq->diff_ignore = PWQ_DEFAULT_DIFF_IGNORE;
pwq->min_length = PWQ_DEFAULT_MIN_LENGTH;
pwq->dig_credit = PWQ_DEFAULT_DIG_CREDIT;
pwq->up_credit = PWQ_DEFAULT_UP_CREDIT;
@@ -51,7 +50,6 @@
static const struct setting_mapping s_map[] = {
{ "difok", PWQ_SETTING_DIFF_OK, PWQ_TYPE_INT},
- { "difignore", PWQ_SETTING_DIFF_IGNORE, PWQ_TYPE_INT},
{ "minlen", PWQ_SETTING_MIN_LENGTH, PWQ_TYPE_INT},
{ "dcredit", PWQ_SETTING_DIG_CREDIT, PWQ_TYPE_INT},
{ "ucredit", PWQ_SETTING_UP_CREDIT, PWQ_TYPE_INT},
@@ -209,9 +207,6 @@
case PWQ_SETTING_DIFF_OK:
pwq->diff_ok = value;
break;
- case PWQ_SETTING_DIFF_IGNORE:
- pwq->diff_ignore = value;
- break;
case PWQ_SETTING_MIN_LENGTH:
if (value < PWQ_BASE_MIN_LENGTH)
value = PWQ_BASE_MIN_LENGTH;
@@ -278,9 +273,6 @@
case PWQ_SETTING_DIFF_OK:
*value = pwq->diff_ok;
break;
- case PWQ_SETTING_DIFF_IGNORE:
- *value = pwq->diff_ignore;
- break;
case PWQ_SETTING_MIN_LENGTH:
*value = pwq->min_length;
break;