R
Randy
I have a URL Rewriting class that implements the IRules interface.
Everything works fine until my code accesses the HttpContext via the
HttpApplication.Context property.
I'm trying to pass a string from the global.asax BeginRequest event to my
url rewriter by placing it on the Context.Cache.
However, as soon as I add code to access the context, i get a
SecurityException of type AspNetHostingPermission
here is my httpModule code:
public string Execute(HttpApplication appl, string _path, string
settingsSection)
{
string tabUrlKeyword = appl.Context.Items["urlKeyword"].ToString();
Here is the exception
SecurityException: Request for the permission of type
System.Web.AspNetHostingPermission, System, Version=1.0.5000.0,
Culture=neutral, PublicKeyToken=b77a5c561934e089 failed.]
I've tried explicitly the trust level but that doesn't help either.
<trust level="Full" originUrl=""/>
Everything works fine until my code accesses the HttpContext via the
HttpApplication.Context property.
I'm trying to pass a string from the global.asax BeginRequest event to my
url rewriter by placing it on the Context.Cache.
However, as soon as I add code to access the context, i get a
SecurityException of type AspNetHostingPermission
here is my httpModule code:
public string Execute(HttpApplication appl, string _path, string
settingsSection)
{
string tabUrlKeyword = appl.Context.Items["urlKeyword"].ToString();
Here is the exception
SecurityException: Request for the permission of type
System.Web.AspNetHostingPermission, System, Version=1.0.5000.0,
Culture=neutral, PublicKeyToken=b77a5c561934e089 failed.]
I've tried explicitly the trust level but that doesn't help either.
<trust level="Full" originUrl=""/>