[tor-bugs] #9022 [Pluggable transport]: Create an XMPP pluggable transport
Tor Bug Tracker & Wiki
blackhole at torproject.org
Sat Jun 8 17:00:19 UTC 2013
#9022: Create an XMPP pluggable transport
---------------------------------+------------------------------------------
Reporter: asn | Owner: feynman
Type: task | Status: accepted
Priority: normal | Milestone:
Component: Pluggable transport | Version:
Keywords: | Parent:
Points: | Actualpoints:
---------------------------------+------------------------------------------
Comment(by feynman):
Replying to [comment:3 asn]:
I should make a couple of notes here. First of all, the client really
controls every aspect of initializing the connection. The xmpp bot on the
server side just logs into an xmpp server and listens for traffic. It does
not even bind to a port.
On the client side, the xmpp bot binds to one or more ports and listens
for traffic. It associates each of these ports with:
*An xmpp username to forward traffic to
*An ip:port that the xmpp bot on the server side should try to connect to
When it gets a connection, it sends a message "connect me!" to the xmpp
bot on the server through the chatline. It puts the ip:port the server
should try to connect to in the xml subject tag and the ip:port of its
newly spawned connect socket in the xml nick tag (used for nicknames).
This way, the xmpp bot on the server side has a way to send data to that
connected socket when replying. The client xmpp bot also creates an entry
in its routing table that associates the following tuple:
(ip:port of connected socket, server's xmpp username, server ip:port to
connect to)
with the newly connected socket.
When the xmpp bot on the server side gets a connection request, it creates
a new socket and tries to connect it to the ip:port specified in the
subject tag. If successful, it adds an entry to its routing table that
associates the following tuple:
(ip:port that the server just connected to, client's xmpp username,
client's connected socket's ip:port)
with the newly connected socket.
Now, when either socket receives data, they are prompted to send the data
over the chat server using the socket's key in the routing table to
construct the appropriate nick and subject xml tags. When a message is
received over an xmpp server, the routing table key is constructed from
the username of the computer that sent it, along with the nick and subject
xml tags. The data is then forwarded to the appropriate socket.
An analogous process takes place for disconnections, starting with a
closing socket sending a "disconnect me!" message to the xmpp bot on the
other side of the chat server.
--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/9022#comment:7>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
More information about the tor-bugs
mailing list