使用Java的Net库时如何伪造特定的浏览器客户端? [英] How do I fake an specific browser client when using Java's Net library?
本文介绍了使用Java的Net库时如何伪造特定的浏览器客户端?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我的一个小程序刚刚破解,因为看起来,我以编程方式浏览的网站现在假定Java请求来自手机,我正在寻找的链接不在他们的移动页面上。
A small program of mine just broke because, it seems, the site I was programmatically browsing now assumes a Java request comes from a mobile phone, and the link I was looking for is not on their mobile page.
所以我想假冒Internet Explorer访问。我如何用java.net做到这一点?
So I want to fake an Internet Explorer access. How do I do that with java.net?
推荐答案
IIRC,设置http.agent
系统属性通过系统
, -D
在命令行,JNLP文件或其他地方。
IIRC, set "http.agent"
system property through System
, -D
on the command line, in your JNLP file or elsewhere.
这篇关于使用Java的Net库时如何伪造特定的浏览器客户端?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文