|
|
Java and X509 Certificates .. help!!
Hello,
I need some help! I would like to know if it is possible to get, from
the browser (web client), the server X509 certificate used by it in an
already SSL established session with the client (browser). As in the
server side, with your application you can get the client X509
certificate used by the client in order to authenticate himself, it
should be an analogous process or API in the web client to get the
server certificate.
The aim is to develop some client script (preferable JavaScript, but
could be with Java Applet) in order to deal with the server X509
certificate fields.
Can you help me? Thanks in advance!!
Best regards,
|
|
0
|
|
|
|
Reply
|
paxtra (4)
|
9/4/2006 10:22:55 AM |
|
Could n't you get the SSLSession from the SSLSocket using getSession and
then use getPeerCertificate or getPeerCertificatChain to get the
certificates?
something like this..
......
SSLSession session = socket.getSession();
java.security.cert.Certificate certs[] =
session.getPeerCertificates();
for (int i=0; i < certs.length; i++) {
System.out.println("Certificate[" + i + "]" + certs[i]);
}
javax.security.cert.X509Certificate X509certs[] =
session.getPeerCertificateChain();
for (int i=0; i < certs.length; i++) {
System.out.println("X509 Certificate[" + i + "]" + X509certs[i]);
}
......
= Ram Marti
pax wrote:
> Hello,
>
> I need some help! I would like to know if it is possible to get, from
> the browser (web client), the server X509 certificate used by it in an
> already SSL established session with the client (browser). As in the
> server side, with your application you can get the client X509
> certificate used by the client in order to authenticate himself, it
> should be an analogous process or API in the web client to get the
> server certificate.
>
> The aim is to develop some client script (preferable JavaScript, but
> could be with Java Applet) in order to deal with the server X509
> certificate fields.
>
> Can you help me? Thanks in advance!!
>
> Best regards,
>
|
|
0
|
|
|
|
Reply
|
ram_no_spam_marti
|
9/5/2006 7:08:14 PM
|
|
|
1 Replies
260 Views
(page loaded in 3.819 seconds)
Similiar Articles: Java and X509 Certificates .. help!! - comp.lang.java.security ...Java and X509 Certificates .. help!! - comp.lang.java.security ... Hello, I need some help! I would like to know if it is possible to get, from the browser (web ... JavaScript and X509 Certificates .. help !! - comp.lang.javascript ...Hello, I need some help! I would like to know if it is possible to get, from the browser (web client), the server X509 certificate used by it in an a... Tutorial on usage of X509 certificate extension - comp.lang.java ...Java and X509 Certificates .. help!! - comp.lang.java.security ... Tutorial on usage of X509 certificate extension - comp.lang.java ... > interested on the difference ... SSL Socket handshake problem - comp.lang.java.securityX509 Certificates w/ JDK 1.1 - comp.lang.java.security SSL Socket handshake problem - comp.lang.java.security Windows 7 and Eudora 7.1: problems, problems and problems ... Extracting an X509Certificate from XML - comp.lang.java.security ...I have a SOAP envelope digitally signed and including an X509 certificate. ... Java and X509 Certificates .. help!! - comp.lang.java.security ... Extracting RSA Private Key ... Problems importing final certificate into keystore - comp.lang ...Importing private key from PKCS#8 file format - comp.lang.java ..... down sending the x509 certificate ... Problems importing PKCS12 keystore in IBM JCE - comp.lang ... Encrypt/Decrypt String with RSA and X509Certificate - comp.lang ...Hi, I've 2 files : CA.cert (X509 certificate) and CA.key (contains private key) I want to ... Keys - comp.lang.java.security I need to create a very simple application whick ... disable ssl certificate host name check in java.policy - comp.lang ...Java and X509 Certificates .. help!! - comp.lang.java.security ... disable ssl certificate host name check in java.policy - comp.lang ..... if it's possible and how to ... JAVA HELP problem with SSL - comp.lang.java.securityHi dears, Is any one connected to java help using SSL ? Our ... Java and X509 Certificates .. help!! - comp.lang.java.security ... JAVA HELP problem with SSL ... DER decoding from x.509 v3 certificate - comp.lang.java.security ...Java and X509 Certificates .. help!! - comp.lang.java.security ... DER decoding from x.509 v3 certificate - comp.lang.java.security ... JavaScript and X509 Certificates ... Java and X509 Certificates .. help!! - Application Forum at ...Java and X509 Certificates .. help!! - Java . This is a discussion on Java and X509 Certificates .. help!! - Java; Hello, I need some help! I would like to know if it ... Java and X509 Certificates .. help!! - comp.lang.java.security ...Java and X509 Certificates .. help!! - comp.lang.java.security ... Hello, I need some help! I would like to know if it is possible to get, from the browser (web ... 7/23/2012 7:09:07 PM
|
|
|
|
|
|
|
|
|