From d3a10338d643cf04e89e577ba496c547e0bf7516 Mon Sep 17 00:00:00 2001
From: neil_a_wilson <neil_a_wilson@localhost>
Date: Wed, 28 Feb 2007 21:01:32 +0000
Subject: [PATCH] Add a new key manager which provides the ability to specify which certificate should be presented based on its alias (aka its nickname).  This is used both by server-side code which needs to present a certificate to clients, as well as by client-side code which needs to present a certificate to the server.

---
 opends/src/server/org/opends/server/protocols/ldap/LDAPClientConnection.java |   17 +++++++++++++++++
 1 files changed, 17 insertions(+), 0 deletions(-)

diff --git a/opends/src/server/org/opends/server/protocols/ldap/LDAPClientConnection.java b/opends/src/server/org/opends/server/protocols/ldap/LDAPClientConnection.java
index 06bad10..4cd3342 100644
--- a/opends/src/server/org/opends/server/protocols/ldap/LDAPClientConnection.java
+++ b/opends/src/server/org/opends/server/protocols/ldap/LDAPClientConnection.java
@@ -2653,5 +2653,22 @@
 
     return connectionHandler.getTrustManagerProviderDN();
   }
+
+
+
+  /**
+   * Retrieves the alias of the server certificate that should be used
+   * for operations requiring a server certificate.  The default
+   * implementation returns {@code null} to indicate that any alias is
+   * acceptable.
+   *
+   * @return  The alias of the server certificate that should be used
+   *          for operations requring a server certificate, or
+   *          {@code null} if any alias is acceptable.
+   */
+  public String getCertificateAlias()
+  {
+    return connectionHandler.getSSLServerCertNickname();
+  }
 }
 

--
Gitblit v1.10.0