繁体   English   中英

无法通过 SCIM2 API 在 WSO2 IS 中创建用户,并带有外部声明

[英]Unable to create user in WSO2 IS via SCIM2 API with external claims

我试图用外部声明创建用户,但是出了点问题。 我将我的声明添加到 scim2-schema-extension.config、外部声明和本地声明,但 API 对我的请求的响应是:

{
"schemas": [
    "urn:ietf:params:scim:api:messages:2.0:Error"
],
"detail": "Error in adding the user: testoviy22@mail.ru to the user store.",
"status": "500"

}

在日志中我有

: ERR_13735_ELEMENT_FOR_OID_DOES_NOT_EXIST ATTRIBUTE_TYPE for OID comment does not exist!]; remaining name 'mail=testoviy22@mail.ru'
at java.naming/com.sun.jndi.ldap.LdapCtx.mapErrorCode(LdapCtx.java:3280)
at java.naming/com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:3205)
at java.naming/com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2996)
at java.naming/com.sun.jndi.ldap.LdapCtx.c_bind(LdapCtx.java:452)
at java.naming/com.sun.jndi.toolkit.ctx.ComponentDirContext.p_bind(ComponentDirContext.java:299)
at java.naming/com.sun.jndi.toolkit.ctx.PartialCompositeDirContext.bind(PartialCompositeDirContext.java:217)
at org.wso2.carbon.user.core.ldap.UniqueIDReadWriteLDAPUserStoreManager.persistUser(UniqueIDReadWriteLDAPUserStoreManager.java:312)
... 73 more

本地索赔外部索赔

索取样品:

{
"name": {
  "familyName": "Zubenko",
  "givenName": "Michael"
},
"password": "qwerty",
"urn:ietf:params:scim:schemas:extension:enterprise:2.0:User": {
  "comment": "test"
},
"userName": "testoviy22@mail.ru"

}

似乎您正在使用 LDAP 服务器作为您的主要用户存储,并且该服务器不支持名为“comment”的属性,请参阅https://is.docs.Z8995A8D9DC109CB7F2C89344/FB207BADE5Z//en供应/扩展-scim2-用户模式/#map-the-custom-claim

仅当使用 JDBC 用户存储时,您可以使用单词“customClaim”(或任何其他首选词)作为映射属性,因为 JDBC 用户存储将自动创建一个新属性,如果它不存在于用户存储中。 但是,如果您使用的是 LDAP 或 Active Directory,则必须使用已存在于用户存储中的属性

将本地声明的映射属性更改为 LDAP 架构中的某个有效属性

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM