When working with Weblogic on a local machine behind a NTLM HTTP proxy server can be a pain. If weblogic needs to hit an external resource, such as a SOAP service, that resides on the other side of the proxy server, a 401 Access Denied error will probably come up. The server’s log files will typically say something like “This proxy server requires authentication.” The bad news, neither Weblogic or Java directly support NTLM proxy authentication (at least not that I know 0f), the good news is that there is a mostly harmless easy solution that does not require code changes.
The soltuion is to deploy a local private proxy server that handles the NTLM for Java. NTLMAPS is an open source proxy server that does not require admin rights to install and that was build just for the job. So here is a step by step…
- Download a copy of ntlmaps from the download page. Check under ntlmaps-dev for a self extracting zip file or binary installer.
- Update the server.cfg file for ntlmaps to point to the external NTLM proxy and setup the username/password.
- Update the startWeblogic script to tell Java to use your local proxy server
- -Dhttp.ProxyPort=<port number from server.cfg>
- Start the ntlmaps proxy server from the command line
- Start Weblogic
This method works for more than just Weblogic. If fact, it can be used to get any non NTLM aware application to the outside world. Note that ntlmaps doesn’t work well under a heavy load and I would not recommend it for anything other than development work, but it does intended purpose well.
I am currently updating the main blogging platform from Lifetype to WordPress so some links may still point to the old site. All post references, including search engines and bookmarks, should magically redirect to the new WordPress post. All pictures should be imported but some may be rotated funny. This update should be completed over the next few weeks.