summaryrefslogtreecommitdiff
path: root/src/vm/prestub.cpp
diff options
context:
space:
mode:
authorJan Kotas <jkotas@microsoft.com>2017-08-07 12:16:45 -0700
committerGitHub <noreply@github.com>2017-08-07 12:16:45 -0700
commit46ab1d132c9ad471d79afa20c188c2f9c85e5f20 (patch)
tree233ab93323e49cf4c5404e18304374a9faae74de /src/vm/prestub.cpp
parenta9516dacd742ccaeae2820b89ad313a53d22d917 (diff)
downloadcoreclr-46ab1d132c9ad471d79afa20c188c2f9c85e5f20.tar.gz
coreclr-46ab1d132c9ad471d79afa20c188c2f9c85e5f20.tar.bz2
coreclr-46ab1d132c9ad471d79afa20c188c2f9c85e5f20.zip
Cleanup code access security from the unmanaged runtime (#13241)
Diffstat (limited to 'src/vm/prestub.cpp')
-rw-r--r--src/vm/prestub.cpp20
1 files changed, 2 insertions, 18 deletions
diff --git a/src/vm/prestub.cpp b/src/vm/prestub.cpp
index 2cc14166e4..84d27943f5 100644
--- a/src/vm/prestub.cpp
+++ b/src/vm/prestub.cpp
@@ -13,7 +13,6 @@
#include "common.h"
#include "vars.hpp"
-#include "security.h"
#include "eeconfig.h"
#include "dllimport.h"
#include "comdelegate.h"
@@ -482,23 +481,9 @@ COR_ILMETHOD_DECODER* MethodDesc::GetAndVerifyMetadataILHeader(PrepareCodeConfig
pHeader = new (pDecoderMemory) COR_ILMETHOD_DECODER(ilHeader, GetMDImport(), &status);
}
- if (status == COR_ILMETHOD_DECODER::VERIFICATION_ERROR &&
- Security::CanSkipVerification(GetModule()->GetDomainAssembly()))
+ if (status == COR_ILMETHOD_DECODER::FORMAT_ERROR)
{
- status = COR_ILMETHOD_DECODER::SUCCESS;
- }
-
- if (status != COR_ILMETHOD_DECODER::SUCCESS)
- {
- if (status == COR_ILMETHOD_DECODER::VERIFICATION_ERROR)
- {
- // Throw a verification HR
- COMPlusThrowHR(COR_E_VERIFICATION);
- }
- else
- {
- COMPlusThrowHR(COR_E_BADIMAGEFORMAT, BFA_BAD_IL);
- }
+ COMPlusThrowHR(COR_E_BADIMAGEFORMAT, BFA_BAD_IL);
}
#ifdef _VER_EE_VERIFICATION_ENABLED
@@ -769,7 +754,6 @@ PCODE MethodDesc::JitCompileCodeLockedEventWrapper(PrepareCodeConfig* pConfig, J
// Notify the profiler that JIT completed.
// Must do this after the address has been set.
// @ToDo: Why must we set the address before notifying the profiler ??
- // Note that if IsInterceptedForDeclSecurity is set no one should access the jitted code address anyway.
{
if (!IsNoMetadata())
{