From 4a4a8540f0b64feff6934c3215c6f896c9561c7d Mon Sep 17 00:00:00 2001
From: neil_a_wilson <neil_a_wilson@localhost>
Date: Thu, 08 Feb 2007 22:27:58 +0000
Subject: [PATCH] Update the AuthenticationInfo object to store the entries for the authentication and authorization identities rather than just their DNs.  This includes a mechanism to keep those entries up to date as changes occur in the server, and also includes a hook for ClientConnection subclasses to perform processing whenever a connection is terminated.

---
 opends/src/server/org/opends/server/core/SearchOperation.java |   62 +++++++++++++++---------------
 1 files changed, 31 insertions(+), 31 deletions(-)

diff --git a/opends/src/server/org/opends/server/core/SearchOperation.java b/opends/src/server/org/opends/server/core/SearchOperation.java
index 5667eae..d8b6f44 100644
--- a/opends/src/server/org/opends/server/core/SearchOperation.java
+++ b/opends/src/server/org/opends/server/core/SearchOperation.java
@@ -22,7 +22,7 @@
  * CDDL HEADER END
  *
  *
- *      Portions Copyright 2006 Sun Microsystems, Inc.
+ *      Portions Copyright 2006-2007 Sun Microsystems, Inc.
  */
 package org.opends.server.core;
 
@@ -1783,25 +1783,25 @@
             }
 
 
-            DN authzDN;
-            try
-            {
-              authzDN = proxyControl.getValidatedAuthorizationDN();
-            }
-            catch (DirectoryException de)
-            {
-              assert debugException(CLASS_NAME, "run", de);
+              Entry authorizationEntry;
+              try
+              {
+                authorizationEntry = proxyControl.getAuthorizationEntry();
+              }
+              catch (DirectoryException de)
+              {
+                assert debugException(CLASS_NAME, "run", de);
 
-              setResultCode(de.getResultCode());
-              appendErrorMessage(de.getErrorMessage());
+                setResultCode(de.getResultCode());
+                appendErrorMessage(de.getErrorMessage());
 
-              break searchProcessing;
-            }
+                break searchProcessing;
+              }
 
 
-            // FIXME -- Should we specifically check permissions here, or let
-            //          the earlier access control checks handle it?
-            setAuthorizationDN(authzDN);
+              // FIXME -- Should we specifically check permissions here, or let
+              //          the earlier access control checks handle it?
+              setAuthorizationEntry(authorizationEntry);
           }
           else if (oid.equals(OID_PROXIED_AUTH_V2))
           {
@@ -1828,25 +1828,25 @@
             }
 
 
-            DN authzDN;
-            try
-            {
-              authzDN = proxyControl.getValidatedAuthorizationDN();
-            }
-            catch (DirectoryException de)
-            {
-              assert debugException(CLASS_NAME, "run", de);
+              Entry authorizationEntry;
+              try
+              {
+                authorizationEntry = proxyControl.getAuthorizationEntry();
+              }
+              catch (DirectoryException de)
+              {
+                assert debugException(CLASS_NAME, "run", de);
 
-              setResultCode(de.getResultCode());
-              appendErrorMessage(de.getErrorMessage());
+                setResultCode(de.getResultCode());
+                appendErrorMessage(de.getErrorMessage());
 
-              break searchProcessing;
-            }
+                break searchProcessing;
+              }
 
 
-            // FIXME -- Should we specifically check permissions here, or let
-            //          the earlier access control checks handle it?
-            setAuthorizationDN(authzDN);
+              // FIXME -- Should we specifically check permissions here, or let
+              //          the earlier access control checks handle it?
+              setAuthorizationEntry(authorizationEntry);
           }
           else if (oid.equals(OID_PERSISTENT_SEARCH))
           {

--
Gitblit v1.10.0