Forums Register Login
Use Http And Https in Same application
Hi all,

I have one web application working in https: , but for dome url (i mean paths) i have to use http only ..How can I configure http and https in same application. Please give some idea to do this...

Thnaks in advance

You can change the header details of the request before it reaches the action class.

You write one class which extends RequestProcessor, the looks like below one

//First check if the connection is secure.
if (request.getHeader("HTTP")==null || !request.getHeader("HTTP").equals("on")){
return false;
catch(Throwable t){
log("There is a Exception in the request Processor while redirecting the request",t );
return false;
return true;

The RequestProcessor class will be excecuted before calling the action class and change the header from HTTPS to HTTP.

I have not tested the code. But, have a try and also look for other replies.
thanks Saravanaprabu...

Whether we can do anything through Tomcat Configarations ?
Wink, wink, nudge, nudge, say no more ... https://richsoil.com/cards

All times above are in ranch (not your local) time.
The current ranch time is
Oct 22, 2017 03:53:31.