Configuring a shared custom user registry
You can configure a custom user registry to provide user authentication for the Cloud Manager, the API Manager, and the Developer Portal.
Before you begin
To configure a custom user registry as a resource in the Cloud Manager, the external user directory must be created and available to use with your API Connect ecosystem.
Custom user registries can be used for authenticating users to the Cloud Manager, the API Manager, and the Developer Portal, but cannot be used to secure APIs.
One of the following roles is required to configure a custom user registry:
- Administrator
- Owner
- Topology Administrator
- Custom role with the Settings: Manage permissions
About this task
You can create a custom user registry that is specific to a provider organization, or one that can be shared and available to all of the provider organizations in your API Connect environment. An organization-specific custom user registry can be used for authenticating Developer Portal users, while a shared custom user registry can be used for authenticating Cloud Manager, API Manager, and Developer Portal users.
This topic describes how to configure a shared custom user registry. If you want to create an organization-specific registry, see Creating an organization-specific custom user registry for more information. Note also that the visibility of a user registry is set toshared
by default. However, you can
change the visibility setting to make the registry private, or visible only to specific provider
organizations. For more information, see Setting visibility for a user registry.- You can also create custom user registries by using the API Connect REST APIs (see the API Connect REST API documentation).
You can use the following instructions to create a writable or a read-only custom user registry.
Creating a shared custom user registry by using the Cloud Manager UI
You configure a custom user registry by first creating a custom user registry type that defines your external user registry, and then creating a new custom user registry resource that references the custom user registry type that you just created. To make the registry available for user authentication, you need to add the registry to the Cloud Manager, or to the API Manager, or both, depending on your requirements. When the custom user registry is used for authentication, API Connect makes a REST call to the endpoint of your external registry, as defined in the custom user registry type.
Creating a custom user registry type
- In the Cloud Manager, click Resources.
- Click Create in the User registry type section.
- Enter the following information:
Property Description Title A descriptive name of the custom user registry type to display in the UI. For example, My custom user registry type. Name The name of the user registry type. This name is auto-generated, and is used in CLI commands. Version The version number of the custom user registry type. Summary A brief description of the custom user registry type. Properties Enter the properties of your external user registry. Must include the property:
This property must be set toremote: true
true
to indicate that this is an external user registry.Secured Endpoint Denotes the external registry secured endpoint section of the custom user registry type. URL The secure endpoint of your external user registry interface, where your platform REST API is located. It is made up of the URL and port, for example:
API Connect will make REST calls to this endpoint for the user registry actions.https://custom.ms.com:8888
TLS Client Profile Optionally set the TLS Client Profile URL that the custom server requires. Headers Optionally complete the user-defined header section to your external registry specification. Configuration schema Optionally complete the user-defined configuration schema section to your external registry specification. - Click Create. A new user registry with a Type of Custom is displayed in the User registry type list.
Creating a custom user registry resource
- Click Create in the User Registries section of Resources.
- Click the Custom user registry tile.
- Enter the following information:
Property Description Custom type The name of the custom user registry type that you just created. For example, my-custom-user-registry-type. Use the drop-down arrow to select different custom user registry types. Title A descriptive name to display in the UI. Name The name of the custom user registry. This name is auto-generated, and is used in CLI commands. Summary A brief description of the custom user registry. Endpoint Optional endpoint information. Case sensitive To ensure proper handling of user name capitalization, you must ensure that your case-sensitivity setting here matches the setting on your backend server: - Only select Case sensitive if your backend server supports case-sensitivity.
- Do not select Case sensitive if your backend server does not support case-sensitivity.
Note:- The Developer Portal does not support case sensitive usernames.
- After at least one user has been onboarded into the registry, you cannot change this setting.
User registry managed Determines whether API Connect manages your user registry. Valid values are: true
- select the checkboxfalse
- clear the checkbox
User managed Determines whether your user registry is writable or not. Select the checkbox to set to true
for writable. Clear the checkbox for the non-writable option.Email required Select this checkbox if an email address is required as part of the user onboarding process. If selected, the source identity provider must supply the email address as part of the authentication process during onboarding. Note: An email address is not required by default for onboarding to the Cloud Manager or the API Manager, but it is required for onboarding to the Developer Portal.Unique email address Select this checkbox if email addresses must be unique within the user registry. Note: Every account in the Developer Portal, including across different user registries for the same site, must have a unique email address, including the site Admin account. - Click Create. The new user registry is displayed in the User registries list.
Adding your custom user registry to the Cloud Manager or API Manager login
To make the custom user registry available for user authentication in the Cloud Manager or the API Manager, you must set it as active in the section of the Cloud Manager UI. See Selecting user registries for Cloud Manager and API Manager for more information.If you want to make the custom user registry available for authenticating Developer Portal users, you must enable it in the Catalog that is associated with that Developer Portal. In the API Manager UI, click Manage followed by the relevant Catalog, and then click . In the Catalog User Registries section, click Edit, select the user registry, and click Save. For more information, see Creating and configuring Catalogs.
Creating a shared custom user registry by using the developer toolkit CLI
You configure a custom user registry by first configuring an integration document that defines your external user registry, and then creating a new custom user registry resource that references the integration document that you just created. You use developer toolkit CLI commands to create the integration document, and then the custom user registry. Finally, to make the registry available for user authentication, you need to configure the registry in the management server, or in the appropriate Catalog, or both, depending on your requirements. When the custom user registry is used for authentication, API Connect makes a REST call to the endpoint of your external registry, as defined in the integration document.
Logging in to the management server CLI
apic login --server mgmt_endpoint_url --username user_id --password password --realm admin/identity_provider
--realm
parameter by entering the following command to see a list of all available
identity providers (you do not need to be logged in to use this
command):apic identity-providers:list --scope admin --server mgmt_endpoint_url --fields title,realm
For example:apic identity-providers:list --scope admin --server myserver.com --fields title,realm
total_results: 2
results:
- title: Cloud Manager User Registry
realm: admin/default-idp-1
- title: Corporate LDAP user registry
realm: admin/corporate-ldap
The title
value should enable you to determine which
identity provider to use; you can then copy the corresponding --realm
parameter
directly from the displayed realm
value. For any identity providers that were
created by your administrator after API Connect was installed,
the names will have been determined at creation time. The default Cloud Manager Local User Registry
for login as a member of the cloud administration organization is
default-idp-1
.For full details of the login command, see Logging in to a management server.
For more information about how to use the CLI, see Installing the toolkit, and Overview of the command-line tool.
Defining your integration document
integration_file.yaml
document, as shown in the following
example.integration: '1.0.0'
integration_type: 'user_registry'
info:
name: 'custom_user_registry'
version: '1.0.0'
title: 'Custom External User Registry'
summary: 'Configure External User Registry'
properties:
remote: true
secured_endpoint:
endpoint: 'https://custom.ms.com:8888'
tls_client_profile_url: {$tslClientProfileUrl}
headers:
key1: value1
key2: value2
configuration_schema:
option_config1:
type: string
option_config2:
type: boolean
Property | Description |
---|---|
integration_type |
The type of integration, which in this case is user_registry . |
info |
Denotes the information section for the integration document. |
name |
The name of the user registry type, for example
custom_user_registry . This name is used in the user registry
file to denote the registry type. |
version |
The version number of the integration document. |
title |
A descriptive name to display in a graphical user interface. |
summary |
A brief description of the integration document. |
properties |
Denotes the property section of the integration document. |
remote |
Indicates that this is an external user registry. Must be set to
true . |
secured_endpoint |
Denotes the external registry endpoint section of the integration document. |
endpoint |
The secure endpoint of your external user registry interface, where your platform REST API
is located. It is made up of the url and port, for
example: API Connect will make REST
calls to this endpoint for the user registry actions. |
tls_client_profile_url |
Optionally set the TLS Client Profile URL that the custom server requires. |
headers |
Complete the user-defined header section to your external registry specification. |
configuration_schema |
Complete the user-defined configuration schema section to your external registry specification. |
Save your integration_file.yaml
so it can be accessed by the
integrations:create
command in the following section.
Creating your custom integration
apic integrations:create --server mgmt_endpoint_url --subcollection user-registry integration_file.yaml
where:mgmt_endpoint_url
is the management platform API endpoint URL.integration_file
is the name of the YAML file that defines the configuration of your external user registry.
endpoint
that is configured in the integration document, and
the external platform REST API will need to return the requested information. integration_name custom_integration_url
The
integration_name
is derived from the name
property in the configuration YAML file. The
custom_integration_url
is the URL with which the integration can
be accessed. Both properties are needed when defining your custom user registry in the next
section.After your custom integration has completed successfully, you can continue to create the custom user registry.
Defining your custom user registry
custom_config_file.yaml
file, as shown in the following example.
name: 'custom_registry_name'
title: 'display_title'
registry_type: 'custom_user_registry'
integration_url: custom_integration_url
case_sensitive: true_or_false
user_managed: true_or_false
user_registry_managed: true_or_false
email_required: true_or_false
email_unique_if_exist: true_or_false
identity_providers:
- name: provider_name
title: 'provider_title'
configuration:
custom_config1: 'value1'
customize: true
Property | Description |
---|---|
name |
The name of the custom user registry. This name is used in the CLI commands. |
title |
A descriptive name to display in a graphical user interface. |
registry_type |
The registry type that you configured in the name property in the
integration document, for example
custom_user_registry . |
integration_url |
The custom integration URL in your API Connect configuration.
You can determine the custom integration URL by using the following CLI
command: Or
you can copy and paste from the summary of the integration creation. |
case_sensitive |
Determines whether your user registry is case-sensitive. Valid values are:
Note: After at least one user has been onboarded into the registry, you cannot change this
setting.
|
user_managed |
Determines whether your user registry is writable or not. Must be set to
true for writable. Set to false if you don't want the registry to
be writable. |
user_registry_managed |
Determines whether API Connect manages your
user registry. Valid values are:
|
email_required |
Determines whether an email address is required as part of the user onboarding process.
Valid values are:
true , the source identity provider must supply the email address as
part of the authentication process during onboarding.Note: An email address is not required by
default for onboarding to the Cloud Manager or the API
Manager, but it is required
for onboarding to the Developer Portal.
|
email_unique_if_exist |
Determines whether email addresses must be unique within the user registry. Valid values
are:
Note: Every account in the Developer Portal,
including across different user registries for the same site, must have a unique email address,
including the site Admin account.
|
identity_providers |
An array containing the details of your custom server, where:
|
configuration |
The user-defined configuration based on the configuration_schema that is
defined in the integration document. |
Save your custom_config_file.yaml
so it can be accessed by
the user-registries:create
command in the following section.
Creating your custom user registry
apic user-registries:create --server mgmt_endpoint_url --org admin custom_config_file.yaml
where:mgmt_endpoint_url
is the platform API endpoint URL.--org admin
means that the registry will be created in the admin organization, which is required for a user registry to be shared.custom_config_file
is the name of the YAML file that defines the configuration of your custom user registry.
registry_name registry_url
The
registry_name
is derived from the name
property
in the custom user registry YAML file. The registry_url
is the
URL with which the custom registry resource can be accessed.Your shared custom user registry is now created; see the following sections for instructions on how to make the registry available to users.