| | |
| | | package org.opends.server.replication.protocol; |
| | | |
| | | import java.io.IOException; |
| | | import org.forgerock.i18n.slf4j.LocalizedLogger; |
| | | import java.net.Socket; |
| | | import java.util.SortedSet; |
| | | |
| | |
| | | import javax.net.ssl.SSLSocket; |
| | | import javax.net.ssl.SSLSocketFactory; |
| | | |
| | | import org.forgerock.i18n.LocalizableMessage; |
| | | import org.opends.server.config.ConfigException; |
| | | import org.opends.server.types.CryptoManager; |
| | | import org.opends.server.types.DirectoryConfig; |
| | | |
| | | import static org.opends.messages.ReplicationMessages.*; |
| | | import static org.opends.server.loggers.ErrorLogger.*; |
| | | import static org.opends.server.util.StaticUtils.*; |
| | | |
| | | /** |
| | |
| | | */ |
| | | public final class ReplSessionSecurity |
| | | { |
| | | |
| | | private static final LocalizedLogger logger = LocalizedLogger.getLoggerForThisClass(); |
| | | |
| | | /** |
| | | * Whether replication sessions use SSL encryption. |
| | | */ |
| | |
| | | { |
| | | // This is probably a connection attempt from an unexpected client |
| | | // log that to warn the administrator. |
| | | final LocalizableMessage message = INFO_SSL_SERVER_CON_ATTEMPT_ERROR.get( |
| | | socket.getRemoteSocketAddress().toString(), |
| | | logger.debug(INFO_SSL_SERVER_CON_ATTEMPT_ERROR, socket.getRemoteSocketAddress().toString(), |
| | | socket.getLocalSocketAddress().toString(), |
| | | e.getLocalizedMessage()); |
| | | logError(message); |
| | | return null; |
| | | } |
| | | finally |