diff options
author | vodz <vodz@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2006-01-31 12:36:51 +0000 |
---|---|---|
committer | vodz <vodz@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2006-01-31 12:36:51 +0000 |
commit | 35b0a0bf241a15eebf9296834e91505f22385991 (patch) | |
tree | 084b81121af050e2b81f3a65496bd2f9945711d0 /libbb | |
parent | ffbbd864b7914e8dc1e72c5bbd9f4f9cedad2f7b (diff) | |
download | busybox-w32-35b0a0bf241a15eebf9296834e91505f22385991.tar.gz busybox-w32-35b0a0bf241a15eebf9296834e91505f22385991.tar.bz2 busybox-w32-35b0a0bf241a15eebf9296834e91505f22385991.zip |
more obscure
git-svn-id: svn://busybox.net/trunk/busybox@13758 69ca8d6d-28ef-0310-b511-8ec308f3f277
Diffstat (limited to 'libbb')
-rw-r--r-- | libbb/obscure.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/libbb/obscure.c b/libbb/obscure.c index 18373510f..8df3e7504 100644 --- a/libbb/obscure.c +++ b/libbb/obscure.c | |||
@@ -162,6 +162,9 @@ password_check(const char *old, const char *newval, const struct passwd *pwdp) | |||
162 | else if (similiar(wrapped, newmono)) | 162 | else if (similiar(wrapped, newmono)) |
163 | msg = "too similiar"; | 163 | msg = "too similiar"; |
164 | 164 | ||
165 | else if ( strstr(newval, pwdp->pw_name) ) | ||
166 | msg = "don't use something like your username as password"; | ||
167 | |||
165 | else { | 168 | else { |
166 | safe_strncpy(wrapped + lenwrap, wrapped, lenwrap + 1); | 169 | safe_strncpy(wrapped + lenwrap, wrapped, lenwrap + 1); |
167 | if (strstr(wrapped, newmono)) | 170 | if (strstr(wrapped, newmono)) |
@@ -186,7 +189,7 @@ obscure_msg(const char *old, const char *newval, const struct passwd *pwdp) | |||
186 | oldlen = strlen(old); | 189 | oldlen = strlen(old); |
187 | newlen = strlen(newval); | 190 | newlen = strlen(newval); |
188 | 191 | ||
189 | #if 0 /* why not check the password when set for the first time? --marekm */ | 192 | #if 0 /* why not check the password when set for the first time? --marekm */ |
190 | if (old[0] == '\0') | 193 | if (old[0] == '\0') |
191 | /* return (1); */ | 194 | /* return (1); */ |
192 | return NULL; | 195 | return NULL; |