Could not load file or assembly 'Microsoft.IdentityModel RRS feed

  • Question

  • Hello,

    I am trying to register my custom workflow for CRM Online 2013 using Pluginregistration tool.

    While, creating a new connection and providing in username and password, it is throwing the following error:-

    Source : Microsoft.Xrm.Sdk
    Method : AuthenticateLiveIdInternal
    Date : 8/26/2014
    Time : 4:06:26 PM
    Error : Could not load file or assembly 'Microsoft.IdentityModel, Version=, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.
    Stack Trace : at Microsoft.Xrm.Sdk.Client.ServiceConfiguration`1.AuthenticateLiveIdInternal(ClientCredentials clientCredentials, SecurityTokenResponse deviceToken, String keyType)
       at Microsoft.Xrm.Sdk.Client.ServiceConfiguration`1.AuthenticateDevice(ClientCredentials clientCredentials)
       at Microsoft.Xrm.Sdk.Client.ServiceConfiguration`1.AuthenticateLiveIdInternal(AuthenticationCredentials authenticationCredentials)
       at Microsoft.Xrm.Sdk.Client.ServiceConfiguration`1.Authenticate(AuthenticationCredentials authenticationCredentials)
       at Microsoft.Xrm.Sdk.Client.DiscoveryServiceConfiguration.Authenticate(AuthenticationCredentials authenticationCredentials)
       at Microsoft.Xrm.Tooling.Connector.CrmWebSvc.ClaimsIFDFailOverAuth[T](IServiceManagement`1 servicecfg, Uri homeRealm, ClientCredentials userCredentials, ClientCredentials deviceCredentials, Int32 depthLevel, Boolean tryNetworkCred)
       at Microsoft.Xrm.Tooling.Connector.CrmWebSvc.CreateAndAuthenticateProxy[T](IServiceManagement`1 servicecfg, Uri ServiceUri, Uri homeRealm, ClientCredentials userCredentials, ClientCredentials deviceCredentials, String LogString)
       at Microsoft.Xrm.Tooling.Connector.CrmWebSvc.DiscoverOrganizations(Uri discoveryServiceUri, Uri homeRealmUri, ClientCredentials clientCredentials, ClientCredentials deviceCredentials)
       at Microsoft.Xrm.Tooling.CrmConnectControl.CrmConnectionManager.QueryLiveDiscoveryServer(ClientCredentials liveCreds, Uri discoServer)
       at Microsoft.Xrm.Tooling.CrmConnectControl.CrmConnectionManager.QueryOnlineServerList(ObservableCollection`1 svrs, OrganizationDetailCollection col, ClientCredentials liveCreds)
       at Microsoft.Xrm.Tooling.CrmConnectControl.CrmConnectionManager.FindCrmOnlineDiscoveryServer(ClientCredentials liveCreds)
       at Microsoft.Xrm.Tooling.CrmConnectControl.CrmConnectionManager.ValidateServerConnection(CrmOrgByServer selectedOrg)

    Further to this, I downloaded and installed WIF 3.5 from the link:- http://www.microsoft.com/en-us/download/details.aspx?id=17331 for Windows 7- 32 Bit. After installing WIF, Igot the same error. Is that because .net framework 4.5.2 isn't compatible with WIF 3.5? If I uninstall .net framework 4.5.2, I work be able to run Pluginregistration tool for CRM 2013.

    Tuesday, August 26, 2014 12:40 PM

All replies

  • You need to install Windows Identity Foundation on the machine you're running the plugin registration tool.


    Tuesday, August 26, 2014 12:44 PM
  • Hello,

    I have installed Windows Identify Foundation in my machine but I received the same error. Is there any other way?'


    Tuesday, August 26, 2014 12:50 PM
  • Are you using the latest plugin registration tool?

    you can download the sdk from http://www.microsoft.com/en-us/download/details.aspx?id=40321 (will be inside the Tools folder)

    are you sure you downloaded the WIF for your machine? Windows 7 32 bit is Windows6.1-KB974405-x86.msu

    did you choose the right authentication inside plugin registration tool? Online or Office 365 and the right region?

    My blog: www.crmanswers.net - Rockstar 365 Profile

    Tuesday, August 26, 2014 1:11 PM
  • Hello,

    Yes, I have used the latest Plugin registration tool (inside tools folder). I have also downloaded Windows6.1-KB974405-x86.msu in my machine. For authentication I used Online and region as - Don't know. I used other regions as well just in case, but no luck.


    Tuesday, August 26, 2014 1:25 PM
  • did you try office 365?

    the region depends on your organization url

    companyname.crm.dynamics.com North America
    companyname.crm4.dynamics.com Europe, Middle East and Africa
    companyname.crm5.dynamics.com Asia Pacific Area
    companyname.crm2.dynamics.com South America

    restart also your machine just in case.

    My blog: www.crmanswers.net - Rockstar 365 Profile

    Tuesday, August 26, 2014 1:33 PM
  • Hello,

    It worked!! turns out I haven't given a chance to Office 365.

    Thank you for your help!!!

    Tuesday, August 26, 2014 1:38 PM