Manage Sensitive Data Discovery Rules
In previous documentation, rule is referred to as classifier or identifier and framework is referred to as template.
Prerequisite
Sensitive data discovery must be enabled.
Command overview: immuta sdd classifier
immuta sdd classifier
This command allows you to manage rules that will apply tags to data that matches patterns you specify during SDD. The table below illustrates subcommands and arguments.
Subcommands | Aliases | Description |
---|---|---|
| Create a rule. | |
None | Delete the passed rule. | |
None | Get a rule. | |
| Search all rules. | |
None | Update a rule. |
Options
Use these options to get more details about the sdd classifier
command or any of its subcommands:
-h
--help
Create a rule
Save your rule to a valid YAML or JSON file using these attributes.
Attribute Description Required name
string
Unique, request-friendly rule name.Yes
displayName
string
Unique, human-readable rule name.Yes
description
string
The rule description.Yes
type
string
The type of pattern:regex
,dictionary
,columnNameRegex
, orbuiltIn
.Yes
config
object
The configuration of the rule, which may includeconfig.values
,config.caseSensitive
,config.regex
,config.columnNameRegex
, andconfig.tags
.Yes
config.tags
array[string]
The name of the tags to apply to the data source.Yes
config.regex
string
A case-insensitive regular expression to match against column values.No
config.columnNameRegex
string
A case-insensitive regular expression to match against column names.No
config.values
array[string]
The list of words to include in the dictionary.No
config.caseSensitive
boolean
Indicates whether or notvalues
are case sensitive. Defaults tofalse
.No
Examples are provided below.
Run
immuta sdd classifier create <filepath> [flags]
, referencing the file you just created. The options you can specify include-h
or--help
: Get more information about the command.-o
or--output json | yaml
: Specify the output format.--outputTemplate string
: Format the response using a Go template.
Example
Get a rule
Run immuta sdd classifier get <classifierName> [flags]
, specifying the name of the rule you would like to get. Options you can specify include
-h
or--help
: Get more information about the command.-o
or--output json | yaml
: Specify the output format.--outputTemplate string
: Format the response using a Go template.
Example
The example below illustrates a user getting a rule called ACCOUNT_NUMBER_RULE.
Search rules
Run immuta sdd classifier search [string] [flags]
to list all rules or search rules by name. Options you can specify include
-h
,--help
: Help for search.--limit int
The search limit for pagination (default 25).--offset int
: The search offset for pagination.--order asc | desc
: The sort order.-o
,--output json | yaml
: The output format.--outputTemplate string
: Format the response using a Go template.-s
,--sort id | name | displayName | type | createdAt | updatedAt
: Field to sort by.--type regex | columnNameRegex | dictionary | builtIn
: Limit results to the specified pattern type.
Example
The example below illustrates a user searching all rules containing account
.
Update a rule
Update your rule in a valid YAML or JSON file using these attributes:
Attribute Description Required name
string
Unique, request-friendly rule name.Yes
displayName
string
Unique, human-readable rule name.Yes
description
string
The rule description.Yes
type
string
The type of pattern:regex
,dictionary
,columnNameRegex
, orbuiltIn
.Yes
config
object
The configuration of the rule, which may includeconfig.values
,config.caseSensitive
,config.regex
,config.columnNameRegex
, andconfig.tags
.Yes
config.tags
array[string]
The name of the tags to apply to the data source.Yes
config.regex
string
A case-insensitive regular expression to match against column values.No
config.columnNameRegex
string
A case-insensitive regular expression to match against column names.No
config.values
array[string]
The list of words to include in the dictionary.No
config.caseSensitive
boolean
Indicates whether or notvalues
are case sensitive. Defaults tofalse
.No
Run
immuta sdd classifier update <classifierName> <filepath> [flags]
, referencing the file you just updated. The options you can specify include-h
or--help
: Get more information about the command.-o
or--output json | yaml
: Specify the output format.--outputTemplate string
: Format the response using a Go template.
Example
The example below illustrates a user updating a rule named ACCOUNT_NUMBER_RULE.
Delete a rule
Run immuta sdd classifier delete <classifierName> [flags]
to delete the rule. The options you can specify include
-h
or--help
: Get more information about the command.-o
or--output json | yaml
: Specify the output format.--outputTemplate string
: Format the response using a Go template.
Example
Last updated