google-apis-cloudasset_v1p4beta1 0.1.0 → 0.6.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f7ff7f847fb076ec80f559da0b77c1ac90d5f0d7ef6cae0a84dc6c2ebbe3e286
4
- data.tar.gz: 7ff9d505d045533dd3b1144d90c8c99ff8080e906d33bcb78947ed89a105d100
3
+ metadata.gz: d3cef2f7bbf838cbf423e0a5d51a92a0425c6e093f006bafcd8373217f22d78f
4
+ data.tar.gz: 19df6ec1a25a7d60f3d1dde5694cdb3ec2afd7f564aeb5907732bf6f3128f4f0
5
5
  SHA512:
6
- metadata.gz: 4f5a7bf5fb9d18f0b510ebd1435750c7347c65a283b1ace376c2d749b7c81713df60ac1bd4ed4871b75520bef4cd73548ad8de1ec8d91ea343b492761ebdb81f
7
- data.tar.gz: a0996641fbdaebd366f483b043150ed8d641f31f50aadd786019fa6653d64d30d0ff3248303ff2fdb8d625ad65baae5155afa85a5d3eb0b1033f39d17a126ecf
6
+ metadata.gz: f115593940ab62f784a1ee8168769394bf5c18a3a0063bcf18e0ff5b6041cb2ccca5b71980d9cd18410b8d80eef6052302c6a6f89bdece0cba521c3c8d298816
7
+ data.tar.gz: fad6027103f7dd5b639520e744ab88578ed3bb5cf1669b5708f3be095cafdadd83a2863c18cba2dd805a04608a32ec2b8d814bb1961c4deb071189185c208869
data/CHANGELOG.md CHANGED
@@ -1,5 +1,27 @@
1
1
  # Release history for google-apis-cloudasset_v1p4beta1
2
2
 
3
+ ### v0.6.0 (2021-05-19)
4
+
5
+ * Unspecified changes
6
+
7
+ ### v0.5.0 (2021-04-22)
8
+
9
+ * Regenerated from discovery document revision 20210416
10
+
11
+ ### v0.4.0 (2021-03-31)
12
+
13
+ * Regenerated from discovery document revision 20210326
14
+
15
+ ### v0.3.0 (2021-03-09)
16
+
17
+ * Regenerated from discovery document revision 20210305
18
+ * Regenerated using generator version 0.2.0
19
+
20
+ ### v0.2.0 (2021-03-04)
21
+
22
+ * Regenerated from discovery document revision 20210226
23
+ * Regenerated using generator version 0.1.2
24
+
3
25
  ### v0.1.0 (2021-01-07)
4
26
 
5
27
  * Regenerated using generator version 0.1.1
@@ -29,7 +29,7 @@ module Google
29
29
  # This is NOT the gem version.
30
30
  VERSION = 'V1p4beta1'
31
31
 
32
- # View and manage your data across Google Cloud Platform services
32
+ # See, edit, configure, and delete your Google Cloud Platform data
33
33
  AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'
34
34
  end
35
35
  end
@@ -51,6 +51,19 @@ module Google
51
51
  end
52
52
  end
53
53
 
54
+ # A response message for AssetService.AnalyzeIamPolicyLongrunning.
55
+ class AnalyzeIamPolicyLongrunningResponse
56
+ include Google::Apis::Core::Hashable
57
+
58
+ def initialize(**args)
59
+ update!(**args)
60
+ end
61
+
62
+ # Update properties of this object
63
+ def update!(**args)
64
+ end
65
+ end
66
+
54
67
  # A response message for AssetService.AnalyzeIamPolicy.
55
68
  class AnalyzeIamPolicyResponse
56
69
  include Google::Apis::Core::Hashable
@@ -93,6 +106,77 @@ module Google
93
106
  end
94
107
  end
95
108
 
109
+ # Specifies the audit configuration for a service. The configuration determines
110
+ # which permission types are logged, and what identities, if any, are exempted
111
+ # from logging. An AuditConfig must have one or more AuditLogConfigs. If there
112
+ # are AuditConfigs for both `allServices` and a specific service, the union of
113
+ # the two AuditConfigs is used for that service: the log_types specified in each
114
+ # AuditConfig are enabled, and the exempted_members in each AuditLogConfig are
115
+ # exempted. Example Policy with multiple AuditConfigs: ` "audit_configs": [ ` "
116
+ # service": "allServices", "audit_log_configs": [ ` "log_type": "DATA_READ", "
117
+ # exempted_members": [ "user:jose@example.com" ] `, ` "log_type": "DATA_WRITE" `,
118
+ # ` "log_type": "ADMIN_READ" ` ] `, ` "service": "sampleservice.googleapis.com",
119
+ # "audit_log_configs": [ ` "log_type": "DATA_READ" `, ` "log_type": "DATA_WRITE"
120
+ # , "exempted_members": [ "user:aliya@example.com" ] ` ] ` ] ` For sampleservice,
121
+ # this policy enables DATA_READ, DATA_WRITE and ADMIN_READ logging. It also
122
+ # exempts jose@example.com from DATA_READ logging, and aliya@example.com from
123
+ # DATA_WRITE logging.
124
+ class AuditConfig
125
+ include Google::Apis::Core::Hashable
126
+
127
+ # The configuration for logging of each type of permission.
128
+ # Corresponds to the JSON property `auditLogConfigs`
129
+ # @return [Array<Google::Apis::CloudassetV1p4beta1::AuditLogConfig>]
130
+ attr_accessor :audit_log_configs
131
+
132
+ # Specifies a service that will be enabled for audit logging. For example, `
133
+ # storage.googleapis.com`, `cloudsql.googleapis.com`. `allServices` is a special
134
+ # value that covers all services.
135
+ # Corresponds to the JSON property `service`
136
+ # @return [String]
137
+ attr_accessor :service
138
+
139
+ def initialize(**args)
140
+ update!(**args)
141
+ end
142
+
143
+ # Update properties of this object
144
+ def update!(**args)
145
+ @audit_log_configs = args[:audit_log_configs] if args.key?(:audit_log_configs)
146
+ @service = args[:service] if args.key?(:service)
147
+ end
148
+ end
149
+
150
+ # Provides the configuration for logging a type of permissions. Example: ` "
151
+ # audit_log_configs": [ ` "log_type": "DATA_READ", "exempted_members": [ "user:
152
+ # jose@example.com" ] `, ` "log_type": "DATA_WRITE" ` ] ` This enables '
153
+ # DATA_READ' and 'DATA_WRITE' logging, while exempting jose@example.com from
154
+ # DATA_READ logging.
155
+ class AuditLogConfig
156
+ include Google::Apis::Core::Hashable
157
+
158
+ # Specifies the identities that do not cause logging for this type of permission.
159
+ # Follows the same format of Binding.members.
160
+ # Corresponds to the JSON property `exemptedMembers`
161
+ # @return [Array<String>]
162
+ attr_accessor :exempted_members
163
+
164
+ # The log type that this config enables.
165
+ # Corresponds to the JSON property `logType`
166
+ # @return [String]
167
+ attr_accessor :log_type
168
+
169
+ def initialize(**args)
170
+ update!(**args)
171
+ end
172
+
173
+ # Update properties of this object
174
+ def update!(**args)
175
+ @exempted_members = args[:exempted_members] if args.key?(:exempted_members)
176
+ @log_type = args[:log_type] if args.key?(:log_type)
177
+ end
178
+ end
179
+
96
180
  # Associates `members` with a `role`.
97
181
  class Binding
98
182
  include Google::Apis::Core::Hashable
@@ -492,27 +576,123 @@ module Google
492
576
  end
493
577
  end
494
578
 
495
- # An analysis message to group the query and results.
496
- class IamPolicyAnalysis
579
+ # An asset in Google Cloud. An asset can be any resource in the Google Cloud [
580
+ # resource hierarchy](https://cloud.google.com/resource-manager/docs/cloud-
581
+ # platform-resource-hierarchy), a resource outside the Google Cloud resource
582
+ # hierarchy (such as Google Kubernetes Engine clusters and objects), or a policy
583
+ # (e.g. Cloud IAM policy). See [Supported asset types](https://cloud.google.com/
584
+ # asset-inventory/docs/supported-asset-types) for more information.
585
+ class GoogleCloudAssetV1p7beta1Asset
497
586
  include Google::Apis::Core::Hashable
498
587
 
499
- # IAM policy analysis query message.
500
- # Corresponds to the JSON property `analysisQuery`
501
- # @return [Google::Apis::CloudassetV1p4beta1::IamPolicyAnalysisQuery]
502
- attr_accessor :analysis_query
588
+ # An `AccessLevel` is a label that can be applied to requests to Google Cloud
589
+ # services, along with a list of requirements necessary for the label to be
590
+ # applied.
591
+ # Corresponds to the JSON property `accessLevel`
592
+ # @return [Google::Apis::CloudassetV1p4beta1::GoogleIdentityAccesscontextmanagerV1AccessLevel]
593
+ attr_accessor :access_level
594
+
595
+ # `AccessPolicy` is a container for `AccessLevels` (which define the necessary
596
+ # attributes to use Google Cloud services) and `ServicePerimeters` (which define
597
+ # regions of services able to freely pass data within a perimeter). An access
598
+ # policy is globally visible within an organization, and the restrictions it
599
+ # specifies apply to all projects within an organization.
600
+ # Corresponds to the JSON property `accessPolicy`
601
+ # @return [Google::Apis::CloudassetV1p4beta1::GoogleIdentityAccesscontextmanagerV1AccessPolicy]
602
+ attr_accessor :access_policy
603
+
604
+ # The ancestry path of an asset in Google Cloud [resource hierarchy](https://
605
+ # cloud.google.com/resource-manager/docs/cloud-platform-resource-hierarchy),
606
+ # represented as a list of relative resource names. An ancestry path starts with
607
+ # the closest ancestor in the hierarchy and ends at root. If the asset is a
608
+ # project, folder, or organization, the ancestry path starts from the asset
609
+ # itself. Example: `["projects/123456789", "folders/5432", "organizations/1234"]`
610
+ # Corresponds to the JSON property `ancestors`
611
+ # @return [Array<String>]
612
+ attr_accessor :ancestors
503
613
 
504
- # A list of IamPolicyAnalysisResult that matches the analysis query, or empty if
505
- # no result is found.
506
- # Corresponds to the JSON property `analysisResults`
507
- # @return [Array<Google::Apis::CloudassetV1p4beta1::IamPolicyAnalysisResult>]
508
- attr_accessor :analysis_results
614
+ # The type of the asset. Example: `compute.googleapis.com/Disk` See [Supported
615
+ # asset types](https://cloud.google.com/asset-inventory/docs/supported-asset-
616
+ # types) for more information.
617
+ # Corresponds to the JSON property `assetType`
618
+ # @return [String]
619
+ attr_accessor :asset_type
620
+
621
+ # An Identity and Access Management (IAM) policy, which specifies access
622
+ # controls for Google Cloud resources. A `Policy` is a collection of `bindings`.
623
+ # A `binding` binds one or more `members` to a single `role`. Members can be
624
+ # user accounts, service accounts, Google groups, and domains (such as G Suite).
625
+ # A `role` is a named list of permissions; each `role` can be an IAM predefined
626
+ # role or a user-created custom role. For some types of Google Cloud resources,
627
+ # a `binding` can also specify a `condition`, which is a logical expression that
628
+ # allows access to a resource only if the expression evaluates to `true`. A
629
+ # condition can add constraints based on attributes of the request, the resource,
630
+ # or both. To learn which resources support conditions in their IAM policies,
631
+ # see the [IAM documentation](https://cloud.google.com/iam/help/conditions/
632
+ # resource-policies). **JSON example:** ` "bindings": [ ` "role": "roles/
633
+ # resourcemanager.organizationAdmin", "members": [ "user:mike@example.com", "
634
+ # group:admins@example.com", "domain:google.com", "serviceAccount:my-project-id@
635
+ # appspot.gserviceaccount.com" ] `, ` "role": "roles/resourcemanager.
636
+ # organizationViewer", "members": [ "user:eve@example.com" ], "condition": ` "
637
+ # title": "expirable access", "description": "Does not grant access after Sep
638
+ # 2020", "expression": "request.time < timestamp('2020-10-01T00:00:00.000Z')", `
639
+ # ` ], "etag": "BwWWja0YfJA=", "version": 3 ` **YAML example:** bindings: -
640
+ # members: - user:mike@example.com - group:admins@example.com - domain:google.
641
+ # com - serviceAccount:my-project-id@appspot.gserviceaccount.com role: roles/
642
+ # resourcemanager.organizationAdmin - members: - user:eve@example.com role:
643
+ # roles/resourcemanager.organizationViewer condition: title: expirable access
644
+ # description: Does not grant access after Sep 2020 expression: request.time <
645
+ # timestamp('2020-10-01T00:00:00.000Z') - etag: BwWWja0YfJA= - version: 3 For a
646
+ # description of IAM and its features, see the [IAM documentation](https://cloud.
647
+ # google.com/iam/docs/).
648
+ # Corresponds to the JSON property `iamPolicy`
649
+ # @return [Google::Apis::CloudassetV1p4beta1::Policy]
650
+ attr_accessor :iam_policy
651
+
652
+ # The full name of the asset. Example: `//compute.googleapis.com/projects/
653
+ # my_project_123/zones/zone1/instances/instance1` See [Resource names](https://
654
+ # cloud.google.com/apis/design/resource_names#full_resource_name) for more
655
+ # information.
656
+ # Corresponds to the JSON property `name`
657
+ # @return [String]
658
+ attr_accessor :name
509
659
 
