@google-cloud/dlp 5.10.0 → 5.11.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -4,6 +4,13 @@
4
4
 
5
5
  [1]: https://www.npmjs.com/package/PACKAGE NAME?activeTab=versions
6
6
 
7
+ ## [5.11.0](https://github.com/googleapis/google-cloud-node/compare/dlp-v5.10.0...dlp-v5.11.0) (2024-09-24)
8
+
9
+
10
+ ### Features
11
+
12
+ * [dlp] action for publishing data profiles to SecOps (formelly known as Chronicle) ([#5691](https://github.com/googleapis/google-cloud-node/issues/5691)) ([106d029](https://github.com/googleapis/google-cloud-node/commit/106d029eacd05fc890dffd1169a19d4596d93c54))
13
+
7
14
  ## [5.10.0](https://github.com/googleapis/google-cloud-node/compare/dlp-v5.9.0...dlp-v5.10.0) (2024-08-19)
8
15
 
9
16
 
package/README.md CHANGED
@@ -44,7 +44,7 @@ Google APIs Client Libraries, in [Client Libraries Explained][explained].
44
44
  1. [Select or create a Cloud Platform project][projects].
45
45
  1. [Enable billing for your project][billing].
46
46
  1. [Enable the Cloud Data Loss Prevention API][enable_api].
47
- 1. [Set up authentication with a service account][auth] so you can access the
47
+ 1. [Set up authentication][auth] so you can access the
48
48
  API from your local workstation.
49
49
 
50
50
  ### Installing the client library
@@ -250,4 +250,4 @@ See [LICENSE](https://github.com/googleapis/google-cloud-node/blob/main/LICENSE)
250
250
  [projects]: https://console.cloud.google.com/project
251
251
  [billing]: https://support.google.com/cloud/answer/6293499#enable-billing
252
252
  [enable_api]: https://console.cloud.google.com/flows/enableapi?apiid=dlp.googleapis.com
253
- [auth]: https://cloud.google.com/docs/authentication/getting-started
253
+ [auth]: https://cloud.google.com/docs/authentication/external/set-up-adc-local
@@ -4897,6 +4897,12 @@ message DataProfileAction {
4897
4897
  ERROR_CHANGED = 4;
4898
4898
  }
4899
4899
 
4900
+ // Message expressing intention to publish to Google Security Operations.
4901
+ message PublishToChronicle {}
4902
+
4903
+ // If set, a summary finding will be created/updated in SCC for each profile.
4904
+ message PublishToSecurityCommandCenter {}
4905
+
4900
4906
  // If set, attaches the [tags]
4901
4907
  // (https://cloud.google.com/resource-manager/docs/tags/tags-overview)
4902
4908
  // provided to profiled resources. Tags support [access
@@ -4959,6 +4965,15 @@ message DataProfileAction {
4959
4965
  // Publish a message into the Pub/Sub topic.
4960
4966
  PubSubNotification pub_sub_notification = 2;
4961
4967
 
4968
+ // Publishes generated data profiles to Google Security Operations.
4969
+ // For more information, see [Use Sensitive Data Protection data in
4970
+ // context-aware
4971
+ // analytics](https://cloud.google.com/chronicle/docs/detection/usecase-dlp-high-risk-user-download).
4972
+ PublishToChronicle publish_to_chronicle = 3;
4973
+
4974
+ // Publishes findings to SCC for each data profile.
4975
+ PublishToSecurityCommandCenter publish_to_scc = 4;
4976
+
4962
4977
  // Tags the profiled resources with the specified tag values.
4963
4978
  TagResources tag_resources = 8;
4964
4979
  }
@@ -4980,6 +4995,9 @@ message DataProfileJobConfig {
4980
4995
  // that are profiled, and the Cloud DLP API must be enabled.
4981
4996
  string project_id = 5;
4982
4997
 
4998
+ // Must be set only when scanning other clouds.
4999
+ OtherCloudDiscoveryStartingLocation other_cloud_starting_location = 8;
5000
+
4983
5001
  // Detection logic for profile generation.
4984
5002
  //
4985
5003
  // Not all template features are used by profiles. FindingLimits,
@@ -5144,6 +5162,9 @@ message DiscoveryConfig {
5144
5162
  // Only set when the parent is an org.
5145
5163
  OrgConfig org_config = 2;
5146
5164
 
5165
+ // Must be set only when scanning other clouds.
5166
+ OtherCloudDiscoveryStartingLocation other_cloud_starting_location = 12;
5167
+
5147
5168
  // Detection logic for profile generation.
5148
5169
  //
5149
5170
  // Not all template features are used by Discovery. FindingLimits,
@@ -5210,6 +5231,10 @@ message DiscoveryTarget {
5210
5231
  // Cloud Storage target for Discovery. The first target to match a table
5211
5232
  // will be the one applied.
5212
5233
  CloudStorageDiscoveryTarget cloud_storage_target = 4;
5234
+
5235
+ // Other clouds target for discovery. The first target to match a resource
5236
+ // will be the one applied.
5237
+ OtherCloudDiscoveryTarget other_cloud_target = 5;
5213
5238
  }
5214
5239
  }
5215
5240
 
@@ -5821,6 +5846,208 @@ message DiscoveryFileStoreConditions {
5821
5846
  }
5822
5847
  }
5823
5848
 
5849
+ // Target used to match against for discovery of resources from other clouds.
5850
+ // An [AWS connector in Security Command Center
5851
+ // (Enterprise](https://cloud.google.com/security-command-center/docs/connect-scc-to-aws)
5852
+ // is required to use this feature.
5853
+ message OtherCloudDiscoveryTarget {
5854
+ // Required. The type of data profiles generated by this discovery target.
5855
+ // Supported values are:
5856
+ // * aws/s3/bucket
5857
+ DataSourceType data_source_type = 1 [(google.api.field_behavior) = REQUIRED];
5858
+
5859
+ // Required. The resources that the discovery cadence applies to. The
5860
+ // first target with a matching filter will be the one to apply to a resource.
5861
+ DiscoveryOtherCloudFilter filter = 2 [(google.api.field_behavior) = REQUIRED];
5862
+
5863
+ // Optional. In addition to matching the filter, these conditions must be true
5864
+ // before a profile is generated.
5865
+ DiscoveryOtherCloudConditions conditions = 3
5866
+ [(google.api.field_behavior) = OPTIONAL];
5867
+
5868
+ // Type of cadence.
5869
+ oneof cadence {
5870
+ // How often and when to update data profiles. New resources that match both
5871
+ // the filter and conditions are scanned as quickly as possible depending on
5872
+ // system capacity.
5873
+ DiscoveryOtherCloudGenerationCadence generation_cadence = 4;
5874
+
5875
+ // Disable profiling for resources that match this filter.
5876
+ Disabled disabled = 5;
5877
+ }
5878
+ }
5879
+
5880
+ // Determines which resources from the other cloud will have profiles generated.
5881
+ // Includes the ability to filter by resource names.
5882
+ message DiscoveryOtherCloudFilter {
5883
+ // Whether the filter applies to a specific set of resources or all
5884
+ // other resources. The first filter to match will be applied, regardless of
5885
+ // the condition. Defaults to `others` if none is set.
5886
+ oneof filter {
5887
+ // A collection of resources for this filter to apply to.
5888
+ OtherCloudResourceCollection collection = 1;
5889
+
5890
+ // The resource to scan. Configs using this filter can only have one target
5891
+ // (the target with this single resource reference).
5892
+ OtherCloudSingleResourceReference single_resource = 2;
5893
+
5894
+ // Optional. Catch-all. This should always be the last target in the list
5895
+ // because anything above it will apply first. Should only appear once in a
5896
+ // configuration. If none is specified, a default one will be added
5897
+ // automatically.
5898
+ AllOtherResources others = 100 [(google.api.field_behavior) = OPTIONAL];
5899
+ }
5900
+ }
5901
+
5902
+ // Match resources using regex filters.
5903
+ message OtherCloudResourceCollection {
5904
+ // The first filter containing a pattern that matches a resource will be used.
5905
+ oneof pattern {
5906
+ // A collection of regular expressions to match a resource against.
5907
+ OtherCloudResourceRegexes include_regexes = 1;
5908
+ }
5909
+ }
5910
+
5911
+ // A collection of regular expressions to determine what resources to match
5912
+ // against.
5913
+ message OtherCloudResourceRegexes {
5914
+ // A group of regular expression patterns to match against one or more
5915
+ // resources.
5916
+ // Maximum of 100 entries. The sum of all regular expression's length can't
5917
+ // exceed 10 KiB.
5918
+ repeated OtherCloudResourceRegex patterns = 1;
5919
+ }
5920
+
5921
+ // A pattern to match against one or more resources. At least one pattern must
5922
+ // be specified. Regular expressions use RE2
5923
+ // [syntax](https://github.com/google/re2/wiki/Syntax); a guide can be found
5924
+ // under the google/re2 repository on GitHub.
5925
+ message OtherCloudResourceRegex {
5926
+ // The type of resource regex to use.
5927
+ oneof resource_regex {
5928
+ // Regex for Amazon S3 buckets.
5929
+ AmazonS3BucketRegex amazon_s3_bucket_regex = 1;
5930
+ }
5931
+ }
5932
+
5933
+ // AWS account regex.
5934
+ message AwsAccountRegex {
5935
+ // Optional. Regex to test the AWS account ID against.
5936
+ // If empty, all accounts match.
5937
+ string account_id_regex = 1 [(google.api.field_behavior) = OPTIONAL];
5938
+ }
5939
+
5940
+ // Amazon S3 bucket regex.
5941
+ message AmazonS3BucketRegex {
5942
+ // The AWS account regex.
5943
+ AwsAccountRegex aws_account_regex = 1;
5944
+
5945
+ // Optional. Regex to test the bucket name against.
5946
+ // If empty, all buckets match.
5947
+ string bucket_name_regex = 2 [(google.api.field_behavior) = OPTIONAL];
5948
+ }
5949
+
5950
+ // Identifies a single resource, like a single Amazon S3 bucket.
5951
+ message OtherCloudSingleResourceReference {
5952
+ // The resource to scan.
5953
+ oneof resource {
5954
+ // Amazon S3 bucket.
5955
+ AmazonS3Bucket amazon_s3_bucket = 1;
5956
+ }
5957
+ }
5958
+
5959
+ // AWS account.
5960
+ message AwsAccount {
5961
+ // Required. AWS account ID.
5962
+ string account_id = 1 [(google.api.field_behavior) = REQUIRED];
5963
+ }
5964
+
5965
+ // Amazon S3 bucket.
5966
+ message AmazonS3Bucket {
5967
+ // The AWS account.
5968
+ AwsAccount aws_account = 1;
5969
+
5970
+ // Required. The bucket name.
5971
+ string bucket_name = 2 [(google.api.field_behavior) = REQUIRED];
5972
+ }
5973
+
5974
+ // Requirements that must be true before a resource is profiled for the first
5975
+ // time.
5976
+ message DiscoveryOtherCloudConditions {
5977
+ // Minimum age a resource must be before Cloud DLP can profile it. Value must
5978
+ // be 1 hour or greater.
5979
+ google.protobuf.Duration min_age = 1;
5980
+
5981
+ // The conditions to apply.
5982
+ oneof conditions {
5983
+ // Amazon S3 bucket conditions.
5984
+ AmazonS3BucketConditions amazon_s3_bucket_conditions = 2;
5985
+ }
5986
+ }
5987
+
5988
+ // Amazon S3 bucket conditions.
5989
+ message AmazonS3BucketConditions {
5990
+ // Supported Amazon S3 bucket types.
5991
+ // Defaults to TYPE_ALL_SUPPORTED.
5992
+ enum BucketType {
5993
+ // Unused.
5994
+ TYPE_UNSPECIFIED = 0;
5995
+
5996
+ // All supported classes.
5997
+ TYPE_ALL_SUPPORTED = 1;
5998
+
5999
+ // A general purpose Amazon S3 bucket.
6000
+ TYPE_GENERAL_PURPOSE = 2;
6001
+ }
6002
+
6003
+ // Supported Amazon S3 object storage classes.
6004
+ // Defaults to ALL_SUPPORTED_CLASSES.
6005
+ enum ObjectStorageClass {
6006
+ // Unused.
6007
+ UNSPECIFIED = 0;
6008
+
6009
+ // All supported classes.
6010
+ ALL_SUPPORTED_CLASSES = 1;
6011
+
6012
+ // Standard object class.
6013
+ STANDARD = 2;
6014
+
6015
+ // Standard - infrequent access object class.
6016
+ STANDARD_INFREQUENT_ACCESS = 4;
6017
+
6018
+ // Glacier - instant retrieval object class.
6019
+ GLACIER_INSTANT_RETRIEVAL = 6;
6020
+
6021
+ // Objects in the S3 Intelligent-Tiering access tiers.
6022
+ INTELLIGENT_TIERING = 7;
6023
+ }
6024
+
6025
+ // Optional. Bucket types that should be profiled.
6026
+ // Optional. Defaults to TYPE_ALL_SUPPORTED if unspecified.
6027
+ repeated BucketType bucket_types = 1 [(google.api.field_behavior) = OPTIONAL];
6028
+
6029
+ // Optional. Object classes that should be profiled.
6030
+ // Optional. Defaults to ALL_SUPPORTED_CLASSES if unspecified.
6031
+ repeated ObjectStorageClass object_storage_classes = 2
6032
+ [(google.api.field_behavior) = OPTIONAL];
6033
+ }
6034
+
6035
+ // How often existing resources should have their profiles refreshed.
6036
+ // New resources are scanned as quickly as possible depending on system
6037
+ // capacity.
6038
+ message DiscoveryOtherCloudGenerationCadence {
6039
+ // Optional. Frequency to update profiles regardless of whether the underlying
6040
+ // resource has changes. Defaults to never.
6041
+ DataProfileUpdateFrequency refresh_frequency = 1
6042
+ [(google.api.field_behavior) = OPTIONAL];
6043
+
6044
+ // Optional. Governs when to update data profiles when the inspection rules
6045
+ // defined by the `InspectTemplate` change.
6046
+ // If not set, changing the template will not cause a data profile to update.
6047
+ DiscoveryInspectTemplateModifiedCadence inspect_template_modified_cadence = 2
6048
+ [(google.api.field_behavior) = OPTIONAL];
6049
+ }
6050
+
5824
6051
  // The location to begin a discovery scan. Denotes an organization ID or folder
5825
6052
  // ID within an organization.
5826
6053
  message DiscoveryStartingLocation {
@@ -5834,6 +6061,31 @@ message DiscoveryStartingLocation {
5834
6061
  }
5835
6062
  }
5836
6063
 
6064
+ // The other cloud starting location for discovery.
6065
+ message OtherCloudDiscoveryStartingLocation {
6066
+ // The AWS starting location for discovery.
6067
+ message AwsDiscoveryStartingLocation {
6068
+ // The scope of this starting location.
6069
+ oneof scope {
6070
+ // The AWS account ID that this discovery config applies to.
6071
+ // Within an AWS organization, you can find the AWS account ID inside an
6072
+ // AWS account ARN. Example:
6073
+ // arn:{partition}:organizations::{management_account_id}:account/{org_id}/{account_id}
6074
+ string account_id = 2;
6075
+
6076
+ // All AWS assets stored in Asset Inventory that didn't match other AWS
6077
+ // discovery configs.
6078
+ bool all_asset_inventory_assets = 3;
6079
+ }
6080
+ }
6081
+
6082
+ // The other cloud starting location for discovery.
6083
+ oneof location {
6084
+ // The AWS starting location for discovery.
6085
+ AwsDiscoveryStartingLocation aws_location = 1;
6086
+ }
6087
+ }
6088
+
5837
6089
  // Match discovery resources not covered by any other filter.
5838
6090
  message AllOtherResources {}
5839
6091
 
@@ -6946,7 +7198,7 @@ message ProjectDataProfile {
6946
7198
  // The resource name of the profile.
6947
7199
  string name = 1;
6948
7200
 
6949
- // Project ID that was profiled.
7201
+ // Project ID or account that was profiled.
6950
7202
  string project_id = 2;
6951
7203
 
6952
7204
  // The last time the profile was generated.
@@ -7364,6 +7616,7 @@ message ColumnDataProfile {
7364
7616
  // The profile for a file store.
7365
7617
  //
7366
7618
  // * Cloud Storage: maps 1:1 with a bucket.
7619
+ // * Amazon S3: maps 1:1 with a bucket.
7367
7620
  message FileStoreDataProfile {
7368
7621
  option (google.api.resource) = {
7369
7622
  type: "dlp.googleapis.com/FileStoreDataProfile"
@@ -7396,12 +7649,15 @@ message FileStoreDataProfile {
7396
7649
  string project_data_profile = 3;
7397
7650
 
7398
7651
  // The Google Cloud project ID that owns the resource.
7652
+ // For Amazon S3 buckets, this is the AWS Account Id.
7399
7653
  string project_id = 4;
7400
7654
 
7401
7655
  // The location of the file store.
7402
7656
  //
7403
7657
  // * Cloud Storage:
7404
7658
  // https://cloud.google.com/storage/docs/locations#available-locations
7659
+ // * Amazon S3:
7660
+ // https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints
7405
7661
  string file_store_location = 5;
7406
7662
 
7407
7663
  // For resources that have multiple storage locations, these are those
@@ -7419,10 +7675,14 @@ message FileStoreDataProfile {
7419
7675
  // The file store path.
7420
7676
  //
7421
7677
  // * Cloud Storage: `gs://{bucket}`
7678
+ // * Amazon S3: `s3://{bucket}`
7422
7679
  string file_store_path = 6;
7423
7680
 
7424
7681
  // The resource name of the resource profiled.
7425
7682
  // https://cloud.google.com/apis/design/resource_names#full_resource_name
7683
+ //
7684
+ // Example format of an S3 bucket full resource name:
7685
+ // `//cloudasset.googleapis.com/organizations/{org_id}/otherCloudConnections/aws/arn:aws:s3:::{bucket_name}`
7426
7686
  string full_resource = 24;
7427
7687
 
7428
7688
  // The snapshot of the configurations used to generate the profile.
@@ -7599,6 +7859,7 @@ message ListFileStoreDataProfilesRequest {
7599
7859
  // * A restriction has the form of `{field} {operator} {value}`.
7600
7860
  // * Supported fields/values:
7601
7861
  // - `project_id` - The Google Cloud project ID.
7862
+ // - `account_id` - The AWS account ID.
7602
7863
  // - `file_store_path` - The path like "gs://bucket".
7603
7864
  // - `data_source_type` - The profile's data source type, like
7604
7865
  // "google/storage/bucket".
@@ -7995,7 +8256,12 @@ message DeleteTableDataProfileRequest {
7995
8256
  // Message used to identify the type of resource being profiled.
7996
8257
  message DataSourceType {
7997
8258
  // Output only. An identifying string to the type of resource being profiled.
7998
- // Current values: google/bigquery/table, google/project
8259
+ // Current values:
8260
+ //
8261
+ // * google/bigquery/table
8262
+ // * google/project
8263
+ // * google/sql/table
8264
+ // * google/gcs/bucket
7999
8265
  string data_source = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
8000
8266
  }
8001
8267