Closed stefan-wauters closed 4 months ago
Fixed. But there is also another solution you could have used. You could have set the value-attribute of the manager to required: false
Either by reregistering the UserEndpoint
with a customized schema or on the ResourceHandler#postConstruct
method
@Override
public void postConstruct(de.captaingoldfish.scim.sdk.server.schemas.ResourceType resourceType)
{
resourceType.getSchemaAttribute(String.format("%s.%s",
AttributeNames.RFC7643.MANAGER,
AttributeNames.RFC7643.VALUE))
.ifPresent(managerValue -> {
managerValue.setRequired(false);
});
}
We are in the process of setting up a SCIM Server that integrates with Okta. When a User has a manager assigned in Okta and subsequently removes it, Okta sends the following
PUT
request:This is a valid request according to the SCIM RFC because
manager.value
is considered 'recommended', while in the implementation of the SCIM SDK it is marked asrequired
here.This results in the following error being sent even though
manager.value
is not required according to the SCIM Spec:We have worked around this for now by adding a custom
RequestValidator<User>
to theResourceHandler<User>
that removes this validation on update:This feels more like a workaround than a proper solution for the issue. Could you advise on a more appropriate way to solve this? Can
manager.value
be marked asrequired = false
or would a similar pre-processing step be required as the Microsoft AzurePATCH
requests?Thanks in advance.