          return succeed(None)
  
  class DAVPrincipalResource (DAVLeafResource):
-@@ -1712,6 +2082,37 @@
+@@ -1712,6 +2076,37 @@
  davxml.registerElement(TwistedACLInheritable)
  davxml.ACE.allowed_children[(twisted_dav_namespace, "inheritable")] = (0, 1)
  

 
         getChild()
 
@@ -564,19 +622,21 @@
         See L{IDAVResource.authorize}.
         """
         def onError(failure):
-            log.err("Invalid authentication details: %s" % (request,))
-            raise HTTPError(UnauthorizedResponse(
+            failure.trap(UnauthorizedLogin)
+
+            log.err("Authentication failed: %s" % (failure.value,))
+            return Failure(HTTPError(UnauthorizedResponse(
                 request.credentialFactories,
                 request.remoteAddr
-            ))
+            )))
 
         def onAuth(result):
             def onErrors(failure):
                 failure.trap(AccessDeniedError)
                 

             if privileges is None:
                 return child
    
@@ -517,14 +570,17 @@
             return d
 
         def gotChild(child, childpath):
