This topic describes the procedure and common use cases of connecting WeCom to IDaaS EIAM.
Overview
Connecting WeCom to IDaaS requires only four steps:
Create an application: Create applications in both the WeCom admin console and the Alibaba Cloud IDaaS console. Configure basic information and set a trusted domain name and a trusted IP address to meet the security requirements of WeCom.
Grant permissions: Adjust the visible scope of the WeCom application to determine the contacts that IDaaS can access (departments and members only). This scope serves as the source node for subsequent data synchronization.
Select scenarios: Select the feature scenarios that you need, such as contact synchronization, QR code logon, and web authorization logon. Then configure the synchronization rules, such as scheduled full synchronization and field matching logic, and the logon methods.
Field mapping: Bind or map the fields of WeCom members and departments to the fields of IDaaS accounts and organizations to ensure data correlation and consistency.
Preparations
For security purposes, WeCom verifies the trusted domain name and trusted IP address when the contacts and identity verification APIs are called. A trusted IP address can be used for only one enterprise in WeCom. If you use it for multiple enterprises, WeCom identifies you as a service provider, and APIs such as contacts and identity verification become unavailable. To meet the security requirements of WeCom, prepare the following items in advance:
Verification item | Preparation |
Trusted domain name | A dedicated domain name whose owner is the same as the authenticated entity in WeCom. (Recommended) Configure it in advance as the custom domain name of your IDaaS EIAM instance. For more information, see Custom domains. |
Trusted IP address | Your IDaaS EIAM instance must have at least one available dedicated endpoint. IDaaS EIAM accesses WeCom through your dedicated public egress IP address. For more information, see Network access endpoints|Configure a dedicated public egress IP address. |
Use cases
After you connect WeCom, you can use the following capabilities.
Category | Capability |
Account |
|
Logon |
|
Procedure
Step 1: Create an application
Create on the WeCom side.
Create on the IDaaS side.
Step 2: Grant permissions
In this step, adjust the Visible To scope as instructed. Visible To is the contact data that IDaaS EIAM is authorized to access for data synchronization and logon. Only departments and members are supported; tags are not included. If you synchronize data, the visible scope serves as the source node for synchronization.
Step 3: Select scenarios
In this step, select the scenario capabilities that you want to use.
Capability description
Synchronization target: WeCom contact data is imported under this node in IDaaS.
Scheduled verification: Because WeCom does not support querying incremental data, IDaaS automatically performs a full synchronization of all data under the WeCom source node in the early morning every day.
You can set a mapping identifier in the field mapping settings to match a field of the IDaaS account, such as the account name, with a field of the WeCom user, such as
userid. If a match is found, the accounts are bound and the data is overwritten and updated. Otherwise, an IDaaS account is created.If you need to synchronize data immediately, manually trigger a full synchronization.
IDaaS has a built-in synchronization protection capability. When more than 30 accounts or more than 10 organizations need to be deleted, the synchronization task is automatically canceled to prevent data from being deleted by mistake. (Recommended) Adjust the synchronization protection settings based on the size of your enterprise.
QR code logon: After you enable this feature, a WeCom QR code logon option is created in the Logon menu and is enabled. Users can scan the QR code to log on directly.
Web authorization logon: This feature is enabled by default when the Domain Name Type is set to Custom domain name. After it is enabled, SSO from the WeCom workbench to IDaaS EIAM or its applications is supported, and sensitive data synchronization is supported after authorization.
To get sensitive data, users must manually grant authorization when they open IDaaS EIAM in the WeCom environment. The authorization page appears when SSO is initiated. After authorization, the WeCom mobile phone number and corporate email address are used directly as the mobile phone number and email address of the IDaaS EIAM account. If no corporate email address exists, the personal email address is used instead.
Step 4: Field mapping
Configure field mapping in Step 4 if you have existing data in IDaaS and need to bind WeCom members and departments to IDaaS accounts and organizations. Field mapping is also required if you want to use certain fields of WeCom members as IDaaS account data. For example, you can use the alias of a WeCom member as the display name of the IDaaS account.
If the account ID in WeCom (that is, userid) is automatically generated by the system, it can be modified only once. Because this field is the only primary key that IDaaS can rely on, if it is modified, the associated IDaaS account is deleted and recreated. Modify it with caution.
To protect the data security and privacy of enterprises and employees, the WeCom platform has updated its API policy:
From 20:00 on June 20, 2022, WeCom APIs no longer return the following sensitive fields, except for contact synchronization: avatar, gender, mobile phone number, email address, corporate email address, employee personal QR code, and address. If your application needs this information, use the WeCom OAuth2.0 authorization mechanism to guide administrators and employees to actively grant the relevant permissions, and then get the data.
Manage the WeCom identity provider
After the integration is complete, you are automatically redirected to the IdPs menu. In this menu, you can manage the different features that are linked with the identity provider.
Important notes
Notes on QR code logon
WeCom QR code logon depends on the configuration of the authorization callback domain. Specifically, if your users need to log on to access IDaaS EIAM or an application, these three items must match exactly: the domain name of the IDaaS EIAM logon page in the browser, the authorization callback domain of the WeCom identity provider in IDaaS EIAM, and the authorization callback domain configured in WeCom. Otherwise, WeCom QR code logon is unavailable.
Therefore, if you want users to access IDaaS EIAM through a custom domain name, set it as the default domain name (for details, see Custom domains) and enable the automatic redirect feature. Also set the authorization callback domain in both IDaaS EIAM and WeCom to the custom domain name.
Notes on sensitive data synchronization
To get sensitive data, users must manually grant authorization when they open IDaaS EIAM in the WeCom environment. The authorization page appears when SSO is initiated. After authorization, the WeCom mobile phone number and corporate email address are used directly as the mobile phone number and email address of the IDaaS EIAM account. If no corporate email address exists, the personal email address is used instead.
After a user manually grants authorization, the authorization page does not appear again when the user opens the WeCom application page within 30 days. If a user needs to change the personal sensitive information authorization within 30 days, the user can open the details page of the WeCom application (the application created in WeCom when the identity provider was integrated). On the Personal Sensitive Information Authorization Management page, the user can change the personal sensitive information authorization again.
In addition to manual authorization by users, administrators must also go to in WeCom and check whether the display of the required sensitive data, such as mobile phone numbers and email addresses, is enabled. IDaaS EIAM can get only the sensitive user data that users have authorized and that administrators have configured for display.
Retain other logon methods
Alibaba Cloud IDaaS makes best efforts to ensure the availability of your WeCom contact data synchronization and identity verification. However, the verification methods and risk control rules of WeCom, such as trusted domain names and trusted IP addresses, are not publicly disclosed in detail. Alibaba Cloud therefore cannot guarantee continuous and stable logon to IDaaS by using a WeCom account.
To avoid being unable to log on to IDaaS when WeCom is unavailable, you should also retain other logon methods, such as an account password or an SMS verification code. If you do not use other logon methods and cannot log on, you are solely responsible for the resulting losses.
For information about how to configure and use other logon methods, see General settings.