Dynamic Data Masking Lab Guide
Dynamic Data Masking Lab Guide
Lab Guide
Version:
ILM951_DDM_201310
Informatica Dynamic Data Masking
Version: ILM951_DDM_201310
October 2013
Copyright (c) 1998–2013 Informatica Corporation. All rights reserved.
This educational service, materials, documentation and related software contain proprietary
information of Informatica Corporation and are provided under a license agreement containing
restrictions on use and disclosure and are also protected by copyright law. Reverse engineering
of the software is prohibited. No part of the materials and documentation may be reproduced or
transmitted in any form, by any means (electronic, photocopying, recording or otherwise) without
prior consent of Informatica Corporation. The related software is protected by U.S. and/or
international Patents and other Patents Pending.
Use, duplication, or disclosure of the related software by the U.S. Government is subject to the
restrictions set forth in the applicable software license agreement and as provided in DFARS
227.7202-1(a) and 227.7702-3(a) (1995), DFARS 252.227-7013(c)(1)(ii) (OCT 1988), FAR
12.212(a) (1995), FAR 52.227-19, or FAR 52.227-14 (ALT III), as applicable.
The information in this educational service, materials and documentation is subject to change
without notice. If you find any problems in this educational service, materials or documentation,
please report them to us in writing.
Informatica, Informatica Platform, Informatica Data Services, PowerCenter, PowerCenterRT,
PowerCenter Connect, PowerCenter Data Analyzer, PowerExchange, PowerMart, Metadata
Manager, Informatica Data Quality, Informatica Data Explorer, Informatica B2B Data
Transformation, Informatica B2B Data Exchange Informatica On Demand, Informatica Identity
Resolution, Informatica Application Information Lifecycle Management, Informatica Complex
Event Processing, Ultra Messaging and Informatica Master Data Management are trademarks or
registered trademarks of Informatica Corporation in the United States and in jurisdictions
throughout the world. All other company and product names may be trade names or trademarks
of their respective owners.
Portions of this educational service, materials and/or documentation are subject to copyright held
by third parties, including without limitation: Copyright © Adobe Systems Incorporated. All rights
reserved. Copyright © Microsoft. All rights reserved. Copyright © Oracle. All rights reserved.
Copyright @ the CentOS Project.
This Software is protected by U.S. Patent Numbers 5,794,246; 6,014,670; 6,016,501; 6,029,178;
6,032,158; 6,035,307; 6,044,374; 6,092,086; 6,208,990; 6,339,775; 6,640,226; 6,789,096;
6,820,077; 6,823,373; 6,850,947; 6,895,471; 7,117,215; 7,162,643; 7,243,110, 7,254,590;
7,281,001; 7,421,458; 7,496,588; 7,523,121; 7,584,422, 7,720,842; 7,721,270; and 7,774,791,
international Patents and other Patents Pending.
DISCLAIMER: Informatica Corporation provides this educational services, materials and
documentation “as is” without warranty of any kind, either express or implied, including, but not
limited to, the implied warranties of non-infringement, merchantability, or use for a particular
purpose. Informatica Corporation does not warrant that this educational service, materials,
documentation or related software is error free. The information provided in this educational
service, materials, documentation and related software may include technical inaccuracies or
typographical errors. The information in this educational service, materials, documentation and
related software is subject to change at any time without notice.
ii
Preface
Prerequisites:
This course is designed for database administrators and professional developers with at
least one year of SQL and database experience. This is meant for those who will be
involved in ILM Dynamic Data Masking project. Additional prerequisites include:
Knowledge of Structures Query Language (SQL)
Microsoft Windows Graphical User Interface
General programming basics
Course Objectives
After successfully completing this course, students should be able to:
Describe the Informatica ILM Dynamic Data Masking
Know the DDM critical terms
Describe the purpose and benefits of DDM
Configure DDM listener Ports
Configure DDM to protect a database
Configure a database client with DDM listener port
Describe and configure Switching Rule Components
Describe and configure a Rule Set
Basic Troubleshooting steps
Audience
This course is designed for professional developers with at least one year of SQL and
database experience. This is meant for those who will be involved in ILM Dynamic Data
Masking project.
3
Document Conventions
This guide uses the following formatting conventions:
If you see… It means… Example
> Indicates a submenu to navigate Click Repository > Connect.
to. In this example, you should click the
Repository menu or button and choose
Connect.
boldfaced text Indicates text you need to type or Click the Rename button and name the new
enter. source definition S_EMPLOYEE.
UPPERCASE Database tables and column names T_ITEM_SUMMARY
are shown in all UPPERCASE.
italicized text Indicates a variable you must Connect to the Repository using the assigned
replace with specific login_id.
information
Note: The following paragraph provides Note: You can select multiple objects to
additional facts. import by using the Ctrl key.
Tip: The following paragraph provides Tip: The m_ prefix for a mapping name is…
suggested uses or a Velocity best
practice.
4
Other Informatica Resources
In addition to the student and lab guides, Informatica provides these other resources:
Informatica Documentation
Informatica Customer Portal
Informatica web site
Informatica Developer Network
Informatica Knowledge Base
Informatica Multimedia Knowledge Base
Informatica How-to Library
Informatica Professional Certification
Informatica Technical Support
Obtaining Informatica Documentation
The Informatica Documentation team takes every effort to create accurate, usable documentation. If
you have questions, comments, or ideas about this documentation, contact the Informatica
Documentation team through email at [email protected]. We will use your
feedback to improve our documentation. Let us know if we can contact you regarding your
comments. The Documentation team updates documentation as needed. To get the latest
documentation for your product, navigate to Product Documentation from
http://mysupport.informatica.com.
5
Visiting the Informatica Knowledge Base
As an Informatica customer, you can access the Informatica Knowledge Base at
http://mysupport.informatica.com. Use the Knowledge Base to search for documented solutions to
known technical issues about Informatica products. You can also find answers to frequently asked
questions, technical white papers, and technical tips. If you have questions, comments, or ideas
about the Knowledge Base, contact the Informatica Knowledge Base team through email at
[email protected].
Providing Feedback
Email any comments on this guide to [email protected].
WebSupport requires a user name and password. You can request a user name and password at:
http://communities.informatica.com
6
Informatica Global Customer Support
You can contact a Customer Support Center by telephone or through the Online Support.
Online Support requires a user name and password. You can request a user name and password
at http://mysupport.informatica.com.
Use the following telephone numbers to contact Informatica Global Customer Support:
vii
Table of Contents
Goals:
Use DDM to create a DDM listener port
Configure DDM to protect a database
Configure a database client with the DDM listener port
Duration:
15 minutes
5) In the Add DDM Services window, select DDM for Oracle and then click
OK.
Figure 3
Note: In the Student environment, you use ports 1525, 1526, and 1530 as
DDM listener ports.
8) The Edit dialog box lists ports 1525 and 1526 by default. Click Add Port.
3) In the SQL Developer, from the toolbar, click File > New
Figure 16: Creating a new database connection
7) Click Connect.
Goals:
Configure a connection rule to intercept database requests specific to a database
Configure a statement processing rule set
Configure a rule within the rule set to validate the time frame
Configure another rule to deny access to the database table CREDIT_CARDS.
Duration:
15 minutes
2) The Rule Editor – DDM for Oracle window appears. In the Rule Editor
Navigator, right-click DDM for Oracle Rules and select Append Rule.
Figure 2: Add connection rule
Note: The Rule Set Name: Source_DB_Rules does not exist at this moment.
You create this rule set in the next step.
4) Click OK.
5) Click File > Update Rules.
6) Click File > Exit.
2) The Add Rule Set window appears. Enter the Rule Set name as
Source_DB_Rules and click OK.
Figure 5: Name a rule set
Goals:
Learn how to
Configure statement processing Rule Set
o Learn to use the text matching method
o Learn to use the mask action type
Display subset of CSR_ID, SSN, and phone columns.
Duration:
15 minutes
Note: By default the Table Name and Column Names are set to .* (dot
star) and the Masking Function is set to substr(\(col)1,2). This means
that all columns in the table will be masked using the substr function
there by resulting only a part of the actual data.
5) To mask the PHONE column, specify the TABLE Name as customer.*
(dot star) and the Column Name as .*PHONE (dot star PHONE)
6) To mask the SSN column, specify the Table Name as customer.* (dot
star) and the Column Name as .*SSN (dot star SSN).
7) To mask the ID column, specify the TABLE Name as customer.* (dot
star) and the Column Name as .*ID (dot star ID)
Figure 4: Specify the columns and the SQL function
Note: For the Masking action, the SQL substr function is completed
automatically. You may use any sql function as a masking function. For this
exercise, use the default substr function.
Goals:
Learn how to
Disable rules within a rule set
Export rules to XML files
Delete rules from DDM
Duration:
5 minutes
Note: You can also select the rule and click Disable from the Rule Editor’s toolbar
Goals:
Learn how to
Intercept an incoming database request
Replace an incoming database request
Duration:
10 minutes
Prerequisites
Deleted Time_Frame, Credit_Cards, and Customer_Tables rules.
Goals:
Learn how to
Create a rule to search and replace parts of an intercepted database request.
Duration:
10 minutes
Prerequisite
Disable or delete all prior rules in the rule set.
Goals:
Learn how to
Import Rules.
Use a JAR file with masking logic in DDM.
Duration:
10 minutes
4) Click OK.
5) In the Rule Editor, click File -> Update Rules.
6) In the rule Editor, click File -> Exit.
2) The Rule Editor window appears. In the Rule Editor Navigator, right-click
Source_DB_Rules and select Import.
Figure 5: Import the rule
4) A new rule named java appears in the list. The Java rule allows the user
scott to access the database and displays a list of tables for the rest of
the users. The logic is defined inside a JAR file which the java rule uses
Figure 7: Imported rule appears in the rule set
Note: Every time you import a rule, the older rules are deleted. The rule from
the previous exercise is deleted once you import the java rule.
Scenario:
You want to dynamically mask the credit card number within the
CREDIT_CARDS table of the SOURCE schema.
Rather than using an existing listener port, you configure a new listener port and
define the protected database within Dynamic Data Masking.
The following workshop is based on all that you have learned in this course. If
you have any difficulty in completing the steps in this workshop, refer back to
your labs as a reference.
Configure a
listener port Add a new listener port
Define Protected
Database Define a protected database
Create Switching Configure a switching rule to capture incoming
Rule database requests
Figure 1
2) In the Edit window, click Add Port. Enter 1600 and click OK.
Figure 2
Figure 3
2) In the Create Database window, click the plus sign (+) and enter the
following:
a) Database Name: Source_Schema
b) Instance Name: infaorcl
c) Listener Address: 10.10.10.10
d) Listener Port: 1521
e) Service Name: infaorcl
f) DBA Username: SYSTEM
g) DBA Password: admin
Figure 4
Figure 5
2) In the Rule Editor Navigator, right-click DDM for Oracle and select
Append rule.
Figure 6
Figure 7
Figure 8
2) In the Add Rule Set box, enter the Rule Set name as CreditCards.
Figure 9
Figure 10
Figure 11
Figure 12
6) In the Append Rule window, click the plus sign (+) and enter the following:
a) Action: Mask
b) Table Name: .* (Dot Star)
c) Column Name: .*CARD.*
d) Masking Function:
TRUNC(DBMS_RANDOM.VALUE(5555555555555555,
9999999999999999))
Note: The TRUNC SQL function determines the random value range
that will be used to mask the credit card numbers.
Figure 13
Figure 14
Figure 15
Figure 16
7) Expand the Tables (Filtered) and select the CREDIT_CARDS table and
then select the Data tab. The original values of the
CREDIT_CARD_NUMBER column appear. You compare the original
values with the masked values in the next step.
Figure 18