Why does JBoss log a "javax.management.JMRuntimeException: JBAS011360: Unauthorized access" error when invoking MBeanServer operations in JBoss EAP 7 / 6 ?

Solution Unverified - Updated -

Issue

  • Why does JBoss EAP log a javax.management.JMRuntimeException: JBAS011360: Unauthorized access error when invoking MBeanServer operations?

  • We are getting javax.management.JMRuntimeException: JBAS011360: Unauthorized access when invoking MBeanServer operations. The odd thing is that this only happens if the java security manager is enabled. I can reproduce this by calling MBeanServer.isRegistered() in a servlet's doGet() method. If the security manager is disabled, the call works.

  • It looks like the user's permissions (userPermissions in org.jboss.as.controller.access.permission.ManagementPermissionAuthorizer.authorize()) are different depending on whether or not the security manager is enabled or disabled:

Environment

  • Red Hat JBoss Enterprise Application Platform (EAP)
    • 7.x
    • 6.4.x

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content