CRM 2013 plugin registration issue RRS feed

  • Question

  • Hi, I have set up a CRM 2013 instance to test.  I am trying to connect to this instance through the plugin registration tool from the CRM 2013 SDK but even though I am using the correct details I still get an authentication error (below). The details I am using are admin credentials and allow me to access the CRM site, which should allow the plugin registration tool to connect.  If I enter a random password I also get the same authentication error.  Any help would be much appreciated.

    Unhandled Exception: System.ServiceModel.Security.MessageSecurityException: An unsecured or incorrectly secured fault was received from the other party. See the inner FaultException for the fault code and detail.

    Server stack trace:
       at System.ServiceModel.Channels.SecurityChannelFactory`1.SecurityRequestChannel.ProcessReply(Message reply, SecurityProtocolCorrelationState correlationState, TimeSpan timeout)
       at System.ServiceModel.Channels.SecurityChannelFactory`1.SecurityRequestChannel.Request(Message message, TimeSpan timeout)
       at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean oneway, ProxyOperationRuntime operation, Object[] ins, Object[] outs, TimeSpan timeout)
       at System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage methodCall, ProxyOperationRuntime operation)
       at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message)

    Exception rethrown at [0]:
       at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)
       at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)
       at Microsoft.IdentityModel.Protocols.WSTrust.IWSTrustContract.Issue(Message message)
       at Microsoft.IdentityModel.Protocols.WSTrust.WSTrustChannel.Issue(RequestSecurityToken rst, RequestSecurityTokenResponse& rstr)
       at Microsoft.Xrm.Sdk.Client.ServiceConfiguration`1.AuthenticateLiveIdInternal(ClientCredentials clientCredentials, SecurityTokenResponse deviceToken, String keyType)
       at Microsoft.Xrm.Sdk.Client.ServiceConfiguration`1.Authenticate(ClientCredentials clientCredentials, SecurityTokenResponse deviceTokenResponse, String keyType)
       at Microsoft.Xrm.Sdk.Client.ServiceConfiguration`1.Authenticate(ClientCredentials clientCredentials, SecurityTokenResponse deviceTokenResponse)
       at Microsoft.Xrm.Sdk.Client.ServiceProxy`1.AuthenticateCore()
       at Microsoft.Xrm.Sdk.Client.ServiceProxy`1.ValidateAuthentication()
       at Microsoft.Xrm.Sdk.Client.ServiceContextInitializer`1.Initialize(ServiceProxy`1 proxy)
       at Microsoft.Xrm.Sdk.Client.DiscoveryServiceProxy.Execute(DiscoveryRequest request)
       at Microsoft.Crm.Tools.PluginRegistration.CrmConnection.RetrieveOrganizations()
       at Microsoft.Crm.Tools.PluginRegistration.ConnectionsForm.OpenConnection(CrmConnection con)
    Inner Exception: System.ServiceModel.FaultException: Authentication Failure

    Friday, November 1, 2013 3:04 PM


All replies

  • I've seen this behavior happen if the computer's time settings are too far out of sync between the client machine and the server you are registering the plugin against.  I believe any more than 5 minutes difference will trigger this type of fault.
    Friday, November 1, 2013 5:58 PM
  • Hi,

    Is this a new instance or an upgrade?

    Are you using the discovery url without the organisation name?

    sometimes the tool could cache a wrong credential. did you try to delete and recreate the connection profile?

    Also, where are the 2 parts? are you running the tool from another machine within or without the same network?

    I have experimented an issue where  my crm machine was being hosted on a problematic host and the plugin tool was timing out with the same error. on that case I had to RDP to the host and run the plugin registration on the server.




    I Hope I could help. If I have answered please mark as 'Answer'. If was just helpful, please vote. Thanks and happy coding!

    Friday, November 1, 2013 10:17 PM
  • Thank you for your reply.  I have checked the time on both the server and my machine, there was a difference of 1 minute I fixed this but still unable to connect 
    Monday, November 4, 2013 2:47 PM
  • Thank you for your reply.

    This is a new instance of the CRM 2013 trial.  I have tried your suggestions but still unable to connect the plugin registration tool.  I am trying to connect from my machine to an on line version hosted by micrsoft

    Monday, November 4, 2013 2:49 PM
  • Here it is how to connect to CRM Online


    I Hope I could help. If I have answered please mark as 'Answer'. If was just helpful, please vote. Thanks and happy coding! Bruno Lucas, http://dynamicday.wordpress.com/

    Tuesday, November 5, 2013 9:40 AM
  • Excellent, this solved my issue.
    Tuesday, November 5, 2013 11:38 AM