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
06ab8f64
Unverified
Commit
06ab8f64
authored
Nov 11, 2016
by
akrherz
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
OF-1209 fix s2s whitelist/blacklist on admin console
parent
118ffb84
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
4 deletions
+12
-4
connection-settings-socket-s2s.jsp
src/web/connection-settings-socket-s2s.jsp
+12
-4
No files found.
src/web/connection-settings-socket-s2s.jsp
View file @
06ab8f64
...
@@ -19,13 +19,13 @@
...
@@ -19,13 +19,13 @@
<%
<%
final
ConnectionType
connectionType
=
ConnectionType
.
SOCKET_S2S
;
final
ConnectionType
connectionType
=
ConnectionType
.
SOCKET_S2S
;
final
ConnectionManagerImpl
manager
=
(
ConnectionManagerImpl
)
XMPPServer
.
getInstance
().
getConnectionManager
();
final
ConnectionManagerImpl
manager
=
(
ConnectionManagerImpl
)
XMPPServer
.
getInstance
().
getConnectionManager
();
final
ConnectionConfiguration
plaintextConfiguration
=
manager
.
getListener
(
connectionType
,
false
).
generateConnectionConfiguration
();
final
ConnectionConfiguration
plaintextConfiguration
=
manager
.
getListener
(
connectionType
,
false
).
generateConnectionConfiguration
();
final
boolean
update
=
request
.
getParameter
(
"update"
)
!=
null
;
final
boolean
update
=
request
.
getParameter
(
"update"
)
!=
null
;
final
boolean
closeSettings
=
request
.
getParameter
(
"closeSettings"
)
!=
null
;
final
boolean
closeSettings
=
request
.
getParameter
(
"closeSettings"
)
!=
null
;
final
boolean
serverAllowed
=
request
.
getParameter
(
"serverAllowed"
)
!=
null
;
final
boolean
serverAllowed
=
request
.
getParameter
(
"serverAllowed"
)
!=
null
;
final
boolean
serverBlocked
=
request
.
getParameter
(
"serverBlocked"
)
!=
null
;
final
boolean
serverBlocked
=
request
.
getParameter
(
"serverBlocked"
)
!=
null
;
final
boolean
permissionUpdate
=
request
.
getParameter
(
"permissionUpdate"
)
!=
null
;
final
String
configToDelete
=
ParamUtils
.
getParameter
(
request
,
"deleteConf"
);
final
String
configToDelete
=
ParamUtils
.
getParameter
(
request
,
"deleteConf"
);
final
Map
<
String
,
String
>
errors
=
new
HashMap
<
>
();
final
Map
<
String
,
String
>
errors
=
new
HashMap
<
>
();
...
@@ -46,6 +46,13 @@
...
@@ -46,6 +46,13 @@
webManager
.
logEvent
(
"Updated connection settings for "
+
connectionType
,
"plain: enabled="
+
plaintextEnabled
+
", port="
+
plaintextTcpPort
);
webManager
.
logEvent
(
"Updated connection settings for "
+
connectionType
,
"plain: enabled="
+
plaintextEnabled
+
", port="
+
plaintextTcpPort
);
response
.
sendRedirect
(
"connection-settings-socket-s2s.jsp?success=update"
);
response
.
sendRedirect
(
"connection-settings-socket-s2s.jsp?success=update"
);
}
}
else
if
(
permissionUpdate
&&
errors
.
isEmpty
()
)
{
final
String
permissionFilter
=
ParamUtils
.
getParameter
(
request
,
"permissionFilter"
);
RemoteServerManager
.
setPermissionPolicy
(
permissionFilter
);
webManager
.
logEvent
(
"Updated s2s permission policy to: "
+
permissionFilter
,
null
);
response
.
sendRedirect
(
"connection-settings-socket-s2s.jsp?success=update"
);
}
else
if
(
closeSettings
&&
errors
.
isEmpty
()
)
else
if
(
closeSettings
&&
errors
.
isEmpty
()
)
{
{
// TODO below is the 'idle connection' handing. This should go into the connection configuration, like all other configuration.
// TODO below is the 'idle connection' handing. This should go into the connection configuration, like all other configuration.
...
@@ -177,6 +184,7 @@
...
@@ -177,6 +184,7 @@
response
.
sendRedirect
(
"connection-settings-socket-s2s.jsp?success=delete"
);
response
.
sendRedirect
(
"connection-settings-socket-s2s.jsp?success=delete"
);
}
}
pageContext
.
setAttribute
(
"permissionPolicy"
,
RemoteServerManager
.
getPermissionPolicy
().
toString
());
pageContext
.
setAttribute
(
"errors"
,
errors
);
pageContext
.
setAttribute
(
"errors"
,
errors
);
pageContext
.
setAttribute
(
"plaintextConfiguration"
,
plaintextConfiguration
);
pageContext
.
setAttribute
(
"plaintextConfiguration"
,
plaintextConfiguration
);
// pageContext.setAttribute( "clientIdle", JiveGlobals.getIntProperty( ConnectionSettings.Client.IDLE_TIMEOUT, 6*60*1000 ) );
// pageContext.setAttribute( "clientIdle", JiveGlobals.getIntProperty( ConnectionSettings.Client.IDLE_TIMEOUT, 6*60*1000 ) );
...
@@ -332,7 +340,7 @@
...
@@ -332,7 +340,7 @@
<table
cellpadding=
"3"
cellspacing=
"0"
border=
"0"
>
<table
cellpadding=
"3"
cellspacing=
"0"
border=
"0"
>
<tr
valign=
"top"
>
<tr
valign=
"top"
>
<td
width=
"1%"
nowrap
>
<td
width=
"1%"
nowrap
>
<input
type=
"radio"
name=
"permissionFilter"
value=
"blacklist"
id=
"rb05"
${
'
blacklist
'
eq
param
.
permissionFilter
?
'
checked
'
:
''}
>
<input
type=
"radio"
name=
"permissionFilter"
value=
"blacklist"
id=
"rb05"
${
permissionPolicy
eq
'
blacklist
'
?
'
checked
'
:
''}
>
</td>
</td>
<td
width=
"99%"
>
<td
width=
"99%"
>
<label
for=
"rb05"
>
<label
for=
"rb05"
>
...
@@ -342,7 +350,7 @@
...
@@ -342,7 +350,7 @@
</tr>
</tr>
<tr
valign=
"top"
>
<tr
valign=
"top"
>
<td
width=
"1%"
nowrap
>
<td
width=
"1%"
nowrap
>
<input
type=
"radio"
name=
"permissionFilter"
value=
"whitelist"
id=
"rb06"
${
'
whitelist
'
eq
param
.
permissionFilter
?
'
checked
'
:
''}
>
<input
type=
"radio"
name=
"permissionFilter"
value=
"whitelist"
id=
"rb06"
${
permissionPolicy
eq
'
whitelist
'
?
'
checked
'
:
''}
>
</td>
</td>
<td
width=
"99%"
>
<td
width=
"99%"
>
<label
for=
"rb06"
>
<label
for=
"rb06"
>
...
@@ -456,4 +464,4 @@
...
@@ -456,4 +464,4 @@
<!-- END 'Not Allowed to Connect' -->
<!-- END 'Not Allowed to Connect' -->
</body>
</body>
</html>
</html>
\ No newline at end of file
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