ejabberd - Comments for "username validation while creating a new user in EJabberd server" https://www.ejabberd.im/node/3362 en Thanks https://www.ejabberd.im/node/3362#comment-53956 <p>Thanks for your reply...</p> Mon, 19 Jan 2009 12:14:08 +0000 kamaljoshi comment 53956 at https://www.ejabberd.im Username cannot contain @ https://www.ejabberd.im/node/3362#comment-53953 <div class="quote-msg"> <div class="quote-author"><em>kamaljoshi</em> wrote:</div> <p>Hi All,</p> <p>Please suggest, if it is possible to make email-id (like <noindex><a href="mailto:abc@test.com" rel="nofollow" >abc@test.com</a></noindex>) as username while creating a new account in my Ejabberd server, I am using smack client apis and getting Bad request(400) while doing above. </p></div> <p><noindex><a href="http://xmpp.org/internet-drafts/draft-saintandre-rfc3920bis-08.html#addressing" rel="nofollow" >XMPP-Core -&gt; Addresses</a></noindex></p> <div class="quote-msg"> <div class="quote-author">Quote:</div> <pre> jid = [ node "@" ] domain [ "/" resource ] node = 1*(nodepoint) ; a "nodepoint" is a UTF-8 encoded Unicode code ; point that satisfies the Nodeprep profile of ; stringprep </pre><p> A node identifier MUST be formatted such that the Nodeprep profile of [STRINGPREP] can be applied without failing (see Appendix A). </p></div> <p><noindex><a href="http://xmpp.org/internet-drafts/draft-saintandre-rfc3920bis-08.html#nodeprep-prohibited" rel="nofollow" >Appendix A. Nodeprep -&gt; A.5. Prohibited Output</a></noindex></p> <pre> In addition, the following additional Unicode characters are also prohibited: U+0022 (QUOTATION MARK) U+0026 (AMPERSAND) U+0027 (APOSTROPHE) U+002F (SOLIDUS) U+003A (COLON) U+003C (LESS-THAN SIGN) U+003E (GREATER-THAN SIGN) U+0040 (COMMERCIAL AT) </pre><p>And the prohibited U+0040 (COMMERCIAL AT) is what you wanted to use: @</p> <p>It seems XMPP-Core allows in a username the characters # and %, for example. Maybe you can use those characters: abc%test.com@jabber.example.org.</p> Sat, 17 Jan 2009 11:05:00 +0000 mfoss comment 53953 at https://www.ejabberd.im