510
- # Represents whether all entries in the analysis_results have been fully
511
- # explored to answer the query.
512
- # Corresponds to the JSON property `fullyExplored`
513
- # @return [Boolean]
514
- attr_accessor :fully_explored
515
- alias_method :fully_explored?, :fully_explored
660
+ # A representation of an [organization policy](https://cloud.google.com/resource-
661
+ # manager/docs/organization-policy/overview#organization_policy). There can be
662
+ # more than one organization policy with different constraints set on a given
663
+ # resource.
664
+ # Corresponds to the JSON property `orgPolicy`
665
+ # @return [Array<Google::Apis::CloudassetV1p4beta1::GoogleCloudOrgpolicyV1Policy>]
666
+ attr_accessor :org_policy
667
+
668
+ # The detailed related assets with the `relationship_type`.
669
+ # Corresponds to the JSON property `relatedAssets`
670
+ # @return [Google::Apis::CloudassetV1p4beta1::GoogleCloudAssetV1p7beta1RelatedAssets]
671
+ attr_accessor :related_assets
672
+
673
+ # A representation of a Google Cloud resource.
674
+ # Corresponds to the JSON property `resource`
675
+ # @return [Google::Apis::CloudassetV1p4beta1::GoogleCloudAssetV1p7beta1Resource]
676
+ attr_accessor :resource
677
+
678
+ # `ServicePerimeter` describes a set of Google Cloud resources which can freely
679
+ # import and export data amongst themselves, but not export outside of the `
680
+ # ServicePerimeter`. If a request with a source within this `ServicePerimeter`
681
+ # has a target outside of the `ServicePerimeter`, the request will be blocked.
682
+ # Otherwise the request is allowed. There are two types of Service Perimeter -
683
+ # Regular and Bridge. Regular Service Perimeters cannot overlap, a single Google
684
+ # Cloud project can only belong to a single regular Service Perimeter. Service
685
+ # Perimeter Bridges can contain only Google Cloud projects as members, a single
686
+ # Google Cloud project may belong to multiple Service Perimeter Bridges.
687
+ # Corresponds to the JSON property `servicePerimeter`
688
+ # @return [Google::Apis::CloudassetV1p4beta1::GoogleIdentityAccesscontextmanagerV1ServicePerimeter]
689
+ attr_accessor :service_perimeter
690
+
691
+ # The last update timestamp of an asset. update_time is updated when create/
692
+ # update/delete operation is performed.
693
+ # Corresponds to the JSON property `updateTime`
694
+ # @return [String]
695
+ attr_accessor :update_time
516
696
 
517
697
  def initialize(**args)
518
698
  update!(**args)
@@ -520,20 +700,53 @@ module Google
520
700
 
521
701
  # Update properties of this object
522
702
  def update!(**args)
523
- @analysis_query = args[:analysis_query] if args.key?(:analysis_query)
524
- @analysis_results = args[:analysis_results] if args.key?(:analysis_results)
525
- @fully_explored = args[:fully_explored] if args.key?(:fully_explored)
703
+ @access_level = args[:access_level] if args.key?(:access_level)
704
+ @access_policy = args[:access_policy] if args.key?(:access_policy)
705
+ @ancestors = args[:ancestors] if args.key?(:ancestors)
706
+ @asset_type = args[:asset_type] if args.key?(:asset_type)
707
+ @iam_policy = args[:iam_policy] if args.key?(:iam_policy)
708
+ @name = args[:name] if args.key?(:name)
709
+ @org_policy = args[:org_policy] if args.key?(:org_policy)
710
+ @related_assets = args[:related_assets] if args.key?(:related_assets)
711
+ @resource = args[:resource] if args.key?(:resource)
712
+ @service_perimeter = args[:service_perimeter] if args.key?(:service_perimeter)
713
+ @update_time = args[:update_time] if args.key?(:update_time)
526
714
  end
527
715
  end
528
716
 
529
- # Output configuration for export IAM policy analysis destination.
530
- class IamPolicyAnalysisOutputConfig
717
+ # An asset identify in Google Cloud which contains its name, type and ancestors.
718
+ # An asset can be any resource in the Google Cloud [resource hierarchy](https://
719
+ # cloud.google.com/resource-manager/docs/cloud-platform-resource-hierarchy), a
720
+ # resource outside the Google Cloud resource hierarchy (such as Google
721
+ # Kubernetes Engine clusters and objects), or a policy (e.g. Cloud IAM policy).
722
+ # See [Supported asset types](https://cloud.google.com/asset-inventory/docs/
723
+ # supported-asset-types) for more information.
724
+ class GoogleCloudAssetV1p7beta1RelatedAsset
531
725
  include Google::Apis::Core::Hashable
532
726
 
533
- # A Cloud Storage location.
534
- # Corresponds to the JSON property `gcsDestination`
535
- # @return [Google::Apis::CloudassetV1p4beta1::GcsDestination]
536
- attr_accessor :gcs_destination
727
+ # The ancestors of an asset in Google Cloud [resource hierarchy](https://cloud.
728
+ # google.com/resource-manager/docs/cloud-platform-resource-hierarchy),
729
+ # represented as a list of relative resource names. An ancestry path starts with
730
+ # the closest ancestor in the hierarchy and ends at root. Example: `["projects/
731
+ # 123456789", "folders/5432", "organizations/1234"]`
732
+ # Corresponds to the JSON property `ancestors`
733
+ # @return [Array<String>]
734
+ attr_accessor :ancestors
735
+
736
+ # The full name of the asset. Example: `//compute.googleapis.com/projects/
737
+ # my_project_123/zones/zone1/instances/instance1` See [Resource names](https://
738
+ # cloud.google.com/apis/design/resource_names#full_resource_name) for more
739
+ # information.
740
+ # Corresponds to the JSON property `asset`
741
+ # @return [String]
742
+ attr_accessor :asset
743
+
744
+ # The type of the asset. Example: `compute.googleapis.com/Disk` See [Supported
745
+ # asset types](https://cloud.google.com/asset-inventory/docs/supported-asset-
746
+ # types) for more information.
747
+ # Corresponds to the JSON property `assetType`
748
+ # @return [String]
749
+ attr_accessor :asset_type
537
750
 
538
751
  def initialize(**args)
539
752
  update!(**args)
@@ -541,49 +754,63 @@ module Google
541
754
 
542
755
  # Update properties of this object
543
756
  def update!(**args)
544
- @gcs_destination = args[:gcs_destination] if args.key?(:gcs_destination)
757
+ @ancestors = args[:ancestors] if args.key?(:ancestors)
758
+ @asset = args[:asset] if args.key?(:asset)
759
+ @asset_type = args[:asset_type] if args.key?(:asset_type)
545
760
  end
546
761
  end
547
762
 
548
- # IAM policy analysis query message.
549
- class IamPolicyAnalysisQuery
763
+ # The detailed related assets with the `relationship_type`.
764
+ class GoogleCloudAssetV1p7beta1RelatedAssets
550
765
  include Google::Apis::Core::Hashable
551
766
 
552
- # Specifies roles and/or permissions to analyze, to determine both the
553
- # identities possessing them and the resources they control. If multiple values
554
- # are specified, results will include identities and resources matching any of
555
- # them. The total number of roles and permissions should be equal or less than
556
- # 10.
557
- # Corresponds to the JSON property `accessSelector`
558
- # @return [Google::Apis::CloudassetV1p4beta1::AccessSelector]
559
- attr_accessor :access_selector
767
+ # The peer resources of the relationship.
768
+ # Corresponds to the JSON property `assets`
769
+ # @return [Array<Google::Apis::CloudassetV1p4beta1::GoogleCloudAssetV1p7beta1RelatedAsset>]
770
+ attr_accessor :assets
560
771
 
561
- # Specifies an identity for which to determine resource access, based on roles
562
- # assigned either directly to them or to the groups they belong to, directly or
563
- # indirectly.
564
- # Corresponds to the JSON property `identitySelector`
565
- # @return [Google::Apis::CloudassetV1p4beta1::IdentitySelector]
566
- attr_accessor :identity_selector
772
+ # The relationship attributes which include `type`, `source_resource_type`, `
773
+ # target_resource_type` and `action`.
774
+ # Corresponds to the JSON property `relationshipAttributes`
775
+ # @return [Google::Apis::CloudassetV1p4beta1::GoogleCloudAssetV1p7beta1RelationshipAttributes]
776
+ attr_accessor :relationship_attributes
567
777
 
568
- # Required. The relative name of the root asset. Only resources and IAM policies
569
- # within the parent will be analyzed. This can only be an organization number (
570
- # such as "organizations/123"), a folder number (such as "folders/123"), a
571
- # project ID (such as "projects/my-project-id"), or a project number (such as "
572
- # projects/12345"). To know how to get organization id, visit [here ](https://
573
- # cloud.google.com/resource-manager/docs/creating-managing-organization#
574
- # retrieving_your_organization_id). To know how to get folder or project id,
575
- # visit [here ](https://cloud.google.com/resource-manager/docs/creating-managing-
576
- # folders#viewing_or_listing_folders_and_projects).
577
- # Corresponds to the JSON property `parent`
778
+ def initialize(**args)
779
+ update!(**args)
780
+ end
781
+
782
+ # Update properties of this object
783
+ def update!(**args)
784
+ @assets = args[:assets] if args.key?(:assets)
785
+ @relationship_attributes = args[:relationship_attributes] if args.key?(:relationship_attributes)
786
+ end
787
+ end
788
+
789
+ # The relationship attributes which include `type`, `source_resource_type`, `
790
+ # target_resource_type` and `action`.
791
+ class GoogleCloudAssetV1p7beta1RelationshipAttributes
792
+ include Google::Apis::Core::Hashable
793
+
794
+ # The detail of the relationship, e.g. `contains`, `attaches`
795
+ # Corresponds to the JSON property `action`
578
796
  # @return [String]
579
- attr_accessor :parent
797
+ attr_accessor :action
580
798
 
581
- # Specifies the resource to analyze for access policies, which may be set
582
- # directly on the resource, or on ancestors such as organizations, folders or
583
- # projects.
584
- # Corresponds to the JSON property `resourceSelector`
585
- # @return [Google::Apis::CloudassetV1p4beta1::ResourceSelector]
586
- attr_accessor :resource_selector
799
+ # The source asset type. Example: `compute.googleapis.com/Instance`
800
+ # Corresponds to the JSON property `sourceResourceType`
801
+ # @return [String]
802
+ attr_accessor :source_resource_type
803
+
804
+ # The target asset type. Example: `compute.googleapis.com/Disk`
805
+ # Corresponds to the JSON property `targetResourceType`
806
+ # @return [String]
807
+ attr_accessor :target_resource_type
808
+
809
+ # The unique identifier of the relationship type. Example: `
810
+ # INSTANCE_TO_INSTANCEGROUP`
811
+ # Corresponds to the JSON property `type`
812
+ # @return [String]
813
+ attr_accessor :type
587
814
 
588
815
  def initialize(**args)
589
816
  update!(**args)
@@ -591,46 +818,67 @@ module Google
591
818
 
592
819
  # Update properties of this object
593
820
  def update!(**args)
594
- @access_selector = args[:access_selector] if args.key?(:access_selector)
595
- @identity_selector = args[:identity_selector] if args.key?(:identity_selector)
596
- @parent = args[:parent] if args.key?(:parent)
597
- @resource_selector = args[:resource_selector] if args.key?(:resource_selector)
821
+ @action = args[:action] if args.key?(:action)
822
+ @source_resource_type = args[:source_resource_type] if args.key?(:source_resource_type)
823
+ @target_resource_type = args[:target_resource_type] if args.key?(:target_resource_type)
824
+ @type = args[:type] if args.key?(:type)
598
825
  end
599
826
  end
600
827
 
601
- # IAM Policy analysis result, consisting of one IAM policy binding and derived
602
- # access control lists.
603
- class IamPolicyAnalysisResult
828
+ # A representation of a Google Cloud resource.
829
+ class GoogleCloudAssetV1p7beta1Resource
604
830
  include Google::Apis::Core::Hashable
605
831
 
606
- # The access control lists derived from the iam_binding that match or
607
- # potentially match resource and access selectors specified in the request.
608
- # Corresponds to the JSON property `accessControlLists`
609
- # @return [Array<Google::Apis::CloudassetV1p4beta1::GoogleCloudAssetV1p4beta1AccessControlList>]
610
- attr_accessor :access_control_lists
832
+ # The content of the resource, in which some sensitive fields are removed and
833
+ # may not be present.
834
+ # Corresponds to the JSON property `data`
835
+ # @return [Hash<String,Object>]
836
+ attr_accessor :data
611
837
 
612
- # The [full resource name](https://cloud.google.com/asset-inventory/docs/
613
- # resource-name-format) of the resource to which the iam_binding policy attaches.
614
- # Corresponds to the JSON property `attachedResourceFullName`
838
+ # The URL of the discovery document containing the resource's JSON schema.
839
+ # Example: `https://www.googleapis.com/discovery/v1/apis/compute/v1/rest` This
840
+ # value is unspecified for resources that do not have an API based on a
841
+ # discovery document, such as Cloud Bigtable.
842
+ # Corresponds to the JSON property `discoveryDocumentUri`
615
843
  # @return [String]
616
- attr_accessor :attached_resource_full_name
844
+ attr_accessor :discovery_document_uri
617
845
 
618
- # Represents whether all analyses on the iam_binding have successfully finished.
619
- # Corresponds to the JSON property `fullyExplored`
620
- # @return [Boolean]
621
- attr_accessor :fully_explored
622
- alias_method :fully_explored?, :fully_explored
846
+ # The JSON schema name listed in the discovery document. Example: `Project` This
847
+ # value is unspecified for resources that do not have an API based on a
848
+ # discovery document, such as Cloud Bigtable.
849
+ # Corresponds to the JSON property `discoveryName`
850
+ # @return [String]
851
+ attr_accessor :discovery_name
623
852
 
624
- # Associates `members` with a `role`.
625
- # Corresponds to the JSON property `iamBinding`
626
- # @return [Google::Apis::CloudassetV1p4beta1::Binding]
627
- attr_accessor :iam_binding
853
+ # The location of the resource in Google Cloud, such as its zone and region. For
854
+ # more information, see https://cloud.google.com/about/locations/.
855
+ # Corresponds to the JSON property `location`
856
+ # @return [String]
857
+ attr_accessor :location
628
858
 
