void OnAuthenticateRequest(object sender, EventArgs args) { HttpApplication app = (HttpApplication)sender; BaseWorkerRequest req = J2EEUtils.GetWorkerRequest(app.Context); if (req.GetRemoteUser() != null) { app.Context.User = new ServletPrincipal(req); } }
internal ServletPrincipal(BaseWorkerRequest req) { _request = req; string authType = req.GetAuthType(); if (authType == null) { authType = String.Empty; } _identity = new GenericIdentity(req.GetRemoteUser(), authType); }
public string GetSessionID(HttpContext context) { BaseWorkerRequest request = J2EEUtils.GetWorkerRequest(context); return(request.IsRequestedSessionIdValid() ? request.GetRequestedSessionId() : null); }