Package org.opennms.core.utils
Class RelaxedX509ExtendedTrustManager
- java.lang.Object
-
- javax.net.ssl.X509ExtendedTrustManager
-
- org.opennms.core.utils.RelaxedX509ExtendedTrustManager
-
- All Implemented Interfaces:
javax.net.ssl.TrustManager
,javax.net.ssl.X509TrustManager
public class RelaxedX509ExtendedTrustManager extends javax.net.ssl.X509ExtendedTrustManager
This class is used to change the behavior of the X509ExtendedTrustManager that is used to validate certificates, and algorithms for SSL/TLS sockets. With this class all certificates will be approved.- Author:
- Ronald Roskens, OpenNMS
-
-
Constructor Summary
Constructors Constructor Description RelaxedX509ExtendedTrustManager()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
checkClientTrusted(java.security.cert.X509Certificate[] chain, java.lang.String authType)
void
checkClientTrusted(java.security.cert.X509Certificate[] chain, java.lang.String authType, java.net.Socket socket)
void
checkClientTrusted(java.security.cert.X509Certificate[] chain, java.lang.String authType, javax.net.ssl.SSLEngine ssle)
void
checkServerTrusted(java.security.cert.X509Certificate[] chain, java.lang.String authType)
void
checkServerTrusted(java.security.cert.X509Certificate[] chain, java.lang.String authType, java.net.Socket socket)
void
checkServerTrusted(java.security.cert.X509Certificate[] chain, java.lang.String authType, javax.net.ssl.SSLEngine ssle)
java.security.cert.X509Certificate[]
getAcceptedIssuers()
getAcceptedIssuers
-
-
-
Method Detail
-
checkClientTrusted
public void checkClientTrusted(java.security.cert.X509Certificate[] chain, java.lang.String authType) throws java.security.cert.CertificateException
- Throws:
java.security.cert.CertificateException
-
checkServerTrusted
public void checkServerTrusted(java.security.cert.X509Certificate[] chain, java.lang.String authType) throws java.security.cert.CertificateException
- Throws:
java.security.cert.CertificateException
-
getAcceptedIssuers
public java.security.cert.X509Certificate[] getAcceptedIssuers()
getAcceptedIssuers
- Returns:
- an array of
X509Certificate
objects.
-
checkClientTrusted
public void checkClientTrusted(java.security.cert.X509Certificate[] chain, java.lang.String authType, java.net.Socket socket) throws java.security.cert.CertificateException
- Specified by:
checkClientTrusted
in classjavax.net.ssl.X509ExtendedTrustManager
- Throws:
java.security.cert.CertificateException
-
checkServerTrusted
public void checkServerTrusted(java.security.cert.X509Certificate[] chain, java.lang.String authType, java.net.Socket socket) throws java.security.cert.CertificateException
- Specified by:
checkServerTrusted
in classjavax.net.ssl.X509ExtendedTrustManager
- Throws:
java.security.cert.CertificateException
-
checkClientTrusted
public void checkClientTrusted(java.security.cert.X509Certificate[] chain, java.lang.String authType, javax.net.ssl.SSLEngine ssle) throws java.security.cert.CertificateException
- Specified by:
checkClientTrusted
in classjavax.net.ssl.X509ExtendedTrustManager
- Throws:
java.security.cert.CertificateException
-
checkServerTrusted
public void checkServerTrusted(java.security.cert.X509Certificate[] chain, java.lang.String authType, javax.net.ssl.SSLEngine ssle) throws java.security.cert.CertificateException
- Specified by:
checkServerTrusted
in classjavax.net.ssl.X509ExtendedTrustManager
- Throws:
java.security.cert.CertificateException
-
-