629
- # The identity list derived from members of the iam_binding that match or
630
- # potentially match identity selector specified in the request.
631
- # Corresponds to the JSON property `identityList`
632
- # @return [Google::Apis::CloudassetV1p4beta1::GoogleCloudAssetV1p4beta1IdentityList]
633
- attr_accessor :identity_list
859
+ # The full name of the immediate parent of this resource. See [Resource Names](
860
+ # https://cloud.google.com/apis/design/resource_names#full_resource_name) for
861
+ # more information. For Google Cloud assets, this value is the parent resource
862
+ # defined in the [Cloud IAM policy hierarchy](https://cloud.google.com/iam/docs/
863
+ # overview#policy_hierarchy). Example: `//cloudresourcemanager.googleapis.com/
864
+ # projects/my_project_123` For third-party assets, this field may be set
865
+ # differently.
866
+ # Corresponds to the JSON property `parent`
867
+ # @return [String]
868
+ attr_accessor :parent
869
+
870
+ # The REST URL for accessing the resource. An HTTP `GET` request using this URL
871
+ # returns the resource itself. Example: `https://cloudresourcemanager.googleapis.
872
+ # com/v1/projects/my-project-123` This value is unspecified for resources
873
+ # without a REST API.
874
+ # Corresponds to the JSON property `resourceUrl`
875
+ # @return [String]
876
+ attr_accessor :resource_url
877
+
878
+ # The API version. Example: `v1`
879
+ # Corresponds to the JSON property `version`
880
+ # @return [String]
881
+ attr_accessor :version
634
882
 
635
883
  def initialize(**args)
636
884
  update!(**args)
@@ -638,29 +886,48 @@ module Google
638
886
 
639
887
  # Update properties of this object
640
888
  def update!(**args)
641
- @access_control_lists = args[:access_control_lists] if args.key?(:access_control_lists)
642
- @attached_resource_full_name = args[:attached_resource_full_name] if args.key?(:attached_resource_full_name)
643
- @fully_explored = args[:fully_explored] if args.key?(:fully_explored)
644
- @iam_binding = args[:iam_binding] if args.key?(:iam_binding)
645
- @identity_list = args[:identity_list] if args.key?(:identity_list)
889
+ @data = args[:data] if args.key?(:data)
890
+ @discovery_document_uri = args[:discovery_document_uri] if args.key?(:discovery_document_uri)
891
+ @discovery_name = args[:discovery_name] if args.key?(:discovery_name)
892
+ @location = args[:location] if args.key?(:location)
893
+ @parent = args[:parent] if args.key?(:parent)
894
+ @resource_url = args[:resource_url] if args.key?(:resource_url)
895
+ @version = args[:version] if args.key?(:version)
646
896
  end
647
897
  end
648
898
 
649
- # Specifies an identity for which to determine resource access, based on roles
650
- # assigned either directly to them or to the groups they belong to, directly or
651
- # indirectly.
652
- class IdentitySelector
899
+ # Used in `policy_type` to specify how `boolean_policy` will behave at this
900
+ # resource.
901
+ class GoogleCloudOrgpolicyV1BooleanPolicy
653
902
  include Google::Apis::Core::Hashable
654
903
 
655
- # Required. The identity appear in the form of members in [IAM policy binding](
656
- # https://cloud.google.com/iam/reference/rest/v1/Binding). The examples of
657
- # supported forms are: "user:mike@example.com", "group:admins@example.com", "
658
- # domain:google.com", "serviceAccount:my-project-id@appspot.gserviceaccount.com".
659
- # Notice that wildcard characters (such as * and ?) are not supported. You must
660
- # give a specific identity.
661
- # Corresponds to the JSON property `identity`
662
- # @return [String]
663
- attr_accessor :identity
904
+ # If `true`, then the `Policy` is enforced. If `false`, then any configuration
905
+ # is acceptable. Suppose you have a `Constraint` `constraints/compute.
906
+ # disableSerialPortAccess` with `constraint_default` set to `ALLOW`. A `Policy`
907
+ # for that `Constraint` exhibits the following behavior: - If the `Policy` at
908
+ # this resource has enforced set to `false`, serial port connection attempts
909
+ # will be allowed. - If the `Policy` at this resource has enforced set to `true`,
910
+ # serial port connection attempts will be refused. - If the `Policy` at this
911
+ # resource is `RestoreDefault`, serial port connection attempts will be allowed.
912
+ # - If no `Policy` is set at this resource or anywhere higher in the resource
913
+ # hierarchy, serial port connection attempts will be allowed. - If no `Policy`
914
+ # is set at this resource, but one exists higher in the resource hierarchy, the
915
+ # behavior is as if the`Policy` were set at this resource. The following
916
+ # examples demonstrate the different possible layerings: Example 1 (nearest `
917
+ # Constraint` wins): `organizations/foo` has a `Policy` with: `enforced: false` `
918
+ # projects/bar` has no `Policy` set. The constraint at `projects/bar` and `
919
+ # organizations/foo` will not be enforced. Example 2 (enforcement gets replaced):
920
+ # `organizations/foo` has a `Policy` with: `enforced: false` `projects/bar` has
921
+ # a `Policy` with: `enforced: true` The constraint at `organizations/foo` is not
922
+ # enforced. The constraint at `projects/bar` is enforced. Example 3 (
923
+ # RestoreDefault): `organizations/foo` has a `Policy` with: `enforced: true` `
924
+ # projects/bar` has a `Policy` with: `RestoreDefault: ``` The constraint at `
925
+ # organizations/foo` is enforced. The constraint at `projects/bar` is not
926
+ # enforced, because `constraint_default` for the `Constraint` is `ALLOW`.
927
+ # Corresponds to the JSON property `enforced`
928
+ # @return [Boolean]
929
+ attr_accessor :enforced
930
+ alias_method :enforced?, :enforced
664
931
 
665
932
  def initialize(**args)
666
933
  update!(**args)
@@ -668,57 +935,207 @@ module Google
668
935
 
669
936
  # Update properties of this object
670
937
  def update!(**args)
671
- @identity = args[:identity] if args.key?(:identity)
938
+ @enforced = args[:enforced] if args.key?(:enforced)
672
939
  end
673
940
  end
674
941
 
675
- # This resource represents a long-running operation that is the result of a
676
- # network API call.
677
- class Operation
942
+ # Used in `policy_type` to specify how `list_policy` behaves at this resource. `
943
+ # ListPolicy` can define specific values and subtrees of Cloud Resource Manager
944
+ # resource hierarchy (`Organizations`, `Folders`, `Projects`) that are allowed
945
+ # or denied by setting the `allowed_values` and `denied_values` fields. This is
946
+ # achieved by using the `under:` and optional `is:` prefixes. The `under:`
947
+ # prefix is used to denote resource subtree values. The `is:` prefix is used to
948
+ # denote specific values, and is required only if the value contains a ":".
949
+ # Values prefixed with "is:" are treated the same as values with no prefix.
950
+ # Ancestry subtrees must be in one of the following formats: - "projects/", e.g.
951
+ # "projects/tokyo-rain-123" - "folders/", e.g. "folders/1234" - "organizations/",
952
+ # e.g. "organizations/1234" The `supports_under` field of the associated `
953
+ # Constraint` defines whether ancestry prefixes can be used. You can set `
954
+ # allowed_values` and `denied_values` in the same `Policy` if `all_values` is `
955
+ # ALL_VALUES_UNSPECIFIED`. `ALLOW` or `DENY` are used to allow or deny all
956
+ # values. If `all_values` is set to either `ALLOW` or `DENY`, `allowed_values`
957
+ # and `denied_values` must be unset.
958
+ class GoogleCloudOrgpolicyV1ListPolicy
678
959
  include Google::Apis::Core::Hashable
679
960
 
680
- # If the value is `false`, it means the operation is still in progress. If `true`
681
- # , the operation is completed, and either `error` or `response` is available.
682
- # Corresponds to the JSON property `done`
961
+ # The policy all_values state.
962
+ # Corresponds to the JSON property `allValues`
963
+ # @return [String]
964
+ attr_accessor :all_values
965
+
966
+ # List of values allowed at this resource. Can only be set if `all_values` is
967
+ # set to `ALL_VALUES_UNSPECIFIED`.
968
+ # Corresponds to the JSON property `allowedValues`
969
+ # @return [Array<String>]
970
+ attr_accessor :allowed_values
971
+
972
+ # List of values denied at this resource. Can only be set if `all_values` is set
973
+ # to `ALL_VALUES_UNSPECIFIED`.
974
+ # Corresponds to the JSON property `deniedValues`
975
+ # @return [Array<String>]
976
+ attr_accessor :denied_values
977
+
978
+ # Determines the inheritance behavior for this `Policy`. By default, a `
979
+ # ListPolicy` set at a resource supersedes any `Policy` set anywhere up the
980
+ # resource hierarchy. However, if `inherit_from_parent` is set to `true`, then
981
+ # the values from the effective `Policy` of the parent resource are inherited,
982
+ # meaning the values set in this `Policy` are added to the values inherited up
983
+ # the hierarchy. Setting `Policy` hierarchies that inherit both allowed values
984
+ # and denied values isn't recommended in most circumstances to keep the
985
+ # configuration simple and understandable. However, it is possible to set a `
986
+ # Policy` with `allowed_values` set that inherits a `Policy` with `denied_values`
987
+ # set. In this case, the values that are allowed must be in `allowed_values`
988
+ # and not present in `denied_values`. For example, suppose you have a `
989
+ # Constraint` `constraints/serviceuser.services`, which has a `constraint_type`
990
+ # of `list_constraint`, and with `constraint_default` set to `ALLOW`. Suppose
991
+ # that at the Organization level, a `Policy` is applied that restricts the
992
+ # allowed API activations to ``E1`, `E2``. Then, if a `Policy` is applied to a
993
+ # project below the Organization that has `inherit_from_parent` set to `false`
994
+ # and field all_values set to DENY, then an attempt to activate any API will be
995
+ # denied. The following examples demonstrate different possible layerings for `
996
+ # projects/bar` parented by `organizations/foo`: Example 1 (no inherited values):
997
+ # `organizations/foo` has a `Policy` with values: `allowed_values: "E1"
998
+ # allowed_values:"E2"` `projects/bar` has `inherit_from_parent` `false` and
999
+ # values: `allowed_values: "E3" allowed_values: "E4"` The accepted values at `
1000
+ # organizations/foo` are `E1`, `E2`. The accepted values at `projects/bar` are `
1001
+ # E3`, and `E4`. Example 2 (inherited values): `organizations/foo` has a `Policy`
1002
+ # with values: `allowed_values: "E1" allowed_values:"E2"` `projects/bar` has a `
1003
+ # Policy` with values: `value: "E3" value: "E4" inherit_from_parent: true` The
1004
+ # accepted values at `organizations/foo` are `E1`, `E2`. The accepted values at `
1005
+ # projects/bar` are `E1`, `E2`, `E3`, and `E4`. Example 3 (inheriting both
1006
+ # allowed and denied values): `organizations/foo` has a `Policy` with values: `
1007
+ # allowed_values: "E1" allowed_values: "E2"` `projects/bar` has a `Policy` with:
1008
+ # `denied_values: "E1"` The accepted values at `organizations/foo` are `E1`, `E2`
1009
+ # . The value accepted at `projects/bar` is `E2`. Example 4 (RestoreDefault): `
1010
+ # organizations/foo` has a `Policy` with values: `allowed_values: "E1"
1011
+ # allowed_values:"E2"` `projects/bar` has a `Policy` with values: `
1012
+ # RestoreDefault: ``` The accepted values at `organizations/foo` are `E1`, `E2`.
1013
+ # The accepted values at `projects/bar` are either all or none depending on the
1014
+ # value of `constraint_default` (if `ALLOW`, all; if `DENY`, none). Example 5 (
1015
+ # no policy inherits parent policy): `organizations/foo` has no `Policy` set. `
1016
+ # projects/bar` has no `Policy` set. The accepted values at both levels are
1017
+ # either all or none depending on the value of `constraint_default` (if `ALLOW`,
1018
+ # all; if `DENY`, none). Example 6 (ListConstraint allowing all): `organizations/
1019
+ # foo` has a `Policy` with values: `allowed_values: "E1" allowed_values: "E2"` `
1020
+ # projects/bar` has a `Policy` with: `all: ALLOW` The accepted values at `
1021
+ # organizations/foo` are `E1`, E2`. Any value is accepted at `projects/bar`.
1022
+ # Example 7 (ListConstraint allowing none): `organizations/foo` has a `Policy`
1023
+ # with values: `allowed_values: "E1" allowed_values: "E2"` `projects/bar` has a `
1024
+ # Policy` with: `all: DENY` The accepted values at `organizations/foo` are `E1`,
1025
+ # E2`. No value is accepted at `projects/bar`. Example 10 (allowed and denied
1026
+ # subtrees of Resource Manager hierarchy): Given the following resource
1027
+ # hierarchy O1->`F1, F2`; F1->`P1`; F2->`P2, P3`, `organizations/foo` has a `
1028
+ # Policy` with values: `allowed_values: "under:organizations/O1"` `projects/bar`
1029
+ # has a `Policy` with: `allowed_values: "under:projects/P3"` `denied_values: "
1030
+ # under:folders/F2"` The accepted values at `organizations/foo` are `
1031
+ # organizations/O1`, `folders/F1`, `folders/F2`, `projects/P1`, `projects/P2`, `
1032
+ # projects/P3`. The accepted values at `projects/bar` are `organizations/O1`, `
1033
+ # folders/F1`, `projects/P1`.
1034
+ # Corresponds to the JSON property `inheritFromParent`
683
1035
  # @return [Boolean]
684
- attr_accessor :done
685
- alias_method :done?, :done
1036
+ attr_accessor :inherit_from_parent
1037
+ alias_method :inherit_from_parent?, :inherit_from_parent
1038
+
1039
+ # Optional. The Google Cloud Console will try to default to a configuration that
1040
+ # matches the value specified in this `Policy`. If `suggested_value` is not set,
1041
+ # it will inherit the value specified higher in the hierarchy, unless `
1042
+ # inherit_from_parent` is `false`.
1043
+ # Corresponds to the JSON property `suggestedValue`
1044
+ # @return [String]
1045
+ attr_accessor :suggested_value
686
1046
 
