Interface IAuthenticationControl
The authentication control feature that allows a client session to authenticate the credentials of other sessions.
Inherited Members
Namespace: PushTechnology.ClientInterface.Client.Features.Control.Clients
Assembly: Diffusion.Client.dll
Syntax
public interface IAuthenticationControl : IFeature
Remarks
Access control
In order to register an authentication handler a session needs both REGISTER_HANDLER and AUTHENTICATE permissions.
Accessing the feature
This feature may be obtained from a ISession with the AuthenticationControl property.
Methods
SetAuthenticationHandlerAsync(String, IControlAuthenticator)
Registers an authentication handler for client authentication events.
Declaration
Task<IRegistration> SetAuthenticationHandlerAsync(string handlerName, IControlAuthenticator authenticator)
Parameters
Type | Name | Description |
---|---|---|
String | handlerName | The handler name which must match an entry in the server's security configuration. |
IControlAuthenticator | authenticator | The authentication handler. |
Returns
Type | Description |
---|---|
Task<IRegistration> | The |
Remarks
If the task completes successfully, the Task
result will be IRegistration
which can be used to unregister the authentication handler.
Exceptions
Type | Condition |
---|---|
SessionException | The server configuration does not contain a |
SessionSecurityException | The calling session does not have the REGISTER_HANDLER or
AUTHENTICATE permission. Thrown by the returned |
SessionClosedException | The session is closed. Thrown by the returned |
SetAuthenticationHandlerAsync(String, IControlAuthenticator, CancellationToken)
Registers an authentication handler for client authentication events.
Declaration
Task<IRegistration> SetAuthenticationHandlerAsync(string handlerName, IControlAuthenticator authenticator, CancellationToken cancellationToken)
Parameters
Type | Name | Description |
---|---|---|
String | handlerName | The handler name which must match an entry in the server's security configuration. |
IControlAuthenticator | authenticator | The authentication handler. |
CancellationToken | cancellationToken | The cancellation token used to cancel the current operation. |
Returns
Type | Description |
---|---|
Task<IRegistration> | The |
Remarks
If the task completes successfully, the Task
result will be IRegistration
which can be used to unregister the authentication handler.
Exceptions
Type | Condition |
---|---|
SessionException | The server configuration does not contain a |
SessionSecurityException | The calling session does not have the REGISTER_HANDLER or
AUTHENTICATE permission. Thrown by the returned |
SessionClosedException | The session is closed. Thrown by the returned |