[Bug 39933] New: Gabble advertises tube services as supported with just a Chan.Requested=true Client filter
bugzilla-daemon at freedesktop.org
bugzilla-daemon at freedesktop.org
Mon Aug 8 17:35:26 CEST 2011
https://bugs.freedesktop.org/show_bug.cgi?id=39933
Summary: Gabble advertises tube services as supported with just
a Chan.Requested=true Client filter
Product: Telepathy
Version: git master
Platform: Other
OS/Version: All
Status: ASSIGNED
Severity: normal
Priority: medium
Component: gabble
AssignedTo: ollisal at gmail.com
ReportedBy: ollisal at gmail.com
QAContact: telepathy-bugs at lists.freedesktop.org
1) I start my example tube initiator application for the new TpQt4 plug-in
StreamTube API (#30584), which registers a Handler with
dict entry(
string "HandlerChannelFilter"
variant array [
array [
dict entry(
string "org.freedesktop.Telepathy.Channel.ChannelType"
variant string
"org.freedesktop.Telepathy.Channel.Type.StreamTube"
)
dict entry(
string "org.freedesktop.Telepathy.Channel.Requested"
variant boolean true
)
dict entry(
string
"org.freedesktop.Telepathy.Channel.TargetHandleType"
variant uint32 1
)
dict entry(
string
"org.freedesktop.Telepathy.Channel.Type.StreamTube.Service"
variant string
"tp-qt4-stube-example"
)
]
]
)
2) MC calls UpdateCapabilities on all connections with that filter verbatim as
expected:
method call sender=:1.1354 -> dest=:1.1353 serial=155
path=/org/freedesktop/Telepathy/Connection/gabble/jabber/test2_40test_2ecollabora_2eco_2euk_2fda6967aa;
interface=org.freedesktop.Telepathy.Connection.Interface.ContactCapabilities;
member=UpdateCapabilities
array [
struct {
string
"org.freedesktop.Telepathy.Client.TpQt4STubeServer__1_1360_18f0410"
array [
array [
dict entry(
string "org.freedesktop.Telepathy.Channel.Requested"
variant boolean true
)
dict entry(
string "org.freedesktop.Telepathy.Channel.ChannelType"
variant string
"org.freedesktop.Telepathy.Channel.Type.StreamTube"
)
dict entry(
string "org.freedesktop.Telepathy.Channel.TargetHandleType"
variant uint64 1
)
dict entry(
string
"org.freedesktop.Telepathy.Channel.Type.StreamTube.Service"
variant string "tp-qt4-stube-example"
)
]
]
array [
]
}
]
3) Gabble gets all raved up
(telepathy-gabble:11783): gabble-DEBUG: gabble_connection_update_capabilities
(connection.c:3170): enter
(telepathy-gabble:11783): gabble-DEBUG: gabble_private_tubes_factory_add_cap
(private-tubes-factory.c:598):
org.freedesktop.Telepathy.Client.TpQt4STubeServer__1_1358_e5a410: adding
capability
http://telepathy.freedesktop.org/xmpp/tubes/stream#tp-qt4-stube-example
(telepathy-gabble:11783): gabble-DEBUG: gabble_media_factory_add_caps
(media-factory.c:1018): Client
org.freedesktop.Telepathy.Client.TpQt4STubeServer__1_1358_e5a410 media
capabilities:
(telepathy-gabble:11783): gabble-DEBUG: gabble_connection_update_capabilities
(connection.c:3215): client
org.freedesktop.Telepathy.Client.TpQt4STubeServer__1_1358_e5a410 contributes:
--begin--
Feature:
http://telepathy.freedesktop.org/xmpp/tubes/stream#tp-qt4-stube-example
--end--
(telepathy-gabble:11783): gabble-DEBUG: gabble_connection_refresh_capabilities
(connection.c:2369): incorporating caps for
org.freedesktop.Telepathy.Client.TpQt4STubeServer__1_1358_e5a410:
--begin--
Feature:
http://telepathy.freedesktop.org/xmpp/tubes/stream#tp-qt4-stube-example
--end--
4) Anybody in disco terms with the local Gabble account here sees
http://telepathy.freedesktop.org/xmpp/tubes/stream#tp-qt4-stube-example as a
supported capability, which would mean that they can now receive stream tubes
with the service tp-qt4-stube-example
Similar issues might exist for other kinds of channels, but for stream tubes
this is especially important, as the initiator (classically, a TCP server) and
receiver (~TCP client) applications are often separate and not dependent on
each other. With the current Gabble behavior, just installing the server
application would make it appear that something usable as a client through a
tube is available.
Of course, this could be fixed in MC by ignoring Requested=true channel classes
from the UpdateCapabilities round, but that seems like a short-sighted hack;
after all, as Will pointed out, on some protocols it might be perfectly
sensible to advertise to the network e.g. that "this person here might call
you" ( there is a Handler with a Requested=true, Type=Call class in its
filters).
I'll cook a patch for Gabble - specifically the tube factories.
--
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
More information about the telepathy-bugs
mailing list