Struct lockchain_core::users::User[][src]

pub struct User { /* fields omitted */ }

A generic user representation

A user has an identify check built in that can verify a passphrase but is ultimately only a metadata item for a API layer. Any layer is free to disregard these access rights (as such, they should not be considered security, only obscurity/ management control)

A company might not want allow non-admins to create new vaults or users to delete records. This does not cryptographically stop anyone from breaking into the company server, swapping the source code and changing the rules!

An user can have multiple role-access pairs

Methods

impl User
[src]

Register a new user with a name and password

Verify a user password input

Generate a token unique to this user (or return the existing one)

Verify that a user is allowed access to a piece of data

None means "no access of any kind"

Modify access to an item for a role or create a new access entry

Trait Implementations

impl Clone for User
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl AutoEncoder for User
[src]

Auto Trait Implementations

impl Send for User

impl Sync for User