我正在使用数据泄漏预防(GCP)开发 PII de 识别应用程序。我正在为去识别规则使用去识别模板。
问题:我无法弄清楚如何在去标识化模板中使用自定义信息类型。
这是一个示例去标识化模板:
{
"deidentifyTemplate":{
"displayName":"Email and id masker",
"description":"De-identifies emails and ids with a series of asterisks.",
"deidentifyConfig":{
"infoTypeTransformations":{
"transformations":[
{
"infoTypes":[
{
"name":"EMAIL_ADDRESS"
}
],
"primitiveTransformation":{
"characterMaskConfig":{
"maskingCharacter":"*"
}
}
}
]
}
}
}
}
在上面的示例中,它是一个 bultin 信息类型(电子邮件),并且在文档中自定义信息类型片段如下所示:
"inspect_config":{
"custom_info_types":[
{
"info_type":{
"name":"CUSTOM_ID"
},
"regex":{
"pattern":"[1-9]{2}-[1-9]{4}"
},
"likelihood":"POSSIBLE"
}
]
}
去识别模板的剩余文档没有有效的对象定义inspect_config
,它仅在检查模板中有效。
是否可以在识别模板(infoTypeTransformations
)中使用自定义信息类型?
这是其余文档的链接。