From a53f4da70f844d001c6720e943e06822a04dd0e7 Mon Sep 17 00:00:00 2001 From: Matt Tucker Date: Mon, 15 Nov 2004 08:08:23 +0000 Subject: [PATCH] Lowercase username on authentication. git-svn-id: http://svn.igniterealtime.org/svn/repos/smack/trunk@2417 b35dd754-fafc-0310-a699-88a17e54d16e --- source/org/jivesoftware/smack/XMPPConnection.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/source/org/jivesoftware/smack/XMPPConnection.java b/source/org/jivesoftware/smack/XMPPConnection.java index 70cb7ffd9..bec91a0d1 100644 --- a/source/org/jivesoftware/smack/XMPPConnection.java +++ b/source/org/jivesoftware/smack/XMPPConnection.java @@ -239,7 +239,7 @@ public class XMPPConnection { /** * Logs in to the server using the strongest authentication mode supported by - * the server, then set our presence to available. If more than five seconds + * the server, then sets presence to available. If more than five seconds * elapses in each step of the authentication process without a response from * the server, or if an error occurs, a XMPPException will be thrown. * @@ -258,6 +258,8 @@ public class XMPPConnection { if (authenticated) { throw new IllegalStateException("Already logged in to server."); } + // Do partial version of nameprep on the username. + username = username.toLowerCase().trim(); // If we send an authentication packet in "get" mode with just the username, // the server will return the list of authentication protocols it supports. Authentication discoveryAuth = new Authentication();