static Map<String, String> decodeOpaqueSecrets(Secret secret) {
      if (secret == null) {
         return Collections.emptyMap();
      }
      String opaqueIdentities = secret.getData().get("identities.yaml");
      String yaml = new String(Base64.getDecoder().decode(opaqueIdentities));
      YamlConfigurationReader reader = new YamlConfigurationReader(new StringReader(yaml), new URLConfigurationResourceResolver(null), new Properties(), PropertyReplacer.DEFAULT, NamingStrategy.KEBAB_CASE);
      Map<String, Object> identities = reader.asMap();
      List<Map<String, String>> credentialsList = (List<Map<String, String>>) identities.get("credentials");
      Map<String, String> res = new LinkedHashMap<>(identities.size());
      for (Map<String, String> credentials : credentialsList) {
         res.put(credentials.get("username"), credentials.get("password"));
      }
      return res;
   }
@Test
   public void testKubeSecrets() {
      Secret secret = new Secret();
      secret.setData(Collections.singletonMap("identities.yaml", "Y3JlZGVudGlhbHM6Ci0gdXNlcm5hbWU6IGFkbWluCiAgcGFzc3dvcmQ6IHBhc3N3b3JkCgo="));
      Map<String, String> map = Kube.decodeOpaqueSecrets(secret);
      assertEquals(1, map.size());
      Map.Entry<String, String> next = map.entrySet().iterator().next();
      assertEquals("admin", next.getKey());
      assertEquals("password", next.getValue());
   }