BizTalk WCF Adapter – BasicHttpBinding results in Partial Trust Exception

Exception: System.ServiceModel.ServiceActivationException: The service ‘/MyService/Service.svc’ cannot be activated due to an exception during compilation. The exception message is: That assembly does not allow partially trusted callers.. —> System.Security.SecurityException: That assembly does not allow partially trusted callers.

Solution

After some research, I found that I’m getting this problem because the WCF service requires full trust permission to run from the server. One way to solve the problem is:

  • Open web.config file in notepad
  • In <system.web> section add the following tag:
<trust level="Full" originUrl=""/>

These steps solved my problem.

Author: Sandro Pereira

Sandro Pereira lives in Portugal and works as a consultant at DevScope. In the past years, he has been working on implementing Integration scenarios both on-premises and cloud for various clients, each with different scenarios from a technical point of view, size, and criticality, using Microsoft Azure, Microsoft BizTalk Server and different technologies like AS2, EDI, RosettaNet, SAP, TIBCO etc. He is a regular blogger, international speaker, and technical reviewer of several BizTalk books all focused on Integration. He is also the author of the book “BizTalk Mapping Patterns & Best Practices”. He has been awarded MVP since 2011 for his contributions to the integration community.

Leave a Reply

Your email address will not be published. Required fields are marked *

turbo360

Back to Top