You can configure masking of sensitive information in query results on the Data Masking page. On the Security Settings and Others page, you can securely isolate code and logs, enforce mandatory code review to control code quality, and require smoke testing to ensure task correctness.
Limitations
Configure data masking for query results on the Data Masking page. To mask query results in multiple workspaces, enable the relevant workspaces in Workspace Management for dynamic data masking, and configure and enable the applicable masking rules and policies.
For example, workspace A has data masking enabled, but workspace B does not. If a user in workspace B has permission to view tables in workspace A, querying those tables from workspace B returns the data in plaintext.
Access security settings and others
-
Log on to the DataWorks console. In the target region, click in the left-side navigation pane. Select a workspace from the drop-down list and click Go to Data Development.
-
At the bottom of the left-side navigation pane in DataStudio, click the
icon to open the Configure page. -
On the Configure page, click Security Settings and Others to open the Security Settings and Others page.
On this page, you can:
-
Data masking for query results has moved to the Data Masking page. For configuration details, see Data masking.
-
Enable secure isolation for code and logs. For more information, see Enable secure isolation for code and logs.
-
Enable baseline impact prompts for task submission. For more information, see Enable baseline impact prompts for task submission.
-
Enable mandatory code review. For more information, see Enable mandatory code review.
-
Enable mandatory smoke testing. For more information, see Enable mandatory smoke testing.
-
Enable data masking for query results
-
Feature description
When enabled, DataWorks masks query results using built-in data masking rules. If the built-in rules do not meet your needs, you can create custom rules in Data Security Guard. For more information, see Data Security Guard.
NoteThis feature performs dynamic data masking and does not affect the underlying data.
-
Configuration
Data masking for query results has moved to the Data Masking page. For configuration instructions, see Data masking. When you configure a dynamic data masking policy, select Data development as the DataWorks feature in the effective conditions to mask query results in Data Studio.
Note-
If you do not enable data masking, you risk exposing sensitive information.
-
To mask query results in the current workspace, enable the workspace in Workspace Management for dynamic data masking, and configure and enable the corresponding masking rules and policies.
-
-
Built-in data masking rules
The following table lists the built-in data masking rules.
Type
Data masking rule
Original data
Masked data
ID card number
Displays only the first and last digits. This rule applies to 15- and 18-digit ID card numbers.
111222190002309999
1*************9
Mobile number
Displays the first seven digits and replaces the last four digits with asterisks (
*). This rule applies to mobile numbers in Chinese mainland.13900001234
1390000****
Email address
-
If there are three or more characters before the at sign (
@), only the first three characters are displayed. -
If there are fewer than three characters before the at sign (
@), it displays all preceding characters, followed by three asterisks (*).
-
username@example.com
-
a@example.net
-
use***@example.com
-
a***@example.net
Bank card number
Displays only the last four digits. This rule applies to credit cards and debit cards.
-
6888 8888 8888 8888
-
4666 6666 6666 6666
-
**** **** **** 8888
-
**** **** **** 6666
IP or MAC address
Displays only the first segment. The remaining segments are replaced with asterisks (
*).-
192.168.0.1
-
01-80-C2-00-00-00
-
192.***.*.*
-
01-**-**-**-**-**
License plate number
Displays the
region identifier and the last three characters of the plate number in plaintext. The other characters are replaced with asterisks (*).-
CityA 666666
-
CityA 888888
-
CityA***666
-
CityA***888
-
Enable secure isolation for code and logs
After you enable this feature, users who are not members of the current workspace cannot view the task code and logs. To grant access, a workspace administrator must add the user as a workspace member. For more information, see Add workspace members and manage their roles.
Enable baseline impact prompts
When this feature is enabled, the system displays the associated baseline when you commit or deploy a task. This helps you assess whether your changes will affect the execution of baseline tasks.
Enable mandatory code review
Mandatory code review is supported only in DataWorks Professional Edition and Enterprise Edition.
-
Feature description
Mandatory code review is a workspace-level feature. When enabled, code submitted by developers must be reviewed and approved before deployment. You can also scope code review based on baselines to ensure the quality of high-priority tasks and prevent failures that could block other tasks.
-
Configuration
In the Code Review section of the Security Settings and Others page, configure the mandatory code review settings. The following table describes the parameters.
Parameter
Description
Code reviewers
The policy for selecting reviewers for node submissions.
-
Any Developer Role: After a code review is initiated, any user with the Developer role in the workspace can approve the change. The user who commits the node selects the specific reviewer.
-
Specify development role users: After a code review is initiated, only the specified users with the Developer role can approve the change. DataWorks selects the reviewers configured here by default when you commit a node.
Baseline scopes for code review
The nodes that require a code review upon submission.
You can select the nodes that require mandatory code review based on their baseline priority. The logic is as follows:
-
If you set the review scope to non-baseline tasks, newly created tasks in the workspace require approval.
-
If you set the review scope to tasks of a specific baseline level, nodes on that baseline require approval upon submission.
-
A higher baseline number indicates a higher priority. Baseline tasks have a higher priority than non-baseline tasks.
For more information about how baselines control task priority, see Smart Baseline overview.
-
For more information about code review, see Code review.
Enable mandatory smoke testing
In the Perform Smoke Testing section of the Security Settings and Others page, turn on the switch to enforce mandatory smoke testing. Once enabled, tasks can be deployed only after they pass smoke testing.
After you enable mandatory smoke testing:
-
If a task has not been smoke tested, or if its test fails, its check status on the Task Deployment page is marked as failed, preventing deployment.
-
In special cases where a task that failed the check must be deployed, a Workspace Administrator can go to the page and manually set the status for the record to Passed.
For more information about task deployment, see Deploy tasks.