Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 6460 days old. Please don't post here. Open a new topic instead.

Recommended Posts

  • Newbies
Posted

Hi

I'm developing an XSLT custom webpublishing solution that needs to use a single sign on product called Ubilogin. I have successfully added ubilogin to the tomcat server, but I need to get hold of the login name that can be retrieved from the HttpServletRequest, that is used/stored by the tomcat server, using the method getRemoteUser(). I have looked how one can add java code to an XSLT document using xalan-j, but I have yet to figure out how everything fits together in this complex puzzle. Has anyone added some java code to the tomcat server in order to be called from xalan-j in an XSLT document?

  • Newbies
Posted

Yes I have. I managed to create a Java class which i put on the tomcat server (I'm home at the moment so I don't remember the exact path). It was something like

public class GetUserName extends HttpServlet {

...

private Request request;

public doPost(HttpServletRequest req, HttpServletResponse res) {

request = req;

}

public static getUserName(){

return request.getRemoteUserName();

}

}

...

The code threw a nullpointer exception which I have no idea why.

This topic is 6460 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.