Skip to content
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

Allow generic restrictions upon credentials #35

Open
therealbstern opened this issue Feb 13, 2018 · 2 comments
Open

Allow generic restrictions upon credentials #35

therealbstern opened this issue Feb 13, 2018 · 2 comments

Comments

@therealbstern
Copy link
Collaborator

therealbstern commented Feb 13, 2018

This is a superset of #33 (make usernames more restrictive). The premise is that we want to tell the Authenticator that passwords (or usernames, or X.509 certificates, or ...) need to have certain criteria before they can be accepted.

The trivial way to do this is to implement a trait where the default implementation is to accept the value, and it can be overridden with an implementation that knows better.

@therealbstern
Copy link
Collaborator Author

Ideally, the Username should have a trait associated with each store type and presumably a method to convert usernames between backing store types.

@therealbstern
Copy link
Collaborator Author

I would like to fluff and fold so that we could provide overlapping sets of traits, maybe a Vec of rules that must be satisfied, and the library enumerates them, but the lower-hanging fruit is to allow the consumer of the library to implement the trait in whole cloth.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant