File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Servlets and the fly likes Servlets and SSL Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » Servlets
Reply Bookmark "Servlets and SSL" Watch "Servlets and SSL" New topic
Author

Servlets and SSL

Bharatesh H Kakamari
Ranch Hand

Joined: Nov 09, 2000
Posts: 198
How do I change the code in the Servlets to only accepts https (SSL) connections rather than http connections ?
Peter den Haan
author
Ranch Hand

Joined: Apr 20, 2000
Posts: 3252
Originally posted by Bharatesh H Kakamari:
How do I change the code in the Servlets to only accepts https (SSL) connections rather than http connections ?

This is more an application server set-up or request filtering issue. Arguably, the servlets themselves should be agnostic. Having said that, look into HttpServletRequest.getAuthType().
- Peter
Eager Beaver
Ranch Hand

Joined: Feb 26, 2001
Posts: 187
Hi,
HTTP/HTTPS, how are they different. Which to use when.
thanks.
Brett Knapik
Ranch Hand

Joined: Oct 15, 2000
Posts: 255
HTTP: standard used when browsing the web.
HTTPS: Secure version of HTTP. This is what makes it safe to transfer CC numbers online and other personal information private
------------------
In Gates we trust. Yeah right....


"Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning."
Mark Leong
Ranch Hand

Joined: Dec 11, 2000
Posts: 60
Can I just move the servlets (without changes) to a web server with SSL support and expect them to work?
Ruslan Ivanov
Ranch Hand

Joined: Feb 22, 2001
Posts: 72
what exactly ssl is ? how does one obtain it ?
Carl Trusiak
Sheriff

Joined: Jun 13, 2000
Posts: 3340
Originally posted by Mark Leong:
Can I just move the servlets (without changes) to a web server with SSL support and expect them to work?

Maybe, you'll have to evaluate the servlet code and the new webserver.
1) Does the webserver implement the same version (or higher) of the servlet API that your existing server does?
2) Did your servlet code use any propietary packages or code from your origninal server that isn't included or supported on the new one?
3) Does the new server have a documented bug that will prevent your code from executing properly?
If this evalutes positively then the only thing you can do is test it. Chances are there will be some tweeking to be done to either your servlet code or to the configuration of the new server.
------------------
Hope This Helps
Carl Trusiak


I Hope This Helps
Carl Trusiak, SCJP2, SCWCD
Mark Leong
Ranch Hand

Joined: Dec 11, 2000
Posts: 60
Thank you for reply.
Assuming that the answers to the questions are positive, what type of tweakings do I need to do, for example?
 
IntelliJ Java IDE
 
subject: Servlets and SSL
 
Threads others viewed
Want send username and password in url in some secure manner
javax.mail.SendFailedException:Sending Failed; when i send other domain
WA #2 ..... word association
JSSE/SSL with Applets
JSSE with Applets
WebSphere development made easy
without the weight of IBM tools
http://www.myeclipseide.com