Issue in authentication, web service running in IIS server.
843811Mar 28 2006 — edited Jun 1 2006We are trying to make a web service call to Microsoft share point portal server.
This share point portal run on top of Microsoft IIS server and my client in java
So I get a error like (401)Unauthorized when ever I try to call the web service.
This problem is because IIS server use windows authentication to identify the user calling the web service (or calling any web page).
If I access the same in a browser (IE) it works fine because the browser set the credentials (authentication details) along with every request.
How I set the same programmatically in java code?
We did following experiments but don�t work.
We try to use java.net.Authenticator class to set the credentials, but it is still giving same error.
Setting the system property like
System.setProperty("http.proxyHost", "mtwproxy");
System.setProperty("http.proxyPort", "8085");
System.setProperty("http.proxyUser", "username");
System.setProperty"http.proxyPassword", "password");
This time the request takes long time and gets an error like 504 proxy timeout. It is because the request tries to get the server URL from internet and don�t find the same.
Please reply if you have a solution in your mind.