authenticate_sync
Description:
public virtual AuthenticationResult authenticate_sync (string? mechanism, Cancellable? cancellable = null) throws Error
Attempts to authenticate this using mechanism
and, if necessary, this
's password property.
The function makes only ONE attempt at authentication and does not loop.
If the authentication attempt completed and the server accepted the credentials, the function returns ACCEPTED.
If the authentication attempt completed but the server rejected the credentials, the function returns REJECTED.
If the authentication attempt failed to complete due to a network communication issue or some other mishap, the function sets throws and returns ERROR.
Generally this function should only be called from a Session subclass in order to implement its own authentication loop.
Parameters:
this |
a Service |
mechanism |
a SASL mechanism name, or null |
cancellable |
optional Cancellable object, or null |
Returns:
the authentication result |