google-apis-cloudasset_v1p1beta1 0.1.0 → 0.2.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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8f7f14b77a774c0240d0179001ec5a7c2cb296fc29346633fbbbc1bd83ec3184
|
4
|
+
data.tar.gz: a9ad5ef50b1fbb92e444ceba28632f0c72f6cb96c8475bbfcc04830e94d4129a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2668b90d84b8b2bec32cb38989b203a62296baa1687df1fa27c567d8e2b4e9ca5f695ac20cacc30ed929280bed37c7af2ac6f40f1a8463bc966d58907d2bcb8a
|
7
|
+
data.tar.gz: 5091600fe2d82f2c54c149fab198cdd4545013ae83ddbebfc0afc80eb84ad5b498ce583005eabb097da6c376948b6339a16e84287b8c073ae85b6fa4b688e9d8
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,10 @@
|
|
1
1
|
# Release history for google-apis-cloudasset_v1p1beta1
|
2
2
|
|
3
|
+
### v0.2.0 (2021-03-04)
|
4
|
+
|
5
|
+
* Regenerated from discovery document revision 20210226
|
6
|
+
* Regenerated using generator version 0.1.2
|
7
|
+
|
3
8
|
### v0.1.0 (2021-01-07)
|
4
9
|
|
5
10
|
* Regenerated using generator version 0.1.1
|
@@ -241,6 +241,1419 @@ module Google
|
|
241
241
|
end
|
242
242
|
end
|
243
243
|
|
244
|
+
# An asset in Google Cloud. An asset can be any resource in the Google Cloud [
|
245
|
+
# resource hierarchy](https://cloud.google.com/resource-manager/docs/cloud-
|
246
|
+
# platform-resource-hierarchy), a resource outside the Google Cloud resource
|
247
|
+
# hierarchy (such as Google Kubernetes Engine clusters and objects), or a policy
|
248
|
+
# (e.g. Cloud IAM policy). See [Supported asset types](https://cloud.google.com/
|
249
|
+
# asset-inventory/docs/supported-asset-types) for more information.
|
250
|
+
class GoogleCloudAssetV1p7beta1Asset
|
251
|
+
include Google::Apis::Core::Hashable
|
252
|
+
|
253
|
+
# An `AccessLevel` is a label that can be applied to requests to Google Cloud
|
254
|
+
# services, along with a list of requirements necessary for the label to be
|
255
|
+
# applied.
|
256
|
+
# Corresponds to the JSON property `accessLevel`
|
257
|
+
# @return [Google::Apis::CloudassetV1p1beta1::GoogleIdentityAccesscontextmanagerV1AccessLevel]
|
258
|
+
attr_accessor :access_level
|
259
|
+
|
260
|
+
# `AccessPolicy` is a container for `AccessLevels` (which define the necessary
|
261
|
+
# attributes to use Google Cloud services) and `ServicePerimeters` (which define
|
262
|
+
# regions of services able to freely pass data within a perimeter). An access
|
263
|
+
# policy is globally visible within an organization, and the restrictions it
|
264
|
+
# specifies apply to all projects within an organization.
|
265
|
+
# Corresponds to the JSON property `accessPolicy`
|
266
|
+
# @return [Google::Apis::CloudassetV1p1beta1::GoogleIdentityAccesscontextmanagerV1AccessPolicy]
|
267
|
+
attr_accessor :access_policy
|
268
|
+
|
269
|
+
# The ancestry path of an asset in Google Cloud [resource hierarchy](https://
|
270
|
+
# cloud.google.com/resource-manager/docs/cloud-platform-resource-hierarchy),
|
271
|
+
# represented as a list of relative resource names. An ancestry path starts with
|
272
|
+
# the closest ancestor in the hierarchy and ends at root. If the asset is a
|
273
|
+
# project, folder, or organization, the ancestry path starts from the asset
|
274
|
+
# itself. Example: `["projects/123456789", "folders/5432", "organizations/1234"]`
|
275
|
+
# Corresponds to the JSON property `ancestors`
|
276
|
+
# @return [Array<String>]
|
277
|
+
attr_accessor :ancestors
|
278
|
+
|
279
|
+
# The type of the asset. Example: `compute.googleapis.com/Disk` See [Supported
|
280
|
+
# asset types](https://cloud.google.com/asset-inventory/docs/supported-asset-
|
281
|
+
# types) for more information.
|
282
|
+
# Corresponds to the JSON property `assetType`
|
283
|
+
# @return [String]
|
284
|
+
attr_accessor :asset_type
|
285
|
+
|
286
|
+
# An Identity and Access Management (IAM) policy, which specifies access
|
287
|
+
# controls for Google Cloud resources. A `Policy` is a collection of `bindings`.
|
288
|
+
# A `binding` binds one or more `members` to a single `role`. Members can be
|
289
|
+
# user accounts, service accounts, Google groups, and domains (such as G Suite).
|
290
|
+
# A `role` is a named list of permissions; each `role` can be an IAM predefined
|
291
|
+
# role or a user-created custom role. For some types of Google Cloud resources,
|
292
|
+
# a `binding` can also specify a `condition`, which is a logical expression that
|
293
|
+
# allows access to a resource only if the expression evaluates to `true`. A
|
294
|
+
# condition can add constraints based on attributes of the request, the resource,
|
295
|
+
# or both. To learn which resources support conditions in their IAM policies,
|
296
|
+
# see the [IAM documentation](https://cloud.google.com/iam/help/conditions/
|
297
|
+
# resource-policies). **JSON example:** ` "bindings": [ ` "role": "roles/
|
298
|
+
# resourcemanager.organizationAdmin", "members": [ "user:mike@example.com", "
|
299
|
+
# group:admins@example.com", "domain:google.com", "serviceAccount:my-project-id@
|
300
|
+
# appspot.gserviceaccount.com" ] `, ` "role": "roles/resourcemanager.
|
301
|
+
# organizationViewer", "members": [ "user:eve@example.com" ], "condition": ` "
|
302
|
+
# title": "expirable access", "description": "Does not grant access after Sep
|
303
|
+
# 2020", "expression": "request.time < timestamp('2020-10-01T00:00:00.000Z')", `
|
304
|
+
# ` ], "etag": "BwWWja0YfJA=", "version": 3 ` **YAML example:** bindings: -
|
305
|
+
# members: - user:mike@example.com - group:admins@example.com - domain:google.
|
306
|
+
# com - serviceAccount:my-project-id@appspot.gserviceaccount.com role: roles/
|
307
|
+
# resourcemanager.organizationAdmin - members: - user:eve@example.com role:
|
308
|
+
# roles/resourcemanager.organizationViewer condition: title: expirable access
|
309
|
+
# description: Does not grant access after Sep 2020 expression: request.time <
|
310
|
+
# timestamp('2020-10-01T00:00:00.000Z') - etag: BwWWja0YfJA= - version: 3 For a
|
311
|
+
# description of IAM and its features, see the [IAM documentation](https://cloud.
|
312
|
+
# google.com/iam/docs/).
|
313
|
+
# Corresponds to the JSON property `iamPolicy`
|
314
|
+
# @return [Google::Apis::CloudassetV1p1beta1::Policy]
|
315
|
+
attr_accessor :iam_policy
|
316
|
+
|
317
|
+
# The full name of the asset. Example: `//compute.googleapis.com/projects/
|
318
|
+
# my_project_123/zones/zone1/instances/instance1` See [Resource names](https://
|
319
|
+
# cloud.google.com/apis/design/resource_names#full_resource_name) for more
|
320
|
+
# information.
|
321
|
+
# Corresponds to the JSON property `name`
|
322
|
+
# @return [String]
|
323
|
+
attr_accessor :name
|
324
|
+
|
325
|
+
# A representation of an [organization policy](https://cloud.google.com/resource-
|
326
|
+
# manager/docs/organization-policy/overview#organization_policy). There can be
|
327
|
+
# more than one organization policy with different constraints set on a given
|
328
|
+
# resource.
|
329
|
+
# Corresponds to the JSON property `orgPolicy`
|
330
|
+
# @return [Array<Google::Apis::CloudassetV1p1beta1::GoogleCloudOrgpolicyV1Policy>]
|
331
|
+
attr_accessor :org_policy
|
332
|
+
|
333
|
+
# The detailed related assets with the `relationship_type`.
|
334
|
+
# Corresponds to the JSON property `relatedAssets`
|
335
|
+
# @return [Google::Apis::CloudassetV1p1beta1::GoogleCloudAssetV1p7beta1RelatedAssets]
|
336
|
+
attr_accessor :related_assets
|
337
|
+
|
338
|
+
# A representation of a Google Cloud resource.
|
339
|
+
# Corresponds to the JSON property `resource`
|
340
|
+
# @return [Google::Apis::CloudassetV1p1beta1::GoogleCloudAssetV1p7beta1Resource]
|
341
|
+
attr_accessor :resource
|
342
|
+
|
343
|
+
# `ServicePerimeter` describes a set of Google Cloud resources which can freely
|
344
|
+
# import and export data amongst themselves, but not export outside of the `
|
345
|
+
# ServicePerimeter`. If a request with a source within this `ServicePerimeter`
|
346
|
+
# has a target outside of the `ServicePerimeter`, the request will be blocked.
|
347
|
+
# Otherwise the request is allowed. There are two types of Service Perimeter -
|
348
|
+
# Regular and Bridge. Regular Service Perimeters cannot overlap, a single Google
|
349
|
+
# Cloud project can only belong to a single regular Service Perimeter. Service
|
350
|
+
# Perimeter Bridges can contain only Google Cloud projects as members, a single
|
351
|
+
# Google Cloud project may belong to multiple Service Perimeter Bridges.
|
352
|
+
# Corresponds to the JSON property `servicePerimeter`
|
353
|
+
# @return [Google::Apis::CloudassetV1p1beta1::GoogleIdentityAccesscontextmanagerV1ServicePerimeter]
|
354
|
+
attr_accessor :service_perimeter
|
355
|
+
|
356
|
+
# The last update timestamp of an asset. update_time is updated when create/
|
357
|
+
# update/delete operation is performed.
|
358
|
+
# Corresponds to the JSON property `updateTime`
|
359
|
+
# @return [String]
|
360
|
+
attr_accessor :update_time
|
361
|
+
|
362
|
+
def initialize(**args)
|
363
|
+
update!(**args)
|
364
|
+
end
|
365
|
+
|
366
|
+
# Update properties of this object
|
367
|
+
def update!(**args)
|
368
|
+
@access_level = args[:access_level] if args.key?(:access_level)
|
369
|
+
@access_policy = args[:access_policy] if args.key?(:access_policy)
|
370
|
+
@ancestors = args[:ancestors] if args.key?(:ancestors)
|
371
|
+
@asset_type = args[:asset_type] if args.key?(:asset_type)
|
372
|
+
@iam_policy = args[:iam_policy] if args.key?(:iam_policy)
|
373
|
+
@name = args[:name] if args.key?(:name)
|
374
|
+
@org_policy = args[:org_policy] if args.key?(:org_policy)
|
375
|
+
@related_assets = args[:related_assets] if args.key?(:related_assets)
|
376
|
+
@resource = args[:resource] if args.key?(:resource)
|
377
|
+
@service_perimeter = args[:service_perimeter] if args.key?(:service_perimeter)
|
378
|
+
@update_time = args[:update_time] if args.key?(:update_time)
|
379
|
+
end
|
380
|
+
end
|
381
|
+
|
382
|
+
# An asset identify in Google Cloud which contains its name, type and ancestors.
|
383
|
+
# An asset can be any resource in the Google Cloud [resource hierarchy](https://
|
384
|
+
# cloud.google.com/resource-manager/docs/cloud-platform-resource-hierarchy), a
|
385
|
+
# resource outside the Google Cloud resource hierarchy (such as Google
|
386
|
+
# Kubernetes Engine clusters and objects), or a policy (e.g. Cloud IAM policy).
|
387
|
+
# See [Supported asset types](https://cloud.google.com/asset-inventory/docs/
|
388
|
+
# supported-asset-types) for more information.
|
389
|
+
class GoogleCloudAssetV1p7beta1RelatedAsset
|
390
|
+
include Google::Apis::Core::Hashable
|
391
|
+
|
392
|
+
# The ancestors of an asset in Google Cloud [resource hierarchy](https://cloud.
|
393
|
+
# google.com/resource-manager/docs/cloud-platform-resource-hierarchy),
|
394
|
+
# represented as a list of relative resource names. An ancestry path starts with
|
395
|
+
# the closest ancestor in the hierarchy and ends at root. Example: `["projects/
|
396
|
+
# 123456789", "folders/5432", "organizations/1234"]`
|
397
|
+
# Corresponds to the JSON property `ancestors`
|
398
|
+
# @return [Array<String>]
|
399
|
+
attr_accessor :ancestors
|
400
|
+
|
401
|
+
# The full name of the asset. Example: `//compute.googleapis.com/projects/
|
402
|
+
# my_project_123/zones/zone1/instances/instance1` See [Resource names](https://
|
403
|
+
# cloud.google.com/apis/design/resource_names#full_resource_name) for more
|
404
|
+
# information.
|
405
|
+
# Corresponds to the JSON property `asset`
|
406
|
+
# @return [String]
|
407
|
+
attr_accessor :asset
|
408
|
+
|
409
|
+
# The type of the asset. Example: `compute.googleapis.com/Disk` See [Supported
|
410
|
+
# asset types](https://cloud.google.com/asset-inventory/docs/supported-asset-
|
411
|
+
# types) for more information.
|
412
|
+
# Corresponds to the JSON property `assetType`
|
413
|
+
# @return [String]
|
414
|
+
attr_accessor :asset_type
|
415
|
+
|
416
|
+
def initialize(**args)
|
417
|
+
update!(**args)
|
418
|
+
end
|
419
|
+
|
420
|
+
# Update properties of this object
|
421
|
+
def update!(**args)
|
422
|
+
@ancestors = args[:ancestors] if args.key?(:ancestors)
|
423
|
+
@asset = args[:asset] if args.key?(:asset)
|
424
|
+
@asset_type = args[:asset_type] if args.key?(:asset_type)
|
425
|
+
end
|
426
|
+
end
|
427
|
+
|
428
|
+
# The detailed related assets with the `relationship_type`.
|
429
|
+
class GoogleCloudAssetV1p7beta1RelatedAssets
|
430
|
+
include Google::Apis::Core::Hashable
|
431
|
+
|
432
|
+
# The peer resources of the relationship.
|
433
|
+
# Corresponds to the JSON property `assets`
|
434
|
+
# @return [Array<Google::Apis::CloudassetV1p1beta1::GoogleCloudAssetV1p7beta1RelatedAsset>]
|
435
|
+
attr_accessor :assets
|
436
|
+
|
437
|
+
# The relationship attributes which include `type`, `source_resource_type`, `
|
438
|
+
# target_resource_type` and `action`.
|
439
|
+
# Corresponds to the JSON property `relationshipAttributes`
|
440
|
+
# @return [Google::Apis::CloudassetV1p1beta1::GoogleCloudAssetV1p7beta1RelationshipAttributes]
|
441
|
+
attr_accessor :relationship_attributes
|
442
|
+
|
443
|
+
def initialize(**args)
|
444
|
+
update!(**args)
|
445
|
+
end
|
446
|
+
|
447
|
+
# Update properties of this object
|
448
|
+
def update!(**args)
|
449
|
+
@assets = args[:assets] if args.key?(:assets)
|
450
|
+
@relationship_attributes = args[:relationship_attributes] if args.key?(:relationship_attributes)
|
451
|
+
end
|
452
|
+
end
|
453
|
+
|
454
|
+
# The relationship attributes which include `type`, `source_resource_type`, `
|
455
|
+
# target_resource_type` and `action`.
|
456
|
+
class GoogleCloudAssetV1p7beta1RelationshipAttributes
|
457
|
+
include Google::Apis::Core::Hashable
|
458
|
+
|
459
|
+
# The detail of the relationship, e.g. `contains`, `attaches`
|
460
|
+
# Corresponds to the JSON property `action`
|
461
|
+
# @return [String]
|
462
|
+
attr_accessor :action
|
463
|
+
|
464
|
+
# The source asset type. Example: `compute.googleapis.com/Instance`
|
465
|
+
# Corresponds to the JSON property `sourceResourceType`
|
466
|
+
# @return [String]
|
467
|
+
attr_accessor :source_resource_type
|
468
|
+
|
469
|
+
# The target asset type. Example: `compute.googleapis.com/Disk`
|
470
|
+
# Corresponds to the JSON property `targetResourceType`
|
471
|
+
# @return [String]
|
472
|
+
attr_accessor :target_resource_type
|
473
|
+
|
474
|
+
# The unique identifier of the relationship type. Example: `
|
475
|
+
# INSTANCE_TO_INSTANCEGROUP`
|
476
|
+
# Corresponds to the JSON property `type`
|
477
|
+
# @return [String]
|
478
|
+
attr_accessor :type
|
479
|
+
|
480
|
+
def initialize(**args)
|
481
|
+
update!(**args)
|
482
|
+
end
|
483
|
+
|
484
|
+
# Update properties of this object
|
485
|
+
def update!(**args)
|
486
|
+
@action = args[:action] if args.key?(:action)
|
487
|
+
@source_resource_type = args[:source_resource_type] if args.key?(:source_resource_type)
|
488
|
+
@target_resource_type = args[:target_resource_type] if args.key?(:target_resource_type)
|
489
|
+
@type = args[:type] if args.key?(:type)
|
490
|
+
end
|
491
|
+
end
|
492
|
+
|
493
|
+
# A representation of a Google Cloud resource.
|
494
|
+
class GoogleCloudAssetV1p7beta1Resource
|
495
|
+
include Google::Apis::Core::Hashable
|
496
|
+
|
497
|
+
# The content of the resource, in which some sensitive fields are removed and
|
498
|
+
# may not be present.
|
499
|
+
# Corresponds to the JSON property `data`
|
500
|
+
# @return [Hash<String,Object>]
|
501
|
+
attr_accessor :data
|
502
|
+
|
503
|
+
# The URL of the discovery document containing the resource's JSON schema.
|
504
|
+
# Example: `https://www.googleapis.com/discovery/v1/apis/compute/v1/rest` This
|
505
|
+
# value is unspecified for resources that do not have an API based on a
|
506
|
+
# discovery document, such as Cloud Bigtable.
|
507
|
+
# Corresponds to the JSON property `discoveryDocumentUri`
|
508
|
+
# @return [String]
|
509
|
+
attr_accessor :discovery_document_uri
|
510
|
+
|
511
|
+
# The JSON schema name listed in the discovery document. Example: `Project` This
|
512
|
+
# value is unspecified for resources that do not have an API based on a
|
513
|
+
# discovery document, such as Cloud Bigtable.
|
514
|
+
# Corresponds to the JSON property `discoveryName`
|
515
|
+
# @return [String]
|
516
|
+
attr_accessor :discovery_name
|
517
|
+
|
518
|
+
# The location of the resource in Google Cloud, such as its zone and region. For
|
519
|
+
# more information, see https://cloud.google.com/about/locations/.
|
520
|
+
# Corresponds to the JSON property `location`
|
521
|
+
# @return [String]
|
522
|
+
attr_accessor :location
|
523
|
+
|
524
|
+
# The full name of the immediate parent of this resource. See [Resource Names](
|
525
|
+
# https://cloud.google.com/apis/design/resource_names#full_resource_name) for
|
526
|
+
# more information. For Google Cloud assets, this value is the parent resource
|
527
|
+
# defined in the [Cloud IAM policy hierarchy](https://cloud.google.com/iam/docs/
|
528
|
+
# overview#policy_hierarchy). Example: `//cloudresourcemanager.googleapis.com/
|
529
|
+
# projects/my_project_123` For third-party assets, this field may be set
|
530
|
+
# differently.
|
531
|
+
# Corresponds to the JSON property `parent`
|
532
|
+
# @return [String]
|
533
|
+
attr_accessor :parent
|
534
|
+
|
535
|
+
# The REST URL for accessing the resource. An HTTP `GET` request using this URL
|
536
|
+
# returns the resource itself. Example: `https://cloudresourcemanager.googleapis.
|
537
|
+
# com/v1/projects/my-project-123` This value is unspecified for resources
|
538
|
+
# without a REST API.
|
539
|
+
# Corresponds to the JSON property `resourceUrl`
|
540
|
+
# @return [String]
|
541
|
+
attr_accessor :resource_url
|
542
|
+
|
543
|
+
# The API version. Example: `v1`
|
544
|
+
# Corresponds to the JSON property `version`
|
545
|
+
# @return [String]
|
546
|
+
attr_accessor :version
|
547
|
+
|
548
|
+
def initialize(**args)
|
549
|
+
update!(**args)
|
550
|
+
end
|
551
|
+
|
552
|
+
# Update properties of this object
|
553
|
+
def update!(**args)
|
554
|
+
@data = args[:data] if args.key?(:data)
|
555
|
+
@discovery_document_uri = args[:discovery_document_uri] if args.key?(:discovery_document_uri)
|
556
|
+
@discovery_name = args[:discovery_name] if args.key?(:discovery_name)
|
557
|
+
@location = args[:location] if args.key?(:location)
|
558
|
+
@parent = args[:parent] if args.key?(:parent)
|
559
|
+
@resource_url = args[:resource_url] if args.key?(:resource_url)
|
560
|
+
@version = args[:version] if args.key?(:version)
|
561
|
+
end
|
562
|
+
end
|
563
|
+
|
564
|
+
# Used in `policy_type` to specify how `boolean_policy` will behave at this
|
565
|
+
# resource.
|
566
|
+
class GoogleCloudOrgpolicyV1BooleanPolicy
|
567
|
+
include Google::Apis::Core::Hashable
|
568
|
+
|
569
|
+
# If `true`, then the `Policy` is enforced. If `false`, then any configuration
|
570
|
+
# is acceptable. Suppose you have a `Constraint` `constraints/compute.
|
571
|
+
# disableSerialPortAccess` with `constraint_default` set to `ALLOW`. A `Policy`
|
572
|
+
# for that `Constraint` exhibits the following behavior: - If the `Policy` at
|
573
|
+
# this resource has enforced set to `false`, serial port connection attempts
|
574
|
+
# will be allowed. - If the `Policy` at this resource has enforced set to `true`,
|
575
|
+
# serial port connection attempts will be refused. - If the `Policy` at this
|
576
|
+
# resource is `RestoreDefault`, serial port connection attempts will be allowed.
|
577
|
+
# - If no `Policy` is set at this resource or anywhere higher in the resource
|
578
|
+
# hierarchy, serial port connection attempts will be allowed. - If no `Policy`
|
579
|
+
# is set at this resource, but one exists higher in the resource hierarchy, the
|
580
|
+
# behavior is as if the`Policy` were set at this resource. The following
|
581
|
+
# examples demonstrate the different possible layerings: Example 1 (nearest `
|
582
|
+
# Constraint` wins): `organizations/foo` has a `Policy` with: `enforced: false` `
|
583
|
+
# projects/bar` has no `Policy` set. The constraint at `projects/bar` and `
|
584
|
+
# organizations/foo` will not be enforced. Example 2 (enforcement gets replaced):
|
585
|
+
# `organizations/foo` has a `Policy` with: `enforced: false` `projects/bar` has
|
586
|
+
# a `Policy` with: `enforced: true` The constraint at `organizations/foo` is not
|
587
|
+
# enforced. The constraint at `projects/bar` is enforced. Example 3 (
|
588
|
+
# RestoreDefault): `organizations/foo` has a `Policy` with: `enforced: true` `
|
589
|
+
# projects/bar` has a `Policy` with: `RestoreDefault: ``` The constraint at `
|
590
|
+
# organizations/foo` is enforced. The constraint at `projects/bar` is not
|
591
|
+
# enforced, because `constraint_default` for the `Constraint` is `ALLOW`.
|
592
|
+
# Corresponds to the JSON property `enforced`
|
593
|
+
# @return [Boolean]
|
594
|
+
attr_accessor :enforced
|
595
|
+
alias_method :enforced?, :enforced
|
596
|
+
|
597
|
+
def initialize(**args)
|
598
|
+
update!(**args)
|
599
|
+
end
|
600
|
+
|
601
|
+
# Update properties of this object
|
602
|
+
def update!(**args)
|
603
|
+
@enforced = args[:enforced] if args.key?(:enforced)
|
604
|
+
end
|
605
|
+
end
|
606
|
+
|
607
|
+
# Used in `policy_type` to specify how `list_policy` behaves at this resource. `
|
608
|
+
# ListPolicy` can define specific values and subtrees of Cloud Resource Manager
|
609
|
+
# resource hierarchy (`Organizations`, `Folders`, `Projects`) that are allowed
|
610
|
+
# or denied by setting the `allowed_values` and `denied_values` fields. This is
|
611
|
+
# achieved by using the `under:` and optional `is:` prefixes. The `under:`
|
612
|
+
# prefix is used to denote resource subtree values. The `is:` prefix is used to
|
613
|
+
# denote specific values, and is required only if the value contains a ":".
|
614
|
+
# Values prefixed with "is:" are treated the same as values with no prefix.
|
615
|
+
# Ancestry subtrees must be in one of the following formats: - "projects/", e.g.
|
616
|
+
# "projects/tokyo-rain-123" - "folders/", e.g. "folders/1234" - "organizations/",
|
617
|
+
# e.g. "organizations/1234" The `supports_under` field of the associated `
|
618
|
+
# Constraint` defines whether ancestry prefixes can be used. You can set `
|
619
|
+
# allowed_values` and `denied_values` in the same `Policy` if `all_values` is `
|
620
|
+
# ALL_VALUES_UNSPECIFIED`. `ALLOW` or `DENY` are used to allow or deny all
|
621
|
+
# values. If `all_values` is set to either `ALLOW` or `DENY`, `allowed_values`
|
622
|
+
# and `denied_values` must be unset.
|
623
|
+
class GoogleCloudOrgpolicyV1ListPolicy
|
624
|
+
include Google::Apis::Core::Hashable
|
625
|
+
|
626
|
+
# The policy all_values state.
|
627
|
+
# Corresponds to the JSON property `allValues`
|
628
|
+
# @return [String]
|
629
|
+
attr_accessor :all_values
|
630
|
+
|
631
|
+
# List of values allowed at this resource. Can only be set if `all_values` is
|
632
|
+
# set to `ALL_VALUES_UNSPECIFIED`.
|
633
|
+
# Corresponds to the JSON property `allowedValues`
|
634
|
+
# @return [Array<String>]
|
635
|
+
attr_accessor :allowed_values
|
636
|
+
|
637
|
+
# List of values denied at this resource. Can only be set if `all_values` is set
|
638
|
+
# to `ALL_VALUES_UNSPECIFIED`.
|
639
|
+
# Corresponds to the JSON property `deniedValues`
|
640
|
+
# @return [Array<String>]
|
641
|
+
attr_accessor :denied_values
|
642
|
+
|
643
|
+
# Determines the inheritance behavior for this `Policy`. By default, a `
|
644
|
+
# ListPolicy` set at a resource supersedes any `Policy` set anywhere up the
|
645
|
+
# resource hierarchy. However, if `inherit_from_parent` is set to `true`, then
|
646
|
+
# the values from the effective `Policy` of the parent resource are inherited,
|
647
|
+
# meaning the values set in this `Policy` are added to the values inherited up
|
648
|
+
# the hierarchy. Setting `Policy` hierarchies that inherit both allowed values
|
649
|
+
# and denied values isn't recommended in most circumstances to keep the
|
650
|
+
# configuration simple and understandable. However, it is possible to set a `
|
651
|
+
# Policy` with `allowed_values` set that inherits a `Policy` with `denied_values`
|
652
|
+
# set. In this case, the values that are allowed must be in `allowed_values`
|
653
|
+
# and not present in `denied_values`. For example, suppose you have a `
|
654
|
+
# Constraint` `constraints/serviceuser.services`, which has a `constraint_type`
|
655
|
+
# of `list_constraint`, and with `constraint_default` set to `ALLOW`. Suppose
|
656
|
+
# that at the Organization level, a `Policy` is applied that restricts the
|
657
|
+
# allowed API activations to ``E1`, `E2``. Then, if a `Policy` is applied to a
|
658
|
+
# project below the Organization that has `inherit_from_parent` set to `false`
|
659
|
+
# and field all_values set to DENY, then an attempt to activate any API will be
|
660
|
+
# denied. The following examples demonstrate different possible layerings for `
|
661
|
+
# projects/bar` parented by `organizations/foo`: Example 1 (no inherited values):
|
662
|
+
# `organizations/foo` has a `Policy` with values: `allowed_values: "E1"
|
663
|
+
# allowed_values:"E2"` `projects/bar` has `inherit_from_parent` `false` and
|
664
|
+
# values: `allowed_values: "E3" allowed_values: "E4"` The accepted values at `
|
665
|
+
# organizations/foo` are `E1`, `E2`. The accepted values at `projects/bar` are `
|
666
|
+
# E3`, and `E4`. Example 2 (inherited values): `organizations/foo` has a `Policy`
|
667
|
+
# with values: `allowed_values: "E1" allowed_values:"E2"` `projects/bar` has a `
|
668
|
+
# Policy` with values: `value: "E3" value: "E4" inherit_from_parent: true` The
|
669
|
+
# accepted values at `organizations/foo` are `E1`, `E2`. The accepted values at `
|
670
|
+
# projects/bar` are `E1`, `E2`, `E3`, and `E4`. Example 3 (inheriting both
|
671
|
+
# allowed and denied values): `organizations/foo` has a `Policy` with values: `
|
672
|
+
# allowed_values: "E1" allowed_values: "E2"` `projects/bar` has a `Policy` with:
|
673
|
+
# `denied_values: "E1"` The accepted values at `organizations/foo` are `E1`, `E2`
|
674
|
+
# . The value accepted at `projects/bar` is `E2`. Example 4 (RestoreDefault): `
|
675
|
+
# organizations/foo` has a `Policy` with values: `allowed_values: "E1"
|
676
|
+
# allowed_values:"E2"` `projects/bar` has a `Policy` with values: `
|
677
|
+
# RestoreDefault: ``` The accepted values at `organizations/foo` are `E1`, `E2`.
|
678
|
+
# The accepted values at `projects/bar` are either all or none depending on the
|
679
|
+
# value of `constraint_default` (if `ALLOW`, all; if `DENY`, none). Example 5 (
|
680
|
+
# no policy inherits parent policy): `organizations/foo` has no `Policy` set. `
|
681
|
+
# projects/bar` has no `Policy` set. The accepted values at both levels are
|
682
|
+
# either all or none depending on the value of `constraint_default` (if `ALLOW`,
|
683
|
+
# all; if `DENY`, none). Example 6 (ListConstraint allowing all): `organizations/
|
684
|
+
# foo` has a `Policy` with values: `allowed_values: "E1" allowed_values: "E2"` `
|
685
|
+
# projects/bar` has a `Policy` with: `all: ALLOW` The accepted values at `
|
686
|
+
# organizations/foo` are `E1`, E2`. Any value is accepted at `projects/bar`.
|
687
|
+
# Example 7 (ListConstraint allowing none): `organizations/foo` has a `Policy`
|
688
|
+
# with values: `allowed_values: "E1" allowed_values: "E2"` `projects/bar` has a `
|
689
|
+
# Policy` with: `all: DENY` The accepted values at `organizations/foo` are `E1`,
|
690
|
+
# E2`. No value is accepted at `projects/bar`. Example 10 (allowed and denied
|
691
|
+
# subtrees of Resource Manager hierarchy): Given the following resource
|
692
|
+
# hierarchy O1->`F1, F2`; F1->`P1`; F2->`P2, P3`, `organizations/foo` has a `
|
693
|
+
# Policy` with values: `allowed_values: "under:organizations/O1"` `projects/bar`
|
694
|
+
# has a `Policy` with: `allowed_values: "under:projects/P3"` `denied_values: "
|
695
|
+
# under:folders/F2"` The accepted values at `organizations/foo` are `
|
696
|
+
# organizations/O1`, `folders/F1`, `folders/F2`, `projects/P1`, `projects/P2`, `
|
697
|
+
# projects/P3`. The accepted values at `projects/bar` are `organizations/O1`, `
|
698
|
+
# folders/F1`, `projects/P1`.
|
699
|
+
# Corresponds to the JSON property `inheritFromParent`
|
700
|
+
# @return [Boolean]
|
701
|
+
attr_accessor :inherit_from_parent
|
702
|
+
alias_method :inherit_from_parent?, :inherit_from_parent
|
703
|
+
|
704
|
+
# Optional. The Google Cloud Console will try to default to a configuration that
|
705
|
+
# matches the value specified in this `Policy`. If `suggested_value` is not set,
|
706
|
+
# it will inherit the value specified higher in the hierarchy, unless `
|
707
|
+
# inherit_from_parent` is `false`.
|
708
|
+
# Corresponds to the JSON property `suggestedValue`
|
709
|
+
# @return [String]
|
710
|
+
attr_accessor :suggested_value
|
711
|
+
|
712
|
+
def initialize(**args)
|
713
|
+
update!(**args)
|
714
|
+
end
|
715
|
+
|
716
|
+
# Update properties of this object
|
717
|
+
def update!(**args)
|
718
|
+
@all_values = args[:all_values] if args.key?(:all_values)
|
719
|
+
@allowed_values = args[:allowed_values] if args.key?(:allowed_values)
|
720
|
+
@denied_values = args[:denied_values] if args.key?(:denied_values)
|
721
|
+
@inherit_from_parent = args[:inherit_from_parent] if args.key?(:inherit_from_parent)
|
722
|
+
@suggested_value = args[:suggested_value] if args.key?(:suggested_value)
|
723
|
+
end
|
724
|
+
end
|
725
|
+
|
726
|
+
# Defines a Cloud Organization `Policy` which is used to specify `Constraints`
|
727
|
+
# for configurations of Cloud Platform resources.
|
728
|
+
class GoogleCloudOrgpolicyV1Policy
|
729
|
+
include Google::Apis::Core::Hashable
|
730
|
+
|
731
|
+
# Used in `policy_type` to specify how `boolean_policy` will behave at this
|
732
|
+
# resource.
|
733
|
+
# Corresponds to the JSON property `booleanPolicy`
|
734
|
+
# @return [Google::Apis::CloudassetV1p1beta1::GoogleCloudOrgpolicyV1BooleanPolicy]
|
735
|
+
attr_accessor :boolean_policy
|
736
|
+
|
737
|
+
# The name of the `Constraint` the `Policy` is configuring, for example, `
|
738
|
+
# constraints/serviceuser.services`. A [list of available constraints](/resource-
|
739
|
+
# manager/docs/organization-policy/org-policy-constraints) is available.
|
740
|
+
# Immutable after creation.
|
741
|
+
# Corresponds to the JSON property `constraint`
|
742
|
+
# @return [String]
|
743
|
+
attr_accessor :constraint
|
744
|
+
|
745
|
+
# An opaque tag indicating the current version of the `Policy`, used for
|
746
|
+
# concurrency control. When the `Policy` is returned from either a `GetPolicy`
|
747
|
+
# or a `ListOrgPolicy` request, this `etag` indicates the version of the current
|
748
|
+
# `Policy` to use when executing a read-modify-write loop. When the `Policy` is
|
749
|
+
# returned from a `GetEffectivePolicy` request, the `etag` will be unset. When
|
750
|
+
# the `Policy` is used in a `SetOrgPolicy` method, use the `etag` value that was
|
751
|
+
# returned from a `GetOrgPolicy` request as part of a read-modify-write loop for
|
752
|
+
# concurrency control. Not setting the `etag`in a `SetOrgPolicy` request will
|
753
|
+
# result in an unconditional write of the `Policy`.
|
754
|
+
# Corresponds to the JSON property `etag`
|
755
|
+
# NOTE: Values are automatically base64 encoded/decoded in the client library.
|
756
|
+
# @return [String]
|
757
|
+
attr_accessor :etag
|
758
|
+
|
759
|
+
# Used in `policy_type` to specify how `list_policy` behaves at this resource. `
|
760
|
+
# ListPolicy` can define specific values and subtrees of Cloud Resource Manager
|
761
|
+
# resource hierarchy (`Organizations`, `Folders`, `Projects`) that are allowed
|
762
|
+
# or denied by setting the `allowed_values` and `denied_values` fields. This is
|
763
|
+
# achieved by using the `under:` and optional `is:` prefixes. The `under:`
|
764
|
+
# prefix is used to denote resource subtree values. The `is:` prefix is used to
|
765
|
+
# denote specific values, and is required only if the value contains a ":".
|
766
|
+
# Values prefixed with "is:" are treated the same as values with no prefix.
|
767
|
+
# Ancestry subtrees must be in one of the following formats: - "projects/", e.g.
|
768
|
+
# "projects/tokyo-rain-123" - "folders/", e.g. "folders/1234" - "organizations/",
|
769
|
+
# e.g. "organizations/1234" The `supports_under` field of the associated `
|
770
|
+
# Constraint` defines whether ancestry prefixes can be used. You can set `
|
771
|
+
# allowed_values` and `denied_values` in the same `Policy` if `all_values` is `
|
772
|
+
# ALL_VALUES_UNSPECIFIED`. `ALLOW` or `DENY` are used to allow or deny all
|
773
|
+
# values. If `all_values` is set to either `ALLOW` or `DENY`, `allowed_values`
|
774
|
+
# and `denied_values` must be unset.
|
775
|
+
# Corresponds to the JSON property `listPolicy`
|
776
|
+
# @return [Google::Apis::CloudassetV1p1beta1::GoogleCloudOrgpolicyV1ListPolicy]
|
777
|
+
attr_accessor :list_policy
|
778
|
+
|
779
|
+
# Ignores policies set above this resource and restores the `constraint_default`
|
780
|
+
# enforcement behavior of the specific `Constraint` at this resource. Suppose
|
781
|
+
# that `constraint_default` is set to `ALLOW` for the `Constraint` `constraints/
|
782
|
+
# serviceuser.services`. Suppose that organization foo.com sets a `Policy` at
|
783
|
+
# their Organization resource node that restricts the allowed service
|
784
|
+
# activations to deny all service activations. They could then set a `Policy`
|
785
|
+
# with the `policy_type` `restore_default` on several experimental projects,
|
786
|
+
# restoring the `constraint_default` enforcement of the `Constraint` for only
|
787
|
+
# those projects, allowing those projects to have all services activated.
|
788
|
+
# Corresponds to the JSON property `restoreDefault`
|
789
|
+
# @return [Google::Apis::CloudassetV1p1beta1::GoogleCloudOrgpolicyV1RestoreDefault]
|
790
|
+
attr_accessor :restore_default
|
791
|
+
|
792
|
+
# The time stamp the `Policy` was previously updated. This is set by the server,
|
793
|
+
# not specified by the caller, and represents the last time a call to `
|
794
|
+
# SetOrgPolicy` was made for that `Policy`. Any value set by the client will be
|
795
|
+
# ignored.
|
796
|
+
# Corresponds to the JSON property `updateTime`
|
797
|
+
# @return [String]
|
798
|
+
attr_accessor :update_time
|
799
|
+
|
800
|
+
# Version of the `Policy`. Default version is 0;
|
801
|
+
# Corresponds to the JSON property `version`
|
802
|
+
# @return [Fixnum]
|
803
|
+
attr_accessor :version
|
804
|
+
|
805
|
+
def initialize(**args)
|
806
|
+
update!(**args)
|
807
|
+
end
|
808
|
+
|
809
|
+
# Update properties of this object
|
810
|
+
def update!(**args)
|
811
|
+
@boolean_policy = args[:boolean_policy] if args.key?(:boolean_policy)
|
812
|
+
@constraint = args[:constraint] if args.key?(:constraint)
|
813
|
+
@etag = args[:etag] if args.key?(:etag)
|
814
|
+
@list_policy = args[:list_policy] if args.key?(:list_policy)
|
815
|
+
@restore_default = args[:restore_default] if args.key?(:restore_default)
|
816
|
+
@update_time = args[:update_time] if args.key?(:update_time)
|
817
|
+
@version = args[:version] if args.key?(:version)
|
818
|
+
end
|
819
|
+
end
|
820
|
+
|
821
|
+
# Ignores policies set above this resource and restores the `constraint_default`
|
822
|
+
# enforcement behavior of the specific `Constraint` at this resource. Suppose
|
823
|
+
# that `constraint_default` is set to `ALLOW` for the `Constraint` `constraints/
|
824
|
+
# serviceuser.services`. Suppose that organization foo.com sets a `Policy` at
|
825
|
+
# their Organization resource node that restricts the allowed service
|
826
|
+
# activations to deny all service activations. They could then set a `Policy`
|
827
|
+
# with the `policy_type` `restore_default` on several experimental projects,
|
828
|
+
# restoring the `constraint_default` enforcement of the `Constraint` for only
|
829
|
+
# those projects, allowing those projects to have all services activated.
|
830
|
+
class GoogleCloudOrgpolicyV1RestoreDefault
|
831
|
+
include Google::Apis::Core::Hashable
|
832
|
+
|
833
|
+
def initialize(**args)
|
834
|
+
update!(**args)
|
835
|
+
end
|
836
|
+
|
837
|
+
# Update properties of this object
|
838
|
+
def update!(**args)
|
839
|
+
end
|
840
|
+
end
|
841
|
+
|
842
|
+
# An `AccessLevel` is a label that can be applied to requests to Google Cloud
|
843
|
+
# services, along with a list of requirements necessary for the label to be
|
844
|
+
# applied.
|
845
|
+
class GoogleIdentityAccesscontextmanagerV1AccessLevel
|
846
|
+
include Google::Apis::Core::Hashable
|
847
|
+
|
848
|
+
# `BasicLevel` is an `AccessLevel` using a set of recommended features.
|
849
|
+
# Corresponds to the JSON property `basic`
|
850
|
+
# @return [Google::Apis::CloudassetV1p1beta1::GoogleIdentityAccesscontextmanagerV1BasicLevel]
|
851
|
+
attr_accessor :basic
|
852
|
+
|
853
|
+
# `CustomLevel` is an `AccessLevel` using the Cloud Common Expression Language
|
854
|
+
# to represent the necessary conditions for the level to apply to a request. See
|
855
|
+
# CEL spec at: https://github.com/google/cel-spec
|
856
|
+
# Corresponds to the JSON property `custom`
|
857
|
+
# @return [Google::Apis::CloudassetV1p1beta1::GoogleIdentityAccesscontextmanagerV1CustomLevel]
|
858
|
+
attr_accessor :custom
|
859
|
+
|
860
|
+
# Description of the `AccessLevel` and its use. Does not affect behavior.
|
861
|
+
# Corresponds to the JSON property `description`
|
862
|
+
# @return [String]
|
863
|
+
attr_accessor :description
|
864
|
+
|
865
|
+
# Required. Resource name for the Access Level. The `short_name` component must
|
866
|
+
# begin with a letter and only include alphanumeric and '_'. Format: `
|
867
|
+
# accessPolicies/`policy_id`/accessLevels/`short_name``. The maximum length of
|
868
|
+
# the `short_name` component is 50 characters.
|
869
|
+
# Corresponds to the JSON property `name`
|
870
|
+
# @return [String]
|
871
|
+
attr_accessor :name
|
872
|
+
|
873
|
+
# Human readable title. Must be unique within the Policy.
|
874
|
+
# Corresponds to the JSON property `title`
|
875
|
+
# @return [String]
|
876
|
+
attr_accessor :title
|
877
|
+
|
878
|
+
def initialize(**args)
|
879
|
+
update!(**args)
|
880
|
+
end
|
881
|
+
|
882
|
+
# Update properties of this object
|
883
|
+
def update!(**args)
|
884
|
+
@basic = args[:basic] if args.key?(:basic)
|
885
|
+
@custom = args[:custom] if args.key?(:custom)
|
886
|
+
@description = args[:description] if args.key?(:description)
|
887
|
+
@name = args[:name] if args.key?(:name)
|
888
|
+
@title = args[:title] if args.key?(:title)
|
889
|
+
end
|
890
|
+
end
|
891
|
+
|
892
|
+
# `AccessPolicy` is a container for `AccessLevels` (which define the necessary
|
893
|
+
# attributes to use Google Cloud services) and `ServicePerimeters` (which define
|
894
|
+
# regions of services able to freely pass data within a perimeter). An access
|
895
|
+
# policy is globally visible within an organization, and the restrictions it
|
896
|
+
# specifies apply to all projects within an organization.
|
897
|
+
class GoogleIdentityAccesscontextmanagerV1AccessPolicy
|
898
|
+
include Google::Apis::Core::Hashable
|
899
|
+
|
900
|
+
# Output only. An opaque identifier for the current version of the `AccessPolicy`
|
901
|
+
# . This will always be a strongly validated etag, meaning that two Access
|
902
|
+
# Polices will be identical if and only if their etags are identical. Clients
|
903
|
+
# should not expect this to be in any specific format.
|
904
|
+
# Corresponds to the JSON property `etag`
|
905
|
+
# @return [String]
|
906
|
+
attr_accessor :etag
|
907
|
+
|
908
|
+
# Output only. Resource name of the `AccessPolicy`. Format: `accessPolicies/`
|
909
|
+
# policy_id``
|
910
|
+
# Corresponds to the JSON property `name`
|
911
|
+
# @return [String]
|
912
|
+
attr_accessor :name
|
913
|
+
|
914
|
+
# Required. The parent of this `AccessPolicy` in the Cloud Resource Hierarchy.
|
915
|
+
# Currently immutable once created. Format: `organizations/`organization_id``
|
916
|
+
# Corresponds to the JSON property `parent`
|
917
|
+
# @return [String]
|
918
|
+
attr_accessor :parent
|
919
|
+
|
920
|
+
# Required. Human readable title. Does not affect behavior.
|
921
|
+
# Corresponds to the JSON property `title`
|
922
|
+
# @return [String]
|
923
|
+
attr_accessor :title
|
924
|
+
|
925
|
+
def initialize(**args)
|
926
|
+
update!(**args)
|
927
|
+
end
|
928
|
+
|
929
|
+
# Update properties of this object
|
930
|
+
def update!(**args)
|
931
|
+
@etag = args[:etag] if args.key?(:etag)
|
932
|
+
@name = args[:name] if args.key?(:name)
|
933
|
+
@parent = args[:parent] if args.key?(:parent)
|
934
|
+
@title = args[:title] if args.key?(:title)
|
935
|
+
end
|
936
|
+
end
|
937
|
+
|
938
|
+
# Identification for an API Operation.
|
939
|
+
class GoogleIdentityAccesscontextmanagerV1ApiOperation
|
940
|
+
include Google::Apis::Core::Hashable
|
941
|
+
|
942
|
+
# API methods or permissions to allow. Method or permission must belong to the
|
943
|
+
# service specified by `service_name` field. A single MethodSelector entry with `
|
944
|
+
# *` specified for the `method` field will allow all methods AND permissions for
|
945
|
+
# the service specified in `service_name`.
|
946
|
+
# Corresponds to the JSON property `methodSelectors`
|
947
|
+
# @return [Array<Google::Apis::CloudassetV1p1beta1::GoogleIdentityAccesscontextmanagerV1MethodSelector>]
|
948
|
+
attr_accessor :method_selectors
|
949
|
+
|
950
|
+
# The name of the API whose methods or permissions the IngressPolicy or
|
951
|
+
# EgressPolicy want to allow. A single ApiOperation with `service_name` field
|
952
|
+
# set to `*` will allow all methods AND permissions for all services.
|
953
|
+
# Corresponds to the JSON property `serviceName`
|
954
|
+
# @return [String]
|
955
|
+
attr_accessor :service_name
|
956
|
+
|
957
|
+
def initialize(**args)
|
958
|
+
update!(**args)
|
959
|
+
end
|
960
|
+
|
961
|
+
# Update properties of this object
|
962
|
+
def update!(**args)
|
963
|
+
@method_selectors = args[:method_selectors] if args.key?(:method_selectors)
|
964
|
+
@service_name = args[:service_name] if args.key?(:service_name)
|
965
|
+
end
|
966
|
+
end
|
967
|
+
|
968
|
+
# `BasicLevel` is an `AccessLevel` using a set of recommended features.
|
969
|
+
class GoogleIdentityAccesscontextmanagerV1BasicLevel
|
970
|
+
include Google::Apis::Core::Hashable
|
971
|
+
|
972
|
+
# How the `conditions` list should be combined to determine if a request is
|
973
|
+
# granted this `AccessLevel`. If AND is used, each `Condition` in `conditions`
|
974
|
+
# must be satisfied for the `AccessLevel` to be applied. If OR is used, at least
|
975
|
+
# one `Condition` in `conditions` must be satisfied for the `AccessLevel` to be
|
976
|
+
# applied. Default behavior is AND.
|
977
|
+
# Corresponds to the JSON property `combiningFunction`
|
978
|
+
# @return [String]
|
979
|
+
attr_accessor :combining_function
|
980
|
+
|
981
|
+
# Required. A list of requirements for the `AccessLevel` to be granted.
|
982
|
+
# Corresponds to the JSON property `conditions`
|
983
|
+
# @return [Array<Google::Apis::CloudassetV1p1beta1::GoogleIdentityAccesscontextmanagerV1Condition>]
|
984
|
+
attr_accessor :conditions
|
985
|
+
|
986
|
+
def initialize(**args)
|
987
|
+
update!(**args)
|
988
|
+
end
|
989
|
+
|
990
|
+
# Update properties of this object
|
991
|
+
def update!(**args)
|
992
|
+
@combining_function = args[:combining_function] if args.key?(:combining_function)
|
993
|
+
@conditions = args[:conditions] if args.key?(:conditions)
|
994
|
+
end
|
995
|
+
end
|
996
|
+
|
997
|
+
# A condition necessary for an `AccessLevel` to be granted. The Condition is an
|
998
|
+
# AND over its fields. So a Condition is true if: 1) the request IP is from one
|
999
|
+
# of the listed subnetworks AND 2) the originating device complies with the
|
1000
|
+
# listed device policy AND 3) all listed access levels are granted AND 4) the
|
1001
|
+
# request was sent at a time allowed by the DateTimeRestriction.
|
1002
|
+
class GoogleIdentityAccesscontextmanagerV1Condition
|
1003
|
+
include Google::Apis::Core::Hashable
|
1004
|
+
|
1005
|
+
# `DevicePolicy` specifies device specific restrictions necessary to acquire a
|
1006
|
+
# given access level. A `DevicePolicy` specifies requirements for requests from
|
1007
|
+
# devices to be granted access levels, it does not do any enforcement on the
|
1008
|
+
# device. `DevicePolicy` acts as an AND over all specified fields, and each
|
1009
|
+
# repeated field is an OR over its elements. Any unset fields are ignored. For
|
1010
|
+
# example, if the proto is ` os_type : DESKTOP_WINDOWS, os_type : DESKTOP_LINUX,
|
1011
|
+
# encryption_status: ENCRYPTED`, then the DevicePolicy will be true for requests
|
1012
|
+
# originating from encrypted Linux desktops and encrypted Windows desktops.
|
1013
|
+
# Corresponds to the JSON property `devicePolicy`
|
1014
|
+
# @return [Google::Apis::CloudassetV1p1beta1::GoogleIdentityAccesscontextmanagerV1DevicePolicy]
|
1015
|
+
attr_accessor :device_policy
|
1016
|
+
|
1017
|
+
# CIDR block IP subnetwork specification. May be IPv4 or IPv6. Note that for a
|
1018
|
+
# CIDR IP address block, the specified IP address portion must be properly
|
1019
|
+
# truncated (i.e. all the host bits must be zero) or the input is considered
|
1020
|
+
# malformed. For example, "192.0.2.0/24" is accepted but "192.0.2.1/24" is not.
|
1021
|
+
# Similarly, for IPv6, "2001:db8::/32" is accepted whereas "2001:db8::1/32" is
|
1022
|
+
# not. The originating IP of a request must be in one of the listed subnets in
|
1023
|
+
# order for this Condition to be true. If empty, all IP addresses are allowed.
|
1024
|
+
# Corresponds to the JSON property `ipSubnetworks`
|
1025
|
+
# @return [Array<String>]
|
1026
|
+
attr_accessor :ip_subnetworks
|
1027
|
+
|
1028
|
+
# The request must be made by one of the provided user or service accounts.
|
1029
|
+
# Groups are not supported. Syntax: `user:`emailid`` `serviceAccount:`emailid``
|
1030
|
+
# If not specified, a request may come from any user.
|
1031
|
+
# Corresponds to the JSON property `members`
|
1032
|
+
# @return [Array<String>]
|
1033
|
+
attr_accessor :members
|
1034
|
+
|
1035
|
+
# Whether to negate the Condition. If true, the Condition becomes a NAND over
|
1036
|
+
# its non-empty fields, each field must be false for the Condition overall to be
|
1037
|
+
# satisfied. Defaults to false.
|
1038
|
+
# Corresponds to the JSON property `negate`
|
1039
|
+
# @return [Boolean]
|
1040
|
+
attr_accessor :negate
|
1041
|
+
alias_method :negate?, :negate
|
1042
|
+
|
1043
|
+
# The request must originate from one of the provided countries/regions. Must be
|
1044
|
+
# valid ISO 3166-1 alpha-2 codes.
|
1045
|
+
# Corresponds to the JSON property `regions`
|
1046
|
+
# @return [Array<String>]
|
1047
|
+
attr_accessor :regions
|
1048
|
+
|
1049
|
+
# A list of other access levels defined in the same `Policy`, referenced by
|
1050
|
+
# resource name. Referencing an `AccessLevel` which does not exist is an error.
|
1051
|
+
# All access levels listed must be granted for the Condition to be true. Example:
|
1052
|
+
# "`accessPolicies/MY_POLICY/accessLevels/LEVEL_NAME"`
|
1053
|
+
# Corresponds to the JSON property `requiredAccessLevels`
|
1054
|
+
# @return [Array<String>]
|
1055
|
+
attr_accessor :required_access_levels
|
1056
|
+
|
1057
|
+
def initialize(**args)
|
1058
|
+
update!(**args)
|
1059
|
+
end
|
1060
|
+
|
1061
|
+
# Update properties of this object
|
1062
|
+
def update!(**args)
|
1063
|
+
@device_policy = args[:device_policy] if args.key?(:device_policy)
|
1064
|
+
@ip_subnetworks = args[:ip_subnetworks] if args.key?(:ip_subnetworks)
|
1065
|
+
@members = args[:members] if args.key?(:members)
|
1066
|
+
@negate = args[:negate] if args.key?(:negate)
|
1067
|
+
@regions = args[:regions] if args.key?(:regions)
|
1068
|
+
@required_access_levels = args[:required_access_levels] if args.key?(:required_access_levels)
|
1069
|
+
end
|
1070
|
+
end
|
1071
|
+
|
1072
|
+
# `CustomLevel` is an `AccessLevel` using the Cloud Common Expression Language
|
1073
|
+
# to represent the necessary conditions for the level to apply to a request. See
|
1074
|
+
# CEL spec at: https://github.com/google/cel-spec
|
1075
|
+
class GoogleIdentityAccesscontextmanagerV1CustomLevel
|
1076
|
+
include Google::Apis::Core::Hashable
|
1077
|
+
|
1078
|
+
# Represents a textual expression in the Common Expression Language (CEL) syntax.
|
1079
|
+
# CEL is a C-like expression language. The syntax and semantics of CEL are
|
1080
|
+
# documented at https://github.com/google/cel-spec. Example (Comparison): title:
|
1081
|
+
# "Summary size limit" description: "Determines if a summary is less than 100
|
1082
|
+
# chars" expression: "document.summary.size() < 100" Example (Equality): title: "
|
1083
|
+
# Requestor is owner" description: "Determines if requestor is the document
|
1084
|
+
# owner" expression: "document.owner == request.auth.claims.email" Example (
|
1085
|
+
# Logic): title: "Public documents" description: "Determine whether the document
|
1086
|
+
# should be publicly visible" expression: "document.type != 'private' &&
|
1087
|
+
# document.type != 'internal'" Example (Data Manipulation): title: "Notification
|
1088
|
+
# string" description: "Create a notification string with a timestamp."
|
1089
|
+
# expression: "'New message received at ' + string(document.create_time)" The
|
1090
|
+
# exact variables and functions that may be referenced within an expression are
|
1091
|
+
# determined by the service that evaluates it. See the service documentation for
|
1092
|
+
# additional information.
|
1093
|
+
# Corresponds to the JSON property `expr`
|
1094
|
+
# @return [Google::Apis::CloudassetV1p1beta1::Expr]
|
1095
|
+
attr_accessor :expr
|
1096
|
+
|
1097
|
+
def initialize(**args)
|
1098
|
+
update!(**args)
|
1099
|
+
end
|
1100
|
+
|
1101
|
+
# Update properties of this object
|
1102
|
+
def update!(**args)
|
1103
|
+
@expr = args[:expr] if args.key?(:expr)
|
1104
|
+
end
|
1105
|
+
end
|
1106
|
+
|
1107
|
+
# `DevicePolicy` specifies device specific restrictions necessary to acquire a
|
1108
|
+
# given access level. A `DevicePolicy` specifies requirements for requests from
|
1109
|
+
# devices to be granted access levels, it does not do any enforcement on the
|
1110
|
+
# device. `DevicePolicy` acts as an AND over all specified fields, and each
|
1111
|
+
# repeated field is an OR over its elements. Any unset fields are ignored. For
|
1112
|
+
# example, if the proto is ` os_type : DESKTOP_WINDOWS, os_type : DESKTOP_LINUX,
|
1113
|
+
# encryption_status: ENCRYPTED`, then the DevicePolicy will be true for requests
|
1114
|
+
# originating from encrypted Linux desktops and encrypted Windows desktops.
|
1115
|
+
class GoogleIdentityAccesscontextmanagerV1DevicePolicy
|
1116
|
+
include Google::Apis::Core::Hashable
|
1117
|
+
|
1118
|
+
# Allowed device management levels, an empty list allows all management levels.
|
1119
|
+
# Corresponds to the JSON property `allowedDeviceManagementLevels`
|
1120
|
+
# @return [Array<String>]
|
1121
|
+
attr_accessor :allowed_device_management_levels
|
1122
|
+
|
1123
|
+
# Allowed encryptions statuses, an empty list allows all statuses.
|
1124
|
+
# Corresponds to the JSON property `allowedEncryptionStatuses`
|
1125
|
+
# @return [Array<String>]
|
1126
|
+
attr_accessor :allowed_encryption_statuses
|
1127
|
+
|
1128
|
+
# Allowed OS versions, an empty list allows all types and all versions.
|
1129
|
+
# Corresponds to the JSON property `osConstraints`
|
1130
|
+
# @return [Array<Google::Apis::CloudassetV1p1beta1::GoogleIdentityAccesscontextmanagerV1OsConstraint>]
|
1131
|
+
attr_accessor :os_constraints
|
1132
|
+
|
1133
|
+
# Whether the device needs to be approved by the customer admin.
|
1134
|
+
# Corresponds to the JSON property `requireAdminApproval`
|
1135
|
+
# @return [Boolean]
|
1136
|
+
attr_accessor :require_admin_approval
|
1137
|
+
alias_method :require_admin_approval?, :require_admin_approval
|
1138
|
+
|
1139
|
+
# Whether the device needs to be corp owned.
|
1140
|
+
# Corresponds to the JSON property `requireCorpOwned`
|
1141
|
+
# @return [Boolean]
|
1142
|
+
attr_accessor :require_corp_owned
|
1143
|
+
alias_method :require_corp_owned?, :require_corp_owned
|
1144
|
+
|
1145
|
+
# Whether or not screenlock is required for the DevicePolicy to be true.
|
1146
|
+
# Defaults to `false`.
|
1147
|
+
# Corresponds to the JSON property `requireScreenlock`
|
1148
|
+
# @return [Boolean]
|
1149
|
+
attr_accessor :require_screenlock
|
1150
|
+
alias_method :require_screenlock?, :require_screenlock
|
1151
|
+
|
1152
|
+
def initialize(**args)
|
1153
|
+
update!(**args)
|
1154
|
+
end
|
1155
|
+
|
1156
|
+
# Update properties of this object
|
1157
|
+
def update!(**args)
|
1158
|
+
@allowed_device_management_levels = args[:allowed_device_management_levels] if args.key?(:allowed_device_management_levels)
|
1159
|
+
@allowed_encryption_statuses = args[:allowed_encryption_statuses] if args.key?(:allowed_encryption_statuses)
|
1160
|
+
@os_constraints = args[:os_constraints] if args.key?(:os_constraints)
|
1161
|
+
@require_admin_approval = args[:require_admin_approval] if args.key?(:require_admin_approval)
|
1162
|
+
@require_corp_owned = args[:require_corp_owned] if args.key?(:require_corp_owned)
|
1163
|
+
@require_screenlock = args[:require_screenlock] if args.key?(:require_screenlock)
|
1164
|
+
end
|
1165
|
+
end
|
1166
|
+
|
1167
|
+
# Defines the conditions under which an EgressPolicy matches a request.
|
1168
|
+
# Conditions based on information about the source of the request. Note that if
|
1169
|
+
# the destination of the request is protected by a ServicePerimeter, then that
|
1170
|
+
# ServicePerimeter must have an IngressPolicy which allows access in order for
|
1171
|
+
# this request to succeed.
|
1172
|
+
class GoogleIdentityAccesscontextmanagerV1EgressFrom
|
1173
|
+
include Google::Apis::Core::Hashable
|
1174
|
+
|
1175
|
+
# A list of identities that are allowed access through this [EgressPolicy].
|
1176
|
+
# Should be in the format of email address. The email address should represent
|
1177
|
+
# individual user or service account only.
|
1178
|
+
# Corresponds to the JSON property `identities`
|
1179
|
+
# @return [Array<String>]
|
1180
|
+
attr_accessor :identities
|
1181
|
+
|
1182
|
+
# Specifies the type of identities that are allowed access to outside the
|
1183
|
+
# perimeter. If left unspecified, then members of `identities` field will be
|
1184
|
+
# allowed access.
|
1185
|
+
# Corresponds to the JSON property `identityType`
|
1186
|
+
# @return [String]
|
1187
|
+
attr_accessor :identity_type
|
1188
|
+
|
1189
|
+
def initialize(**args)
|
1190
|
+
update!(**args)
|
1191
|
+
end
|
1192
|
+
|
1193
|
+
# Update properties of this object
|
1194
|
+
def update!(**args)
|
1195
|
+
@identities = args[:identities] if args.key?(:identities)
|
1196
|
+
@identity_type = args[:identity_type] if args.key?(:identity_type)
|
1197
|
+
end
|
1198
|
+
end
|
1199
|
+
|
1200
|
+
# Policy for egress from perimeter. EgressPolicies match requests based on `
|
1201
|
+
# egress_from` and `egress_to` stanzas. For an EgressPolicy to match, both `
|
1202
|
+
# egress_from` and `egress_to` stanzas must be matched. If an EgressPolicy
|
1203
|
+
# matches a request, the request is allowed to span the ServicePerimeter
|
1204
|
+
# boundary. For example, an EgressPolicy can be used to allow VMs on networks
|
1205
|
+
# within the ServicePerimeter to access a defined set of projects outside the
|
1206
|
+
# perimeter in certain contexts (e.g. to read data from a Cloud Storage bucket
|
1207
|
+
# or query against a BigQuery dataset). EgressPolicies are concerned with the *
|
1208
|
+
# resources* that a request relates as well as the API services and API actions
|
1209
|
+
# being used. They do not related to the direction of data movement. More
|
1210
|
+
# detailed documentation for this concept can be found in the descriptions of
|
1211
|
+
# EgressFrom and EgressTo.
|
1212
|
+
class GoogleIdentityAccesscontextmanagerV1EgressPolicy
|
1213
|
+
include Google::Apis::Core::Hashable
|
1214
|
+
|
1215
|
+
# Defines the conditions under which an EgressPolicy matches a request.
|
1216
|
+
# Conditions based on information about the source of the request. Note that if
|
1217
|
+
# the destination of the request is protected by a ServicePerimeter, then that
|
1218
|
+
# ServicePerimeter must have an IngressPolicy which allows access in order for
|
1219
|
+
# this request to succeed.
|
1220
|
+
# Corresponds to the JSON property `egressFrom`
|
1221
|
+
# @return [Google::Apis::CloudassetV1p1beta1::GoogleIdentityAccesscontextmanagerV1EgressFrom]
|
1222
|
+
attr_accessor :egress_from
|
1223
|
+
|
1224
|
+
# Defines the conditions under which an EgressPolicy matches a request.
|
1225
|
+
# Conditions are based on information about the ApiOperation intended to be
|
1226
|
+
# performed on the `resources` specified. Note that if the destination of the
|
1227
|
+
# request is protected by a ServicePerimeter, then that ServicePerimeter must
|
1228
|
+
# have an IngressPolicy which allows access in order for this request to succeed.
|
1229
|
+
# Corresponds to the JSON property `egressTo`
|
1230
|
+
# @return [Google::Apis::CloudassetV1p1beta1::GoogleIdentityAccesscontextmanagerV1EgressTo]
|
1231
|
+
attr_accessor :egress_to
|
1232
|
+
|
1233
|
+
def initialize(**args)
|
1234
|
+
update!(**args)
|
1235
|
+
end
|
1236
|
+
|
1237
|
+
# Update properties of this object
|
1238
|
+
def update!(**args)
|
1239
|
+
@egress_from = args[:egress_from] if args.key?(:egress_from)
|
1240
|
+
@egress_to = args[:egress_to] if args.key?(:egress_to)
|
1241
|
+
end
|
1242
|
+
end
|
1243
|
+
|
1244
|
+
# Defines the conditions under which an EgressPolicy matches a request.
|
1245
|
+
# Conditions are based on information about the ApiOperation intended to be
|
1246
|
+
# performed on the `resources` specified. Note that if the destination of the
|
1247
|
+
# request is protected by a ServicePerimeter, then that ServicePerimeter must
|
1248
|
+
# have an IngressPolicy which allows access in order for this request to succeed.
|
1249
|
+
class GoogleIdentityAccesscontextmanagerV1EgressTo
|
1250
|
+
include Google::Apis::Core::Hashable
|
1251
|
+
|
1252
|
+
# A list of ApiOperations that this egress rule applies to. A request matches if
|
1253
|
+
# it contains an operation/service in this list.
|
1254
|
+
# Corresponds to the JSON property `operations`
|
1255
|
+
# @return [Array<Google::Apis::CloudassetV1p1beta1::GoogleIdentityAccesscontextmanagerV1ApiOperation>]
|
1256
|
+
attr_accessor :operations
|
1257
|
+
|
1258
|
+
# A list of resources, currently only projects in the form `projects/`, that
|
1259
|
+
# match this to stanza. A request matches if it contains a resource in this list.
|
1260
|
+
# If `*` is specified for resources, then this EgressTo rule will authorize
|
1261
|
+
# access to all resources outside the perimeter.
|
1262
|
+
# Corresponds to the JSON property `resources`
|
1263
|
+
# @return [Array<String>]
|
1264
|
+
attr_accessor :resources
|
1265
|
+
|
1266
|
+
def initialize(**args)
|
1267
|
+
update!(**args)
|
1268
|
+
end
|
1269
|
+
|
1270
|
+
# Update properties of this object
|
1271
|
+
def update!(**args)
|
1272
|
+
@operations = args[:operations] if args.key?(:operations)
|
1273
|
+
@resources = args[:resources] if args.key?(:resources)
|
1274
|
+
end
|
1275
|
+
end
|
1276
|
+
|
1277
|
+
# Defines the conditions under which an IngressPolicy matches a request.
|
1278
|
+
# Conditions are based on information about the source of the request.
|
1279
|
+
class GoogleIdentityAccesscontextmanagerV1IngressFrom
|
1280
|
+
include Google::Apis::Core::Hashable
|
1281
|
+
|
1282
|
+
# A list of identities that are allowed access through this ingress policy.
|
1283
|
+
# Should be in the format of email address. The email address should represent
|
1284
|
+
# individual user or service account only.
|
1285
|
+
# Corresponds to the JSON property `identities`
|
1286
|
+
# @return [Array<String>]
|
1287
|
+
attr_accessor :identities
|
1288
|
+
|
1289
|
+
# Specifies the type of identities that are allowed access from outside the
|
1290
|
+
# perimeter. If left unspecified, then members of `identities` field will be
|
1291
|
+
# allowed access.
|
1292
|
+
# Corresponds to the JSON property `identityType`
|
1293
|
+
# @return [String]
|
1294
|
+
attr_accessor :identity_type
|
1295
|
+
|
1296
|
+
# Sources that this IngressPolicy authorizes access from.
|
1297
|
+
# Corresponds to the JSON property `sources`
|
1298
|
+
# @return [Array<Google::Apis::CloudassetV1p1beta1::GoogleIdentityAccesscontextmanagerV1IngressSource>]
|
1299
|
+
attr_accessor :sources
|
1300
|
+
|
1301
|
+
def initialize(**args)
|
1302
|
+
update!(**args)
|
1303
|
+
end
|
1304
|
+
|
1305
|
+
# Update properties of this object
|
1306
|
+
def update!(**args)
|
1307
|
+
@identities = args[:identities] if args.key?(:identities)
|
1308
|
+
@identity_type = args[:identity_type] if args.key?(:identity_type)
|
1309
|
+
@sources = args[:sources] if args.key?(:sources)
|
1310
|
+
end
|
1311
|
+
end
|
1312
|
+
|
1313
|
+
# Policy for ingress into ServicePerimeter. IngressPolicies match requests based
|
1314
|
+
# on `ingress_from` and `ingress_to` stanzas. For an ingress policy to match,
|
1315
|
+
# both the `ingress_from` and `ingress_to` stanzas must be matched. If an
|
1316
|
+
# IngressPolicy matches a request, the request is allowed through the perimeter
|
1317
|
+
# boundary from outside the perimeter. For example, access from the internet can
|
1318
|
+
# be allowed either based on an AccessLevel or, for traffic hosted on Google
|
1319
|
+
# Cloud, the project of the source network. For access from private networks,
|
1320
|
+
# using the project of the hosting network is required. Individual ingress
|
1321
|
+
# policies can be limited by restricting which services and/or actions they
|
1322
|
+
# match using the `ingress_to` field.
|
1323
|
+
class GoogleIdentityAccesscontextmanagerV1IngressPolicy
|
1324
|
+
include Google::Apis::Core::Hashable
|
1325
|
+
|
1326
|
+
# Defines the conditions under which an IngressPolicy matches a request.
|
1327
|
+
# Conditions are based on information about the source of the request.
|
1328
|
+
# Corresponds to the JSON property `ingressFrom`
|
1329
|
+
# @return [Google::Apis::CloudassetV1p1beta1::GoogleIdentityAccesscontextmanagerV1IngressFrom]
|
1330
|
+
attr_accessor :ingress_from
|
1331
|
+
|
1332
|
+
# Defines the conditions under which an IngressPolicy matches a request.
|
1333
|
+
# Conditions are based on information about the ApiOperation intended to be
|
1334
|
+
# performed on the destination of the request.
|
1335
|
+
# Corresponds to the JSON property `ingressTo`
|
1336
|
+
# @return [Google::Apis::CloudassetV1p1beta1::GoogleIdentityAccesscontextmanagerV1IngressTo]
|
1337
|
+
attr_accessor :ingress_to
|
1338
|
+
|
1339
|
+
def initialize(**args)
|
1340
|
+
update!(**args)
|
1341
|
+
end
|
1342
|
+
|
1343
|
+
# Update properties of this object
|
1344
|
+
def update!(**args)
|
1345
|
+
@ingress_from = args[:ingress_from] if args.key?(:ingress_from)
|
1346
|
+
@ingress_to = args[:ingress_to] if args.key?(:ingress_to)
|
1347
|
+
end
|
1348
|
+
end
|
1349
|
+
|
1350
|
+
# The source that IngressPolicy authorizes access from.
|
1351
|
+
class GoogleIdentityAccesscontextmanagerV1IngressSource
|
1352
|
+
include Google::Apis::Core::Hashable
|
1353
|
+
|
1354
|
+
# An AccessLevel resource name that allow resources within the ServicePerimeters
|
1355
|
+
# to be accessed from the internet. AccessLevels listed must be in the same
|
1356
|
+
# policy as this ServicePerimeter. Referencing a nonexistent AccessLevel will
|
1357
|
+
# cause an error. If no AccessLevel names are listed, resources within the
|
1358
|
+
# perimeter can only be accessed via Google Cloud calls with request origins
|
1359
|
+
# within the perimeter. Example: `accessPolicies/MY_POLICY/accessLevels/MY_LEVEL`
|
1360
|
+
# . If `*` is specified, then all IngressSources will be allowed.
|
1361
|
+
# Corresponds to the JSON property `accessLevel`
|
1362
|
+
# @return [String]
|
1363
|
+
attr_accessor :access_level
|
1364
|
+
|
1365
|
+
# A Google Cloud resource that is allowed to ingress the perimeter. Requests
|
1366
|
+
# from these resources will be allowed to access perimeter data. Currently only
|
1367
|
+
# projects are allowed. Format: `projects/`project_number`` The project may be
|
1368
|
+
# in any Google Cloud organization, not just the organization that the perimeter
|
1369
|
+
# is defined in. `*` is not allowed, the case of allowing all Google Cloud
|
1370
|
+
# resources only is not supported.
|
1371
|
+
# Corresponds to the JSON property `resource`
|
1372
|
+
# @return [String]
|
1373
|
+
attr_accessor :resource
|
1374
|
+
|
1375
|
+
def initialize(**args)
|
1376
|
+
update!(**args)
|
1377
|
+
end
|
1378
|
+
|
1379
|
+
# Update properties of this object
|
1380
|
+
def update!(**args)
|
1381
|
+
@access_level = args[:access_level] if args.key?(:access_level)
|
1382
|
+
@resource = args[:resource] if args.key?(:resource)
|
1383
|
+
end
|
1384
|
+
end
|
1385
|
+
|
1386
|
+
# Defines the conditions under which an IngressPolicy matches a request.
|
1387
|
+
# Conditions are based on information about the ApiOperation intended to be
|
1388
|
+
# performed on the destination of the request.
|
1389
|
+
class GoogleIdentityAccesscontextmanagerV1IngressTo
|
1390
|
+
include Google::Apis::Core::Hashable
|
1391
|
+
|
1392
|
+
# A list of ApiOperations the sources specified in corresponding IngressFrom are
|
1393
|
+
# allowed to perform in this ServicePerimeter.
|
1394
|
+
# Corresponds to the JSON property `operations`
|
1395
|
+
# @return [Array<Google::Apis::CloudassetV1p1beta1::GoogleIdentityAccesscontextmanagerV1ApiOperation>]
|
1396
|
+
attr_accessor :operations
|
1397
|
+
|
1398
|
+
# A list of resources, currently only projects in the form `projects/`,
|
1399
|
+
# protected by this ServicePerimeter that are allowed to be accessed by sources
|
1400
|
+
# defined in the corresponding IngressFrom. A request matches if it contains a
|
1401
|
+
# resource in this list. If `*` is specified for resources, then this IngressTo
|
1402
|
+
# rule will authorize access to all resources inside the perimeter, provided
|
1403
|
+
# that the request also matches the `operations` field.
|
1404
|
+
# Corresponds to the JSON property `resources`
|
1405
|
+
# @return [Array<String>]
|
1406
|
+
attr_accessor :resources
|
1407
|
+
|
1408
|
+
def initialize(**args)
|
1409
|
+
update!(**args)
|
1410
|
+
end
|
1411
|
+
|
1412
|
+
# Update properties of this object
|
1413
|
+
def update!(**args)
|
1414
|
+
@operations = args[:operations] if args.key?(:operations)
|
1415
|
+
@resources = args[:resources] if args.key?(:resources)
|
1416
|
+
end
|
1417
|
+
end
|
1418
|
+
|
1419
|
+
# An allowed method or permission of a service specified in ApiOperation.
|
1420
|
+
class GoogleIdentityAccesscontextmanagerV1MethodSelector
|
1421
|
+
include Google::Apis::Core::Hashable
|
1422
|
+
|
1423
|
+
# Value for `method` should be a valid method name for the corresponding `
|
1424
|
+
# service_name` in ApiOperation. If `*` used as value for `method`, then ALL
|
1425
|
+
# methods and permissions are allowed.
|
1426
|
+
# Corresponds to the JSON property `method`
|
1427
|
+
# @return [String]
|
1428
|
+
attr_accessor :method_prop
|
1429
|
+
|
1430
|
+
# Value for `permission` should be a valid Cloud IAM permission for the
|
1431
|
+
# corresponding `service_name` in ApiOperation.
|
1432
|
+
# Corresponds to the JSON property `permission`
|
1433
|
+
# @return [String]
|
1434
|
+
attr_accessor :permission
|
1435
|
+
|
1436
|
+
def initialize(**args)
|
1437
|
+
update!(**args)
|
1438
|
+
end
|
1439
|
+
|
1440
|
+
# Update properties of this object
|
1441
|
+
def update!(**args)
|
1442
|
+
@method_prop = args[:method_prop] if args.key?(:method_prop)
|
1443
|
+
@permission = args[:permission] if args.key?(:permission)
|
1444
|
+
end
|
1445
|
+
end
|
1446
|
+
|
1447
|
+
# A restriction on the OS type and version of devices making requests.
|
1448
|
+
class GoogleIdentityAccesscontextmanagerV1OsConstraint
|
1449
|
+
include Google::Apis::Core::Hashable
|
1450
|
+
|
1451
|
+
# The minimum allowed OS version. If not set, any version of this OS satisfies
|
1452
|
+
# the constraint. Format: `"major.minor.patch"`. Examples: `"10.5.301"`, `"9.2.1"
|
1453
|
+
# `.
|
1454
|
+
# Corresponds to the JSON property `minimumVersion`
|
1455
|
+
# @return [String]
|
1456
|
+
attr_accessor :minimum_version
|
1457
|
+
|
1458
|
+
# Required. The allowed OS type.
|
1459
|
+
# Corresponds to the JSON property `osType`
|
1460
|
+
# @return [String]
|
1461
|
+
attr_accessor :os_type
|
1462
|
+
|
1463
|
+
# Only allows requests from devices with a verified Chrome OS. Verifications
|
1464
|
+
# includes requirements that the device is enterprise-managed, conformant to
|
1465
|
+
# domain policies, and the caller has permission to call the API targeted by the
|
1466
|
+
# request.
|
1467
|
+
# Corresponds to the JSON property `requireVerifiedChromeOs`
|
1468
|
+
# @return [Boolean]
|
1469
|
+
attr_accessor :require_verified_chrome_os
|
1470
|
+
alias_method :require_verified_chrome_os?, :require_verified_chrome_os
|
1471
|
+
|
1472
|
+
def initialize(**args)
|
1473
|
+
update!(**args)
|
1474
|
+
end
|
1475
|
+
|
1476
|
+
# Update properties of this object
|
1477
|
+
def update!(**args)
|
1478
|
+
@minimum_version = args[:minimum_version] if args.key?(:minimum_version)
|
1479
|
+
@os_type = args[:os_type] if args.key?(:os_type)
|
1480
|
+
@require_verified_chrome_os = args[:require_verified_chrome_os] if args.key?(:require_verified_chrome_os)
|
1481
|
+
end
|
1482
|
+
end
|
1483
|
+
|
1484
|
+
# `ServicePerimeter` describes a set of Google Cloud resources which can freely
|
1485
|
+
# import and export data amongst themselves, but not export outside of the `
|
1486
|
+
# ServicePerimeter`. If a request with a source within this `ServicePerimeter`
|
1487
|
+
# has a target outside of the `ServicePerimeter`, the request will be blocked.
|
1488
|
+
# Otherwise the request is allowed. There are two types of Service Perimeter -
|
1489
|
+
# Regular and Bridge. Regular Service Perimeters cannot overlap, a single Google
|
1490
|
+
# Cloud project can only belong to a single regular Service Perimeter. Service
|
1491
|
+
# Perimeter Bridges can contain only Google Cloud projects as members, a single
|
1492
|
+
# Google Cloud project may belong to multiple Service Perimeter Bridges.
|
1493
|
+
class GoogleIdentityAccesscontextmanagerV1ServicePerimeter
|
1494
|
+
include Google::Apis::Core::Hashable
|
1495
|
+
|
1496
|
+
# Description of the `ServicePerimeter` and its use. Does not affect behavior.
|
1497
|
+
# Corresponds to the JSON property `description`
|
1498
|
+
# @return [String]
|
1499
|
+
attr_accessor :description
|
1500
|
+
|
1501
|
+
# Required. Resource name for the ServicePerimeter. The `short_name` component
|
1502
|
+
# must begin with a letter and only include alphanumeric and '_'. Format: `
|
1503
|
+
# accessPolicies/`policy_id`/servicePerimeters/`short_name``
|
1504
|
+
# Corresponds to the JSON property `name`
|
1505
|
+
# @return [String]
|
1506
|
+
attr_accessor :name
|
1507
|
+
|
1508
|
+
# Perimeter type indicator. A single project is allowed to be a member of single
|
1509
|
+
# regular perimeter, but multiple service perimeter bridges. A project cannot be
|
1510
|
+
# a included in a perimeter bridge without being included in regular perimeter.
|
1511
|
+
# For perimeter bridges, the restricted service list as well as access level
|
1512
|
+
# lists must be empty.
|
1513
|
+
# Corresponds to the JSON property `perimeterType`
|
1514
|
+
# @return [String]
|
1515
|
+
attr_accessor :perimeter_type
|
1516
|
+
|
1517
|
+
# `ServicePerimeterConfig` specifies a set of Google Cloud resources that
|
1518
|
+
# describe specific Service Perimeter configuration.
|
1519
|
+
# Corresponds to the JSON property `spec`
|
1520
|
+
# @return [Google::Apis::CloudassetV1p1beta1::GoogleIdentityAccesscontextmanagerV1ServicePerimeterConfig]
|
1521
|
+
attr_accessor :spec
|
1522
|
+
|
1523
|
+
# `ServicePerimeterConfig` specifies a set of Google Cloud resources that
|
1524
|
+
# describe specific Service Perimeter configuration.
|
1525
|
+
# Corresponds to the JSON property `status`
|
1526
|
+
# @return [Google::Apis::CloudassetV1p1beta1::GoogleIdentityAccesscontextmanagerV1ServicePerimeterConfig]
|
1527
|
+
attr_accessor :status
|
1528
|
+
|
1529
|
+
# Human readable title. Must be unique within the Policy.
|
1530
|
+
# Corresponds to the JSON property `title`
|
1531
|
+
# @return [String]
|
1532
|
+
attr_accessor :title
|
1533
|
+
|
1534
|
+
# Use explicit dry run spec flag. Ordinarily, a dry-run spec implicitly exists
|
1535
|
+
# for all Service Perimeters, and that spec is identical to the status for those
|
1536
|
+
# Service Perimeters. When this flag is set, it inhibits the generation of the
|
1537
|
+
# implicit spec, thereby allowing the user to explicitly provide a configuration
|
1538
|
+
# ("spec") to use in a dry-run version of the Service Perimeter. This allows the
|
1539
|
+
# user to test changes to the enforced config ("status") without actually
|
1540
|
+
# enforcing them. This testing is done through analyzing the differences between
|
1541
|
+
# currently enforced and suggested restrictions. use_explicit_dry_run_spec must
|
1542
|
+
# bet set to True if any of the fields in the spec are set to non-default values.
|
1543
|
+
# Corresponds to the JSON property `useExplicitDryRunSpec`
|
1544
|
+
# @return [Boolean]
|
1545
|
+
attr_accessor :use_explicit_dry_run_spec
|
1546
|
+
alias_method :use_explicit_dry_run_spec?, :use_explicit_dry_run_spec
|
1547
|
+
|
1548
|
+
def initialize(**args)
|
1549
|
+
update!(**args)
|
1550
|
+
end
|
1551
|
+
|
1552
|
+
# Update properties of this object
|
1553
|
+
def update!(**args)
|
1554
|
+
@description = args[:description] if args.key?(:description)
|
1555
|
+
@name = args[:name] if args.key?(:name)
|
1556
|
+
@perimeter_type = args[:perimeter_type] if args.key?(:perimeter_type)
|
1557
|
+
@spec = args[:spec] if args.key?(:spec)
|
1558
|
+
@status = args[:status] if args.key?(:status)
|
1559
|
+
@title = args[:title] if args.key?(:title)
|
1560
|
+
@use_explicit_dry_run_spec = args[:use_explicit_dry_run_spec] if args.key?(:use_explicit_dry_run_spec)
|
1561
|
+
end
|
1562
|
+
end
|
1563
|
+
|
1564
|
+
# `ServicePerimeterConfig` specifies a set of Google Cloud resources that
|
1565
|
+
# describe specific Service Perimeter configuration.
|
1566
|
+
class GoogleIdentityAccesscontextmanagerV1ServicePerimeterConfig
|
1567
|
+
include Google::Apis::Core::Hashable
|
1568
|
+
|
1569
|
+
# A list of `AccessLevel` resource names that allow resources within the `
|
1570
|
+
# ServicePerimeter` to be accessed from the internet. `AccessLevels` listed must
|
1571
|
+
# be in the same policy as this `ServicePerimeter`. Referencing a nonexistent `
|
1572
|
+
# AccessLevel` is a syntax error. If no `AccessLevel` names are listed,
|
1573
|
+
# resources within the perimeter can only be accessed via Google Cloud calls
|
1574
|
+
# with request origins within the perimeter. Example: `"accessPolicies/MY_POLICY/
|
1575
|
+
# accessLevels/MY_LEVEL"`. For Service Perimeter Bridge, must be empty.
|
1576
|
+
# Corresponds to the JSON property `accessLevels`
|
1577
|
+
# @return [Array<String>]
|
1578
|
+
attr_accessor :access_levels
|
1579
|
+
|
1580
|
+
# List of EgressPolicies to apply to the perimeter. A perimeter may have
|
1581
|
+
# multiple EgressPolicies, each of which is evaluated separately. Access is
|
1582
|
+
# granted if any EgressPolicy grants it. Must be empty for a perimeter bridge.
|
1583
|
+
# Corresponds to the JSON property `egressPolicies`
|
1584
|
+
# @return [Array<Google::Apis::CloudassetV1p1beta1::GoogleIdentityAccesscontextmanagerV1EgressPolicy>]
|
1585
|
+
attr_accessor :egress_policies
|
1586
|
+
|
1587
|
+
# List of IngressPolicies to apply to the perimeter. A perimeter may have
|
1588
|
+
# multiple IngressPolicies, each of which is evaluated separately. Access is
|
1589
|
+
# granted if any Ingress Policy grants it. Must be empty for a perimeter bridge.
|
1590
|
+
# Corresponds to the JSON property `ingressPolicies`
|
1591
|
+
# @return [Array<Google::Apis::CloudassetV1p1beta1::GoogleIdentityAccesscontextmanagerV1IngressPolicy>]
|
1592
|
+
attr_accessor :ingress_policies
|
1593
|
+
|
1594
|
+
# A list of Google Cloud resources that are inside of the service perimeter.
|
1595
|
+
# Currently only projects are allowed. Format: `projects/`project_number``
|
1596
|
+
# Corresponds to the JSON property `resources`
|
1597
|
+
# @return [Array<String>]
|
1598
|
+
attr_accessor :resources
|
1599
|
+
|
1600
|
+
# Google Cloud services that are subject to the Service Perimeter restrictions.
|
1601
|
+
# For example, if `storage.googleapis.com` is specified, access to the storage
|
1602
|
+
# buckets inside the perimeter must meet the perimeter's access restrictions.
|
1603
|
+
# Corresponds to the JSON property `restrictedServices`
|
1604
|
+
# @return [Array<String>]
|
1605
|
+
attr_accessor :restricted_services
|
1606
|
+
|
1607
|
+
# Specifies how APIs are allowed to communicate within the Service Perimeter.
|
1608
|
+
# Corresponds to the JSON property `vpcAccessibleServices`
|
1609
|
+
# @return [Google::Apis::CloudassetV1p1beta1::GoogleIdentityAccesscontextmanagerV1VpcAccessibleServices]
|
1610
|
+
attr_accessor :vpc_accessible_services
|
1611
|
+
|
1612
|
+
def initialize(**args)
|
1613
|
+
update!(**args)
|
1614
|
+
end
|
1615
|
+
|
1616
|
+
# Update properties of this object
|
1617
|
+
def update!(**args)
|
1618
|
+
@access_levels = args[:access_levels] if args.key?(:access_levels)
|
1619
|
+
@egress_policies = args[:egress_policies] if args.key?(:egress_policies)
|
1620
|
+
@ingress_policies = args[:ingress_policies] if args.key?(:ingress_policies)
|
1621
|
+
@resources = args[:resources] if args.key?(:resources)
|
1622
|
+
@restricted_services = args[:restricted_services] if args.key?(:restricted_services)
|
1623
|
+
@vpc_accessible_services = args[:vpc_accessible_services] if args.key?(:vpc_accessible_services)
|
1624
|
+
end
|
1625
|
+
end
|
1626
|
+
|
1627
|
+
# Specifies how APIs are allowed to communicate within the Service Perimeter.
|
1628
|
+
class GoogleIdentityAccesscontextmanagerV1VpcAccessibleServices
|
1629
|
+
include Google::Apis::Core::Hashable
|
1630
|
+
|
1631
|
+
# The list of APIs usable within the Service Perimeter. Must be empty unless '
|
1632
|
+
# enable_restriction' is True. You can specify a list of individual services, as
|
1633
|
+
# well as include the 'RESTRICTED-SERVICES' value, which automatically includes
|
1634
|
+
# all of the services protected by the perimeter.
|
1635
|
+
# Corresponds to the JSON property `allowedServices`
|
1636
|
+
# @return [Array<String>]
|
1637
|
+
attr_accessor :allowed_services
|
1638
|
+
|
1639
|
+
# Whether to restrict API calls within the Service Perimeter to the list of APIs
|
1640
|
+
# specified in 'allowed_services'.
|
1641
|
+
# Corresponds to the JSON property `enableRestriction`
|
1642
|
+
# @return [Boolean]
|
1643
|
+
attr_accessor :enable_restriction
|
1644
|
+
alias_method :enable_restriction?, :enable_restriction
|
1645
|
+
|
1646
|
+
def initialize(**args)
|
1647
|
+
update!(**args)
|
1648
|
+
end
|
1649
|
+
|
1650
|
+
# Update properties of this object
|
1651
|
+
def update!(**args)
|
1652
|
+
@allowed_services = args[:allowed_services] if args.key?(:allowed_services)
|
1653
|
+
@enable_restriction = args[:enable_restriction] if args.key?(:enable_restriction)
|
1654
|
+
end
|
1655
|
+
end
|
1656
|
+
|
244
1657
|
# The result for a IAM Policy search.
|
245
1658
|
class IamPolicySearchResult
|
246
1659
|
include Google::Apis::Core::Hashable
|