This allows for a direct access to database and it’s contents.
Init obj.
Add a new customer to the database
Delete a customer from database, bringing along all it’s machines and services
Get a single customer’s data
Put a single customer’s data back to the Vault
Add a new group the database. Nothing will be added to it by default
Add a service to a group.
Call servie_get() first to get the information and decrypt the symkey on your side, then call this function to store the symkey.
The server-side Vault will encrypt it for the given group.
Add a user to a group. Call once to retrieve information, and a second time with cryptgroupkey to save cipher information.
The second call should give the group’s privkey, encrypted by the remote user for the user being added.
is_admin - Gives admin privileges to the user being added or not. user - User can be a username or a user_id
Remove a group from the vault. Only if no services are associated with it anymore.
:force_delete deletes a group even if it has services associated
Remove the association between a group and a service, simply.
Remove the association between a group and a user.
Make sure there are still ‘is_admin’ users associated with the group to be able to give access to someone else in case of need.
SFLvault will refuse to delete a user from a group if no other users are part of that group, and if the group still has some services associated with it. First, call group_del_service from the group for all services, then delete the users, and then the group.
user - can be a username or a user_id
Get a single group’s data
Return a simple list of the available groups
Put a single group’s data back to the Vault
Add a new machine to the database
Delete a machine from database, bringing on all child services.
Get a single machine’s data
Return a simple list of the machines
Do the search, and return the result tree.
Delete a service, making sure no other child remains attached.
Get a single service’s data.
group_id - return this group’s key, otherwise, use first available
Get a service tree, starting with service_id
Change the passwd for a given service
Put a single service’s data back to the vault’s database
Get the specified service ID and return the hierarchy to connect to it or to show it.
We need self.myself_id to be set for this function.
Return a simple list of the users
groups - return the list of groups for each user, or not
Setup the user’s account