Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
JavaRanch.com/granny.jsp
The moose likes Tomcat and the fly likes SSL & relative urls. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Products » Tomcat
Bookmark "SSL & relative urls." Watch "SSL & relative urls." New topic
Author

SSL & relative urls.

Dave Brown
Ranch Hand

Joined: Mar 08, 2005
Posts: 301
Hi all, I've got a webapp running with apache 2/ mod jk2 and tomcat 5.5

I'm just starting to implement some security in the site, so when for example a user registers, the form post will (my intention) go to a HTTPS address..

The question I have is , is there anyway to still keep a relative URL for the post, at the moment, it goes to "/ValidateRegistration".. If I can, I'd like to avoid a fully qualified URL.

Thanks


Regards, Dave Brown
SCJP 6 - [url]http://www.dbws.net/[/url] - Check out Grails Forum
Ben Souther
Sheriff

Joined: Dec 11, 2004
Posts: 13410

Yes, the HttpServletRequest object has all the methods you need for this:



Java API J2EE API Servlet Spec JSP Spec How to ask a question... Simple Servlet Examples jsonf
Dave Brown
Ranch Hand

Joined: Mar 08, 2005
Posts: 301
Thanks Ben
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: SSL & relative urls.