NAME

Google::Cloud::Securityposture::V1::OrgPolicyConfig - Compiled Protocol Buffers messages for google/cloud/securityposture/v1/org_policy_config.proto

SYNOPSIS

use Google::Cloud::Securityposture::V1::OrgPolicyConfig;

my $msg = Google::Cloud::Securityposture::V1::OrgPolicyConfig::PolicyRule->new({
    values => $values,
    allow_all => $allow_all,
    deny_all => $deny_all,
    enforce => $enforce,
});

# Read or update a field
my $val = $msg->values();

# Binary wire-format roundtrip
my $bytes   = $msg->serialize();
my $decoded = Google::Cloud::Securityposture::V1::OrgPolicyConfig::PolicyRule->parse($bytes);

# Canonical ProtoJSON
my $json = $msg->to_json();

DESCRIPTION

Auto-generated Protobuf message classes compiled from google/cloud/securityposture/v1/org_policy_config.proto. All message classes inherit from Protobuf::Message and support new(), serialize(), parse(), to_json(), from_json(), to_text(), and to_perl().

MESSAGES

Google::Cloud::Securityposture::V1::OrgPolicyConfig::PolicyRule

A rule used to express this policy.

Inherits from Protobuf::Message.

Accessors

  • $msg->values() / $msg->values($value)

    Type: Message (Google::Cloud::Securityposture::V1::OrgPolicyConfig::PolicyRule::StringValues)

    List of values to be used for this policy rule. This field can be set only in policies for list constraints.

  • $msg->allow_all() / $msg->allow_all($value)

    Type: Bool

    Setting this to true means that all values are allowed. This field can be set only in policies for list constraints.

  • $msg->deny_all() / $msg->deny_all($value)

    Type: Bool

    Setting this to true means that all values are denied. This field can be set only in policies for list constraints.

  • $msg->enforce() / $msg->enforce($value)

    Type: Bool

    If `true`, then the policy is enforced. If `false`, then any configuration is acceptable. This field can be set only in policies for boolean constraints.

  • $msg->condition() / $msg->condition($value)

    Type: Message (Google::Type::Expr::Expr)

    A condition which determines whether this rule is used in the evaluation of the policy. When set, the `expression` field in the `Expr' must include from 1 to 10 subexpressions, joined by the "||" or "&&" operators. Each subexpression must be of the form "resource.matchTag('<ORG_ID>/tag_key_short_name, 'tag_value_short_name')" or "resource.matchTagId('tagKeys/key_id', 'tagValues/value_id')" where key_name and value_name are the resource names for Label Keys and Values. These names are available from the Tag Manager Service. An example expression is: "resource.matchTag('123456789/environment, 'prod')" or "resource.matchTagId('tagKeys/123', 'tagValues/456')".

Google::Cloud::Securityposture::V1::OrgPolicyConfig::CustomConstraint

A custom constraint defined by customers which can *only* be applied to the given resource types and organization.

By creating a custom constraint, customers can apply policies of this custom constraint. *Creating a custom constraint itself does NOT apply any policy enforcement*.

Inherits from Protobuf::Message.

Accessors

  • $msg->name() / $msg->name($value)

    Type: String

    Immutable. Name of the constraint. This is unique within the organization. Format of the name should be

    - `organizations/{organization_id}/customConstraints/{custom_constraint_id}`

    Example: `organizations/123/customConstraints/custom.createOnlyE2TypeVms`

    The max length is 70 characters and the minimum length is 1. Note that the prefix `organizations/{organization_id}/customConstraints/` is not counted.

  • $msg->resource_types() / $msg->resource_types($value)

    Type: String

    Immutable. The resource instance type on which this policy applies. Format will be of the form : `<canonical service name>/<type>` Example:

    - `compute.googleapis.com/Instance`.
  • $msg->method_types() / $msg->method_types($value)

    Type: Enum (Google::Cloud::Securityposture::V1::CustomConstraint::MethodType)

    All the operations being applied for this constraint.

  • $msg->condition() / $msg->condition($value)

    Type: String

    Org policy condition/expression. For example: `resource.instanceName.matches("[production|test]_.*_(\d)+")` or, `resource.management.auto_upgrade == true`

    The max length of the condition is 1000 characters.

  • $msg->action_type() / $msg->action_type($value)

    Type: Enum (Google::Cloud::Securityposture::V1::CustomConstraint::ActionType)

    Allow or deny type.

  • $msg->display_name() / $msg->display_name($value)

    Type: String

    One line display name for the UI. The max length of the display_name is 200 characters.

  • $msg->description() / $msg->description($value)

    Type: String

    Detailed information about this custom policy constraint. The max length of the description is 2000 characters.

  • $msg->update_time() / $msg->update_time($value)

    Type: Message (Google::Protobuf::Timestamp::Timestamp)

    Output only. The last time this custom constraint was updated. This represents the last time that the `CreateCustomConstraint` or `UpdateCustomConstraint` RPC was called

Enum: CustomConstraint::MethodType

  • METHOD_TYPE_UNSPECIFIED => 0

  • CREATE => 1

  • UPDATE => 2

  • DELETE => 3

Enum: CustomConstraint::ActionType

  • ACTION_TYPE_UNSPECIFIED => 0

  • ALLOW => 1

  • DENY => 2

SEE ALSO

Protobuf, Protobuf::Message, Google::Cloud::Securityposture::V1::OrgPolicyConfig::Types, https://protobuf.dev/

LICENSE AND COPYRIGHT

Copyright (C) 2026 Google LLC

This program is released under the Apache 2.0 license.