summary refs log tree commit diff
path: root/synapse/federation/federation_server.py
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2015-01-30 15:58:28 +0000
committerErik Johnston <erik@matrix.org>2015-01-30 15:58:28 +0000
commit776ac820f9bb7f0e9c2fae9facbee05b0132079e (patch)
tree09d07819de84e9a64f89d4e52b6242b237a95310 /synapse/federation/federation_server.py
parentOnly auth_events with event if event in event.auth_events (diff)
downloadsynapse-776ac820f9bb7f0e9c2fae9facbee05b0132079e.tar.xz
Briefly doc structure of query_auth API.
Diffstat (limited to 'synapse/federation/federation_server.py')
-rw-r--r--synapse/federation/federation_server.py18
1 files changed, 18 insertions, 0 deletions
diff --git a/synapse/federation/federation_server.py b/synapse/federation/federation_server.py
index 84ed0a0ba0..5fbd8b19de 100644
--- a/synapse/federation/federation_server.py
+++ b/synapse/federation/federation_server.py
@@ -232,6 +232,24 @@ class FederationServer(object):
 
     @defer.inlineCallbacks
     def on_query_auth_request(self, origin, content, event_id):
+        """
+        Content is a dict with keys::
+            auth_chain (list): A list of events that give the auth chain.
+            missing (list): A list of event_ids indicating what the other
+              side (`origin`) think we're missing.
+            rejects (dict): A mapping from event_id to a 2-tuple of reason
+              string and a proof (or None) of why the event was rejected.
+              The keys of this dict give the list of events the `origin` has
+              rejected.
+
+        Args:
+            origin (str)
+            content (dict)
+            event_id (str)
+
+        Returns:
+            Deferred: Results in `dict` with the same format as `content`
+        """
         auth_chain = [
             (yield self._check_sigs_and_hash(self.event_from_pdu_json(e)))
             for e in content["auth_chain"]