| | |
| | | * CDDL HEADER END |
| | | * |
| | | * |
| | | * Portions Copyright 2006 Sun Microsystems, Inc. |
| | | * Portions Copyright 2006-2007 Sun Microsystems, Inc. |
| | | */ |
| | | package org.opends.server.extensions; |
| | | |
| | |
| | | import org.opends.server.types.DirectoryException; |
| | | import org.opends.server.types.InitializationException; |
| | | |
| | | import static org.opends.server.loggers.Debug.*; |
| | | import static org.opends.server.messages.ExtensionsMessages.*; |
| | | import static org.opends.server.messages.MessageHandler.*; |
| | | |
| | | |
| | | |
| | |
| | | extends TrustManagerProvider |
| | | implements X509TrustManager |
| | | { |
| | | /** |
| | | * The fully-qualified name of this class for debugging purposes. |
| | | */ |
| | | private static final String CLASS_NAME = |
| | | "org.opends.server.extensions.BlindTrustManagerProvider"; |
| | | |
| | | |
| | | |
| | |
| | | */ |
| | | public BlindTrustManagerProvider() |
| | | { |
| | | assert debugConstructor(CLASS_NAME); |
| | | |
| | | // No implementation is required. |
| | | } |
| | |
| | | public void initializeTrustManagerProvider(ConfigEntry configEntry) |
| | | throws ConfigException, InitializationException |
| | | { |
| | | assert debugEnter(CLASS_NAME, "initializeTrustManagerProvider", |
| | | String.valueOf(configEntry)); |
| | | |
| | | // No implementation is required. |
| | | } |
| | |
| | | */ |
| | | public void finalizeTrustManagerProvider() |
| | | { |
| | | assert debugEnter(CLASS_NAME, "finalizeTrustManagerProvider"); |
| | | |
| | | // No implementation is required. |
| | | } |
| | |
| | | public TrustManager[] getTrustManagers() |
| | | throws DirectoryException |
| | | { |
| | | assert debugEnter(CLASS_NAME, "getTrustManagers"); |
| | | |
| | | return new TrustManager[] { this }; |
| | | } |
| | |
| | | */ |
| | | public void checkClientTrusted(X509Certificate[] chain, String authType) |
| | | { |
| | | assert debugEnter(CLASS_NAME, "checkClientTrusted", |
| | | String.valueOf(chain), String.valueOf(authType)); |
| | | |
| | | // As long as we don't throw an exception, then the client certificate will |
| | | // be considered trusted. |
| | |
| | | */ |
| | | public void checkServerTrusted(X509Certificate[] chain, String authType) |
| | | { |
| | | assert debugEnter(CLASS_NAME, "checkServerTrusted", |
| | | String.valueOf(chain), String.valueOf(authType)); |
| | | |
| | | // As long as we don't throw an exception, then the server certificate will |
| | | // be considered trusted. |
| | |
| | | */ |
| | | public X509Certificate[] getAcceptedIssuers() |
| | | { |
| | | assert debugEnter(CLASS_NAME, "getAcceptedIssuers"); |
| | | |
| | | return new X509Certificate[0]; |
| | | } |