使用OpenAM SDK更改数据存储区配置时,除密码之外的任何操作都可以正常运行。即使我给出相关属性“sun-idrepo-ldapv3-config-authpw”,密码也会重置为空字符串。我尝试了很多情况:从属性中删除字段,并给出一组字符串。他们都没有让我的密码完好无损!从OpenAM SDK更改LDAP数据存储区配置
这里是我的代码部分:
fun setDataStoreConfig(realmName: String, storeName: String, newAttrs: Map<*,*>) {
val srvConf = ServiceConfigManager(IdConstants.REPO_SERVICE, getUserSSOToken())
val orgConf = srvConf.getOrganizationConfig(realmName, null)
val subConf = orgConf.getSubConfig(storeName)
val attrs = subConf.attributes
attrs.putAll(newAttrs)
attrs["sun-idrepo-ldapv3-config-authpw"]=setOf("*********")
subConf.attributes = attrs
}
显然,将这些信息保存到目录服务时,会添加一些盐!我不确定这些盐是由OpenAM还是OpenDJ本身添加的!请帮帮我! – Kamyar