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 Java Server using SSL Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "Java Server using SSL" Watch "Java Server using SSL" New topic
Author

Java Server using SSL

Harry Gohil
Greenhorn

Joined: Oct 11, 2013
Posts: 1
Hi guys, I have implemented a simple server which I have hosted on a VMware and I connect to it using https://ip:port/index.html line. Now, I want to implement ssl on this server and connect to it using https://ip:port/index.html

Now I already tried creating a Secure Socket.When I try to connect to my server using https://ip:8080/index.html (Running the server on VMware) the browser shows "waiting to connect" and nothing happens. I then open a new window and try to connect using it. Now at this time the old window shows a certificate error and the server crashes .. Throwing a null pointer exception.. while the new windows shows "could not connect to server". Here is the code.



[/code]
Any ideas why it is giving me that error? I tried looking at it line by line and I think it is this line which is the main problem. I think the value of s is null and I have absolutely no idea why.
Mark Koontz
Greenhorn

Joined: Aug 20, 2013
Posts: 2
The value of s is not null. Otherwise you would get an NPE at line 37. Line 38 br.readLine() is returning null, which is why the NPE occurs in the StringTokenizer construction.

 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Java Server using SSL