687
- # The `Status` type defines a logical error model that is suitable for different
688
- # programming environments, including REST APIs and RPC APIs. It is used by [
689
- # gRPC](https://github.com/grpc). Each `Status` message contains three pieces of
690
- # data: error code, error message, and error details. You can find out more
691
- # about this error model and how to work with it in the [API Design Guide](https:
692
- # //cloud.google.com/apis/design/errors).
693
- # Corresponds to the JSON property `error`
694
- # @return [Google::Apis::CloudassetV1p4beta1::Status]
695
- attr_accessor :error
1047
+ def initialize(**args)
1048
+ update!(**args)
1049
+ end
696
1050
 
697
- # Service-specific metadata associated with the operation. It typically contains
698
- # progress information and common metadata such as create time. Some services
699
- # might not provide such metadata. Any method that returns a long-running
700
- # operation should document the metadata type, if any.
701
- # Corresponds to the JSON property `metadata`
702
- # @return [Hash<String,Object>]
703
- attr_accessor :metadata
1051
+ # Update properties of this object
1052
+ def update!(**args)
1053
+ @all_values = args[:all_values] if args.key?(:all_values)
1054
+ @allowed_values = args[:allowed_values] if args.key?(:allowed_values)
1055
+ @denied_values = args[:denied_values] if args.key?(:denied_values)
1056
+ @inherit_from_parent = args[:inherit_from_parent] if args.key?(:inherit_from_parent)
1057
+ @suggested_value = args[:suggested_value] if args.key?(:suggested_value)
1058
+ end
1059
+ end
704
1060
 
705
- # The server-assigned name, which is only unique within the same service that
706
- # originally returns it. If you use the default HTTP mapping, the `name` should
707
- # be a resource name ending with `operations/`unique_id``.
708
- # Corresponds to the JSON property `name`
1061
+ # Defines a Cloud Organization `Policy` which is used to specify `Constraints`
1062
+ # for configurations of Cloud Platform resources.
1063
+ class GoogleCloudOrgpolicyV1Policy
1064
+ include Google::Apis::Core::Hashable
1065
+
1066
+ # Used in `policy_type` to specify how `boolean_policy` will behave at this
1067
+ # resource.
1068
+ # Corresponds to the JSON property `booleanPolicy`
1069
+ # @return [Google::Apis::CloudassetV1p4beta1::GoogleCloudOrgpolicyV1BooleanPolicy]
1070
+ attr_accessor :boolean_policy
1071
+
1072
+ # The name of the `Constraint` the `Policy` is configuring, for example, `
1073
+ # constraints/serviceuser.services`. A [list of available constraints](/resource-
1074
+ # manager/docs/organization-policy/org-policy-constraints) is available.
1075
+ # Immutable after creation.
1076
+ # Corresponds to the JSON property `constraint`
709
1077
  # @return [String]
710
- attr_accessor :name
1078
+ attr_accessor :constraint
1079
+
1080
+ # An opaque tag indicating the current version of the `Policy`, used for
1081
+ # concurrency control. When the `Policy` is returned from either a `GetPolicy`
1082
+ # or a `ListOrgPolicy` request, this `etag` indicates the version of the current
1083
+ # `Policy` to use when executing a read-modify-write loop. When the `Policy` is
1084
+ # returned from a `GetEffectivePolicy` request, the `etag` will be unset. When
1085
+ # the `Policy` is used in a `SetOrgPolicy` method, use the `etag` value that was
1086
+ # returned from a `GetOrgPolicy` request as part of a read-modify-write loop for
1087
+ # concurrency control. Not setting the `etag`in a `SetOrgPolicy` request will
1088
+ # result in an unconditional write of the `Policy`.
1089
+ # Corresponds to the JSON property `etag`
1090
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
1091
+ # @return [String]
1092
+ attr_accessor :etag
1093
+
1094
+ # Used in `policy_type` to specify how `list_policy` behaves at this resource. `
1095
+ # ListPolicy` can define specific values and subtrees of Cloud Resource Manager
1096
+ # resource hierarchy (`Organizations`, `Folders`, `Projects`) that are allowed
1097
+ # or denied by setting the `allowed_values` and `denied_values` fields. This is
1098
+ # achieved by using the `under:` and optional `is:` prefixes. The `under:`
1099
+ # prefix is used to denote resource subtree values. The `is:` prefix is used to
1100
+ # denote specific values, and is required only if the value contains a ":".
1101
+ # Values prefixed with "is:" are treated the same as values with no prefix.
1102
+ # Ancestry subtrees must be in one of the following formats: - "projects/", e.g.
1103
+ # "projects/tokyo-rain-123" - "folders/", e.g. "folders/1234" - "organizations/",
1104
+ # e.g. "organizations/1234" The `supports_under` field of the associated `
1105
+ # Constraint` defines whether ancestry prefixes can be used. You can set `
1106
+ # allowed_values` and `denied_values` in the same `Policy` if `all_values` is `
1107
+ # ALL_VALUES_UNSPECIFIED`. `ALLOW` or `DENY` are used to allow or deny all
1108
+ # values. If `all_values` is set to either `ALLOW` or `DENY`, `allowed_values`
1109
+ # and `denied_values` must be unset.
1110
+ # Corresponds to the JSON property `listPolicy`
1111
+ # @return [Google::Apis::CloudassetV1p4beta1::GoogleCloudOrgpolicyV1ListPolicy]
1112
+ attr_accessor :list_policy
1113
+
1114
+ # Ignores policies set above this resource and restores the `constraint_default`
1115
+ # enforcement behavior of the specific `Constraint` at this resource. Suppose
1116
+ # that `constraint_default` is set to `ALLOW` for the `Constraint` `constraints/
1117
+ # serviceuser.services`. Suppose that organization foo.com sets a `Policy` at
1118
+ # their Organization resource node that restricts the allowed service
1119
+ # activations to deny all service activations. They could then set a `Policy`
1120
+ # with the `policy_type` `restore_default` on several experimental projects,
1121
+ # restoring the `constraint_default` enforcement of the `Constraint` for only
1122
+ # those projects, allowing those projects to have all services activated.
1123
+ # Corresponds to the JSON property `restoreDefault`
1124
+ # @return [Google::Apis::CloudassetV1p4beta1::GoogleCloudOrgpolicyV1RestoreDefault]
1125
+ attr_accessor :restore_default
1126
+
1127
+ # The time stamp the `Policy` was previously updated. This is set by the server,
1128
+ # not specified by the caller, and represents the last time a call to `
1129
+ # SetOrgPolicy` was made for that `Policy`. Any value set by the client will be
1130
+ # ignored.
1131
+ # Corresponds to the JSON property `updateTime`
1132
+ # @return [String]
1133
+ attr_accessor :update_time
711
1134
 
712
- # The normal response of the operation in case of success. If the original
713
- # method returns no data on success, such as `Delete`, the response is `google.
714
- # protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`,
715
- # the response should be the resource. For other methods, the response should
716
- # have the type `XxxResponse`, where `Xxx` is the original method name. For
717
- # example, if the original method name is `TakeSnapshot()`, the inferred
718
- # response type is `TakeSnapshotResponse`.
719
- # Corresponds to the JSON property `response`
720
- # @return [Hash<String,Object>]
721
- attr_accessor :response
1135
+ # Version of the `Policy`. Default version is 0;
1136
+ # Corresponds to the JSON property `version`
1137
+ # @return [Fixnum]
1138
+ attr_accessor :version
722
1139
 
723
1140
  def initialize(**args)
724
1141
  update!(**args)
@@ -726,16 +1143,1107 @@ module Google
726
1143
 
727
1144
  # Update properties of this object
728
1145
  def update!(**args)
729
- @done = args[:done] if args.key?(:done)
730
- @error = args[:error] if args.key?(:error)
731
- @metadata = args[:metadata] if args.key?(:metadata)
732
- @name = args[:name] if args.key?(:name)
733
- @response = args[:response] if args.key?(:response)
1146
+ @boolean_policy = args[:boolean_policy] if args.key?(:boolean_policy)
1147
+ @constraint = args[:constraint] if args.key?(:constraint)
1148
+ @etag = args[:etag] if args.key?(:etag)
1149
+ @list_policy = args[:list_policy] if args.key?(:list_policy)
1150
+ @restore_default = args[:restore_default] if args.key?(:restore_default)
1151
+ @update_time = args[:update_time] if args.key?(:update_time)
1152
+ @version = args[:version] if args.key?(:version)
734
1153
  end
735
1154
  end
736
1155
 
