Hello all:

        I have been trying for the last few days to make the juddi console 
(3.0.4) work with XMLDocAuthenticator. If I use JUDDIAuthenticator, 
everything is fine and I can see the contents of the directory in the 
portlets. However, if I enable the XMLDocAuthenticator in the jUDDI 
directory, I always get a "error: Invalid credentials were passed". 
Digging into it (using TCPMon), I found out that the cred was always being 
passed with an empty value to the get_authToken action:

POST /juddiv3/services/security HTTP/1.1
SOAPAction: "get_authToken"
Accept: text/xml, multipart/related, text/html, image/gif, image/jpeg, *; 
q=.2, */*; q=.2
Content-Type: text/xml;charset="utf-8"
User-Agent: JAX-WS RI 2.1.4-b01-
Host: 127.0.0.1:8888
Connection: keep-alive
Content-Length: 515
 
<?xml version="1.0" ?>
   <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/";>
      <S:Body>
         <get_authToken xmlns="urn:uddi-org:api_v3"
                        xmlns:ns2="urn:uddi-org:custody_v3"
                        xmlns:ns3="urn:uddi-org:repl_v3"
                        xmlns:ns4="http://www.w3.org/2000/09/xmldsig#";
                        xmlns:ns5="urn:uddi-org:sub_v3"
                        xmlns:ns6="urn:uddi-org:subr_v3"
                        xmlns:ns7="urn:uddi-org:vscache_v3"
                        xmlns:ns8="urn:uddi-org:policy_v3"
                        xmlns:ns9="urn:uddi-org:vs_v3"
                        xmlns:ns10="urn:uddi-org:policy_v3_instanceParms"
                        cred="" userID="admin"/>
      </S:Body>
   </S:Envelope>
 
        Then I upped the debug level and got this:

INFO [org.apache.juddi.v3.client.config.WebHelper] - Starting Clerk 
Manager uddi-portlet-manager...
DEBUG [org.apache.juddi.v3.client.config.UDDIClerkManager] - 
uddi-portlet-manager already registered to the UDDIClientContainer.
DEBUG [org.apache.juddi.portlets.server.service.SecurityServiceImpl] - 
User null sending token request..
DEBUG [org.apache.juddi.portlets.server.service.SecurityServiceImpl] - 
UserPrincipal <user username="root" password="root" 
roles="pluto,tomcat,manager"/>
ERROR [org.apache.juddi.portlets.server.service.SecurityServiceImpl] - 
Could not obtain token. Invalid credentials were passed
javax.xml.ws.soap.SOAPFaultException: Invalid credentials were passed

        And digging into the code, I found this relevant fragment of code 
within the org.apache.juddi.portlets.server.service.SecurityServiceImpl 
class:

log.debug("User " + username + " sending token request..");
SecurityResponse response = new SecurityResponse();
String token = (String) session.getAttribute("AuthToken");
if (username==null) {
        username = (String) session.getAttribute("UserName");
}
Principal user = request.getUserPrincipal();
log.debug("UserPrincipal " + user);
if (username==null && user!=null) {
        username = user.getName();
        password = "";
}

Being as I am new to this project, the reason for that may be obvious but, 
why is an empty value being assigned to the password variable in there?

Thank you. Best regards. 

-- 

Jose Manuel Arnesto López - R&D Innovation

TELVENT
Telvent Arce Sistemas, S.A.
Telvent - Bilbao - Vizcaya
Phone: +34944224004 (2004)  Fax: +34944440658
[email protected]
P Eco-Tip: Printing e-mails is usually a waste. 

Reply via email to