[
https://issues.apache.org/jira/browse/QPID-7838?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16068166#comment-16068166
]
Alex Rudyy commented on QPID-7838:
----------------------------------
The changes look reasonable to me, however, I might change how
{{ManagementOutputConverter#convertToOutput}} converts object attribute as
given below, but that might be considered as premature optimisation:
{code}
broker-plugins/management-amqp/src/main/java/org/apache/qpid/server/management/amqp/ManagementOutputConverter.java
@@ -61,23 +61,23 @@ class ManagementOutputConverter
}
- for(String name : object.getAttributeNames())
+ Map<String, ConfiguredObjectAttribute<?, ?>> attributeTypes =
object.getModel()
+
.getTypeRegistry()
+
.getAttributeTypes(object.getClass());
+ for(ConfiguredObjectAttribute<?, ?> attribute :
attributeTypes.values())
{
+ String name = attribute.getName();
if(!ID_AND_TYPE.contains(name))
{
- ConfiguredObjectAttribute<?, ?> attribute = object.getModel()
-
.getTypeRegistry()
-
.getAttributeTypes(object.getClass())
- .get(name);
-
- Object value = actuals
- ? object.getActualAttributes().get(name)
- : object.getAttribute(name);
-
- if (attribute.isSecureValue(value))
+ Object value = null;
+ if (attribute.isSecureValue(value) || !actuals)
{
value = object.getAttribute(name);
}
+ else
+ {
+ value = object.getActualAttributes().get(name);
+ }
if (value != null)
{
{code}
> Make AMQP Management Node respect secure attributes and secure operations
> -------------------------------------------------------------------------
>
> Key: QPID-7838
> URL: https://issues.apache.org/jira/browse/QPID-7838
> Project: Qpid
> Issue Type: Improvement
> Components: Java Broker
> Reporter: Keith Wall
> Assignee: Keith Wall
> Fix For: qpid-java-broker-7.0.0
>
>
> The AMQP Management Node currently enforces neither operations that require a
> secure channel nor attributes that are marked as secure. It should.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]