[jcifs] NtlmServlet Authentication Problem

eglass1 at comcast.net eglass1 at comcast.net
Tue Jun 8 12:31:10 GMT 2004

> I tried various settings for domain and domainController but i end up 
> getting either a StackOverflow on super.service(req,res) or this:
You shouldn't have to override init just to set jCIFS properties; the
superclass will automatically set them from the deployment descriptor.
So you can just put (in web.xml):

        .... etc.

Also, you shouldn't call super.service; the NtlmServlet .service method is
invoked by the container, and calls super.service (HttpServlet.service), which
in turn calls doGet, doPost, etc.  If you call super.service within doGet,
you'll get the stack overflow due to infinite recursion.

You should just be able to put the appropriate settings in web.xml and do:

    public class MyNtlmServlet extends NtlmServlet {

        public void doGet(HttpServletRequest req, HttpServletResponse res)
                throws IOException, ServletException {
            String user = req.getSession().getAttribute("ntlmuser");


The connection issue might be something else; it looks like it just isn't able to
connect to the host in question.


More information about the jcifs mailing list