Commit 578d5881 authored by Gaston Dombiak's avatar Gaston Dombiak Committed by gaston

Cannot optimize this. :(


git-svn-id: http://svn.igniterealtime.org/svn/repos/messenger/trunk@1119 b35dd754-fafc-0310-a699-88a17e54d16e
parent 9dd5d455
...@@ -153,7 +153,14 @@ public class IQAuthHandler extends IQHandler implements IQAuthInfo { ...@@ -153,7 +153,14 @@ public class IQAuthHandler extends IQHandler implements IQAuthInfo {
UserNotFoundException UserNotFoundException
{ {
String resource = iq.elementTextTrim("resource"); String resource = iq.elementTextTrim("resource");
resource = resource != null ? resource.toLowerCase() : null; if (resource != null) {
try {
resource = Stringprep.resourceprep(resource);
}
catch (StringprepException e) {
throw new IllegalArgumentException("Invalid resource: " + resource);
}
}
// If a session already exists with the requested JID, then check to see // If a session already exists with the requested JID, then check to see
// if we should kick it off or refuse the new connection // if we should kick it off or refuse the new connection
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment