public static interface SystemAuthenticationControl.ScriptBuilder
Each method call on the builder adds a line to the script and then the
script may be built using the script
method which produces a String script which may be sent to the server
using updateStore
.
Such a builder may be created using the
scriptBuilder
method.
From Diffusion 6.5, script builders are no longer immutable. Each builder operation mutates this script builder and returns it.
Modifier and Type | Method and Description |
---|---|
SystemAuthenticationControl.ScriptBuilder |
abstainAnonymousConnections()
Instruct the system authentication handler to defer authentication
decisions for anonymous connections to subsequent handlers.
|
SystemAuthenticationControl.ScriptBuilder |
addPrincipal(String name,
String password,
Set<String> roles)
Add a new principal.
|
SystemAuthenticationControl.ScriptBuilder |
addPrincipal(String name,
String password,
Set<String> roles,
String lockingPrincipal)
Add a new locked principal.
|
SystemAuthenticationControl.ScriptBuilder |
allowAnonymousConnections(Set<String> roles)
Instruct the system authentication handler to allow anonymous
connections.
|
SystemAuthenticationControl.ScriptBuilder |
append(SystemAuthenticationControl.ScriptBuilder other)
Append all the operations of
other to this ScriptBuilder. |
SystemAuthenticationControl.ScriptBuilder |
assignRoles(String principal,
Set<String> roles)
Change a principal's assigned roles.
|
SystemAuthenticationControl.ScriptBuilder |
denyAnonymousConnections()
Instruct the system authentication handler to deny anonymous
connections.
|
SystemAuthenticationControl.ScriptBuilder |
ignoreClientProposedProperty(String propertyName)
Specifies the name of a client proposed session property that should
now be ignored by the system authenticator.
|
SystemAuthenticationControl.ScriptBuilder |
removePrincipal(String principal)
Remove a principal.
|
String |
script()
Create a script.
|
SystemAuthenticationControl.ScriptBuilder |
setPassword(String principal,
String password)
Set a principal's password.
|
SystemAuthenticationControl.ScriptBuilder |
trustClientProposedPropertyIn(String propertyName,
Set<String> allowedValues)
Specifies the name of a client proposed session property that should
be allowed by the system authenticator along with a set of
permissible values.
|
SystemAuthenticationControl.ScriptBuilder |
trustClientProposedPropertyMatches(String propertyName,
String regex)
Specifies the name of a client proposed session property that should
be allowed by the system authenticator along with a regular
expression to validate the property value.
|
SystemAuthenticationControl.ScriptBuilder |
verifyPassword(String principal,
String password)
Assert that a principal's password is
password . |
SystemAuthenticationControl.ScriptBuilder addPrincipal(String name, String password, Set<String> roles)
The script will fail if the principal is already defined at the server.
name
- principal namepassword
- passwordroles
- assigned roles, may be emptySystemAuthenticationControl.ScriptBuilder addPrincipal(String name, String password, Set<String> roles, String lockingPrincipal)
A locked principal can only be edited by the principal defined in the lock. The script will fail if the principal is already defined at the server.
name
- principal namepassword
- passwordroles
- assigned roles, may be emptylockingPrincipal
- the name of the principal that can edit this
principalSystemAuthenticationControl.ScriptBuilder setPassword(String principal, String password)
The principal must already be defined at the server in order to set the password.
principal
- principal namepassword
- passwordSystemAuthenticationControl.ScriptBuilder verifyPassword(String principal, String password)
password
.
This command does not update the store. It can be used in conjunction
with setPassword
to create a
script that updates a password only if the previous password is
supplied.
principal
- principal namepassword
- passwordSystemAuthenticationControl.ScriptBuilder assignRoles(String principal, Set<String> roles)
The specified principal must already be defined at the server.
principal
- principal nameroles
- assigned rolesSystemAuthenticationControl.ScriptBuilder removePrincipal(String principal)
The principal must be one that is already defined at the server.
principal
- principal nameSystemAuthenticationControl.ScriptBuilder allowAnonymousConnections(Set<String> roles)
roles
- roles to assign to anonymous sessions. This may be emptySystemAuthenticationControl.ScriptBuilder denyAnonymousConnections()
SystemAuthenticationControl.ScriptBuilder abstainAnonymousConnections()
SystemAuthenticationControl.ScriptBuilder trustClientProposedPropertyIn(String propertyName, Set<String> allowedValues)
propertyName
- specifies the name of the client proposed
property to be allowedallowedValues
- specifies a set of allowed values for the client
proposed propertySystemAuthenticationControl.ScriptBuilder trustClientProposedPropertyMatches(String propertyName, String regex)
propertyName
- specifies the name of the client proposed
property to be allowedregex
-
regular expression which will be matched against supplied
values to determine whether they are validSystemAuthenticationControl.ScriptBuilder ignoreClientProposedProperty(String propertyName)
This removes the effect of a previous request to trust the named
property using trustClientProposedPropertyIn(java.lang.String, java.util.Set<java.lang.String>)
or
trustClientProposedPropertyMatches(java.lang.String, java.lang.String)
.
propertyName
- specifies the name of the client proposed
property to be ignoredSystemAuthenticationControl.ScriptBuilder append(SystemAuthenticationControl.ScriptBuilder other)
other
to this ScriptBuilder.String script()
Copyright © 2024 DiffusionData Ltd. All Rights Reserved.