                      response = UnauthorizedResponse(request.credentialFactories,
                                                      request.remoteAddr)
                  else:
-@@ -600,8 +650,13 @@
+@@ -594,22 +644,29 @@
+             return d
+ 
+         d = maybeDeferred(self.authenticate, request)
+-        d.addCallbacks(onAuth, onError)
++        d.addCallback(onAuth)
++        d.addErrback(onError)
+ 
+         return d
  
      def authenticate(self, request):
          def loginSuccess(result):

-            principalCollections = waitForDeferred(self.principalCollections(request))
-            yield principalCollections
-            principalCollections = principalCollections.getResult()
-
-            if len(principalCollections) == 0:
-                log.msg("DAV:principal-collection-set property cannot be found on the resource being authorized: %s" % self)
-            else:
-                log.msg("Could not find principal matching user id: %s" % authid)
-            raise HTTPError(responsecode.FORBIDDEN)
+            yield None
+            return
 
     findPrincipalForAuthID = deferredGenerator(findPrincipalForAuthID)
 
+    def authorizationPrincipal(self, request, authid, authnPrincipal, authnURI):

         for qname in self.deadProperties().list():
             if (qname not in qnames) and (qname[0] != twisted_private_namespace):
                 qnames.append(qname)
 
-        return succeed(qnames)
+        yield qnames
 
+    listProperties = deferredGenerator(listProperties)
+
     def listAllprop(self, request):
         """
         Some DAV properties should not be returned to a C{DAV:allprop} query.
@@ -535,7 +585,7 @@
                 completionDeferred.callback(None)
             else:
