@Test
  public void testMask() {
    final String passwordKey = "hbase.rpc.tls.keystore.password";
    Configuration conf = getTestConf();
    conf.set(passwordKey, "MyPassword");
    Configuration maskedConf = ConfServlet.mask(conf);
    assertEquals(ConfServlet.MASKED, maskedConf.get(passwordKey));
  }
Basic test case that the ConfServlet can write configuration to its output in XML and JSON
format.
hbase-http/src/test/java/org/apache/hadoop/hbase/http/conf/TestConfServlet.java