Class: AWSCDK::Bedrock::CfnDataAutomationProject::SensitiveDataConfigurationProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
bedrock/cfn_data_automation_project.rb

Overview

Configuration for detecting and redacting sensitive data in content.

Use this to control whether sensitive data is detected only or both detected and redacted, specify the scope of detection (standard output, custom output, or both), and configure specific PII entity types to detect along with how they should be masked when redacted.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(detection_mode: nil, detection_scope: nil, pii_entities_configuration: nil) ⇒ SensitiveDataConfigurationProperty

Returns a new instance of SensitiveDataConfigurationProperty.

Parameters:

  • detection_mode (String, nil) (defaults to: nil)

    Specifies the mode for handling sensitive data detection.

  • detection_scope (Array<String>, nil) (defaults to: nil)

    Defines which BDA output types to apply sensitive data detection to.

  • pii_entities_configuration (AWSCDK::IResolvable, AWSCDK::Bedrock::CfnDataAutomationProject::PIIEntitiesConfigurationProperty, nil) (defaults to: nil)

    Configuration for detecting and redacting Personally Identifiable Information (PII) entities.



1926
1927
1928
1929
1930
1931
1932
1933
# File 'bedrock/cfn_data_automation_project.rb', line 1926

def initialize(detection_mode: nil, detection_scope: nil, pii_entities_configuration: nil)
  @detection_mode = detection_mode
  Jsii::Type.check_type(@detection_mode, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "detectionMode") unless @detection_mode.nil?
  @detection_scope = detection_scope
  Jsii::Type.check_type(@detection_scope, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "detectionScope") unless @detection_scope.nil?
  @pii_entities_configuration = pii_entities_configuration.is_a?(Hash) ? ::AWSCDK::Bedrock::CfnDataAutomationProject::PIIEntitiesConfigurationProperty.new(**pii_entities_configuration.transform_keys(&:to_sym)) : pii_entities_configuration
  Jsii::Type.check_type(@pii_entities_configuration, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19iZWRyb2NrLkNmbkRhdGFBdXRvbWF0aW9uUHJvamVjdC5QSUlFbnRpdGllc0NvbmZpZ3VyYXRpb25Qcm9wZXJ0eSJ9XX19")), "piiEntitiesConfiguration") unless @pii_entities_configuration.nil?
end

Instance Attribute Details

#detection_modeString? (readonly)

Specifies the mode for handling sensitive data detection.

Set to DETECTION to only identify sensitive data without modifying content - this produces one output file per detection scope containing detection information with original unredacted content. Set to DETECTION_AND_REDACTION to both identify and mask sensitive data - this produces two output files per detection scope: one unredacted file with detection information and one redacted file with masking applied to sensitive content. For example, if detectionScope includes both STANDARD and CUSTOM with DETECTION_AND_REDACTION mode, four output files will be generated (two for standard output and two for custom output).



1941
1942
1943
# File 'bedrock/cfn_data_automation_project.rb', line 1941

def detection_mode
  @detection_mode
end

#detection_scopeArray<String>? (readonly)

Defines which BDA output types to apply sensitive data detection to.

Specify STANDARD to detect sensitive data in standard output, CUSTOM to detect in custom output (blueprint-based extraction), or both to apply detection to both output types. If not specified, defaults to both STANDARD and CUSTOM. The number of output files generated depends on both the detection mode and the scopes selected - each scope specified will produce its own set of output files according to the detection mode configured.



1948
1949
1950
# File 'bedrock/cfn_data_automation_project.rb', line 1948

def detection_scope
  @detection_scope
end

#pii_entities_configurationAWSCDK::IResolvable, ... (readonly)

Configuration for detecting and redacting Personally Identifiable Information (PII) entities.



1953
1954
1955
# File 'bedrock/cfn_data_automation_project.rb', line 1953

def pii_entities_configuration
  @pii_entities_configuration
end

Class Method Details

.jsii_propertiesObject



1955
1956
1957
1958
1959
1960
1961
# File 'bedrock/cfn_data_automation_project.rb', line 1955

def self.jsii_properties
  {
    :detection_mode => "detectionMode",
    :detection_scope => "detectionScope",
    :pii_entities_configuration => "piiEntitiesConfiguration",
  }
end

Instance Method Details

#to_jsiiObject



1963
1964
1965
1966
1967
1968
1969
1970
1971
# File 'bedrock/cfn_data_automation_project.rb', line 1963

def to_jsii
  result = {}
  result.merge!({
    "detectionMode" => @detection_mode,
    "detectionScope" => @detection_scope,
    "piiEntitiesConfiguration" => @pii_entities_configuration,
  })
  result.compact
end