bumblebeeC / subtext

Automatically exported from code.google.com/p/subtext
0 stars 0 forks source link

Medium Trust Issues - Trunk #292

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1.Navigate to Feedback in admin area (several pages produce this).
2.
3.

What is the expected output? What do you see instead?
See comments

Output:

Inheritance security rules violated by type: 
'Subtext.Web.Controls.PagerDesigner'. Derived types must either match the 
security accessibility of the base type or be less accessible.

Original issue reported on code.google.com by Simon.JPhilp on 25 Jan 2011 at 10:20

GoogleCodeExporter commented 8 years ago
Try setting <trust level="Medium" originUrl=".*" legacyCasModel="true" />

Notice the legacyCasModel.

Original comment by haac...@gmail.com on 16 May 2011 at 5:53

GoogleCodeExporter commented 8 years ago
Fixed in r4199

Original comment by haac...@gmail.com on 16 May 2011 at 10:02

GoogleCodeExporter commented 8 years ago
I believe this is related - in 2.5.2.0 when you access the Identicon handler 
with a path like /images/services/IdenticonHandler.ashx?code=180207287 I get a 
security exception from Ninject that appears to be a Medium trust issue.

System.MethodAccessException: 
System.Configuration.KeyValueInternalCollection..ctor(System.Configuration.AppSe
ttingsSection) ---> System.Security.SecurityException: Request failed.
   at System.Security.CodeAccessSecurityEngine.ThrowSecurityException(Assembly asm, PermissionSet granted, PermissionSet refused, RuntimeMethodHandle rmh, SecurityAction action, Object demand, IPermission permThatFailed)
   at System.Security.CodeAccessSecurityEngine.ThrowSecurityException(Object assemblyOrString, PermissionSet granted, PermissionSet refused, RuntimeMethodHandle rmh, SecurityAction action, Object demand, IPermission permThatFailed)
   at System.Security.CodeAccessSecurityEngine.CheckSetHelper(PermissionSet grants, PermissionSet refused, PermissionSet demands, RuntimeMethodHandle rmh, Object assemblyOrString, SecurityAction action, Boolean throwException)
   at System.Security.PermissionSetTriple.CheckSetDemand(PermissionSet demandSet, PermissionSet& alteredDemandset, RuntimeMethodHandle rmh)
   at System.Security.PermissionListSet.CheckSetDemand(PermissionSet pset, RuntimeMethodHandle rmh)
   at System.Security.PermissionListSet.DemandFlagsOrGrantSet(Int32 flags, PermissionSet grantSet)
   at System.Threading.CompressedStack.DemandFlagsOrGrantSet(Int32 flags, PermissionSet grantSet)
   at System.Security.CodeAccessSecurityEngine.ReflectionTargetDemandHelper(Int32 permission, PermissionSet targetGrant, CompressedStack securityContext)
   at System.Security.CodeAccessSecurityEngine.ReflectionTargetDemandHelper(Int32 permission, PermissionSet targetGrant, Resolver accessContext)
The action that failed was:
Demand
The type of the first permission that failed was:
System.Security.PermissionSet
   --- End of inner exception stack trace ---
   at System.Runtime.CompilerServices.RuntimeHelpers._CompileMethod(IntPtr method)
   at System.Reflection.Emit.DynamicMethod.CreateDelegate(Type delegateType)
   at Ninject.Injection.DynamicMethodInjectorFactory.Create(ConstructorInfo constructor)
   at Ninject.Planning.Strategies.ConstructorReflectionStrategy.Execute(IPlan plan)
   at Ninject.Planning.Planner.<>c__DisplayClass1.<getplan>b__0(IPlanningStrategy s)
   at Ninject.Infrastructure.Language.ExtensionsForIEnumerableOfT.Map[T](IEnumerable`1 series, Action`1 action)
   at Ninject.Planning.Planner.GetPlan(Type type)
   at Ninject.Activation.Context.Resolve()
   at Ninject.KernelBase.<resolve>b__4(IContext context)
   at System.Linq.Enumerable.<>c__DisplayClass12`3.<combineselectors>b__11(TSource x)
   at System.Linq.Enumerable.WhereSelectEnumerableIterator`2.MoveNext()
   at System.Linq.Enumerable.FirstOrDefault[TSource](IEnumerable`1 source)
   at Ninject.Planning.Targets.Target`1.Resolve

Original comment by travis.illig on 2 Aug 2011 at 7:29

GoogleCodeExporter commented 8 years ago
It turns out that Gravatar has support for Identicons. Just add the 
&default=identicon query string parameter to the Gravatar format. I'll make 
this change and we can remove our Identicon support.

Original comment by haac...@gmail.com on 19 Nov 2011 at 11:21

GoogleCodeExporter commented 8 years ago
Fixed in r4237

Original comment by haac...@gmail.com on 20 Nov 2011 at 5:15