diff options
author | David Edmundson <kde@davidedmundson.co.uk> | 2013-09-02 01:32:14 +0000 |
---|---|---|
committer | Guillaume Desmottes <guillaume.desmottes@collabora.co.uk> | 2013-09-06 11:48:50 +0200 |
commit | 247fe13dd2dee1b332fbdad4effee97fc9e1d408 (patch) | |
tree | f90c64135d45f0e9795e7a6c31ac8252455a8294 | |
parent | 420177e944604fb765bec382cbf952379a6ebf71 (diff) |
If we send an IQ to a server allow "from" to be empty
-rw-r--r-- | wocky/wocky-c2s-porter.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/wocky/wocky-c2s-porter.c b/wocky/wocky-c2s-porter.c index 8f0daa0..02c46cd 100644 --- a/wocky/wocky-c2s-porter.c +++ b/wocky/wocky-c2s-porter.c @@ -859,6 +859,16 @@ check_spoofing (WockyC2SPorter *self, goto finally; } + /* If we sent an IQ to the server itself, allow it to + * omit 'from' in its reply, which is normally used + * for messages from the server on behalf of our own + * account (as of 2013-09-02, the Facebook beta server + * does this). See fd.o #68829 */ + + if (from == NULL && !wocky_strdiff (should_be_from, self->priv->domain)) { + goto finally; + } + /* if we sent an IQ to our full or bare JID, allow our server to omit 'to' * in the reply (Prosody 0.6.1 does this with the resulting error if we * send disco#info to our own bare JID), or to use our full JID. */ |