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

Users #7

Open
purrplingcat opened this issue Dec 2, 2017 · 0 comments
Open

Users #7

purrplingcat opened this issue Dec 2, 2017 · 0 comments

Comments

@purrplingcat
Copy link
Contributor

purrplingcat commented Dec 2, 2017

Users

Users has following fields:

  • Login
  • Password
  • Email
  • Name
  • CreatedAt

The field CreatedAt is automatically generated on server side and can't be edited. It's contains a timestamp of user creation.

User registering

At first new user can be registered by register form (via REST call POST /users/register. New user registration can be disabled by administrator.

After registration user must activate account by link in email. After activation user is approved to login.

After login to Web-UI user can manage your profile or owned devices (create, update, delete).

User login

User login via login form in Web-UI (via rest call POST /auth issue #3). User must fill valid login and password to sucessfully login.

At backend server generates a token for user. One token = One session. User can be logged in more sessions (more tokens) instead of device. Device has only one session by one token.

User logout

User can logout by logout button in webui (via rest call DELETE /auth issue #3). At backend token has revoked (removed) and by this operation user was logged out.

Account activation

Before first login user must activate their account. If user not activated their account in 24 hours, then account was deleted. See issue #10

Authentication

Authentication is specified in issue #4

User roles

Service knowns 2 types of user roles:

  • admin
  • member

Admin can all operations in service. Member can manage owned devices, sensors, measure statistics and manage profile.

Profile management

User can manage your profile - Change password, change e-mail or name.


Related: #2 #4
Following:
Source:

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