Making the AntiForgeryAuthorizationFilter validate when an ValidateAntiForgeryTokenOrchardAttribute is present.

--HG--
branch : dev
This commit is contained in:
Nathan Heskew
2010-02-16 15:46:01 -08:00
parent 7d543e14d3
commit 3aa158510d

View File

@@ -45,9 +45,9 @@ namespace Orchard.Mvc.Filters {
if (!string.IsNullOrEmpty(request.QueryString[tokenFieldName])) {
context.HttpContext = new HackHttpContext(context.HttpContext, (HttpContext)context.HttpContext.Items["originalHttpContext"]);
((HackHttpRequest)context.HttpContext.Request).AddFormValue(tokenFieldName, context.HttpContext.Request.QueryString[tokenFieldName]);
return true;
}
return true;
}
return false;