要访问一个网站下载文件,要通过代理访问INTERNET,有代理的用户密码验证,而所要访问的网站又需要用户名密码验证,
Authenticator.setDefault(new Authenticator() {
protected PasswordAuthentication getPasswordAuthentication() {
return new PasswordAuthentication(username,
new String(password).toCharArray());
}
这样的话只有代理的验证完,对网站的验证又该如何进行?
俗气也是惯例,呵呵,肯定有送分的  100