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

Name to contain only characters [a-zA-Z]+ #245

Open
AnshitaVishwa opened this issue Oct 25, 2019 · 3 comments
Open

Name to contain only characters [a-zA-Z]+ #245

AnshitaVishwa opened this issue Oct 25, 2019 · 3 comments

Comments

@AnshitaVishwa
Copy link

In the plugin "users", The Name of the User should not contain any number or special characters, but it is accepting this format, during create user form and update name.
I would like to work on this issue.
Screenshot from 2019-10-25 15-40-19

@td512
Copy link
Contributor

td512 commented Oct 25, 2019

I'm not entirely sure that's correct. the GECOS fields don't discriminate. The username definitely shouldn't contain special characters, but that should also yield to the rules of the system, those mainly being:

  • A username should consist of lowercase alphanumeric characters
  • A username must not contain special characters EXCEPT for _, but never at the start or end
  • A username must not start with a number

Aside from that, there's not really any limits on what the username may contain. The default regex for it is ^[a-z][-a-z0-9]*\$.

Bear in mind that's only if Amahi creates system accounts, and not just virtual users; i.e. real users that can log in to the host, rather than just to the dashboard. If it only creates virtual users, then there's no reason to discriminate at all

@AnshitaVishwa
Copy link
Author

@td512 I agree to the rules for the username that you have told. Could you please help me out explaining the concept of real users and virtual users that you have explained in the last paragraph of your comment. Thanks!!

@td512
Copy link
Contributor

td512 commented Nov 3, 2019

@AnshitaVishwa a virtual user is one that only exists in a database, if it's a real user then you can use it to SSH or locally login to the system

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

No branches or pull requests

2 participants