Hi!
I need to redirect the service request which requires authentication, I have obtained and retained “ss-id” but for some reason the request fails.
Please tell me what am I doing wrong.
Additional question: how to redirect POST requests?
Thanks.
public object Get(Files request) {
var session = SessionAs<MyAuthUserSession>();
var httpResult = new HttpResult();
httpResult.StatusCode = HttpStatusCode.Found;
httpResult.Headers.Add(HttpHeaders.Location, host + Request.PathInfo);
httpResult.Cookies.Add(new Cookie("ss-id", session.sessionCookieValue, host));
return httpResult;
}
That shows an example of the different session cookies you need to add, adding them on the QueryString wont do anything unless Config.AllowSessionIdsInHttpParams = true. By default you’d need to add them as Cookies.