1
0
mirror of https://github.com/moparisthebest/xeps synced 2024-11-21 08:45:04 -05:00

Easy Onboarding: creating invitations

This commit is contained in:
Georg Lukas 2018-01-09 22:22:32 +01:00
parent 62ba903912
commit ef914fbc75

View File

@ -83,12 +83,15 @@
</p>
</section1>
<section1 topic='Discovery' anchor='discover'>
<p>Romeo can query his server for the availability of "User Invitation" and
"Account Creation" commands:</p>
<example caption="Discover available ad-hoc commands"><![CDATA[
<iq type='get' from='romeo@example.com' to='example.com' id='disco'>
<query xmlns='http://jabber.org/protocol/disco#items'
node='http://jabber.org/protocol/commands'/>
</iq>
]]></example>
<p>TODO: use appropriate node namespace.</p>
<example caption="Discovery result for available ad-hoc commands"><![CDATA[
<iq type='result' to='romeo@example.com' from='example.com' id='disco'>
<query xmlns='http://jabber.org/protocol/disco#items'
@ -102,12 +105,17 @@
</query>
</iq>
]]></example>
<p>When performing the account creation, Juliet's client needs to ensure
that the server supports the extended IBR protocol with a &lt;preauth&gt;
token: TODO</p>
</section1>
<section1 topic='Glossary' anchor='glossary'>
<p>OPTIONAL.</p>
</section1>
<section1 topic='Use Cases' anchor='usecases'>
<section2 topic='User Invitation' anchor='invitation'>
<section2 topic='Creating a User Invitation' anchor='create-invitation'>
<p>A user can execute the 'invite' command to obtain a new invitation link
with a unique invitation token.</p>
<example caption="Exceute user invitation command"><![CDATA[
<iq type='set' from='romeo@example.com' to='example.com' id='exec1'>
<command xmlns='http://jabber.org/protocol/commands'
@ -136,22 +144,35 @@
</command>
</iq>
]]></example>
</section2>
<p>The token should be unique, sufficiently
long and generated by a strong random number generator.</p>
<p>A server MUST provide the <strong>uri</strong> field which contains an
XMPP URI of the following format:</p>
<code>xmpp:inviter@example.com?roster;preauth=TOKEN;ibr=true</code>
<p>The <strong>ibr</strong> query component in the XMPP URI indicates that
the invitee is allowed to create an account on the Romeo's server.
the invitee is allowed to create an account on Romeo's server, using the
'preauth' token.
If the server does not support or allow in-band registration for invited
users, the server MUST omit the <strong>ibr</strong> query component.</p>
<p>Additionally, the server SHOULD provide the <strong>landing-url</strong>
field which contains an HTTPS URL of a web-based landing page as described
in &xep0379; § 3.3. The URL format may differ from the example shown here
depending on where the landing page is hosted.</p>
<p>If the server omits the <strong>landing-page</strong> field, Romeo's
client SHOULD generate an appropriate landing page URL hosted by the
client developer or a trusted third party.</p>
<p>A server MAY provide a field which provides the expiration date of the
generated token. The expiration date MUST conform to the DateTime profile
specified in &xep0082;. If the field is not provided, the token does not
expire.</p>
<p>Romeo's client should provide adequate means to export the
<strong>landing-page</strong> URL, possibly accompanied with a short
description and the <strong>expire</strong> information, so that Romeo can
share it with Juliet by other means than XMPP, like e-mail or a QR code.</p>
</section2>
<section2 topic='Redeeming a User Invitation' anchor='redeem-invitation'>
<p></p>
</section2>
<section2 topic='Account Creation' anchor='account-creation'>
<example caption="Exceute account creation command"><![CDATA[
<iq type='set' from='romeo@example.com' to='example.com' id='exec1'>