IAuthEvents
Assembly: ServiceStack.dll
View Source
Declaration
public interface IAuthEvents
Methods
OnCreated(IRequest, IAuthSession)
Fired when a new Session is created
View Source
Declaration
void OnCreated(IRequest httpReq, IAuthSession session)
Parameters
Type | Name |
---|---|
ServiceStack.Web.IRequest | httpReq |
ServiceStack.Auth.IAuthSession | session |
OnRegistered(IRequest, IAuthSession, IServiceBase)
Called when the user is registered or on the first OAuth login
View Source
Declaration
void OnRegistered(IRequest httpReq, IAuthSession session, IServiceBase registrationService)
Parameters
Type | Name |
---|---|
ServiceStack.Web.IRequest | httpReq |
ServiceStack.Auth.IAuthSession | session |
ServiceStack.IServiceBase | registrationService |
Validate(IServiceBase, IAuthSession, IAuthTokens, Dictionary<String, String>)
Override with Custom Validation logic to Assert if User is allowed to Authenticate. Returning a non-null response invalidates Authentication with IHttpResult response returned to client.
View Source
Declaration
IHttpResult Validate(IServiceBase authService, IAuthSession session, IAuthTokens tokens, Dictionary<string, string> authInfo)
Returns
Parameters
Type | Name |
---|---|
ServiceStack.IServiceBase | authService |
ServiceStack.Auth.IAuthSession | session |
ServiceStack.Auth.IAuthTokens | tokens |
System.Collections.Generic.Dictionary<System.String,System.String> | authInfo |
OnAuthenticated(IRequest, IAuthSession, IServiceBase, IAuthTokens, Dictionary<String, String>)
Called after the user has successfully authenticated
View Source
Declaration
void OnAuthenticated(IRequest httpReq, IAuthSession session, IServiceBase authService, IAuthTokens tokens, Dictionary<string, string> authInfo)
Parameters
Type | Name |
---|---|
ServiceStack.Web.IRequest | httpReq |
ServiceStack.Auth.IAuthSession | session |
ServiceStack.IServiceBase | authService |
ServiceStack.Auth.IAuthTokens | tokens |
System.Collections.Generic.Dictionary<System.String,System.String> | authInfo |
OnLogout(IRequest, IAuthSession, IServiceBase)
Fired before the session is removed after the /auth/logout Service is called
View Source
Declaration
void OnLogout(IRequest httpReq, IAuthSession session, IServiceBase authService)
Parameters
Type | Name |
---|---|
ServiceStack.Web.IRequest | httpReq |
ServiceStack.Auth.IAuthSession | session |
ServiceStack.IServiceBase | authService |