{"id":137,"date":"2007-07-25T00:39:21","date_gmt":"2007-07-25T06:39:21","guid":{"rendered":"http:\/\/jameskovacs.com\/2007\/07\/25\/TFS+And+Alternate+Credentials"},"modified":"2007-07-25T00:39:21","modified_gmt":"2007-07-25T06:39:21","slug":"tfs-and-alternate-credentials","status":"publish","type":"post","link":"https:\/\/www.jameskovacs.com\/index.php\/2007\/07\/25\/tfs-and-alternate-credentials\/","title":{"rendered":"TFS and Alternate Credentials"},"content":{"rendered":"<p>I was trying to connect to a TFS server in another domain, but without success. I could connect to the TFS web services through FireFox after providing the correct credentials, but Visual Studio was simply failing with a <em>TF31002: Unable to connect to this Team foundation Server: tfs.<\/em><\/p>\n<p><a href=\"\/wp-content\/uploads\/WindowsLiveWriter\/TFSandAlternateCredentials_2F4\/TF31002.png\" atomicselection=\"true\"><img loading=\"lazy\" decoding=\"async\" style=\"border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px\" height=\"364\" alt=\"TF31002\" src=\"\/wp-content\/uploads\/WindowsLiveWriter\/TFSandAlternateCredentials_2F4\/TF31002_thumb.png\" width=\"525\" border=\"0\"><\/a> <\/p>\n<p>I wasn&#8217;t being prompted for alternate credentials when using Visual Studio, only when navigating to the TFS server (<a title=\"http:\/\/tfs:8080\/services\/v1.0\/ServerStatus.asmx\" href=\"http:\/\/tfs:8080\/services\/v1.0\/ServerStatus.asmx\">http:\/\/tfs:8080\/services\/v1.0\/ServerStatus.asmx<\/a>) through FireFox. Navigating to a network share (<a href=\"file:\/\/\\\\tfs\">\\\\tfs<\/a>) also prompted me for credentials and allowed me to see the shares. Only Visual Studio wasn&#8217;t prompting for credentials. I decided to try IE7 and received a <em>502: Bad Gateway<\/em> error. Ah ha! A lead. Tools&#8230; Internet Options&#8230; Connections&#8230;&nbsp;LAN settings&#8230; Uncheck &#8220;Automatically detect settings&#8221;&#8230; OK&#8230; OK&#8230; Refresh IE and I&#8217;m prompted for credentials and can see the server status page. Woohoo! Now let&#8217;s try adding the TFS server again in Visual Studio:<\/p>\n<p><a href=\"\/wp-content\/uploads\/WindowsLiveWriter\/TFSandAlternateCredentials_2F4\/AddTfsDialog.png\" atomicselection=\"true\"><img loading=\"lazy\" decoding=\"async\" style=\"border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px\" height=\"276\" alt=\"AddTfsDialog\" src=\"\/wp-content\/uploads\/WindowsLiveWriter\/TFSandAlternateCredentials_2F4\/AddTfsDialog_thumb.png\" width=\"484\" border=\"0\"><\/a> <\/p>\n<p>Click OK and the moment of truth&#8230;<\/p>\n<p><a href=\"\/wp-content\/uploads\/WindowsLiveWriter\/TFSandAlternateCredentials_2F4\/TfsCredentialPrompt.png\" atomicselection=\"true\"><img loading=\"lazy\" decoding=\"async\" style=\"border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px\" height=\"297\" alt=\"TfsCredentialPrompt\" src=\"\/wp-content\/uploads\/WindowsLiveWriter\/TFSandAlternateCredentials_2F4\/TfsCredentialPrompt_thumb.png\" width=\"368\" border=\"0\"><\/a> <\/p>\n<p>We have a credential prompt!!! Type in correct credentials for the other domain and&#8230;<\/p>\n<p><a href=\"\/wp-content\/uploads\/WindowsLiveWriter\/TFSandAlternateCredentials_2F4\/AddRemoveTfsDialog.png\" atomicselection=\"true\"><img loading=\"lazy\" decoding=\"async\" style=\"border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px\" height=\"445\" alt=\"AddRemoveTfsDialog\" src=\"\/wp-content\/uploads\/WindowsLiveWriter\/TFSandAlternateCredentials_2F4\/AddRemoveTfsDialog_thumb.png\" width=\"685\" border=\"0\"><\/a> <\/p>\n<p>Houston, the&nbsp;eagle has landed!&nbsp;Looks like automatic proxy detection somehow prevents IE and Visual Studio from connecting to TFS successfully. I would like to point out that &#8220;Automatic proxy detection is enabled&#8221; was not listed amongst the possible reasons for failure in the TF31002 error. Go figure.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>I was trying to connect to a TFS server in another domain, but without success. I could connect to the TFS web services through FireFox after providing the correct credentials, but Visual Studio was simply failing with a TF31002: Unable to connect to this Team foundation Server: tfs. I wasn&#8217;t being prompted for alternate credentials [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[25],"tags":[],"class_list":["post-137","post","type-post","status-publish","format-standard","hentry","category-tfs"],"_links":{"self":[{"href":"https:\/\/www.jameskovacs.com\/index.php\/wp-json\/wp\/v2\/posts\/137","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.jameskovacs.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.jameskovacs.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.jameskovacs.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.jameskovacs.com\/index.php\/wp-json\/wp\/v2\/comments?post=137"}],"version-history":[{"count":0,"href":"https:\/\/www.jameskovacs.com\/index.php\/wp-json\/wp\/v2\/posts\/137\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.jameskovacs.com\/index.php\/wp-json\/wp\/v2\/media?parent=137"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.jameskovacs.com\/index.php\/wp-json\/wp\/v2\/categories?post=137"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.jameskovacs.com\/index.php\/wp-json\/wp\/v2\/tags?post=137"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}