Google Cloud Network Security V1beta1 Client - Class AuthorizationPolicy (0.4.1)

Reference documentation and code samples for the Google Cloud Network Security V1beta1 Client class AuthorizationPolicy.

AuthorizationPolicy is a resource that specifies how a server should authorize incoming connections. This resource in itself does not change the configuration unless it's attached to a target https proxy or endpoint config selector resource.

Generated from protobuf message google.cloud.networksecurity.v1beta1.AuthorizationPolicy

Namespace

Google \ Cloud \ NetworkSecurity \ V1beta1

Methods

__construct

Constructor.

Parameters
NameDescription
data array

Optional. Data for populating the Message object.

↳ name string

Required. Name of the AuthorizationPolicy resource. It matches pattern projects/{project}/locations/{location}/authorizationPolicies/<authorization_policy>.

↳ description string

Optional. Free-text description of the resource.

↳ create_time Google\Protobuf\Timestamp

Output only. The timestamp when the resource was created.

↳ update_time Google\Protobuf\Timestamp

Output only. The timestamp when the resource was updated.

↳ labels array|Google\Protobuf\Internal\MapField

Optional. Set of label tags associated with the AuthorizationPolicy resource.

↳ action int

Required. The action to take when a rule match is found. Possible values are "ALLOW" or "DENY".

↳ rules array<Google\Cloud\NetworkSecurity\V1beta1\AuthorizationPolicy\Rule>

Optional. List of rules to match. Note that at least one of the rules must match in order for the action specified in the 'action' field to be taken. A rule is a match if there is a matching source and destination. If left blank, the action specified in the action field will be applied on every request.

getName

Required. Name of the AuthorizationPolicy resource. It matches pattern projects/{project}/locations/{location}/authorizationPolicies/<authorization_policy>.

Returns
TypeDescription
string

setName

Required. Name of the AuthorizationPolicy resource. It matches pattern projects/{project}/locations/{location}/authorizationPolicies/<authorization_policy>.

Parameter
NameDescription
var string
Returns
TypeDescription
$this

getDescription

Optional. Free-text description of the resource.

Returns
TypeDescription
string

setDescription

Optional. Free-text description of the resource.

Parameter
NameDescription
var string
Returns
TypeDescription
$this

getCreateTime

Output only. The timestamp when the resource was created.

Returns
TypeDescription
Google\Protobuf\Timestamp|null

hasCreateTime

clearCreateTime

setCreateTime

Output only. The timestamp when the resource was created.

Parameter
NameDescription
var Google\Protobuf\Timestamp
Returns
TypeDescription
$this

getUpdateTime

Output only. The timestamp when the resource was updated.

Returns
TypeDescription
Google\Protobuf\Timestamp|null

hasUpdateTime

clearUpdateTime

setUpdateTime

Output only. The timestamp when the resource was updated.

Parameter
NameDescription
var Google\Protobuf\Timestamp
Returns
TypeDescription
$this

getLabels

Optional. Set of label tags associated with the AuthorizationPolicy resource.

Returns
TypeDescription
Google\Protobuf\Internal\MapField

setLabels

Optional. Set of label tags associated with the AuthorizationPolicy resource.

Parameter
NameDescription
var array|Google\Protobuf\Internal\MapField
Returns
TypeDescription
$this

getAction

Required. The action to take when a rule match is found. Possible values are "ALLOW" or "DENY".

Returns
TypeDescription
int

setAction

Required. The action to take when a rule match is found. Possible values are "ALLOW" or "DENY".

Parameter
NameDescription
var int
Returns
TypeDescription
$this

getRules

Optional. List of rules to match. Note that at least one of the rules must match in order for the action specified in the 'action' field to be taken.

A rule is a match if there is a matching source and destination. If left blank, the action specified in the action field will be applied on every request.

Returns
TypeDescription
Google\Protobuf\Internal\RepeatedField

setRules

Optional. List of rules to match. Note that at least one of the rules must match in order for the action specified in the 'action' field to be taken.

A rule is a match if there is a matching source and destination. If left blank, the action specified in the action field will be applied on every request.

Parameter
NameDescription
var array<Google\Cloud\NetworkSecurity\V1beta1\AuthorizationPolicy\Rule>
Returns
TypeDescription
$this