Here are two sets of log entries. The first is from the PRT and the second set is typical of what we're getting when trying to use the Xrm.Tooling assemblies (the latest from Nuget) in a console app with a connection string. From the log output, it's pretty clear that the Xrm.Tooling assemblies that the PRT and other Windows apps use in the SDK are not the same assemblies that Microsoft provides via the Nuget package. The interactive tooling login connector works and the connection string approach does not.
Plug-in Registration Tool Log (successful connection):
DiscoverOrganizations - Initializing Discovery Server Object with disco.crm.dynamics.com/.../Discovery.svc
AuthenticateService - find authority with name login.windows.net/.../authorize
DiscoverOrganizations - Discovery Server Get Orgs Call Complete - Elapsed:00:00:04.9924629
User Specified Org details are used.
Found 1 Org(s)
Microsoft.Xrm.Tooling.Connector.CrmServiceClient Verbose: 16 : DiscoveryServer indicated organization service location = contoso.api.crm.dynamics.com/.../Organization.svc
Organization Service URI is = contoso.api.crm.dynamics.com/.../Organization.svc
ConnectAndInitCrmOrgService - Initializing Organization Service Object
ConnectAndInitCrmOrgService - Requesting connection to Org with CRM Version: 8.2.1.176
AuthenticateService - find authority with name login.windows.net/.../authorize
ConnectAndInitCrmOrgService - Proxy created, total elapsed time: 00:00:00.9081282
User Org (crmNAorg05099) found in Discovery Server - ONLY ORG FOUND
Beginning Validation of CRM Connection
Validation of CRM Connection Complete, total duration: 00:00:01.0035615
Example of failed connection using Xrm.Tooling assemblies with various connection strings:
Microsoft.Xrm.Tooling.Connector.CrmServiceClient Information: 8 : Using User Specified Server
Microsoft.Xrm.Tooling.Connector.CrmServiceClient Information: 8 : Trying Live Discovery Server, (North America) URI is = disco.crm.dynamics.com/.../Discovery.svc
Microsoft.Xrm.Tooling.Connector.CrmServiceClient Information: 8 : DiscoverOrganizations - Initializing Discovery Server Object with disco.crm.dynamics.com/.../Discovery.svc
Microsoft.Xrm.Tooling.Connector.CrmServiceClient Verbose: 16 : DiscoverOrganizations - attempting to connect to CRM server @ disco.crm.dynamics.com/.../Discovery.svc
Microsoft.Xrm.Tooling.Connector.CrmServiceClient Verbose: 16 : DiscoverOrganizations - created CRM server proxy configuration for disco.crm.dynamics.com/.../Discovery.svc - duration: 00:00:00.3812132
Microsoft.Xrm.Tooling.Connector.CrmServiceClient Verbose: 16 : DiscoverOrganizations - proxy requiring authentication type : OnlineFederation
Microsoft.Xrm.Tooling.Connector.CrmServiceClient Error: 2 : Source : mscorlib
Method : HandleReturnMessage
Date : 5/5/2017
Time : 9:44:40 AM
Error : There was no endpoint listening at fs.contoso.com/.../username that could accept the message. This is often caused by an incorrect address or SOAP action. See InnerException, if present, for more details.
Stack Trace : Server stack trace:
at System.ServiceModel.Channels.HttpOutput.WebRequestHttpOutput.GetOutputStream()
at System.ServiceModel.Channels.HttpOutput.Send(TimeSpan timeout)