NAME
Kernel::System::DataPrivacy::Base – Base functions for the data privacy protection driver modules.
DESCRIPTION
All functions to manage the data privacy protection functionality.
PUBLIC INTERFACE
new()
Constructor to handle and transform possible rule definitions to sets of rules, related to their actions.
Verify()
Verifies the available rules for their integrity.
my $VerifyResult = $Driver->Verify();
Returns
{
Success => 0,
Errors => {},
Result => {},
}
Search()
Generates a new UUID.
my $SearchResult = $Driver->Search();
Returns the UUID string.
Execute()
Generates a new UUID.
my $ExecuteResult = $Driver->Execute();
Returns the UUID string.
PRIVATE INTERFACE
_ParseRules()
Parses the raw rule definitions and transforms them to an usable array of hashes, containing prepared data for the related object type modules.
my $RuleSet = $Driver->_ParseRules(
Rules => [
{
RuleName => 'Delete Commercial Data after 10 Years',
RuleType => 'PrivacyByDeletion' || 'Deletion',
RuleSource => 'Sarbanes and Oxley Act',
Ticket => [
'CustomerUserID',
'DynamicField_XYZ',
'CustomerID',
'HistoryType_XYZ'
],
'DataClassification' => undef,
}
]
);
Returns a set of rules:
[
{
Type => 'deletion',
Name => 'Delete Commercial Data after 10 Years'
}
]
_GenerateUUID()
Generates a new UUID.
my $UUID = $Driver->GenerateUUID();
Returns the UUID string.
_Replace()
Performs the deletion, anonymization or pseudonymization actions on the given tables and fields, based on the given identifiers and object id's.
my $ReplacementResult = $Driver->_Replace(
Type => 'pseudonymization', # mandatory
Table => 'ticket', # mandatory
Columns => [ 'title', 'customer_user_id' ], # mandatory
ObjectIDs => [ 123, 234, 345 ], # mandatory
Identifier => 'id', # mandatory
AdditionalIdentifiers => { # optional, AND-concatenated with identifier
'column_name' => 'column_value',
'multi_value' => [ 'value1', 'value2' ], # results in:
# 'multi_value' IN ('value1','value2')
},
);
Returns a hash reference containing the success state, the errors and results.
{
Success => 1
Errors => [],
Result => [
123,
234,
345,
],
}
or
{
Success => 1
Errors => [
{
345 => "Could not pseudonymize data for field 'customer_user_id'!",
},
],
Result => [
123,
234,
],
}
