When an ASP.NET 4.0 web application that uses the AJAX ScriptManager receives its first request, the following exception may occur:
System.MethodAccessException: Attempt to access method System.Management.Instrumentation.InstrumentedAttribute..ctor(System.String) in violation of security transparency rules failed
This occurs when the ScriptManager calls AssemblyCache.GetAjaxFrameworkAssemblyAttribute and encounters an assembly that is already loaded and which has the InstrumentedAttribute. In the above example the assembly with this attribute was System.Management.dll.