diff --git a/src/mscorlib/src/System/Reflection/Metadata/AssemblyExtensions.cs b/src/mscorlib/src/System/Reflection/Metadata/AssemblyExtensions.cs index 64c0e5cb2353..c7efad77d42e 100644 --- a/src/mscorlib/src/System/Reflection/Metadata/AssemblyExtensions.cs +++ b/src/mscorlib/src/System/Reflection/Metadata/AssemblyExtensions.cs @@ -10,6 +10,7 @@ namespace System.Reflection.Metadata public static class AssemblyExtensions { [DllImport(JitHelpers.QCall)] + [SecurityCritical] // unsafe method [SuppressUnmanagedCodeSecurity] [return: MarshalAs(UnmanagedType.Bool)] private unsafe static extern bool InternalTryGetRawMetadata(RuntimeAssembly assembly, ref byte* blob, ref int length); @@ -22,6 +23,7 @@ public static class AssemblyExtensions // associated, is alive. The caller is responsible for keeping the assembly object alive while accessing the // metadata blob. [CLSCompliant(false)] // out byte* blob + [SecurityCritical] // unsafe method public unsafe static bool TryGetRawMetadata(this Assembly assembly, out byte* blob, out int length) { if (assembly == null)