737
- # Contains request options.
738
- class Options
1156
+ # Ignores policies set above this resource and restores the `constraint_default`
1157
+ # enforcement behavior of the specific `Constraint` at this resource. Suppose
1158
+ # that `constraint_default` is set to `ALLOW` for the `Constraint` `constraints/
1159
+ # serviceuser.services`. Suppose that organization foo.com sets a `Policy` at
1160
+ # their Organization resource node that restricts the allowed service
1161
+ # activations to deny all service activations. They could then set a `Policy`
1162
+ # with the `policy_type` `restore_default` on several experimental projects,
1163
+ # restoring the `constraint_default` enforcement of the `Constraint` for only
1164
+ # those projects, allowing those projects to have all services activated.
1165
+ class GoogleCloudOrgpolicyV1RestoreDefault
1166
+ include Google::Apis::Core::Hashable
1167
+
1168
+ def initialize(**args)
1169
+ update!(**args)
1170
+ end
1171
+
1172
+ # Update properties of this object
1173
+ def update!(**args)
1174
+ end
1175
+ end
1176
+
1177
+ # An `AccessLevel` is a label that can be applied to requests to Google Cloud
1178
+ # services, along with a list of requirements necessary for the label to be
1179
+ # applied.
1180
+ class GoogleIdentityAccesscontextmanagerV1AccessLevel
1181
+ include Google::Apis::Core::Hashable
1182
+
1183
+ # `BasicLevel` is an `AccessLevel` using a set of recommended features.
1184
+ # Corresponds to the JSON property `basic`
1185
+ # @return [Google::Apis::CloudassetV1p4beta1::GoogleIdentityAccesscontextmanagerV1BasicLevel]
1186
+ attr_accessor :basic
1187
+
1188
+ # `CustomLevel` is an `AccessLevel` using the Cloud Common Expression Language
1189
+ # to represent the necessary conditions for the level to apply to a request. See
1190
+ # CEL spec at: https://github.com/google/cel-spec
1191
+ # Corresponds to the JSON property `custom`
1192
+ # @return [Google::Apis::CloudassetV1p4beta1::GoogleIdentityAccesscontextmanagerV1CustomLevel]
1193
+ attr_accessor :custom
1194
+
1195
+ # Description of the `AccessLevel` and its use. Does not affect behavior.
1196
+ # Corresponds to the JSON property `description`
1197
+ # @return [String]
1198
+ attr_accessor :description
1199
+
1200
+ # Required. Resource name for the Access Level. The `short_name` component must
1201
+ # begin with a letter and only include alphanumeric and '_'. Format: `
1202
+ # accessPolicies/`policy_id`/accessLevels/`short_name``. The maximum length of
1203
+ # the `short_name` component is 50 characters.
1204
+ # Corresponds to the JSON property `name`
1205
+ # @return [String]
1206
+ attr_accessor :name
1207
+
1208
+ # Human readable title. Must be unique within the Policy.
1209
+ # Corresponds to the JSON property `title`
1210
+ # @return [String]
1211
+ attr_accessor :title
1212
+
1213
+ def initialize(**args)
1214
+ update!(**args)
1215
+ end
1216
+
1217
+ # Update properties of this object
1218
+ def update!(**args)
1219
+ @basic = args[:basic] if args.key?(:basic)
1220
+ @custom = args[:custom] if args.key?(:custom)
1221
+ @description = args[:description] if args.key?(:description)
1222
+ @name = args[:name] if args.key?(:name)
1223
+ @title = args[:title] if args.key?(:title)
1224
+ end
1225
+ end
1226
+
1227
+ # `AccessPolicy` is a container for `AccessLevels` (which define the necessary
1228
+ # attributes to use Google Cloud services) and `ServicePerimeters` (which define
1229
+ # regions of services able to freely pass data within a perimeter). An access
1230
+ # policy is globally visible within an organization, and the restrictions it
1231
+ # specifies apply to all projects within an organization.
1232
+ class GoogleIdentityAccesscontextmanagerV1AccessPolicy
1233
+ include Google::Apis::Core::Hashable
1234
+
1235
+ # Output only. An opaque identifier for the current version of the `AccessPolicy`
1236
+ # . This will always be a strongly validated etag, meaning that two Access
1237
+ # Polices will be identical if and only if their etags are identical. Clients
1238
+ # should not expect this to be in any specific format.
1239
+ # Corresponds to the JSON property `etag`
1240
+ # @return [String]
1241
+ attr_accessor :etag
1242
+
1243
+ # Output only. Resource name of the `AccessPolicy`. Format: `accessPolicies/`
1244
+ # policy_id``
1245
+ # Corresponds to the JSON property `name`
1246
+ # @return [String]
1247
+ attr_accessor :name
1248
+
1249
+ # Required. The parent of this `AccessPolicy` in the Cloud Resource Hierarchy.
1250
+ # Currently immutable once created. Format: `organizations/`organization_id``
1251
+ # Corresponds to the JSON property `parent`
1252
+ # @return [String]
1253
+ attr_accessor :parent
1254
+
1255
+ # Required. Human readable title. Does not affect behavior.
1256
+ # Corresponds to the JSON property `title`
1257
+ # @return [String]
1258
+ attr_accessor :title
1259
+
1260
+ def initialize(**args)
1261
+ update!(**args)
1262
+ end
1263
+
1264
+ # Update properties of this object
1265
+ def update!(**args)
1266
+ @etag = args[:etag] if args.key?(:etag)
1267
+ @name = args[:name] if args.key?(:name)
1268
+ @parent = args[:parent] if args.key?(:parent)
1269
+ @title = args[:title] if args.key?(:title)
1270
+ end
1271
+ end
1272
+
1273
+ # Identification for an API Operation.
1274
+ class GoogleIdentityAccesscontextmanagerV1ApiOperation
1275
+ include Google::Apis::Core::Hashable
1276
+
1277
+ # API methods or permissions to allow. Method or permission must belong to the
1278
+ # service specified by `service_name` field. A single MethodSelector entry with `
1279
+ # *` specified for the `method` field will allow all methods AND permissions for
1280
+ # the service specified in `service_name`.
1281
+ # Corresponds to the JSON property `methodSelectors`
1282
+ # @return [Array<Google::Apis::CloudassetV1p4beta1::GoogleIdentityAccesscontextmanagerV1MethodSelector>]
1283
+ attr_accessor :method_selectors
1284
+
1285
+ # The name of the API whose methods or permissions the IngressPolicy or
1286
+ # EgressPolicy want to allow. A single ApiOperation with `service_name` field
1287
+ # set to `*` will allow all methods AND permissions for all services.
1288
+ # Corresponds to the JSON property `serviceName`
1289
+ # @return [String]
1290
+ attr_accessor :service_name
1291
+
1292
+ def initialize(**args)
1293
+ update!(**args)
1294
+ end
1295
+
1296
+ # Update properties of this object
1297
+ def update!(**args)
1298
+ @method_selectors = args[:method_selectors] if args.key?(:method_selectors)
1299
+ @service_name = args[:service_name] if args.key?(:service_name)
1300
+ end
1301
+ end
1302
+
1303
+ # `BasicLevel` is an `AccessLevel` using a set of recommended features.
1304
+ class GoogleIdentityAccesscontextmanagerV1BasicLevel
1305
+ include Google::Apis::Core::Hashable
1306
+
1307
+ # How the `conditions` list should be combined to determine if a request is
1308
+ # granted this `AccessLevel`. If AND is used, each `Condition` in `conditions`
1309
+ # must be satisfied for the `AccessLevel` to be applied. If OR is used, at least
1310
+ # one `Condition` in `conditions` must be satisfied for the `AccessLevel` to be
1311
+ # applied. Default behavior is AND.
1312
+ # Corresponds to the JSON property `combiningFunction`
1313
+ # @return [String]
1314
+ attr_accessor :combining_function
1315
+
1316
+ # Required. A list of requirements for the `AccessLevel` to be granted.
1317
+ # Corresponds to the JSON property `conditions`
1318
+ # @return [Array<Google::Apis::CloudassetV1p4beta1::GoogleIdentityAccesscontextmanagerV1Condition>]
1319
+ attr_accessor :conditions
1320
+
1321
+ def initialize(**args)
1322
+ update!(**args)
1323
+ end
1324
+
1325
+ # Update properties of this object
1326
+ def update!(**args)
1327
+ @combining_function = args[:combining_function] if args.key?(:combining_function)
1328
+ @conditions = args[:conditions] if args.key?(:conditions)
1329
+ end
1330
+ end
1331
+
1332
+ # A condition necessary for an `AccessLevel` to be granted. The Condition is an
1333
+ # AND over its fields. So a Condition is true if: 1) the request IP is from one
1334
+ # of the listed subnetworks AND 2) the originating device complies with the
1335
+ # listed device policy AND 3) all listed access levels are granted AND 4) the
1336
+ # request was sent at a time allowed by the DateTimeRestriction.
1337
+ class GoogleIdentityAccesscontextmanagerV1Condition
1338
+ include Google::Apis::Core::Hashable
1339
+
1340
+ # `DevicePolicy` specifies device specific restrictions necessary to acquire a
1341
+ # given access level. A `DevicePolicy` specifies requirements for requests from
1342
+ # devices to be granted access levels, it does not do any enforcement on the
1343
+ # device. `DevicePolicy` acts as an AND over all specified fields, and each
1344
+ # repeated field is an OR over its elements. Any unset fields are ignored. For
1345
+ # example, if the proto is ` os_type : DESKTOP_WINDOWS, os_type : DESKTOP_LINUX,
1346
+ # encryption_status: ENCRYPTED`, then the DevicePolicy will be true for requests
1347
+ # originating from encrypted Linux desktops and encrypted Windows desktops.
1348
+ # Corresponds to the JSON property `devicePolicy`
1349
+ # @return [Google::Apis::CloudassetV1p4beta1::GoogleIdentityAccesscontextmanagerV1DevicePolicy]
1350
+ attr_accessor :device_policy
1351
+
1352
+ # CIDR block IP subnetwork specification. May be IPv4 or IPv6. Note that for a
1353
+ # CIDR IP address block, the specified IP address portion must be properly
1354
+ # truncated (i.e. all the host bits must be zero) or the input is considered
1355
+ # malformed. For example, "192.0.2.0/24" is accepted but "192.0.2.1/24" is not.
1356
+ # Similarly, for IPv6, "2001:db8::/32" is accepted whereas "2001:db8::1/32" is
1357
+ # not. The originating IP of a request must be in one of the listed subnets in
1358
+ # order for this Condition to be true. If empty, all IP addresses are allowed.
1359
+ # Corresponds to the JSON property `ipSubnetworks`
1360
+ # @return [Array<String>]
1361
+ attr_accessor :ip_subnetworks
1362
+
1363
+ # The request must be made by one of the provided user or service accounts.
1364
+ # Groups are not supported. Syntax: `user:`emailid`` `serviceAccount:`emailid``
1365
+ # If not specified, a request may come from any user.
1366
+ # Corresponds to the JSON property `members`
1367
+ # @return [Array<String>]
1368
+ attr_accessor :members
1369
+
1370
+ # Whether to negate the Condition. If true, the Condition becomes a NAND over
1371
+ # its non-empty fields, each field must be false for the Condition overall to be
1372
+ # satisfied. Defaults to false.
1373
+ # Corresponds to the JSON property `negate`
1374
+ # @return [Boolean]
1375
+ attr_accessor :negate
1376
+ alias_method :negate?, :negate
1377
+
1378
+ # The request must originate from one of the provided countries/regions. Must be
1379
+ # valid ISO 3166-1 alpha-2 codes.
1380
+ # Corresponds to the JSON property `regions`
1381
+ # @return [Array<String>]
1382
+ attr_accessor :regions
1383
+
1384
+ # A list of other access levels defined in the same `Policy`, referenced by
1385
+ # resource name. Referencing an `AccessLevel` which does not exist is an error.
1386
+ # All access levels listed must be granted for the Condition to be true. Example:
1387
+ # "`accessPolicies/MY_POLICY/accessLevels/LEVEL_NAME"`
1388
+ # Corresponds to the JSON property `requiredAccessLevels`
1389
+ # @return [Array<String>]
1390
+ attr_accessor :required_access_levels
1391
+
1392
+ def initialize(**args)
1393
+ update!(**args)
1394
+ end
1395
+
1396
+ # Update properties of this object
1397
+ def update!(**args)
1398
+ @device_policy = args[:device_policy] if args.key?(:device_policy)
1399
+ @ip_subnetworks = args[:ip_subnetworks] if args.key?(:ip_subnetworks)
1400
+ @members = args[:members] if args.key?(:members)
1401
+ @negate = args[:negate] if args.key?(:negate)
1402
+ @regions = args[:regions] if args.key?(:regions)
1403
+ @required_access_levels = args[:required_access_levels] if args.key?(:required_access_levels)
1404
+ end
1405
+ end
1406
+
1407
+ # `CustomLevel` is an `AccessLevel` using the Cloud Common Expression Language
1408
+ # to represent the necessary conditions for the level to apply to a request. See
1409
+ # CEL spec at: https://github.com/google/cel-spec
1410
+ class GoogleIdentityAccesscontextmanagerV1CustomLevel
1411
+ include Google::Apis::Core::Hashable
1412
+
1413
+ # Represents a textual expression in the Common Expression Language (CEL) syntax.
1414
+ # CEL is a C-like expression language. The syntax and semantics of CEL are
1415
+ # documented at https://github.com/google/cel-spec. Example (Comparison): title:
1416
+ # "Summary size limit" description: "Determines if a summary is less than 100
1417
+ # chars" expression: "document.summary.size() < 100" Example (Equality): title: "
1418
+ # Requestor is owner" description: "Determines if requestor is the document
1419
+ # owner" expression: "document.owner == request.auth.claims.email" Example (
1420
+ # Logic): title: "Public documents" description: "Determine whether the document
1421
+ # should be publicly visible" expression: "document.type != 'private' &&
1422
+ # document.type != 'internal'" Example (Data Manipulation): title: "Notification
1423
+ # string" description: "Create a notification string with a timestamp."
1424
+ # expression: "'New message received at ' + string(document.create_time)" The
1425
+ # exact variables and functions that may be referenced within an expression are
1426
+ # determined by the service that evaluates it. See the service documentation for
1427
+ # additional information.
1428
+ # Corresponds to the JSON property `expr`
1429
+ # @return [Google::Apis::CloudassetV1p4beta1::Expr]
1430
+ attr_accessor :expr
1431
+
1432
+ def initialize(**args)
1433
+ update!(**args)
1434
+ end
1435
+
1436
+ # Update properties of this object
1437
+ def update!(**args)
1438
+ @expr = args[:expr] if args.key?(:expr)
1439
+ end
1440
+ end
1441
+
1442
+ # `DevicePolicy` specifies device specific restrictions necessary to acquire a
1443
+ # given access level. A `DevicePolicy` specifies requirements for requests from
1444
+ # devices to be granted access levels, it does not do any enforcement on the
1445
+ # device. `DevicePolicy` acts as an AND over all specified fields, and each
1446
+ # repeated field is an OR over its elements. Any unset fields are ignored. For
1447
+ # example, if the proto is ` os_type : DESKTOP_WINDOWS, os_type : DESKTOP_LINUX,
1448
+ # encryption_status: ENCRYPTED`, then the DevicePolicy will be true for requests
1449
+ # originating from encrypted Linux desktops and encrypted Windows desktops.
1450
+ class GoogleIdentityAccesscontextmanagerV1DevicePolicy
1451
+ include Google::Apis::Core::Hashable
1452
+
1453
+ # Allowed device management levels, an empty list allows all management levels.
1454
+ # Corresponds to the JSON property `allowedDeviceManagementLevels`
1455
+ # @return [Array<String>]
1456
+ attr_accessor :allowed_device_management_levels
1457
+
1458
+ # Allowed encryptions statuses, an empty list allows all statuses.
1459
+ # Corresponds to the JSON property `allowedEncryptionStatuses`
1460
+ # @return [Array<String>]
1461
+ attr_accessor :allowed_encryption_statuses
1462
+
1463
+ # Allowed OS versions, an empty list allows all types and all versions.
1464
+ # Corresponds to the JSON property `osConstraints`
1465
+ # @return [Array<Google::Apis::CloudassetV1p4beta1::GoogleIdentityAccesscontextmanagerV1OsConstraint>]
1466
+ attr_accessor :os_constraints
1467
+
1468
+ # Whether the device needs to be approved by the customer admin.
1469
+ # Corresponds to the JSON property `requireAdminApproval`
1470
+ # @return [Boolean]
1471
+ attr_accessor :require_admin_approval
1472
+ alias_method :require_admin_approval?, :require_admin_approval
1473
+
1474
+ # Whether the device needs to be corp owned.
1475
+ # Corresponds to the JSON property `requireCorpOwned`
1476
+ # @return [Boolean]
1477
+ attr_accessor :require_corp_owned
1478
+ alias_method :require_corp_owned?, :require_corp_owned
1479
+
1480
+ # Whether or not screenlock is required for the DevicePolicy to be true.
1481
+ # Defaults to `false`.
1482
+ # Corresponds to the JSON property `requireScreenlock`
1483
+ # @return [Boolean]
1484
+ attr_accessor :require_screenlock
1485
+ alias_method :require_screenlock?, :require_screenlock
1486
+
1487
+ def initialize(**args)
1488
+ update!(**args)
1489
+ end
1490
+
1491
+ # Update properties of this object
1492
+ def update!(**args)
1493
+ @allowed_device_management_levels = args[:allowed_device_management_levels] if args.key?(:allowed_device_management_levels)
1494
+ @allowed_encryption_statuses = args[:allowed_encryption_statuses] if args.key?(:allowed_encryption_statuses)
1495
+ @os_constraints = args[:os_constraints] if args.key?(:os_constraints)
1496
+ @require_admin_approval = args[:require_admin_approval] if args.key?(:require_admin_approval)
1497
+ @require_corp_owned = args[:require_corp_owned] if args.key?(:require_corp_owned)
1498
+ @require_screenlock = args[:require_screenlock] if args.key?(:require_screenlock)
1499
+ end
1500
+ end
1501
+
1502
+ # Defines the conditions under which an EgressPolicy matches a request.
1503
+ # Conditions based on information about the source of the request. Note that if
1504
+ # the destination of the request is also protected by a ServicePerimeter, then
1505
+ # that ServicePerimeter must have an IngressPolicy which allows access in order
1506
+ # for this request to succeed.
1507
+ class GoogleIdentityAccesscontextmanagerV1EgressFrom
1508
+ include Google::Apis::Core::Hashable
1509
+
1510
+ # A list of identities that are allowed access through this [EgressPolicy].
1511
+ # Should be in the format of email address. The email address should represent
1512
+ # individual user or service account only.
1513
+ # Corresponds to the JSON property `identities`
1514
+ # @return [Array<String>]
1515
+ attr_accessor :identities
1516
+
1517
+ # Specifies the type of identities that are allowed access to outside the
1518
+ # perimeter. If left unspecified, then members of `identities` field will be
1519
+ # allowed access.
1520
+ # Corresponds to the JSON property `identityType`
1521
+ # @return [String]
1522
+ attr_accessor :identity_type
1523
+
1524
+ def initialize(**args)
1525
+ update!(**args)
1526
+ end
1527
+
1528
+ # Update properties of this object
1529
+ def update!(**args)
1530
+ @identities = args[:identities] if args.key?(:identities)
1531
+ @identity_type = args[:identity_type] if args.key?(:identity_type)
1532
+ end
1533
+ end
1534
+
1535
+ # Policy for egress from perimeter. EgressPolicies match requests based on `
1536
+ # egress_from` and `egress_to` stanzas. For an EgressPolicy to match, both `
1537
+ # egress_from` and `egress_to` stanzas must be matched. If an EgressPolicy
1538
+ # matches a request, the request is allowed to span the ServicePerimeter
1539
+ # boundary. For example, an EgressPolicy can be used to allow VMs on networks
1540
+ # within the ServicePerimeter to access a defined set of projects outside the
1541
+ # perimeter in certain contexts (e.g. to read data from a Cloud Storage bucket
1542
+ # or query against a BigQuery dataset). EgressPolicies are concerned with the *
1543
+ # resources* that a request relates as well as the API services and API actions
1544
+ # being used. They do not related to the direction of data movement. More
1545
+ # detailed documentation for this concept can be found in the descriptions of
1546
+ # EgressFrom and EgressTo.
1547
+ class GoogleIdentityAccesscontextmanagerV1EgressPolicy
1548
+ include Google::Apis::Core::Hashable
1549
+
1550
+ # Defines the conditions under which an EgressPolicy matches a request.
1551
+ # Conditions based on information about the source of the request. Note that if
1552
+ # the destination of the request is also protected by a ServicePerimeter, then
1553
+ # that ServicePerimeter must have an IngressPolicy which allows access in order
1554
+ # for this request to succeed.
1555
+ # Corresponds to the JSON property `egressFrom`
1556
+ # @return [Google::Apis::CloudassetV1p4beta1::GoogleIdentityAccesscontextmanagerV1EgressFrom]
1557
+ attr_accessor :egress_from
1558
+
1559
+ # Defines the conditions under which an EgressPolicy matches a request.
1560
+ # Conditions are based on information about the ApiOperation intended to be
1561
+ # performed on the `resources` specified. Note that if the destination of the
1562
+ # request is also protected by a ServicePerimeter, then that ServicePerimeter
1563
+ # must have an IngressPolicy which allows access in order for this request to
1564
+ # succeed. The request must match `operations` AND `resources` fields in order
1565
+ # to be allowed egress out of the perimeter.
1566
+ # Corresponds to the JSON property `egressTo`
1567
+ # @return [Google::Apis::CloudassetV1p4beta1::GoogleIdentityAccesscontextmanagerV1EgressTo]
1568
+ attr_accessor :egress_to
1569
+
1570
+ def initialize(**args)
1571
+ update!(**args)
1572
+ end
1573
+
1574
+ # Update properties of this object
1575
+ def update!(**args)
1576
+ @egress_from = args[:egress_from] if args.key?(:egress_from)
1577
+ @egress_to = args[:egress_to] if args.key?(:egress_to)
1578
+ end
1579
+ end
1580
+
1581
+ # Defines the conditions under which an EgressPolicy matches a request.
1582
+ # Conditions are based on information about the ApiOperation intended to be
1583
+ # performed on the `resources` specified. Note that if the destination of the
1584
+ # request is also protected by a ServicePerimeter, then that ServicePerimeter
1585
+ # must have an IngressPolicy which allows access in order for this request to
1586
+ # succeed. The request must match `operations` AND `resources` fields in order
1587
+ # to be allowed egress out of the perimeter.
1588
+ class GoogleIdentityAccesscontextmanagerV1EgressTo
1589
+ include Google::Apis::Core::Hashable
1590
+
1591
+ # A list of ApiOperations allowed to be performed by the sources specified in
1592
+ # the corresponding EgressFrom. A request matches if it uses an operation/
1593
+ # service in this list.
1594
+ # Corresponds to the JSON property `operations`
1595
+ # @return [Array<Google::Apis::CloudassetV1p4beta1::GoogleIdentityAccesscontextmanagerV1ApiOperation>]
1596
+ attr_accessor :operations
1597
+
1598
+ # A list of resources, currently only projects in the form `projects/`, that are
1599
+ # allowed to be accessed by sources defined in the corresponding EgressFrom. A
1600
+ # request matches if it contains a resource in this list. If `*` is specified
1601
+ # for `resources`, then this EgressTo rule will authorize access to all
1602
+ # resources outside the perimeter.
1603
+ # Corresponds to the JSON property `resources`
1604
+ # @return [Array<String>]
1605
+ attr_accessor :resources
1606
+
1607
+ def initialize(**args)
1608
+ update!(**args)
1609
+ end
1610
+
1611
+ # Update properties of this object
1612
+ def update!(**args)
1613
+ @operations = args[:operations] if args.key?(:operations)
1614
+ @resources = args[:resources] if args.key?(:resources)
1615
+ end
1616
+ end
1617
+
1618
+ # Defines the conditions under which an IngressPolicy matches a request.
1619
+ # Conditions are based on information about the source of the request. The
1620
+ # request must satisfy what is defined in `sources` AND identity related fields
1621
+ # in order to match.
1622
+ class GoogleIdentityAccesscontextmanagerV1IngressFrom
1623
+ include Google::Apis::Core::Hashable
1624
+
1625
+ # A list of identities that are allowed access through this ingress policy.
1626
+ # Should be in the format of email address. The email address should represent
1627
+ # individual user or service account only.
1628
+ # Corresponds to the JSON property `identities`
1629
+ # @return [Array<String>]
1630
+ attr_accessor :identities
1631
+
1632
+ # Specifies the type of identities that are allowed access from outside the
1633
+ # perimeter. If left unspecified, then members of `identities` field will be
1634
+ # allowed access.
1635
+ # Corresponds to the JSON property `identityType`
1636
+ # @return [String]
1637
+ attr_accessor :identity_type
1638
+
1639
+ # Sources that this IngressPolicy authorizes access from.
1640
+ # Corresponds to the JSON property `sources`
1641
+ # @return [Array<Google::Apis::CloudassetV1p4beta1::GoogleIdentityAccesscontextmanagerV1IngressSource>]
1642
+ attr_accessor :sources
1643
+
1644
+ def initialize(**args)
1645
+ update!(**args)
1646
+ end
1647
+
1648
+ # Update properties of this object
1649
+ def update!(**args)
1650
+ @identities = args[:identities] if args.key?(:identities)
1651
+ @identity_type = args[:identity_type] if args.key?(:identity_type)
1652
+ @sources = args[:sources] if args.key?(:sources)
1653
+ end
1654
+ end
1655
+
1656
+ # Policy for ingress into ServicePerimeter. IngressPolicies match requests based
1657
+ # on `ingress_from` and `ingress_to` stanzas. For an ingress policy to match,
1658
+ # both the `ingress_from` and `ingress_to` stanzas must be matched. If an
1659
+ # IngressPolicy matches a request, the request is allowed through the perimeter
1660
+ # boundary from outside the perimeter. For example, access from the internet can
1661
+ # be allowed either based on an AccessLevel or, for traffic hosted on Google
1662
+ # Cloud, the project of the source network. For access from private networks,
1663
+ # using the project of the hosting network is required. Individual ingress
1664
+ # policies can be limited by restricting which services and/or actions they
1665
+ # match using the `ingress_to` field.
1666
+ class GoogleIdentityAccesscontextmanagerV1IngressPolicy
1667
+ include Google::Apis::Core::Hashable
1668
+
1669
+ # Defines the conditions under which an IngressPolicy matches a request.
1670
+ # Conditions are based on information about the source of the request. The
1671
+ # request must satisfy what is defined in `sources` AND identity related fields
1672
+ # in order to match.
1673
+ # Corresponds to the JSON property `ingressFrom`
1674
+ # @return [Google::Apis::CloudassetV1p4beta1::GoogleIdentityAccesscontextmanagerV1IngressFrom]
1675
+ attr_accessor :ingress_from
1676
+
1677
+ # Defines the conditions under which an IngressPolicy matches a request.
1678
+ # Conditions are based on information about the ApiOperation intended to be
1679
+ # performed on the target resource of the request. The request must satisfy what
1680
+ # is defined in `operations` AND `resources` in order to match.
1681
+ # Corresponds to the JSON property `ingressTo`
1682
+ # @return [Google::Apis::CloudassetV1p4beta1::GoogleIdentityAccesscontextmanagerV1IngressTo]
1683
+ attr_accessor :ingress_to
1684
+
1685
+ def initialize(**args)
1686
+ update!(**args)
1687
+ end
1688
+
1689
+ # Update properties of this object
1690
+ def update!(**args)
1691
+ @ingress_from = args[:ingress_from] if args.key?(:ingress_from)
1692
+ @ingress_to = args[:ingress_to] if args.key?(:ingress_to)
1693
+ end
1694
+ end
1695
+
1696
+ # The source that IngressPolicy authorizes access from.
1697
+ class GoogleIdentityAccesscontextmanagerV1IngressSource
1698
+ include Google::Apis::Core::Hashable
1699
+
1700
+ # An AccessLevel resource name that allow resources within the ServicePerimeters
1701
+ # to be accessed from the internet. AccessLevels listed must be in the same
1702
+ # policy as this ServicePerimeter. Referencing a nonexistent AccessLevel will
1703
+ # cause an error. If no AccessLevel names are listed, resources within the
1704
+ # perimeter can only be accessed via Google Cloud calls with request origins
1705
+ # within the perimeter. Example: `accessPolicies/MY_POLICY/accessLevels/MY_LEVEL`
1706
+ # . If a single `*` is specified for `access_level`, then all IngressSources
1707
+ # will be allowed.
1708
+ # Corresponds to the JSON property `accessLevel`
1709
+ # @return [String]
1710
+ attr_accessor :access_level
1711
+
1712
+ # A Google Cloud resource that is allowed to ingress the perimeter. Requests
1713
+ # from these resources will be allowed to access perimeter data. Currently only
1714
+ # projects are allowed. Format: `projects/`project_number`` The project may be
1715
+ # in any Google Cloud organization, not just the organization that the perimeter
1716
+ # is defined in. `*` is not allowed, the case of allowing all Google Cloud
1717
+ # resources only is not supported.
1718
+ # Corresponds to the JSON property `resource`
1719
+ # @return [String]
1720
+ attr_accessor :resource
1721
+
1722
+ def initialize(**args)
1723
+ update!(**args)
1724
+ end
1725
+
1726
+ # Update properties of this object
1727
+ def update!(**args)
1728
+ @access_level = args[:access_level] if args.key?(:access_level)
1729
+ @resource = args[:resource] if args.key?(:resource)
1730
+ end
1731
+ end
1732
+
1733
+ # Defines the conditions under which an IngressPolicy matches a request.
1734
+ # Conditions are based on information about the ApiOperation intended to be
1735
+ # performed on the target resource of the request. The request must satisfy what
1736
+ # is defined in `operations` AND `resources` in order to match.
1737
+ class GoogleIdentityAccesscontextmanagerV1IngressTo
1738
+ include Google::Apis::Core::Hashable
1739
+
1740
+ # A list of ApiOperations allowed to be performed by the sources specified in
1741
+ # corresponding IngressFrom in this ServicePerimeter.
1742
+ # Corresponds to the JSON property `operations`
1743
+ # @return [Array<Google::Apis::CloudassetV1p4beta1::GoogleIdentityAccesscontextmanagerV1ApiOperation>]
1744
+ attr_accessor :operations
1745
+
1746
+ # A list of resources, currently only projects in the form `projects/`,
1747
+ # protected by this ServicePerimeter that are allowed to be accessed by sources
1748
+ # defined in the corresponding IngressFrom. If a single `*` is specified, then
1749
+ # access to all resources inside the perimeter are allowed.
1750
+ # Corresponds to the JSON property `resources`
1751
+ # @return [Array<String>]
1752
+ attr_accessor :resources
1753
+
1754
+ def initialize(**args)
1755
+ update!(**args)
1756
+ end
1757
+
1758
+ # Update properties of this object
1759
+ def update!(**args)
1760
+ @operations = args[:operations] if args.key?(:operations)
1761
+ @resources = args[:resources] if args.key?(:resources)
1762
+ end
1763
+ end
1764
+
1765
+ # An allowed method or permission of a service specified in ApiOperation.
1766
+ class GoogleIdentityAccesscontextmanagerV1MethodSelector
1767
+ include Google::Apis::Core::Hashable
1768
+
1769
+ # Value for `method` should be a valid method name for the corresponding `
1770
+ # service_name` in ApiOperation. If `*` used as value for `method`, then ALL
1771
+ # methods and permissions are allowed.
1772
+ # Corresponds to the JSON property `method`
1773
+ # @return [String]
1774
+ attr_accessor :method_prop
1775
+
1776
+ # Value for `permission` should be a valid Cloud IAM permission for the
1777
+ # corresponding `service_name` in ApiOperation.
1778
+ # Corresponds to the JSON property `permission`
1779
+ # @return [String]
1780
+ attr_accessor :permission
1781
+
1782
+ def initialize(**args)
1783
+ update!(**args)
1784
+ end
1785
+
1786
+ # Update properties of this object
1787
+ def update!(**args)
1788
+ @method_prop = args[:method_prop] if args.key?(:method_prop)
1789
+ @permission = args[:permission] if args.key?(:permission)
1790
+ end
1791
+ end
1792
+
1793
+ # A restriction on the OS type and version of devices making requests.
1794
+ class GoogleIdentityAccesscontextmanagerV1OsConstraint
1795
+ include Google::Apis::Core::Hashable
1796
+
1797
+ # The minimum allowed OS version. If not set, any version of this OS satisfies
1798
+ # the constraint. Format: `"major.minor.patch"`. Examples: `"10.5.301"`, `"9.2.1"
1799
+ # `.
1800
+ # Corresponds to the JSON property `minimumVersion`
1801
+ # @return [String]
1802
+ attr_accessor :minimum_version
1803
+
1804
+ # Required. The allowed OS type.
1805
+ # Corresponds to the JSON property `osType`
1806
+ # @return [String]
1807
+ attr_accessor :os_type
1808
+
1809
+ # Only allows requests from devices with a verified Chrome OS. Verifications
1810
+ # includes requirements that the device is enterprise-managed, conformant to
1811
+ # domain policies, and the caller has permission to call the API targeted by the
1812
+ # request.
1813
+ # Corresponds to the JSON property `requireVerifiedChromeOs`
1814
+ # @return [Boolean]
1815
+ attr_accessor :require_verified_chrome_os
1816
+ alias_method :require_verified_chrome_os?, :require_verified_chrome_os
1817
+
1818
+ def initialize(**args)
1819
+ update!(**args)
1820
+ end
1821
+
1822
+ # Update properties of this object
1823
+ def update!(**args)
1824
+ @minimum_version = args[:minimum_version] if args.key?(:minimum_version)
1825
+ @os_type = args[:os_type] if args.key?(:os_type)
1826
+ @require_verified_chrome_os = args[:require_verified_chrome_os] if args.key?(:require_verified_chrome_os)
1827
+ end
1828
+ end
1829
+
1830
+ # `ServicePerimeter` describes a set of Google Cloud resources which can freely
1831
+ # import and export data amongst themselves, but not export outside of the `
1832
+ # ServicePerimeter`. If a request with a source within this `ServicePerimeter`
1833
+ # has a target outside of the `ServicePerimeter`, the request will be blocked.
1834
+ # Otherwise the request is allowed. There are two types of Service Perimeter -
1835
+ # Regular and Bridge. Regular Service Perimeters cannot overlap, a single Google
1836
+ # Cloud project can only belong to a single regular Service Perimeter. Service
1837
+ # Perimeter Bridges can contain only Google Cloud projects as members, a single
1838
+ # Google Cloud project may belong to multiple Service Perimeter Bridges.
1839
+ class GoogleIdentityAccesscontextmanagerV1ServicePerimeter
1840
+ include Google::Apis::Core::Hashable
1841
+
1842
+ # Description of the `ServicePerimeter` and its use. Does not affect behavior.
1843
+ # Corresponds to the JSON property `description`
1844
+ # @return [String]
1845
+ attr_accessor :description
1846
+
1847
+ # Required. Resource name for the ServicePerimeter. The `short_name` component
1848
+ # must begin with a letter and only include alphanumeric and '_'. Format: `
1849
+ # accessPolicies/`policy_id`/servicePerimeters/`short_name``
1850
+ # Corresponds to the JSON property `name`
1851
+ # @return [String]
1852
+ attr_accessor :name
1853
+
1854
+ # Perimeter type indicator. A single project is allowed to be a member of single
1855
+ # regular perimeter, but multiple service perimeter bridges. A project cannot be
1856
+ # a included in a perimeter bridge without being included in regular perimeter.
1857
+ # For perimeter bridges, the restricted service list as well as access level
1858
+ # lists must be empty.
1859
+ # Corresponds to the JSON property `perimeterType`
1860
+ # @return [String]
1861
+ attr_accessor :perimeter_type
1862
+
1863
+ # `ServicePerimeterConfig` specifies a set of Google Cloud resources that
1864
+ # describe specific Service Perimeter configuration.
1865
+ # Corresponds to the JSON property `spec`
1866
+ # @return [Google::Apis::CloudassetV1p4beta1::GoogleIdentityAccesscontextmanagerV1ServicePerimeterConfig]
1867
+ attr_accessor :spec
1868
+
1869
+ # `ServicePerimeterConfig` specifies a set of Google Cloud resources that
1870
+ # describe specific Service Perimeter configuration.
1871
+ # Corresponds to the JSON property `status`
1872
+ # @return [Google::Apis::CloudassetV1p4beta1::GoogleIdentityAccesscontextmanagerV1ServicePerimeterConfig]
1873
+ attr_accessor :status
1874
+
1875
+ # Human readable title. Must be unique within the Policy.
1876
+ # Corresponds to the JSON property `title`
1877
+ # @return [String]
1878
+ attr_accessor :title
1879
+
1880
+ # Use explicit dry run spec flag. Ordinarily, a dry-run spec implicitly exists
1881
+ # for all Service Perimeters, and that spec is identical to the status for those
1882
+ # Service Perimeters. When this flag is set, it inhibits the generation of the
1883
+ # implicit spec, thereby allowing the user to explicitly provide a configuration
1884
+ # ("spec") to use in a dry-run version of the Service Perimeter. This allows the
1885
+ # user to test changes to the enforced config ("status") without actually
1886
+ # enforcing them. This testing is done through analyzing the differences between
1887
+ # currently enforced and suggested restrictions. use_explicit_dry_run_spec must
1888
+ # bet set to True if any of the fields in the spec are set to non-default values.
1889
+ # Corresponds to the JSON property `useExplicitDryRunSpec`
1890
+ # @return [Boolean]
1891
+ attr_accessor :use_explicit_dry_run_spec
1892
+ alias_method :use_explicit_dry_run_spec?, :use_explicit_dry_run_spec
1893
+
1894
+ def initialize(**args)
1895
+ update!(**args)
1896
+ end
1897
+
1898
+ # Update properties of this object
1899
+ def update!(**args)
1900
+ @description = args[:description] if args.key?(:description)
1901
+ @name = args[:name] if args.key?(:name)
1902
+ @perimeter_type = args[:perimeter_type] if args.key?(:perimeter_type)
1903
+ @spec = args[:spec] if args.key?(:spec)
1904
+ @status = args[:status] if args.key?(:status)
1905
+ @title = args[:title] if args.key?(:title)
1906
+ @use_explicit_dry_run_spec = args[:use_explicit_dry_run_spec] if args.key?(:use_explicit_dry_run_spec)
1907
+ end
1908
+ end
1909
+
1910
+ # `ServicePerimeterConfig` specifies a set of Google Cloud resources that
1911
+ # describe specific Service Perimeter configuration.
1912
+ class GoogleIdentityAccesscontextmanagerV1ServicePerimeterConfig
1913
+ include Google::Apis::Core::Hashable
1914
+
1915
+ # A list of `AccessLevel` resource names that allow resources within the `
1916
+ # ServicePerimeter` to be accessed from the internet. `AccessLevels` listed must
1917
+ # be in the same policy as this `ServicePerimeter`. Referencing a nonexistent `
1918
+ # AccessLevel` is a syntax error. If no `AccessLevel` names are listed,
1919
+ # resources within the perimeter can only be accessed via Google Cloud calls
1920
+ # with request origins within the perimeter. Example: `"accessPolicies/MY_POLICY/
1921
+ # accessLevels/MY_LEVEL"`. For Service Perimeter Bridge, must be empty.
1922
+ # Corresponds to the JSON property `accessLevels`
1923
+ # @return [Array<String>]
1924
+ attr_accessor :access_levels
1925
+
1926
+ # List of EgressPolicies to apply to the perimeter. A perimeter may have
1927
+ # multiple EgressPolicies, each of which is evaluated separately. Access is
1928
+ # granted if any EgressPolicy grants it. Must be empty for a perimeter bridge.
1929
+ # Corresponds to the JSON property `egressPolicies`
1930
+ # @return [Array<Google::Apis::CloudassetV1p4beta1::GoogleIdentityAccesscontextmanagerV1EgressPolicy>]
1931
+ attr_accessor :egress_policies
1932
+
1933
+ # List of IngressPolicies to apply to the perimeter. A perimeter may have
1934
+ # multiple IngressPolicies, each of which is evaluated separately. Access is
1935
+ # granted if any Ingress Policy grants it. Must be empty for a perimeter bridge.
1936
+ # Corresponds to the JSON property `ingressPolicies`
1937
+ # @return [Array<Google::Apis::CloudassetV1p4beta1::GoogleIdentityAccesscontextmanagerV1IngressPolicy>]
1938
+ attr_accessor :ingress_policies
1939
+
1940
+ # A list of Google Cloud resources that are inside of the service perimeter.
1941
+ # Currently only projects are allowed. Format: `projects/`project_number``
1942
+ # Corresponds to the JSON property `resources`
1943
+ # @return [Array<String>]
1944
+ attr_accessor :resources
1945
+
1946
+ # Google Cloud services that are subject to the Service Perimeter restrictions.
1947
+ # For example, if `storage.googleapis.com` is specified, access to the storage
1948
+ # buckets inside the perimeter must meet the perimeter's access restrictions.
1949
+ # Corresponds to the JSON property `restrictedServices`
1950
+ # @return [Array<String>]
1951
+ attr_accessor :restricted_services
1952
+
1953
+ # Specifies how APIs are allowed to communicate within the Service Perimeter.
1954
+ # Corresponds to the JSON property `vpcAccessibleServices`
1955
+ # @return [Google::Apis::CloudassetV1p4beta1::GoogleIdentityAccesscontextmanagerV1VpcAccessibleServices]
1956
+ attr_accessor :vpc_accessible_services
1957
+
1958
+ def initialize(**args)
1959
+ update!(**args)
1960
+ end
1961
+
1962
+ # Update properties of this object
1963
+ def update!(**args)
1964
+ @access_levels = args[:access_levels] if args.key?(:access_levels)
1965
+ @egress_policies = args[:egress_policies] if args.key?(:egress_policies)
1966
+ @ingress_policies = args[:ingress_policies] if args.key?(:ingress_policies)
1967
+ @resources = args[:resources] if args.key?(:resources)
1968
+ @restricted_services = args[:restricted_services] if args.key?(:restricted_services)
1969
+ @vpc_accessible_services = args[:vpc_accessible_services] if args.key?(:vpc_accessible_services)
1970
+ end
1971
+ end
1972
+
1973
+ # Specifies how APIs are allowed to communicate within the Service Perimeter.
1974
+ class GoogleIdentityAccesscontextmanagerV1VpcAccessibleServices
1975
+ include Google::Apis::Core::Hashable
1976
+
1977
+ # The list of APIs usable within the Service Perimeter. Must be empty unless '
1978
+ # enable_restriction' is True. You can specify a list of individual services, as
1979
+ # well as include the 'RESTRICTED-SERVICES' value, which automatically includes
1980
+ # all of the services protected by the perimeter.
1981
+ # Corresponds to the JSON property `allowedServices`
1982
+ # @return [Array<String>]
1983
+ attr_accessor :allowed_services
1984
+
1985
+ # Whether to restrict API calls within the Service Perimeter to the list of APIs
1986
+ # specified in 'allowed_services'.
1987
+ # Corresponds to the JSON property `enableRestriction`
1988
+ # @return [Boolean]
1989
+ attr_accessor :enable_restriction
1990
+ alias_method :enable_restriction?, :enable_restriction
1991
+
1992
+ def initialize(**args)
1993
+ update!(**args)
1994
+ end
1995
+
1996
+ # Update properties of this object
1997
+ def update!(**args)
1998
+ @allowed_services = args[:allowed_services] if args.key?(:allowed_services)
1999
+ @enable_restriction = args[:enable_restriction] if args.key?(:enable_restriction)
2000
+ end
2001
+ end
2002
+
2003
+ # An analysis message to group the query and results.
2004
+ class IamPolicyAnalysis
2005
+ include Google::Apis::Core::Hashable
2006
+
2007
+ # IAM policy analysis query message.
2008
+ # Corresponds to the JSON property `analysisQuery`
2009
+ # @return [Google::Apis::CloudassetV1p4beta1::IamPolicyAnalysisQuery]
2010
+ attr_accessor :analysis_query
2011
+
2012
+ # A list of IamPolicyAnalysisResult that matches the analysis query, or empty if
2013
+ # no result is found.
2014
+ # Corresponds to the JSON property `analysisResults`
2015
+ # @return [Array<Google::Apis::CloudassetV1p4beta1::IamPolicyAnalysisResult>]
2016
+ attr_accessor :analysis_results
2017
+
2018
+ # Represents whether all entries in the analysis_results have been fully
2019
+ # explored to answer the query.
2020
+ # Corresponds to the JSON property `fullyExplored`
2021
+ # @return [Boolean]
2022
+ attr_accessor :fully_explored
2023
+ alias_method :fully_explored?, :fully_explored
2024
+
2025
+ def initialize(**args)
2026
+ update!(**args)
2027
+ end
2028
+
2029
+ # Update properties of this object
2030
+ def update!(**args)
2031
+ @analysis_query = args[:analysis_query] if args.key?(:analysis_query)
2032
+ @analysis_results = args[:analysis_results] if args.key?(:analysis_results)
2033
+ @fully_explored = args[:fully_explored] if args.key?(:fully_explored)
2034
+ end
2035
+ end
2036
+
2037
+ # Output configuration for export IAM policy analysis destination.
2038
+ class IamPolicyAnalysisOutputConfig
2039
+ include Google::Apis::Core::Hashable
2040
+
2041
+ # A Cloud Storage location.
2042
+ # Corresponds to the JSON property `gcsDestination`
2043
+ # @return [Google::Apis::CloudassetV1p4beta1::GcsDestination]
2044
+ attr_accessor :gcs_destination
2045
+
2046
+ def initialize(**args)
2047
+ update!(**args)
2048
+ end
2049
+
2050
+ # Update properties of this object
2051
+ def update!(**args)
2052
+ @gcs_destination = args[:gcs_destination] if args.key?(:gcs_destination)
2053
+ end
2054
+ end
2055
+
2056
+ # IAM policy analysis query message.
2057
+ class IamPolicyAnalysisQuery
2058
+ include Google::Apis::Core::Hashable
2059
+
2060
+ # Specifies roles and/or permissions to analyze, to determine both the
2061
+ # identities possessing them and the resources they control. If multiple values
2062
+ # are specified, results will include identities and resources matching any of
2063
+ # them. The total number of roles and permissions should be equal or less than
2064
+ # 10.
2065
+ # Corresponds to the JSON property `accessSelector`
2066
+ # @return [Google::Apis::CloudassetV1p4beta1::AccessSelector]
2067
+ attr_accessor :access_selector
2068
+
2069
+ # Specifies an identity for which to determine resource access, based on roles
2070
+ # assigned either directly to them or to the groups they belong to, directly or
2071
+ # indirectly.
2072
+ # Corresponds to the JSON property `identitySelector`
2073
+ # @return [Google::Apis::CloudassetV1p4beta1::IdentitySelector]
2074
+ attr_accessor :identity_selector
2075
+
2076
+ # Required. The relative name of the root asset. Only resources and IAM policies
2077
+ # within the parent will be analyzed. This can only be an organization number (
2078
+ # such as "organizations/123"), a folder number (such as "folders/123"), a
2079
+ # project ID (such as "projects/my-project-id"), or a project number (such as "
2080
+ # projects/12345"). To know how to get organization id, visit [here ](https://
2081
+ # cloud.google.com/resource-manager/docs/creating-managing-organization#
2082
+ # retrieving_your_organization_id). To know how to get folder or project id,
2083
+ # visit [here ](https://cloud.google.com/resource-manager/docs/creating-managing-
2084
+ # folders#viewing_or_listing_folders_and_projects).
2085
+ # Corresponds to the JSON property `parent`
2086
+ # @return [String]
2087
+ attr_accessor :parent
2088
+
2089
+ # Specifies the resource to analyze for access policies, which may be set
2090
+ # directly on the resource, or on ancestors such as organizations, folders or
2091
+ # projects.
2092
+ # Corresponds to the JSON property `resourceSelector`
2093
+ # @return [Google::Apis::CloudassetV1p4beta1::ResourceSelector]
2094
+ attr_accessor :resource_selector
2095
+
2096
+ def initialize(**args)
2097
+ update!(**args)
2098
+ end
2099
+
2100
+ # Update properties of this object
2101
+ def update!(**args)
2102
+ @access_selector = args[:access_selector] if args.key?(:access_selector)
2103
+ @identity_selector = args[:identity_selector] if args.key?(:identity_selector)
2104
+ @parent = args[:parent] if args.key?(:parent)
2105
+ @resource_selector = args[:resource_selector] if args.key?(:resource_selector)
2106
+ end
2107
+ end
2108
+
2109
+ # IAM Policy analysis result, consisting of one IAM policy binding and derived
2110
+ # access control lists.
2111
+ class IamPolicyAnalysisResult
2112
+ include Google::Apis::Core::Hashable
2113
+
2114
+ # The access control lists derived from the iam_binding that match or
2115
+ # potentially match resource and access selectors specified in the request.
2116
+ # Corresponds to the JSON property `accessControlLists`
2117
+ # @return [Array<Google::Apis::CloudassetV1p4beta1::GoogleCloudAssetV1p4beta1AccessControlList>]
2118
+ attr_accessor :access_control_lists
2119
+
2120
+ # The [full resource name](https://cloud.google.com/asset-inventory/docs/
2121
+ # resource-name-format) of the resource to which the iam_binding policy attaches.
2122
+ # Corresponds to the JSON property `attachedResourceFullName`
2123
+ # @return [String]
2124
+ attr_accessor :attached_resource_full_name
2125
+
2126
+ # Represents whether all analyses on the iam_binding have successfully finished.
2127
+ # Corresponds to the JSON property `fullyExplored`
2128
+ # @return [Boolean]
2129
+ attr_accessor :fully_explored
2130
+ alias_method :fully_explored?, :fully_explored
2131
+
2132
+ # Associates `members` with a `role`.
2133
+ # Corresponds to the JSON property `iamBinding`
2134
+ # @return [Google::Apis::CloudassetV1p4beta1::Binding]
2135
+ attr_accessor :iam_binding
2136
+
2137
+ # The identity list derived from members of the iam_binding that match or
2138
+ # potentially match identity selector specified in the request.
2139
+ # Corresponds to the JSON property `identityList`
2140
+ # @return [Google::Apis::CloudassetV1p4beta1::GoogleCloudAssetV1p4beta1IdentityList]
2141
+ attr_accessor :identity_list
2142
+
2143
+ def initialize(**args)
2144
+ update!(**args)
2145
+ end
2146
+
2147
+ # Update properties of this object
2148
+ def update!(**args)
2149
+ @access_control_lists = args[:access_control_lists] if args.key?(:access_control_lists)
2150
+ @attached_resource_full_name = args[:attached_resource_full_name] if args.key?(:attached_resource_full_name)
2151
+ @fully_explored = args[:fully_explored] if args.key?(:fully_explored)
2152
+ @iam_binding = args[:iam_binding] if args.key?(:iam_binding)
2153
+ @identity_list = args[:identity_list] if args.key?(:identity_list)
2154
+ end
2155
+ end
2156
+
2157
+ # Specifies an identity for which to determine resource access, based on roles
2158
+ # assigned either directly to them or to the groups they belong to, directly or
2159
+ # indirectly.
2160
+ class IdentitySelector
2161
+ include Google::Apis::Core::Hashable
2162
+
2163
+ # Required. The identity appear in the form of members in [IAM policy binding](
2164
+ # https://cloud.google.com/iam/reference/rest/v1/Binding). The examples of
2165
+ # supported forms are: "user:mike@example.com", "group:admins@example.com", "
2166
+ # domain:google.com", "serviceAccount:my-project-id@appspot.gserviceaccount.com".
2167
+ # Notice that wildcard characters (such as * and ?) are not supported. You must
2168
+ # give a specific identity.
2169
+ # Corresponds to the JSON property `identity`
2170
+ # @return [String]
2171
+ attr_accessor :identity
2172
+
2173
+ def initialize(**args)
2174
+ update!(**args)
2175
+ end
2176
+
2177
+ # Update properties of this object
2178
+ def update!(**args)
2179
+ @identity = args[:identity] if args.key?(:identity)
2180
+ end
2181
+ end
2182
+
2183
+ # This resource represents a long-running operation that is the result of a
2184
+ # network API call.
2185
+ class Operation
2186
+ include Google::Apis::Core::Hashable
2187
+
2188
+ # If the value is `false`, it means the operation is still in progress. If `true`
2189
+ # , the operation is completed, and either `error` or `response` is available.
2190
+ # Corresponds to the JSON property `done`
2191
+ # @return [Boolean]
2192
+ attr_accessor :done
2193
+ alias_method :done?, :done
2194
+
2195
+ # The `Status` type defines a logical error model that is suitable for different
2196
+ # programming environments, including REST APIs and RPC APIs. It is used by [
2197
+ # gRPC](https://github.com/grpc). Each `Status` message contains three pieces of
2198
+ # data: error code, error message, and error details. You can find out more
2199
+ # about this error model and how to work with it in the [API Design Guide](https:
2200
+ # //cloud.google.com/apis/design/errors).
2201
+ # Corresponds to the JSON property `error`
2202
+ # @return [Google::Apis::CloudassetV1p4beta1::Status]
2203
+ attr_accessor :error
2204
+
2205
+ # Service-specific metadata associated with the operation. It typically contains
2206
+ # progress information and common metadata such as create time. Some services
2207
+ # might not provide such metadata. Any method that returns a long-running
2208
+ # operation should document the metadata type, if any.
2209
+ # Corresponds to the JSON property `metadata`
2210
+ # @return [Hash<String,Object>]
2211
+ attr_accessor :metadata
2212
+
2213
+ # The server-assigned name, which is only unique within the same service that
2214
+ # originally returns it. If you use the default HTTP mapping, the `name` should
2215
+ # be a resource name ending with `operations/`unique_id``.
2216
+ # Corresponds to the JSON property `name`
2217
+ # @return [String]
2218
+ attr_accessor :name
2219
+
2220
+ # The normal response of the operation in case of success. If the original
2221
+ # method returns no data on success, such as `Delete`, the response is `google.
2222
+ # protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`,
2223
+ # the response should be the resource. For other methods, the response should
2224
+ # have the type `XxxResponse`, where `Xxx` is the original method name. For
2225
+ # example, if the original method name is `TakeSnapshot()`, the inferred
2226
+ # response type is `TakeSnapshotResponse`.
2227
+ # Corresponds to the JSON property `response`
2228
+ # @return [Hash<String,Object>]
2229
+ attr_accessor :response
2230
+
2231
+ def initialize(**args)
2232
+ update!(**args)
2233
+ end
2234
+
2235
+ # Update properties of this object
2236
+ def update!(**args)
2237
+ @done = args[:done] if args.key?(:done)
2238
+ @error = args[:error] if args.key?(:error)
2239
+ @metadata = args[:metadata] if args.key?(:metadata)
2240
+ @name = args[:name] if args.key?(:name)
2241
+ @response = args[:response] if args.key?(:response)
2242
+ end
2243
+ end
2244
+
2245
+ # Contains request options.
2246
+ class Options
739
2247
  include Google::Apis::Core::Hashable
