Hello,
I’ve configured the authentication in this way
var authFeature = new AuthFeature(
() => new MyAuthUserSession(),
new[]
{
new AspNetWindowsAuthProvider(this) { AllowAllWindowsAuthUsers = false }
}
);
authFeature.AuthEvents.Add(new MyAuthEvents());
and so the MyAuthEvents class looks like
public class MyAuthEvents : IAuthEvents
{
public void OnAuthenticated(IRequest httpReq, IAuthSession session, IServiceBase authService, IAuthTokens tokens, Dictionary<string, string> authInfo)
{
// …
}
}
I saw that the OnAuthenticated method is called on every HTTP Request and not only on the first attempt to authenticate (I suppose because the AspNetWindowsAuthProviders implements IAuthWithRequest).
For every new session, how can I intercept the first authentication request ?
Thanks