package ez_api
Install
dune-project
Dependency
Authors
Maintainers
Sources
md5=9069f59ac83c958cedc90a25f24faa1e
sha512=4b066a759043e6704a9617bdc412d29f7ded058cb0e01eb3a8207f54b80bebb478bb98a96832e61b15d281bc8f132e1386459c563eb807a51c01324541fe28b2
doc/ez_api.server_session/EzSessionServer/UserStoreInMemory/index.html
Module EzSessionServer.UserStoreInMemorySource
User storage located in the memory of the server.
Parameters
module S : EzSession.TYPES.SessionArg with type user_id = stringSignature
val create_user :
?pwhash:Digest.t ->
?password:string ->
?kind:string ->
login:string ->
S.user_info ->
unit Lwt.tCreates user and adds it to users. If kind is specified, than creates user without password (foreign user). User id corresponds to login. Hash password if pwhash is not specified. Raises UserAlreadyDefined if a user with the same login already exists. Raises NoPasswordProvided if no pwhash or password was specified for a local (non foreign) user.
Removes user with the given login from the storage
Searches for user with given login and returns its password, if defined, its id and its information.
val check_foreign :
origin:string ->
token:string ->
(string, int * string option) result Lwt.tChecks for foreign user with the login origin-token. If exists, returns its login. Otherwise returns an error number with an error message.
val register_foreign :
origin:string ->
token:string ->
(S.user_id * S.user_info option, int * string option) result Lwt.tSee default_register_foreign (not implemented yet).
module SessionArg :
EzSession.TYPES.SessionArg
with type user_info = S.user_info
and type user_id = S.user_idSee EzSession.TYPES.SessionArg
See SessionStore