在Eclipse 3.5中更改用户代理以进行新的软件安装 [英] Change user agent in Eclipse 3.5 for new software installations

查看:140
本文介绍了在Eclipse 3.5中更改用户代理以进行新的软件安装的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何在Eclipse 3.5中更改用户代理?我尝试向eclipse.ini文件添加属性 -Dhttp.agent =我的用户代理,但使用WireShark我可以看到用户代理仍然是 Jakarta Commons-HttpClient / 3.1 。我需要更改这个,以便我可以通过公司的过滤器来下载插件和更新。这是我的eclipse.ini文件:

How can the user-agent be changed in Eclipse 3.5? I tried adding the property -Dhttp.agent=my user agent to the eclipse.ini file, but using WireShark I can see that the user agent is still Jakarta Commons-HttpClient/3.1. I need to change this so that I can get through the company's filter to download plug-ins and updates. Here is my eclipse.ini file:

-startup
plugins/org.eclipse.equinox.launcher_1.0.200.v20090520.jar
--launcher.library
plugins/org.eclipse.equinox.launcher.win32.win32.x86_1.0.200.v20090519
-product
org.eclipse.epp.package.jee.product
--launcher.XXMaxPermSize
256M
-showsplash
org.eclipse.platform
-vm
C:/Progra~1/Java/jdk1.6.0_14/jre/bin/javaw.exe
-vmargs
-Xms1024m
-Xmx1024m
-Dhttp.agent=my agent
-Djava.net.preferIPv4Stack=true
-Dosgi.requiredJavaVersion=1.5


推荐答案

如果Eclipse不覆盖配置,Apache的HttpClient库将使用httpclient.useragent系统属性而不是http.agent。

If Eclipse is not overriding the configuration, Apache's HttpClient library will use the httpclient.useragent system property instead of http.agent.

这篇关于在Eclipse 3.5中更改用户代理以进行新的软件安装的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