wso2 / product-is

Welcome to the WSO2 Identity Server source code! For info on working with the WSO2 Identity Server repository and contributing code, click the link below.
http://wso2.github.io/
Apache License 2.0
744 stars 723 forks source link

[SCIM2] support `/Schemas` endpoint #5284

Open hauntingEcho opened 5 years ago

hauntingEcho commented 5 years ago

per RFC 7644 section 4:

/Schemas
      An HTTP GET to this endpoint is used to retrieve information about
      resource schemas supported by a SCIM service provider.  An HTTP
      GET to the endpoint "/Schemas" SHALL return all supported schemas
      in ListResponse format (see Figure 3).  Individual schema
      definitions can be returned by appending the schema URI to the
      /Schemas endpoint.  For example:

            /Schemas/urn:ietf:params:scim:schemas:core:2.0:User

      The contents of each schema returned are described in Section 7 of
      [RFC7643].  An example representation of SCIM schemas may be found
      in Section 8.7 of [RFC7643].

as of WSO2IS 5.6.0 with WUM update 1557362049847, starting a fresh instance and executing: curl --user admin:admin -k https://localhost:9443/scim2/Schemas returns the response: <html><body>No service was found.</body></html>. This is also the behavior when using the URI of any particular schema, e.g.: curl --user admin:admin -k https://localhost:9443/scim2/Schemas/urn:ietf:params:scim:schemas:core:2.0:User

Subtask

darshanasbg commented 4 years ago

Quoting the SCIM 2.0 Spec:

SCIM defines three endpoints to facilitate discovery of SCIM service provider features and schema that MAY be retrieved using HTTP GET:

/ServiceProviderConfig /Schemas /ResourceTypes

As of Identity Server 5.9.0, it supports only ResourceTypes ServiceProviderConfig endpoints not the Schemas endpoint.

When a SCIM client like user-portal wants to dynamically discover and adjust to the capability of the SCIM Service Provider(IDP), its needed these endpoint and specially the Schemas endpoint, since it defines what are the attributes that IDP support and what are the data-types of it it.

darshanasbg commented 4 years ago

Endpoint has been introduced with: wso2/charon#254 & wso2-extensions/identity-inbound-provisioning-scim2#200

User-Schema Impl has been introduced with: wso2/charon#260 & wso2-extensions/identity-inbound-provisioning-scim2#212

darshanasbg commented 4 years ago

Support for user schema from the schema endpoint is implemented with https://github.com/wso2/product-is/issues/6814

Other functionalities like schemas for user extensions, groups needed to be done as further improvements.