Solved

compiling error. need help!!

Posted on 2002-03-31
1
190 Views
Last Modified: 2010-03-31
Hello,
anybody can give me a clue on how to solve this?

error message:
SSLInfo.java:70: incompatible types
found   : java.lang.Object
required: java.security.cert.X509Certificate
                   cert = req.getAttribute("javax.servlet.request.X509Certificate");
--
the snippet code =
 java.security.cert.X509Certificate cert;
cert = req.getAttribute("javax.servlet.request.X509Certificate");
--

i get this snippet from iplanet documentation. and it gives me compiling error.please help!
0
Comment
Question by:anil_80
1 Comment
 
LVL 6

Accepted Solution

by:
kotan earned 50 total points
ID: 6909544
You need to cast the return object to X509Certificate.

java.security.cert.X509Certificate cert;
cert = (java.security.cert.X509Certificate)  req.getAttribute("javax.servlet.request.X509Certificate");
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
hibernate example for saving data 19 73
What's wrong with this code? 4 34
Adding multiple JVM environments to RedHat 6 7 69
restrict decimal places for double datatype 10 29
Introduction Java can be integrated with native programs using an interface called JNI(Java Native Interface). Native programs are programs which can directly run on the processor. JNI is simply a naming and calling convention so that the JVM (Java…
Java Flight Recorder and Java Mission Control together create a complete tool chain to continuously collect low level and detailed runtime information enabling after-the-fact incident analysis. Java Flight Recorder is a profiling and event collectio…
Viewers learn about the “for” loop and how it works in Java. By comparing it to the while loop learned before, viewers can make the transition easily. You will learn about the formatting of the for loop as we write a program that prints even numbers…
Viewers will learn about if statements in Java and their use The if statement: The condition required to create an if statement: Variations of if statements: An example using if statements:

713 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