Serverside Account Configuration
For a better user experience and less maintenance effort, the possibility to distribute settings for one or more users via a webservice directly to a client is necessary. Not only does this offer the opportunity to share settings efficiently, but also to minimize the possibility of missbehavior due to wrong settings.
Further does this mean that a user does have his environment, even when using a different device without the overhead of creating a fitting setting configuration and typing in all settings by hand.
Contents
Configure the serverside account configuration on the client
There is a default URL under which the app calls the webservice, but it can be freely configured with a file named "source.conf" under the location SD_CARD/UBIK/. It must be considered, that this file overrides the default URL for sure, which means that an empty file will be interpreted as empty URL. If the standard URL should be used, this file should be deleted!
Account Restriction
The account restriction is defined for the whole account configuration. Basically spoken, this flag within the received account configuration decides about whether the users can type in usernames freely or just choose between a list of usernames. Due to that, this feature is really scalable and is sufficient for use cases from defining every user and force them to use specific settings to just provide PreSets for an open range of users.
Accounts restricted
If the account restriction is "restricted", the login dialog provides a dropdown selection which contains all available usernames, delivered through the account configuration. There is no possibility to enter a different username.
Accounts not restricted
In that case, the login dialog looks like if no account configuration was received at all. The only difference is for users who´s settings are restricted. Once such a user enters his username, the UI behave like described in section [Restricted Restricted].
Setting Restriction Level
The setting restriction level is a flag within every account within the account configuration. It handles, how much influence the user has on his settings.
Restricted
A settings restricted user has only very limited options to change his settings. No matter what settings are loaded or set before the login, they are always set to his standard settings when logging in. The only exception are the accounts shared PreSets as well as the "global" shared PreSets, defined in the account configuration. The restricted user has access to them, load them and after logging out and logging in again, they are restored as it would be the case for an open user. Further, a restricted user is neither able to access local PreSets nor to save them.
Open
Open users do not have any restriction regarding what settings they can access, change or save. The only difference to the case that no account configuration was received and described at [Login_Dialog login dialog], is that open users have access to the shared PreSets that are stored in the account configuration.
Shared PreSet is a new term for presets provided through an account configuration. They can be defined "globally" for every account or per account. This presets should not be mistaken by the "setting configuration" for every account, which is the basic preset for every account and the standard preset that is loaded when [Restricted restricted] users attempt to login.
Receive a new configuration
The application tries to fetch a account configuration every time the app starts. A fetched account configuration is always stored locally, which means that it is available directly upon the next start of the app. The user is notified either when a new configuration is received, or when the server is not reachable.
The case that a new configuration is received does only occur when the fetched configuration is different to the locally stored account configuration, or there is no configuration stored locally. In case that a user is already authenticated, the existing configuration remains valid until the user loggs out or the app is shut down.
The case that the server is not reachable does normally occur, when the configured URL is erroneous.
See also
[Login_Dialog Login dialog] [PreSet PreSets]