2.4.
CLASS: SESSION
CHAPTER 2.
API REFERENCE
2.4
Class: session
2.4.1
Fields for class: session
Name
session
Description
A session.
Quals
Field
Type
Description
RO
run
uuid
string
unique identifier/object reference
RO
run
this host
host ref
Currently connected host
RO
run
this user
user ref
Currently connected user
RO
run
last active
datetime
Timestamp for last time session was
active
RO
run
pool
bool
True if this session relates to a intra-
pool login, false otherwise
RW
other config
(string
→
string) Map
additional configuration
2.4.2
RPCs associated with class: session
RPC name: login with password
Overview:
Attempt to authenticate the user, returning a session reference if successful.
Signature:
(session ref) login_with_password (string uname, string pwd, string version)
Arguments:
type
name
description
string
uname
Username for login.
string
pwd
Password for login.
string
version
Client API version.
Return Type:
session ref
reference of newly created session
Possible Error Codes:
SESSION AUTHENTICATION FAILED
RPC name: logout
Overview:
Log out of a session.
Signature:
void logout (session_id s)
Return Type:
void
RPC name: change password
Overview:
Change the account password; if your session is authenticated with root priviledges then the
old pwd is validated and the new pwd is set regardless.
Signature:
21