Solved

Checking if https is used

Posted on 2006-10-24
4
169 Views
Last Modified: 2010-04-01
Hey experts,

  I need to check in the jsp page if ssl is used (i.e. the page is accessed via https), or not (accessed via normal http)...any help on how to do that??
0
Comment
Question by:mte01
  • 2
4 Comments
 
LVL 14

Assisted Solution

by:boonleng
boonleng earned 130 total points
ID: 17801422
use the method getScheme() from HttpServletRequest. It will return http, https, or ftp.

<%=request.getScheme()%>
0
 
LVL 16

Accepted Solution

by:
suprapto45 earned 250 total points
ID: 17801716
Hi,

Alternatively, you can use
<%= request.isSecure() %>
0
 
LVL 3

Author Comment

by:mte01
ID: 17821217
That did the trick!...thx for your help guys!
0
 
LVL 16

Expert Comment

by:suprapto45
ID: 17825721
Glad I could help.

:)
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When we talk about DevOps toolchains, I sometimes wonder how many people really get what we’re talking about. I don’t know if it’s just semantics or tone or something else, but sometimes I think it just sounds like buzzword sausage. So it’s always …
With the rapid rise in mobile usage, mobile devices are here to stay and have become an integral part of doing business. Here are 9 great apps for your BYOD environment.
Windows 10 is mostly good. However the one thing that annoys me is how many clicks you have to do to dial a VPN connection. You have to go to settings from the start menu, (2 clicks), Network and Internet (1 click), Click VPN (another click) then fi…
Migrating to Microsoft Office 365 is becoming increasingly popular for organizations both large and small. If you have made the leap to Microsoft’s cloud platform, you know that you will need to create a corporate email signature for your Office 365…

867 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

23 Experts available now in Live!

Get 1:1 Help Now