jmx.acl.cfg 3.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. ################################################################################
  2. #
  3. # Licensed to the Apache Software Foundation (ASF) under one or more
  4. # contributor license agreements. See the NOTICE file distributed with
  5. # this work for additional information regarding copyright ownership.
  6. # The ASF licenses this file to You under the Apache License, Version 2.0
  7. # (the "License"); you may not use this file except in compliance with
  8. # the License. You may obtain a copy of the License at
  9. #
  10. # http://www.apache.org/licenses/LICENSE-2.0
  11. #
  12. # Unless required by applicable law or agreed to in writing, software
  13. # distributed under the License is distributed on an "AS IS" BASIS,
  14. # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  15. # See the License for the specific language governing permissions and
  16. # limitations under the License.
  17. #
  18. ################################################################################
  19. #
  20. # Generic JMX ACL
  21. #
  22. # This file defines the roles required for MBean operations for MBeans that
  23. # do not have this defined explicitly.
  24. #
  25. # The definition of ACLs for JMX operations works as follows:
  26. #
  27. # The required roles for JMX operations are defined in configuration files
  28. # read via OSGi ConfigAdmin.
  29. #
  30. # JMX RBAC-related configuration is prefixed with jmx.acl and based on the
  31. # JMX ObjectName that it applies to. For example specific configuration for
  32. # an MBean with the following objectName: foo.bar:type=Test can be placed in
  33. # a configuration file called jmx.acl.foo.bar.Test.cfg. More generic
  34. # configuration can be placed in the domain (e.g. jmx.acl.foo.bar.cfg) or
  35. # at the top level (jmx.acl.cfg). A simple configuration file looks like
  36. # this:
  37. # test : admin
  38. # getVal : manager, viewer
  39. #
  40. # The system looks for required roles using the following process:
  41. # The most specific configuration file/pid is tried first. E.g. in the
  42. # above example the jmx.acl.foo.bar.Test.cfg is looked at first. In this
  43. # configuration, the system looks for a:
  44. # 1. Specific match for the current invocation, e.g. test(int)["17"] : role1
  45. # 2. Reg exp match for the current invocation, e.g. test(int)[/[0-9]/] : role2
  46. # In both cases the passed argument is converted to a String for the
  47. # comparison.
  48. # If any of the above match all the roles with matching definitions
  49. # are collected and allowed. If no matches are found the following is tried:
  50. # 3. Signature match for the invocation, e.g. test(int) : role3. If
  51. # matched the associated roles are used.
  52. # 4. Method name match for the invocation, e.g. test : role4. If matched
  53. # the associated roles are used.
  54. # 5. A method name wildcard match, e.g. te* : role5. For all the
  55. # wildcard matches found in the current configuration file, the roles
  56. # associated with the longest match are used. So if you have te* and * and
  57. # the method invoked is 'test', then the roles defined with te* are used,
  58. # not the ones defined with *.
  59. # If no matching definition is found in the current configuration file, a
  60. # more general configuration file is looked for. So jmx.acl.foo.bar.cfg is
  61. # tried next, this matches the domain of the MBean. If there is no match
  62. # found in the domain the most generic configuration file is consulted
  63. # (jmx.acl.cfg).
  64. # If a matching definition is found, this is used and the process will not
  65. # look for any other matching definitions. So the most specific definition
  66. # always takes precedence.
  67. #
  68. list* = viewer
  69. get* = viewer
  70. is* = viewer
  71. set* = admin
  72. * = admin