update xmpp protocol

Amusingly, I am not really using xmpp ping for pairing. I forgot to put in
the ping tag! And when I did, it stopped working, on Google Talk. Seems
it handles client to client pings, at least using the same JID, without
actually sending them to the end client. My mistake avoided this,
and seems to work, so I've left it as-is for now, with just the git-annex
tag in an IQ message. Also tested on prosody.
This commit is contained in:
Joey Hess 2012-11-03 19:18:26 -04:00
parent 21a287a0b3
commit 5108d4b364
2 changed files with 5 additions and 1 deletions

View file

@ -85,7 +85,7 @@ isPresenceQuery p = case filter isGitAnnexTag (presencePayloads p) of
[] -> False
((Element _name attrs _nodes):_) -> any (isAttr queryAttr) attrs
{- A notification about a stage of pairing. Sent as an XMPP ping.
{- A notification about a stage of pairing. Sent as an XMPP IQ.
- The pairing info is sent using its id attribute; it also has a git-annex
- tag to identify it as from us. -}
pairingNotification :: PairStage -> UUID -> JID -> JID -> IQ

View file

@ -40,6 +40,10 @@ To indicate it's pushed changes to a git repo with a given UUID, a client uses:
Multiple UUIDs can be listed when multiple clients were pushed. If the
git repo does not have a git-annex UUID, an empty string is used.
For pairing over XMPP, git-annex uses IQ messages, also containing a
git-annex tag. The id attribute of the iq tag contains the pairing
information.
### security
Data git-annex sends over XMPP will be visible to the XMPP