PicketLink STS on Tomcat 6. Is it working?
mrbeanbg Jul 26, 2010 8:29 AMHello All!
I had tried to install the PicketLink STS on Tomcat 6. I am also having a client which should request token (from STS) and later on validate that.
I was trying to run the client and eventually build prove of concept, but I am having the following problems:
Problem number one - GET request to the PicketLink STS - http://localhost:8080/picketlink-sts/PicketLinkSTS/ - this is causing the following exception:
exception
javax.servlet.ServletException: Class org.picketlink.identity.federation.core.wstrust.PicketLinkSTS is not a Servlet
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:563)
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298)
org.apache.coyote.http11.Http11AprProcessor.process(Http11AprProcessor.java:861)
org.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler.process(Http11AprProtocol.java:579)
org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:1584)
java.lang.Thread.run(Thread.java:619)
root cause
java.lang.ClassCastException: org.picketlink.identity.federation.core.wstrust.PicketLinkSTS cannot be cast to javax.servlet.Servlet
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:563)
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298)
org.apache.coyote.http11.Http11AprProcessor.process(Http11AprProcessor.java:861)
org.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler.process(Http11AprProtocol.java:579)
org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:1584)
java.lang.Thread.run(Thread.java:619)
Indeed, as far as I checked the org.picketlink.identity.federation.core.wstrust.PicketLinkSTS do not extend/implement the HttpServlet, nor either the Servlet class. This is also true for all "parent" classes of org.picketlink.identity.federation.core.wstrust.PicketLinkSTS.
Problem number two - POST request form the Client - this is causing the following exception
SEVERE: Allocate exception for servlet PicketLinkSTS
java.lang.ClassCastException: org.picketlink.identity.federation.core.wstrust.PicketLinkSTS cannot be cast to javax.servlet.Servlet
at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1116)
at org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:809)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:129)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:563)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298)
at org.apache.coyote.http11.Http11AprProcessor.process(Http11AprProcessor.java:861)
at org.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler.process(Http11AprProtocol.java:579)
at org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:1584)
at java.lang.Thread.run(Thread.java:619)
Here is the actual SOAP request:
POST /picketlink-sts/PicketLinkSTS HTTP/1.1
Content-Type: text/xml; charset=UTF-8
SOAPAction: ""
User-Agent: Axis2
Authorization: Basic dG9tY2F0OnRvbWNhdA==
Host: 127.0.0.1:8079
Transfer-Encoding: chunked
338
<?xml version='1.0' encoding='UTF-8'?><soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"><soapenv:Body><ns4:RequestSecurityToken xmlns:ns4="http://docs.oasis-open.org/ws-sx/ws-trust/200512" xmlns:ns2="http://schemas.xmlsoap.org/ws/2004/09/policy" xmlns="http://www.w3.org/2005/08/addressing" xmlns:ns3="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns:ns5="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" xmlns:ns6="http://www.w3.org/2000/09/xmldsig#" Context="context"><ns4:TokenType>http://docs.oasis-open.org/wss/oasis-wss-saml-token-profile-1.1#SAMLV2.0</ns4:TokenType><ns4:RequestType>http://docs.oasis-open.org/ws-sx/ws-trust/200512/Issue</ns4:RequestType></ns4:RequestSecurityToken></soapenv:Body></soapenv:Envelope>
0
My questions are if I am missing something, or if I am doing something wrong? Can PicketLink STS be deployed on Tomcat 6 at all or PicketLinks STS is working only with JBossAS?