开发者

Removing NTLM from Eclipse's

I'm having an issue trying to connect through a proxy from Eclipse 3.6. The proxy supports both NTLM and Basic Auth schemes.

Eclipse seems to prefer NTLM auth scheme, instead of the basic one. However, after the selection is done, the proxy seems to hang and Eclipse retries the开发者_开发技巧 downloads forever. Using wireshark to monitor the traffic I can see:

  • Eclipse is trying to auth through NTLM
  • The proxy sends back a 407 response.

This happens 3 times, then the proxy stops responding and Eclipse retries the download until I hit cancel.

Is there a way to tell Eclipse to try Basic Auth instead of NTLM?

Best regards, Manuel.


I don't know about the Basic Auth, but regarding NTLM proxy, check the bug 281384, also discussed at length in bug 281472.

It introduces a workaround for NTLMv2 Proxies.

-Dorg.eclipse.ecf.provider.filetransfer.excludeContributors=org.eclipse.ecf.provider.filetransfer.httpclient
-Dhttp.proxyPort=8080
-Dhttp.proxyHost=myproxy
-Dhttp.proxyUser=mydomain\myusername
-Dhttp.proxyPassword=mypassword
-Dhttp.nonProxyHosts=localhost|127.0.0.1

The first property disables the httpclient provider (and so uses the URLConnection-based provider, which does have support for NTLMv2 proxies),
and the next 5 properties are as specified by Sun for the URLConnection-based provider.


The problem is that standard Eclipse HTTP client can't manage the so named HTLM proxies. The method, proposed by @VonC was good till Kepler version of Eclipse.

The trick is to turn off the Eclipse HTTP client. But starting from Kepler, its name had changed. Add the following to the eclipse.ini file:

-vmargs 
-Dorg.eclipse.ecf.provider.filetransfer.excludeContributors=org.eclipse.ecf.provider.filetransfer.httpclient4

Also look here for a very good explanation and here for an "official" explanation of the Eclipse team.

You don't need to set the proxy parameters in the eclipse.ini. The settings in Windows-preferences-General-Net are enough. But you should check the global proxy settings on the OS, paying attention to possible automatic settings.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