-
-
Notifications
You must be signed in to change notification settings - Fork 207
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
name is not a property of the Entity user #124
Comments
“name” used to hold a user’s actual name and was removed to make space for developers extending the database with their own fields. This is just a legacy reference that I missed and can probably be removed. |
I figured it was something like that. Thanks. |
It does provide an additional layer of protecting a user from themselves, though, and using common fields. We could always make a configuration that allows the developers to specify one or more fields that should be checked against. What do you guys think? |
I think the idea of preventing password leaking by way of username or email is really important. It would be nice if, for instance, a developer added name field(s) to the entity to be able to keep that data out of the password. But allowing for and checking against ad hoc fields feels... daunting... maybe... or maybe not. I'll have to think about that. I have been thinking that the "no personal info" check should be in a Validator of its own instead of being part of the Here's where I'm at with
|
@dafriend I think you're right that it should be a separate validator. I think what you've shown here is a pretty good solution to it, too. Now - if we can add ad-hoc fields that would be awesome :) I would think it would be too difficult. A config file holds the column names that should be checked against ( in addition to the ones you've already got). Loop over them and check their value against the password. |
I'm making good progress on this. Integrating ad-hoc fields proved to be pretty easy. During testing, I came across some situations that may or may not be edge cases. For instance, One solution might be using I've done some testing and it works pretty well. It even finds anagrams objectionable in most cases using a break-point of 66. What do you guys think? |
DictionaryValidator uses the following to check for personal information in the password
The problem is that, as far as I can determine, the Entity used in myth/auth does not have a
name
property. Should they all be$user->username
?I have been thinking of offering a PR on this functionality anyway and, if
$user->name
needs fixing I can fix it there.The text was updated successfully, but these errors were encountered: