0

Description: The application attempted to perform an operation not allowed by the security policy. To grant this application the required permission please contact your system administrator or change the application's trust level in the configuration file.

Exception Details: System.Security.SecurityException: Request for the permission of type 'System.Security.Permissions.ReflectionPermission, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.

I try trust level high tag in web config but still face same problem

1 Answer 1

1

You don't have to change the trust level in web.config of your own application. Most probably, IIS of your host is configured to run on lower trust level (most probably Medium Trust level) and individual web applications are not allowed to override the main config file. Hence, even if you change the trust level to Full, you won't be able use the Full trust level.

You can ask your web host if they allow you to use full trust level. If they deny you will have to configure your web application to run with low trust levels, or move to web host who supports Full Trust level hosting.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.