【问题标题】:Easy_install or pip with NTLM authEasy_install 或 pip 与 NTLM 身份验证
【发布时间】:2011-06-13 22:41:58
【问题描述】:

在我的工作环境中,上网是通过NTLM身份验证管理的,并与Windows用户帐户相关联,而easy_install或pip不起作用:

C:\>easy_install django
install_dir D:\Python26\Lib\site-packages\
Searching for django
Reading http://pypi.python.org/simple/django/
Download error: timed out -- Some packages may not be found!
....

C:\>pip install django
Downloading/unpacking django
  Cannot fetch index base URL http://pypi.python.org/simple/
  Could not find any downloads that satisfy the requirement django
No distributions at all found for django

是否有可能让他们在这样的环境中工作?

【问题讨论】:

标签: python ntlm easy-install pip


【解决方案1】:

使用NTLMAPS,并将pip指向本地代理。

【讨论】:

  • 系统要求说它需要 Python 1.5.2 及更高版本,这让我觉得它是一个非常古老的包,但它确实适用于 python 2.6!并且 cntlm(cntlm.sourceforge.net) 提到那里也有效。谢谢!
  • 哦,对不起。我自己在 Linux 上使用 cntlm,出于某种原因,我认为它仅适用于 Linux。如果 cntlm 在 Windows 上为您工作,那就是要走的路。
  • 我无法让 NTLMAPS 工作,但我能够使用 cntlm。谢谢!
  • 一旦我设置了HTTPS_PROXYHTTP_PROXY 环境变量,我就可以让cntlm 与easy_install 一起工作。
猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2013-09-02
  • 1970-01-01
  • 1970-01-01
相关资源
最近更新 更多