740
2248
 
741
2249
  # Optional. If true, the response will include access analysis from identities
@@ -820,6 +2328,96 @@ module Google
820
2328
  end
821
2329
  end
822
2330
 
2331
+ # An Identity and Access Management (IAM) policy, which specifies access
2332
+ # controls for Google Cloud resources. A `Policy` is a collection of `bindings`.
2333
+ # A `binding` binds one or more `members` to a single `role`. Members can be
2334
+ # user accounts, service accounts, Google groups, and domains (such as G Suite).
2335
+ # A `role` is a named list of permissions; each `role` can be an IAM predefined
2336
+ # role or a user-created custom role. For some types of Google Cloud resources,
2337
+ # a `binding` can also specify a `condition`, which is a logical expression that
2338
+ # allows access to a resource only if the expression evaluates to `true`. A
2339
+ # condition can add constraints based on attributes of the request, the resource,
2340
+ # or both. To learn which resources support conditions in their IAM policies,
2341
+ # see the [IAM documentation](https://cloud.google.com/iam/help/conditions/
2342
+ # resource-policies). **JSON example:** ` "bindings": [ ` "role": "roles/
2343
+ # resourcemanager.organizationAdmin", "members": [ "user:mike@example.com", "
2344
+ # group:admins@example.com", "domain:google.com", "serviceAccount:my-project-id@
2345
+ # appspot.gserviceaccount.com" ] `, ` "role": "roles/resourcemanager.
2346
+ # organizationViewer", "members": [ "user:eve@example.com" ], "condition": ` "
2347
+ # title": "expirable access", "description": "Does not grant access after Sep
2348
+ # 2020", "expression": "request.time < timestamp('2020-10-01T00:00:00.000Z')", `
2349
+ # ` ], "etag": "BwWWja0YfJA=", "version": 3 ` **YAML example:** bindings: -
2350
+ # members: - user:mike@example.com - group:admins@example.com - domain:google.
2351
+ # com - serviceAccount:my-project-id@appspot.gserviceaccount.com role: roles/
2352
+ # resourcemanager.organizationAdmin - members: - user:eve@example.com role:
2353
+ # roles/resourcemanager.organizationViewer condition: title: expirable access
2354
+ # description: Does not grant access after Sep 2020 expression: request.time <
2355
+ # timestamp('2020-10-01T00:00:00.000Z') - etag: BwWWja0YfJA= - version: 3 For a
2356
+ # description of IAM and its features, see the [IAM documentation](https://cloud.
2357
+ # google.com/iam/docs/).
2358
+ class Policy
2359
+ include Google::Apis::Core::Hashable
2360
+
2361
+ # Specifies cloud audit logging configuration for this policy.
2362
+ # Corresponds to the JSON property `auditConfigs`
2363
+ # @return [Array<Google::Apis::CloudassetV1p4beta1::AuditConfig>]
2364
+ attr_accessor :audit_configs
2365
+
2366
+ # Associates a list of `members` to a `role`. Optionally, may specify a `
2367
+ # condition` that determines how and when the `bindings` are applied. Each of
2368
+ # the `bindings` must contain at least one member.
2369
+ # Corresponds to the JSON property `bindings`
2370
+ # @return [Array<Google::Apis::CloudassetV1p4beta1::Binding>]
2371
+ attr_accessor :bindings
2372
+
2373
+ # `etag` is used for optimistic concurrency control as a way to help prevent
2374
+ # simultaneous updates of a policy from overwriting each other. It is strongly
2375
+ # suggested that systems make use of the `etag` in the read-modify-write cycle
2376
+ # to perform policy updates in order to avoid race conditions: An `etag` is
2377
+ # returned in the response to `getIamPolicy`, and systems are expected to put
2378
+ # that etag in the request to `setIamPolicy` to ensure that their change will be
2379
+ # applied to the same version of the policy. **Important:** If you use IAM
2380
+ # Conditions, you must include the `etag` field whenever you call `setIamPolicy`.
2381
+ # If you omit this field, then IAM allows you to overwrite a version `3` policy
2382
+ # with a version `1` policy, and all of the conditions in the version `3` policy
2383
+ # are lost.
2384
+ # Corresponds to the JSON property `etag`
2385
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
2386
+ # @return [String]
2387
+ attr_accessor :etag
2388
+
2389
+ # Specifies the format of the policy. Valid values are `0`, `1`, and `3`.
2390
+ # Requests that specify an invalid value are rejected. Any operation that
2391
+ # affects conditional role bindings must specify version `3`. This requirement
2392
+ # applies to the following operations: * Getting a policy that includes a
2393
+ # conditional role binding * Adding a conditional role binding to a policy *
2394
+ # Changing a conditional role binding in a policy * Removing any role binding,
2395
+ # with or without a condition, from a policy that includes conditions **
2396
+ # Important:** If you use IAM Conditions, you must include the `etag` field
2397
+ # whenever you call `setIamPolicy`. If you omit this field, then IAM allows you
2398
+ # to overwrite a version `3` policy with a version `1` policy, and all of the
2399
+ # conditions in the version `3` policy are lost. If a policy does not include
2400
+ # any conditions, operations on that policy may specify any valid version or
2401
+ # leave the field unset. To learn which resources support conditions in their
2402
+ # IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/
2403
+ # conditions/resource-policies).
2404
+ # Corresponds to the JSON property `version`
2405
+ # @return [Fixnum]
2406
+ attr_accessor :version
2407
+
2408
+ def initialize(**args)
2409
+ update!(**args)
2410
+ end
2411
+
2412
+ # Update properties of this object
2413
+ def update!(**args)
2414
+ @audit_configs = args[:audit_configs] if args.key?(:audit_configs)
2415
+ @bindings = args[:bindings] if args.key?(:bindings)
2416
+ @etag = args[:etag] if args.key?(:etag)
2417
+ @version = args[:version] if args.key?(:version)
2418
+ end
2419
+ end
2420
+
823
2421
  # Specifies the resource to analyze for access policies, which may be set
824
2422
  # directly on the resource, or on ancestors such as organizations, folders or
825
2423
  # projects.