1 Reply Latest reply on Apr 20, 2010 2:10 PM by 843798

    How to create a secured MBeanServer

      I would like to create a secured MBeanServer(control the access to my MBeanServer with a login and password)
      i tryed this code but when i test, my MBeanServer dosn't require a login and password:
      MBeanServer mbs = MBeanServerFactory.createMBeanServer();
      JMXServiceURL url = new JMXServiceURL("service:jmx:rmi:///jndi/rmi://localhost:1022/server");
      Map environment = new HashMap();
      String[] credentials = new String[] {"uu","pp" };
      environment.put(JMXConnector.CREDENTIALS, credentials);
      jmxConnectorServerDestinataire = JMXConnectorServerFactory.newJMXConnectorServer(url, environment, mbs);
      How could i make access to my MBeanServer controlled by a login and password?