Class: Google::Apis::AccesscontextmanagerV1::Principal

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/accesscontextmanager_v1/classes.rb,
lib/google/apis/accesscontextmanager_v1/representations.rb,
lib/google/apis/accesscontextmanager_v1/representations.rb

Overview

The comprehensive identity container supporting identities including groups, service accounts, and federated identities. Only one of them can be set to create an access binding.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Principal

Returns a new instance of Principal.



1880
1881
1882
# File 'lib/google/apis/accesscontextmanager_v1/classes.rb', line 1880

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#federated_principalString

Immutable. IAM federated principal name to assign policies to workforce/ workload federated identities. Can be principal set or single principal, here are some examples: Single principal: principal://iam.googleapis.com/projects/ project_number/locations/global/workloadIdentityPools/pool_id/subject/ subject_attribute_value PrincipalSet: principalSet://iam.googleapis.com/ projects/project_number/locations/global/workloadIdentityPools/pool_id/* Corresponds to the JSON property federatedPrincipal

Returns:

  • (String)


1862
1863
1864
# File 'lib/google/apis/accesscontextmanager_v1/classes.rb', line 1862

def federated_principal
  @federated_principal
end

#service_accountString

Immutable. Service account email used to assign policies to a specific service account. If a service account is subject to multiple policies (e.g., if there is a policy for all service accounts in a project and a policy for the service account), the closest (i.e. the most specific) dry-run policy will be used for the dry-run functionality and the closest enforcement policy will be used for the enforcement. Corresponds to the JSON property serviceAccount

Returns:

  • (String)


1872
1873
1874
# File 'lib/google/apis/accesscontextmanager_v1/classes.rb', line 1872

def 
  @service_account
end

#service_account_project_numberString

Immutable. Cloud project number used to assign policies to all service accounts owned by the project. Corresponds to the JSON property serviceAccountProjectNumber

Returns:

  • (String)


1878
1879
1880
# File 'lib/google/apis/accesscontextmanager_v1/classes.rb', line 1878

def 
  @service_account_project_number
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1885
1886
1887
1888
1889
# File 'lib/google/apis/accesscontextmanager_v1/classes.rb', line 1885

def update!(**args)
  @federated_principal = args[:federated_principal] if args.key?(:federated_principal)
  @service_account = args[:service_account] if args.key?(:service_account)
  @service_account_project_number = args[:service_account_project_number] if args.key?(:service_account_project_number)
end