Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

By The default , configuration of WSO2 products have has a single , embedded user store. If required, you can configure WSO2 products to connect to multiple several secondary user stores as well. After configuration, users from different stores can log in and perform operations depending on their roles/permissions. You can als o also configure your own customized user stores and connect them with to the products as secondary stores.

...

The topics below explain show how to configure secondary user stores manually or using the management console: 

Table of Contents

...

maxLevel4
minLevel4

Configuring using the management console

  1. In Log in to the management console , click Configure, and then click User Store Management sub menu under Configure menu.
  2. The User Store Management page appearsThe User Store Management page opens. Initially, there are no secondary user stores.

    Info

    Note: You cannot update the PRIMARY user store at run time, so it is not visible on this page.

  3. Click Add Secondary User Store.

  4. The User Store .

  5. In the
  6. Manager page opens. Enter a unique domain name and fill in the rest of the data.

    Info

    Do not include underscore character (_) in domain names.

    For details on each property, see the respective property description that is provided. Also, select the required implementation of user store manager from the User Store Manager Class drop-down list

  7. , select the type of user store you are creating: 
  8. . The displayed property list varies depending on the selected user store manager implementation. By default, all WSO2 products come with four user store manager implementations as follows:

    User store managerDescription
    org.wso2.carbon.user.core.ldap.ReadOnlyLDAPUserStoreManager

    Use ReadOnlyLDAPUserStoreManager to do read-only operations for LDAP user stores.

    org.wso2.carbon.user.core.ldap.ReadWriteLDAPUserStoreManager

    Use ReadWriteLDAPUserStoreManager for LDAP user stores to do both read and write operations.

    org.wso2.carbon.user.core.ldap.ActiveDirectoryUserStoreManager

    Use ActiveDirectoryUserStoreManager to configure an Active Directory Domain Service (AD DS) or Active Directory Lightweight Directory Service (AD LDS). This can be used only for read/write operations. If you need to use AD as read-only, you must use org.wso2.carbon.user.core.ldap.ReadOnlyLDAPUserStoreManager.

    org.wso2.carbon.user.core.jdbc.JDBCUserStoreManager

    Use JDBCUserStoreManager for JDBC user stores. The JDBC user store can be configured for read-only mode or read/write mode using the following property: <Property name="ReadOnly">false/true</Property>. 

    You can also populate this drop-down list with custom user store manager implementations by adding them to the server.

  9. A
  10.  A sample custom user store manager can be found in the repository.

  11. Enter a unique domain name with no underscore (_) characters, and optionally enter a description for this user store.

  12. Enter values for the properties, using the descriptions in the Descriptions column for guidance. The properties that appear vary based on the user store manager class you selected, and there may be additional properties in an Optional or Advanced section at the bottom of the screen.

     

  13. Ensure that all the mandatory fields are filled in and click  and a valid domain name is given and click Add

  14. A message appears indicating that the server is updating the user stores. At this point, saying that the user stores are being added. 
    Image Added

    Info

    The above message does not imply that the user store is added successfully. It simply means that the server is attempting to add the new user store to the end of the available chain of stores.

     
    Image Removed

  15. Refresh the page after a few seconds to verify that the check the status. 

  16. If the new user store was added successfully and now appears in the list of secondary user stores.

...

  1. is successfully added, it will appear in the User Store Management page.

  2. After adding to the server, you can edit the properties of the new secondary user store and enable/disable it

...

  1. in a dynamic manner.

Configuring manually

By default, user-mgt.xml file contains the configuration of the primary user store is saved in the <PRODUCT_HOME>/repository/conf/user-mgt.xml fileWhen you create a secondary user store using the management console as explained above, its configuration is saved to an XML file with the same name as the domain name you specifyspecified. AlternativelyIf required, you can create this XML file manually and save it using the following guidelines:

...

as follows:

    • If it is
  • the
    • configuration of a super tenant, save the
  • secondary user store definitions
    • configuration in
  • the
    • <PRODUCT_HOME>/repository/deployment/server/userstores directory.
    • If it is a general tenant, save the configuration in
  • the
    • <PRODUCT_HOME>/repository/tenants/<tenantid>/userstores directory.

The secondary user store configuration file must have the same name as the domain with an underscore (_) in place of the period. For example, if the domain is

...

 wso2.com,

...

 name the file

...

as  wso2_com.xml. Only one file contains the definition for one user store domain.