Quantcast
Channel: Microsoft Dynamics CRM Forum - Recent Threads
Viewing all articles
Browse latest Browse all 82002

Exception System.TypeLoadException: Inheritance security rules violated after DLL merge using ILmereg tool

$
0
0

I have client requirement to call windows Azura hosted webservice by passing SAS token through the CRM plugin. For this we have to use “Microsoft.ServiceBus.dll” for communication with Microsoft Azure Service Bus.

In solution I used the ILmerge tool to merge two DLLS i.e. plugin DLL and Microsoft.ServiceBus.dll, after registering the plugin I am getting following run time error:


Unhandled Exception: System.ServiceModel.FaultException`1[[Microsoft.Xrm.Sdk.OrganizationServiceFault, Microsoft.Xrm.Sdk, Version=8.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]]: Unexpected exception from plug-in (Execute): XXXX.CRM.Core.Plugins.ERPIntegrationPlugin: System.TypeLoadException: Inheritance security rules violated while overriding member: 'Microsoft.ServiceBus.AuthorizationFailedException.GetObjectData(System.Runtime.Serialization.SerializationInfo, System.Runtime.Serialization.StreamingContext)'. Security accessibility of the overriding method must match the security accessibility of the method being overriden.Detail:
<OrganizationServiceFault xmlns:i="www.w3.org/.../XMLSchema-instance" xmlns="schemas.microsoft.com/.../Contracts">
<ErrorCode>-2147220956</ErrorCode>
<ErrorDetails xmlns:d2p1="schemas.datacontract.org/.../System.Collections.Generic" />
<Message>Unexpected exception from plug-in (Execute): XXXX.CRM.Core.Plugins.ERPIntegrationPlugin: System.TypeLoadException: Inheritance security rules violated while overriding member: 'Microsoft.ServiceBus.AuthorizationFailedException.GetObjectData(System.Runtime.Serialization.SerializationInfo, System.Runtime.Serialization.StreamingContext)'. Security accessibility of the overriding method must match the security accessibility of the method being overriden.</Message>
<Timestamp>2017-01-14T23:19:05.4342215Z</Timestamp>
<ExceptionSource i:nil="true" />
<InnerFault i:nil="true" />
<OriginalException i:nil="true" />
<TraceText>


Viewing all articles
Browse latest Browse all 82002

Latest Images

Trending Articles



Latest Images