Skip to main content

Overview of the mask rules

Overview

The mask rule generates values using input sources.

  • In an update, the rules replaces existing column values
  • In a create, the rules populate new rows of values

ANO Structure

...
task <task-name> {

<update-or-create> <table> <task-name?>
mask <column-name> <rule-name?> // ´?´ means optional
format <format>
transform? <transformation?>
unique?
<input-sources>
convert? <conversion?>
map? <mapping-file?> <mapping-rule?>
}
...

Explained

  • The mask keyword is followed by the column that is being anonymized by the rule
  • format describes the output of the mask rule
  • transform refers to a java transformation function in the DBmasker project that will transform the output of the mask rule before storing back to database
  • unique will make the rule respect the unique constraint of the table column
  • input-sources define where input where the values are sourced from
  • convert refers to a java conversion function in the DBmasker project that will take the input source values as inputs before passing it to the rule
  • map refers to a mapping file that may be used as an input, output or input-output of the rule

Mask Input Sources

random-[type]

The random-[type] input source is used to insert a value drawn from a random sequence as defined by the <from> and <to> properties. The random-[type] is one of