Handle XEP-0092: jabber:iq:version

RESOLVED FIXED in Instantbird 43

Status

Chat Core
XMPP
RESOLVED FIXED
2 years ago
2 years ago

People

(Reporter: aleth, Assigned: abdelrhman)

Tracking

trunk
Instantbird 43

Firefox Tracking Flags

(Not tracked)

Details

(URL)

Attachments

(1 attachment, 1 obsolete attachment)

Comment hidden (empty)
(Reporter)

Comment 1

2 years ago
"Querying Another Entity for its Software Version". Used e.g. by the Slack XMPP gateway on connection.
(Assignee)

Updated

2 years ago
Assignee: nobody → a.ahmed1026
(Reporter)

Comment 2

2 years ago
We shouldn't send the OS, but imho we can send the app name and probably the version, as we do for IRC.
Flags: needinfo?(florian)
(Assignee)

Comment 3

2 years ago
Created attachment 8638958 [details] [diff] [review]
rev 1 - handle version request

(In reply to aleth [:aleth] from comment #2)
> We shouldn't send the OS, but imho we can send the app name and probably the
> version, as we do for IRC.

If it's OK, this patch is ready for review.
Attachment #8638958 - Flags: review?(aleth)
(Reporter)

Comment 4

2 years ago
Comment on attachment 8638958 [details] [diff] [review]
rev 1 - handle version request

Review of attachment 8638958 [details] [diff] [review]:
-----------------------------------------------------------------

Looks good to me. Please make a note in the service discovery bug to implement section 4 of xep-0092.

::: chat/protocols/xmpp/xmpp.jsm
@@ +1230,5 @@
> +        children.push(Stanza.node("version", null, null,
> +                                  Services.appinfo.version));
> +        let versionQuery = Stanza.node("query", Stanza.NS.version, null,
> +                                       children);
> +        this.sendStanza(Stanza.iq("result", aStanza.attributes["id"],

Can we move aStanza.attributes["id"] and "from" into local variables at the beginning of the "get" if clause to reduce duplication? All responses to IQ stanzas will need them.
(In reply to aleth [:aleth] from comment #2)
> We shouldn't send the OS, but imho we can send the app name and probably the
> version, as we do for IRC.

Seems OK to me. Especially if we already do it on IRC. Let's not send the build id though.
Flags: needinfo?(florian)
(Assignee)

Comment 6

2 years ago
Created attachment 8655003 [details] [diff] [review]
rev 2 - handle version request
Attachment #8638958 - Attachment is obsolete: true
Attachment #8638958 - Flags: review?(aleth)
Attachment #8655003 - Flags: review?(aleth)
(Reporter)

Updated

2 years ago
Attachment #8655003 - Flags: review?(aleth) → review+
(Reporter)

Updated

2 years ago
Keywords: checkin-needed
(Reporter)

Comment 7

2 years ago
https://hg.mozilla.org/comm-central/rev/878a4890c96ad20db551abcd65fa2af6d6170da1
Bug 1186658 - Handle received version request and reply in XMPP. r=aleth
(Reporter)

Updated

2 years ago
Status: NEW → RESOLVED
Last Resolved: 2 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → Instantbird 43
You need to log in before you can comment on or make changes to this bug.