web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Customer experience | Sales, Customer Insights,...
Answered

Masking of System Tables

(2) ShareShare
ReportReport
Posted on by 94
Hi Experts,
 
can I apply masking rule on system table, if yes how to work it out .
Categories:
I have the same question (0)
  • Verified answer
    Saif Ali Sabri Profile Picture
    2,351 Super User 2025 Season 2 on at
    You can apply masking on system tables in Dataverse, but not directly. Here are the best approaches:
     
    1. Field-Level Security (Recommended)
    Check if the column supports Field Security (e.g., Email, Phone).
    Create a Field Security Profile, restrict access, and assign it to users.
    2. JavaScript (Client-Side Masking)
     
    Apply a script to mask data on form load.
     
     
    function maskField(executionContext) {
        var formContext = executionContext.getFormContext();
        var fieldValue = formContext.getAttribute("emailaddress1").getValue();
        if (fieldValue) {
            formContext.getControl("emailaddress1").setValue("***" + fieldValue.slice(-3));
        }
    }
     
     
    3. Plugins (Server-Side Masking)
    Create a C# plugin to modify data before saving or retrieving records.
    4. Power Automate
    Use a flow to mask data before sending it in notifications or external integrations.
    Limitations:
    Not all system table fields support Field Security.
    JavaScript works only on forms, not in views or reports.
    Plugins require development effort.
    Would you like help choosing the best approach for your case?
     
     
  • Verified answer
    Daivat Vartak (v-9davar) Profile Picture
    7,835 Super User 2025 Season 2 on at
    Hello Nidhi,
     
    Yes, you can apply masking rules to system tables in Dataverse (which underlies Dynamics 365), but there are important considerations and limitations. Here's how it works and what you need to know:
    How Data Masking Works in Dataverse:
     
    Data masking in Dataverse is achieved using field-level security profiles. These profiles allow you to control the read, create, and update permissions for specific fields, including applying masking rules.
     
    Steps to Apply Masking Rules to System Tables:
    1. Identify the System Table and Field:
      • Determine the system table and the specific field you want to mask. For example, you might want to mask the emailaddress1 field in the systemuser table.
    2. Create a Field Security Profile:
      • In Dynamics 365, go to Settings > Security > Field Security Profiles.
      • Click New.
      • Give the profile a descriptive name (e.g., "Masked Email Addresses").
      • Save the profile.
    3. Add Field Permissions:
      • Open the newly created field security profile.
      • Click Field Permissions.
      • Select the system table and field you identified in step 1 (e.g., systemuser.emailaddress1).
      • Configure the permissions:
        • Read: Set the read permission to "Allow" or "Deny" as needed. If you want to mask the field, you'll need to use a masking rule.
        • Create: Set the create permission to "Allow" or "Deny".
        • Update: Set the update permission to "Allow" or "Deny".
        • Mask: This is where you define the masking rule. Select a masking option:
          • None: No masking is applied.
          • Partial Mask: Masks a portion of the field's value (e.g., last four digits of a phone number).
          • Specific Mask: Allows you to define a custom masking pattern.
          • Full Mask: Masks the entire field's value.
    4. Define Masking Pattern (If Applicable):
      • If you selected "Partial Mask" or "Specific Mask," you'll need to define the masking pattern.
      • Partial Mask: You can specify the number of characters to mask from the beginning or end of the field.
      • Specific Mask: You can use a combination of characters and placeholders to define a custom masking pattern.
    5. Add Users or Teams to the Field Security Profile:
      • In the field security profile, click Users or Teams.
      • Add the users or teams that should have the masking rule applied to them.
    6. Save and Publish:
      • Save the field security profile.
      • Publish the customizations.
     
    Important Considerations and Limitations:
    • System Tables: While you can apply masking rules to system tables, proceed with caution. Changes to system tables can have unintended consequences.
    • Performance: Applying masking rules can impact performance, especially on large datasets.
    • Complex Masking: Dataverse's masking capabilities are relatively basic. If you need complex masking rules, you might need to use custom code or third-party solutions.
    • Security Roles: Field security profiles work in conjunction with security roles. Ensure that users have the necessary security roles to access the system tables and fields.
    • Dataverse Search: Masked data might still be indexed for search, which could expose sensitive information.
    • Impact on Functionality: Masking system table fields could impact core Dynamics 365 functionality. Thoroughly test any masking rules you apply.
    • Supported Masking types: Not all field data types support all masking options.
     
    Best Practices:
    • Principle of Least Privilege: Only apply masking rules when absolutely necessary.
    • Thorough Testing: Thoroughly test any masking rules you apply to system tables.
    • Documentation: Document your masking rules and the reasons for applying them.
     
    In summary, you can apply masking rules to system tables in Dataverse using field security profiles. However, exercise caution, test thoroughly, and be aware of the potential impact on performance and functionality.
     
    If my answer was helpful, please click Like, and if it solved your problem, please mark it as verified to help other community members find more.
    If you have further questions, please feel free to contact me.
     
    My response was crafted with AI assistance and tailored to provide detailed and actionable guidance for your Microsoft Dynamics 365 query.
     
    Regards,
    Daivat Vartak

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > Customer experience | Sales, Customer Insights, CRM

#1
Tom_Gioielli Profile Picture

Tom_Gioielli 83 Super User 2025 Season 2

#2
Gerardo Rentería García Profile Picture

Gerardo Rentería Ga... 49 Most Valuable Professional

#3
#ManoVerse Profile Picture

#ManoVerse 40

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans