Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
O
Openfire
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
Openfire
Commits
550f7aca
Commit
550f7aca
authored
Mar 03, 2016
by
Guus der Kinderen
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #541 from dchinmay/dev2
Outcasts should not be allowed to register with room.
parents
dc84c195
7963d3f8
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
2 deletions
+6
-2
IQMUCRegisterHandler.java
...g/jivesoftware/openfire/muc/spi/IQMUCRegisterHandler.java
+6
-2
No files found.
src/java/org/jivesoftware/openfire/muc/spi/IQMUCRegisterHandler.java
View file @
550f7aca
...
...
@@ -29,6 +29,7 @@ import org.dom4j.Element;
import
org.dom4j.QName
;
import
org.jivesoftware.openfire.muc.ConflictException
;
import
org.jivesoftware.openfire.muc.ForbiddenException
;
import
org.jivesoftware.openfire.muc.MUCRole
;
import
org.jivesoftware.openfire.muc.MUCRoom
;
import
org.jivesoftware.openfire.muc.MultiUserChatService
;
import
org.jivesoftware.util.ElementUtil
;
...
...
@@ -126,8 +127,11 @@ class IQMUCRegisterHandler {
reply
.
setError
(
PacketError
.
Condition
.
item_not_found
);
return
reply
;
}
else
if
(!
room
.
isRegistrationEnabled
())
{
// The room does not accept users to register
else
if
(!
room
.
isRegistrationEnabled
()
||
(
packet
.
getFrom
()
!=
null
&&
MUCRole
.
Affiliation
.
outcast
==
room
.
getAffiliation
(
packet
.
getFrom
().
asBareJID
())))
{
// The room does not accept users to register or
// the user is an outcast and is not allowed to register
reply
=
IQ
.
createResultIQ
(
packet
);
reply
.
setChildElement
(
packet
.
getChildElement
().
createCopy
());
reply
.
setError
(
PacketError
.
Condition
.
not_allowed
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment