You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

264 lines
11 KiB

<?xml version='1.0' encoding='UTF-8'?>
<!DOCTYPE xep SYSTEM 'xep.dtd' [
<!ENTITY % ents SYSTEM "xep.ent">
<?xml-stylesheet type='text/xsl' href='xep.xsl'?>
<title>Account Transfer</title>
<abstract>A proposal for enabling the ability to transfer an account from one Jabber server to another.</abstract>
<type>Standards Track</type>
<spec>XMPP Core</spec>
<remark>Cleaned up the open issues and concerns section.</remark>
<remark>Added more specific details to the protocol. Added more examples. Tried to make the whole document more readable.</remark>
<remark>Setting scope, adding discussion about using jabber:iq:browse in the future for transports</remark>
<remark>Added more pseudo-protocol information. Added a known issues section.</remark>
<remark>First release to CVS, including editorial changes and assignment of number.</remark>
<remark>Initial version.</remark>
<section1 topic='Introduction'>
<p>I have found the need in the past to migrate an account from
one server to another for various reasons. Many of the people who
ask me about Jabber ask if there is a way to migrate their account
from one server to another if the need arises. There is no reason
Jabber can not handle this internally and update all the
JID-references appropriately.</p>
<p>Jabber servers come and go, especially ones run by people who
are just playing with the technology. Computers also die and
funding runs out. It can be hard on users to have to re-create
their rosters every time they have to change to a different
server. Administrators also want to provide an 'out' for their
users, so that they feel more secure in the time spent setting up
rosters. For these reasons there should be a way to migrate an
account from one server to another. </p>
<section1 topic='Main Body'>
<p>A basic overview of the behavior would be as follows.</p>
<section2 topic='Preconditions'>
<li>Bob has a jabber account on a server,
<li>Bob knows that the server is going to go down soon
and therefore needs to find a new jabber server.</li>
<li>He realizes that offers accounts to anyone, so he
sets out to migrate his account to</li>
<li>Bob does not yet have an account on</li>
<section2 topic='Order of events'>
<p>Throughout most of the account transfer the server hosting
the old account will be acting for the user. The end client
should have very little to do with the actual transfer.</p>
<li>Bob creates an account on</li>
<li>Bob logs into both and</li>
<li>From he sends the 'I want to migrate my
account' packet to This packet includes the JID
to migrate to.</li>
<li> sends the 'user wants to migrate account to
you' packet to This packet contains
the JID of the old account.</li>
<li> receives the 'user wants to
migrate account to you' packet and authorizes the
<li>Once the migration is authorized the server
will start the migration process. The first part is to
notify each person subscribed to's
presence that the account has moved to</li>
<li>Once that is complete the roster itself
must be added into's roster. There are
many issues with that remain and should be dealt with in the
future. See the section on scope for more information.</li>
<li>finally informs that the
transfer was completed.</li>
<section2 topic='Protocol Example'>
<example caption="User initiates process">
&#60;iq id='initacctxfer' to='' from='' type='ask'&#62;
&#60;query xmlns='jabber:iq:accountxfer'&#62;
<example caption='Server asks for permission from'>
&#60;iq id='acctxfer1' type='ask' from='' to=''&#62;
&#60;query xmlns='jabber:iq:accountxfer'&#62;
<example caption="XML received at user's new account">
&#60;iq id='acctxfer1' type='ask' from='' to=''&#62;
&#60;query xmlns='jabber:iq:accountxfer'&#62;
<example caption=" accepts the migration">
&#60;iq id='acctxfer1' type='result' to='' from=''&#62;
&#60;query xmlns='jabber:iq:accountxfer'&#62;
<p>On acceptance the server on which the old account resides
starts the migration process by sending this to each person
subscribed to the user's presence.</p>
<example caption="XML sent to each JID subscribed to's presence">
&#60;iq id='acctxferss1' type='set' from='' to=''&#62;
&#60;query xmlns='jabber:iq:accountxfer'&#62;
&#60;rosteritem jid=''/&#62;
<example caption="The server hosting the account of the roster item responds">
&#60;iq id='acctxferss1' type='result' to='' from=''/&#62;
<p>Once that update has been sent to all the contacts on the
roster the server sends to the server's roster as follows:</p>
<example caption="'s roster is transferred into's roster">
&#60;iq type='set' id='acctxferss2' from='' to=''&#62;
&#60;query xmlns='jabber:iq:accountxfer'&#62;
&#60;item jid='' name='friend1' subscription='both'/&#62;
&#60;item jid='' ask='subscribe'/&#62;
&#60;item jid='' subscription='from'/&#62;
<example caption=" responds saying the roster transfer was successful">
&#60;iq type='result' id='acctxferss2' to='' from=''/&#62;
<p>Once the migration finishes a notification is sent to the user:</p>
<example caption="Process completed">
&#60;iq id='initacctxfer' from='' to='' type='result'/&#62;
<section1 topic='Open Issues, Concerns and Scoping'>
<section2 topic='How do we handle transferring transport stuff?'>
<p>Because we cannot determine easily if the new server will
support the same transports as the old server we cannot
easily transfer entities that pass through the
transport. Therefore, until jabber:iq:browse matures, or
some other solution for determining if two transports
support the same functionality we should not attempt to
migrate transport information.</p>
<p>I propose the following algorithm for determining if a
particular roster item is a sub-item of a transport. There are
jabber roster items for each of the transports themselves,
something to the effect of or They contain no user portion of the jid. We
record all of these in a list that we will call the
'transport-list'. Then for each roster item we want to migrate
we compare its 'host' part of the jid to all items in the
'transport-list'. If the roster item matches, then the roster
item is a hosted through the transport and shouldn't be
<section2 topic='Empty Pointer Accounts'>
<p>Does the server keep an empty account that redirects requests
to the new account? I've been hearing mass rumblings of 'NO'
<section2 topic='vCards and private storage data'>
<p>How do we handle vCard information or server side stored
preferences? Since the account we're migrating to can be any
account some of that information might already be there, how do
we resolve conflicts?</p>
<p>Also, we cannot be sure that the new server supports
storage of private data. This again needs some sort of
features negotiation, discovery which could be provided by
<p> Until jabber:iq:browse is in the 'standards' stage, I
recommend we only transfer regular jabber users, and not
transfer anything but the roster. All the client software will
have to set their preferences for themselves on the new