07.11.2011 - Look at java.net.Authenticator and method setDefault(java.net.Authenticator). To sum up, adding this line of code at the beginning helped: Authenticator..