full trust/security issues

Discussion in 'General troubleshooting' started by sasmith81, May 9, 2011.

  1. I am trying to use PDFSharp to create pdf files on my site. I keep getting the error:

    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: That assembly does not allow partially trusted callers.

    I already knew this was a issue with my previous provider and moved to Winhost to take advantage of full trust. I added the appropriate lines to my web.config:

    <system.web>
    <securityPolicy>
    <trustLevel name="Full" policyFile="internal"/>
    </securityPolicy>

    The kb doesn't include policyFile, but it kept erroring and telling me I needed it.

    Any suggestions??
     
    Last edited by a moderator: Oct 14, 2015
  2. Ray

    Ray

    Last edited by a moderator: Oct 14, 2015
  3. I read the kb first, I added it the way they had it and it kept giving me a compilation error because it didn't contain the policy file. I added the policyfile as internal and it got rid of the that error, but didn't fix my original security error.
     
  4. I got it fixed...found in another post to go into IIS manager, set to low and then set to full...works!
     
  5. Ray

    Ray

    Yeah that works too. Glad to hear you got it working.
     

Share This Page