I have some environment with both Linux and Windows servers. Authentication is handled by Kerberos. I want to make some JAVA code which automatically authenticates the http requests it makes as being done by the logged in user executing the program. For example, if I have this code: when I execute it from windows, it works out of the box.