internal static void CheckAssembly( Assembly asm, CodeAccessPermission demand ) { BCLDebug.Assert( asm != null, "Must pass in a good assembly" ); BCLDebug.Assert( demand != null, "Must pass in a good demand" ); PermissionSet granted, denied; asm.nGetGrantSet( out granted, out denied ); CheckHelper( granted, denied, demand, PermissionToken.GetToken(demand) ); }
internal static void CheckAssembly( Assembly asm, PermissionSet permSet ) { BCLDebug.Assert( asm != null, "Must pass in a good assembly" ); BCLDebug.Assert( permSet != null, "Must pass in a good permset" ); PermissionSet granted, denied; asm.nGetGrantSet( out granted, out denied ); CheckSetHelper( granted, denied, permSet ); }
internal static void CheckAssembly( Assembly asm, CodeAccessPermission demand ) { BCLDebug.Assert( asm != null, "Must pass in a good assembly" ); BCLDebug.Assert( demand != null, "Must pass in a good demand" ); if (SecurityManager._IsSecurityOn()) { PermissionSet granted, refused; asm.nGetGrantSet( out granted, out refused ); CheckHelper( granted, refused, demand, PermissionToken.GetToken(demand), RuntimeMethodHandle.EmptyHandle, asm, SecurityAction.Demand, true ); } }