Hi,
I am trying to configure spnego out of the box on tomcat 7.0.55 on Linux 6.5, 
with directions given at 
http://tomcat.apache.org/tomcat-7.0-doc/windows-auth-howto.html. And I am 
trying to test the configuration with a sample hello_spnego.jsp file given 
below. When I load http://localhost:8080/hello_spnego.jsp, the output is "Hello 
null !" The getremoteUser() seems to be returning null.
My setup:
The KDC, client (machine running firefox) and tomcat server are all on the same 
domain. The client (Firefox) is on the same machine as the tomcat instance, 
linux 6.5.
Here is my configuration:
So, it is out of the box tomcat 7.0.55 install, I added these files to 
$CATALINA_BASE/conf:
jaas.conf
krb5.ini
appserver.keytab (copied from KDC)
I am confident the jaas.conf, krb5.ini and the appserver.keytab configurations 
are correct since I have successfully tested them with the spnego library from 
sourceforge ( http://spnego.sourceforge.net/spnego_tomcat.html ).
hello_spnego.jsp:
<html>
  <head>
    <title>Hello SPNEGO Example</title>
  </head>
  <body>
    Hello <%= request.getRemoteUser() %> !
  </body>
</html>
I copied hello_spnego.jsp to webapps/ROOT, and edited 
webapps/ROOT/WEB_INF/web.xml as follows:
< login-config>
<auth-method>SPNEGO</auth-method>
<realm-name>Tomcat Spnego example</realm-name>
< /login-config>
<servlet>
<servlet-name>Test</servlet-name>
<jsp-file>/hello_spnego.jsp</jsp-file>
</servlet>
<servlet-mapping>
<servlet-name>Test</servlet-name>
<url-pattern>*.jsp</url-pattern>
</servlet-mapping>
Am I missing anything in my configuration of web.xml? Any help would be greatly 
appreciated.
Thank you!
Usha






Reply via email to