[jboss-jira] [JBoss JIRA] (WFLY-1983) MBeans for unaddressable resources available through JMX

Jakub Cechacek (JIRA) jira-events at lists.jboss.org
Tue Sep 3 03:05:03 EDT 2013


Jakub Cechacek created WFLY-1983:
------------------------------------

             Summary: MBeans for unaddressable resources available through JMX
                 Key: WFLY-1983
                 URL: https://issues.jboss.org/browse/WFLY-1983
             Project: WildFly
          Issue Type: Sub-task
            Reporter: Jakub Cechacek
            Assignee: Kabir Khan


MBeans for resources which are unaddressable for authenticated user still has its corresponding MBeans registered - e.g. security-realm=ManagementRealm

{code}
Map<String, String[]> env = new HashMap<String, String[]>();
String[] credentials = {"monitor", "asd1asd!"};
env.put(JMXConnector.CREDENTIALS, credentials);

JMXServiceURL url = new JMXServiceURL("service:jmx:remoting-jmx://localhost:9999");
JMXConnector jmxConnector = JMXConnectorFactory.connect(url, env);
MBeanServerConnection mBeanServerConnection = jmxConnector.getMBeanServerConnection();

ObjectName mgmtRealm = new ObjectName("jboss.as:core-service=management,security-realm=ManagementRealm");
MBeanInfo info = mBeanServerConnection.getMBeanInfo(mgmtRealm);
System.out.println(info.getClassName());

>>> org.jboss.as.controller.ModelController
{code}




--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


More information about the jboss-jira mailing list