 +            that is found; {principalURI} is the C{str} URI of the principal.
 +            If not found return None.
 +        """
-+        # FIXME: should self.principalCollections() return resources instead of URIs?
-+
          # Try to match principals in each principal collection on the resource
          collections = waitForDeferred(self.principalCollections(request))
          yield collections
          collections = collections.getResult()
  
--        for collection in collections:
+         for collection in collections:
 -            principalURI = joinURL(str(collection), authid)
-+        for collectionURI in collections:
-+            collection = waitForDeferred(request.locateResource(collectionURI))
-+            yield collection
-+            collection = collection.getResult()
- 
--            principal = waitForDeferred(request.locateResource(principalURI))
-+            # FIXME: collection = IPrincipalCollectionResource(collection)
-+
-+            principal = collection.principalForUser(authid)
-+
-+            # FIXME: Why return a tuple?
-+
++            principalURI = joinURL(collection, authid)
+ 
+             principal = waitForDeferred(request.locateResource(principalURI))
              yield principal
--            principal = principal.getResult()
--
+             principal = principal.getResult()
+ 
 -            if isPrincipalResource(principal):
 -                yield (principal, principalURI)
--                return
-+            return
++            if isPrincipalResource(principal) and principal.exists():
++                yield principal, principalURI
+                 return
          else:
 -            principalCollections = waitForDeferred(self.principalCollections(request))
 -            yield principalCollections

             elif namespace == twisted_dav_namespace:
                 if name == "resource-class":
                     class ResourceClass (davxml.WebDAVTextElement):
@@ -366,12 +404,26 @@
         # FIXME: A set would be better here, that that's a python 2.4+ feature.
         qnames = list(self.liveProperties)
 

+        @param authid: a string containing the uthentication/authorization identifier
+            for the principal to lookup.
+        @param authnPrincipal: the L{IDAVPrincipal} for the authenticated principal
+        @param authnURI: a C{str} containing the URI of the authenticated principal
+        @return: a deferred result C{tuple} of (L{IDAVPrincipal}, C{str}) containing the authorization principal
+            resource and URI respectively.
+        """
+        return succeed((authnPrincipal, authnURI,))
+        
     def samePrincipal(self, principal1, principal2):
         """
         Check whether the two prinicpals are exactly the same in terms of
@@ -1511,6 +1616,265 @@
         return None
 
     ##
