- Resource: NetworkPolicy
- TrafficClassificationRule
- Matcher
- Layer4Config
- Action
- TrafficClass
- DscpMode
- SecureTag
- State
- Association
- Methods
Resource: NetworkPolicy
Represents a Network Policy resource.
| JSON representation |
|---|
{ "kind": string, "id": string, "creationTimestamp": string, "name": string, "description": string, "trafficClassificationRules": [ { object ( |
| Fields | |
|---|---|
kind |
Output only. Type of the resource. Always
for network policies |
id |
Output only. The unique identifier for the resource. This identifier is defined by the server. |
creationTimestamp |
Output only. Creation timestamp in RFC3339 text format. |
name |
Name of the resource. |
description |
An optional description of this resource. Provide this property when you create the resource. |
trafficClassificationRules[] |
Output only. A list of traffic classification rules that belong to this policy. |
selfLink |
Output only. Server-defined URL for the resource. |
selfLinkWithId |
Output only. Server-defined URL for this resource with the resource id. |
associations[] |
Output only. A list of associations that belong to this network policy. |
ruleTupleCount |
Output only. Total count of all network policy rule tuples. A network policy can not exceed a set number of tuples. |
region |
Output only. URL of the region where the regional network policy resides. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body. |
TrafficClassificationRule
Represents a traffic classification rule that describes one or more match conditions along with the action to be taken when traffic matches this condition.
| JSON representation |
|---|
{ "kind": string, "ruleName": string, "description": string, "priority": integer, "match": { object ( |
| Fields | |
|---|---|
kind |
Output only. Type of the resource. Always
for network policy traffic classification rules |
ruleName |
An optional name for the rule. This field is not a unique identifier and can be updated. |
description |
An optional description for this resource. |
priority |
An integer indicating the priority of a rule in the list. The priority must be a positive value between 1 and 2147482647. The priority values from 2147482648 to 2147483647 (1000) are reserved for system default network policy rules. Rules are evaluated from highest to lowest priority where 1 is the highest priority and 2147483647 is the lowest priority. |
match |
A match condition that outgoing traffic is evaluated against. If it evaluates to true, the corresponding 'action' is enforced. |
action |
The Action to perform when the client connection triggers the rule. |
ruleTupleCount |
Output only. Calculation of the complexity of a single network policy rule. |
targetServiceAccounts[] |
A list of service accounts indicating the sets of instances that are applied with this rule. |
targetSecureTags[] |
A list of secure tags that controls which instances the traffic classification rule applies to. If
are specified, then the traffic classification rule applies only to instances in the VPC network that have one of those EFFECTIVE secure tags, if all the
are in INEFFECTIVE state, then this rule will be ignored.
may not be set at the same time as
. If neither
nor
are specified, the traffic classification rule applies to all instances on the specified network. Maximum number of target label tags allowed is 256. |
disabled |
Denotes whether the network policy rule is disabled. When set to true, the network policy rule is not enforced and traffic behaves as if it did not exist. If this is unspecified, the network policy rule will be enabled. |
Matcher
Represents a match condition that incoming traffic is evaluated against. Exactly one field must be specified.
| JSON representation |
|---|
{
"srcIpRanges": [
string
],
"destIpRanges": [
string
],
"layer4Configs": [
{
object ( |
| Fields | |
|---|---|
srcIpRanges[] |
CIDR IP address range. Maximum number of source CIDR IP ranges allowed is 5000. |
destIpRanges[] |
CIDR IP address range. Maximum number of destination CIDR IP ranges allowed is 5000. |
layer4Configs[] |
Pairs of IP protocols and ports that the rule should match. |
Layer4Config
| JSON representation |
|---|
{ "ipProtocol": string, "ports": [ string ] } |
| Fields | |
|---|---|
ipProtocol |
The IP protocol to which this rule applies. The protocol type is required when creating a traffic classification rule. This value can either be one of the following well known protocol strings (
,
,
,
,
,
,
), or the IP protocol number. |
ports[] |
An optional list of ports to which this rule applies. This field is only applicable for UDP, TCP or SCTP protocol. Each entry must be either an integer or a range. If not specified, this rule applies to connections through any port. Example inputs include:
,
, and
. |
Action
| JSON representation |
|---|
{ "type": string, "trafficClass": enum ( |
| Fields | |
|---|---|
type |
Always "apply_traffic_classification" for traffic classification rules. |
trafficClass |
The traffic class that should be applied to the matching packet. |
dscpMode |
DSCP mode. When set to
, the DSCP value will be picked automatically based on selected
. Otherwise,
needs to be explicitly specified. |
dscpValue |
Custom DSCP value from 0-63 range. |
TrafficClass
Enum representing the various traffic classes offered by AAI.
| Enums | |
|---|---|
TC1 |
Traffic Class 1, corresponding to DSCP ranges (0-7) 000xxx. |
TC2 |
Traffic Class 2, corresponding to DSCP ranges (8-15) 001xxx. |
TC3 |
Traffic Class 3, corresponding to DSCP ranges (16-23) 010xxx. |
TC4 |
Traffic Class 4, corresponding to DSCP ranges (24-31) 011xxx. |
TC5 |
Traffic Class 5, corresponding to DSCP ranges (32-47) 10xxxx. |
TC6 |
Traffic Class 6, corresponding to DSCP ranges (48-63) 11xxxx. |
DscpMode
Enum representing the DSCP mode.
| Enums | |
|---|---|
AUTO |
DSCP value will be automatically picked up based on configured trafficClass. |
CUSTOM |
Allows to specify custom DSCP value from selected trafficClass range. |
SecureTag
| JSON representation |
|---|
{
"name": string,
"state": enum ( |
| Fields | |
|---|---|
name |
Name of the secure tag, created with TagManager's TagValue API. |
state |
Output only. State of the secure tag, either |
State
| Enums | |
|---|---|
STATE_UNSPECIFIED |
|
EFFECTIVE |
|
INEFFECTIVE |
|
Association
| JSON representation |
|---|
{ "name": string, "attachmentTarget": string } |
| Fields | |
|---|---|
name |
The name for an association. |
attachmentTarget |
The target that the network policy is attached to. |
Methods |
|
|---|---|
|
The method compute.beta.RegionNetworkPoliciesService.AddAssociation is not available in Cloud de Confiance by S3NS. |
|
The method compute.beta.RegionNetworkPoliciesService.AddTrafficClassificationRule is not available in Cloud de Confiance by S3NS. |
|
The method compute.beta.RegionNetworkPoliciesService.AggregatedList is not available in Cloud de Confiance by S3NS. |
|
The method compute.beta.RegionNetworkPoliciesService.Delete is not available in Cloud de Confiance by S3NS. |
|
The method compute.beta.RegionNetworkPoliciesService.Get is not available in Cloud de Confiance by S3NS. |
|
The method compute.beta.RegionNetworkPoliciesService.GetAssociation is not available in Cloud de Confiance by S3NS. |
|
The method compute.beta.RegionNetworkPoliciesService.GetTrafficClassificationRule is not available in Cloud de Confiance by S3NS. |
|
The method compute.beta.RegionNetworkPoliciesService.Insert is not available in Cloud de Confiance by S3NS. |
|
The method compute.beta.RegionNetworkPoliciesService.List is not available in Cloud de Confiance by S3NS. |
|
The method compute.beta.RegionNetworkPoliciesService.Patch is not available in Cloud de Confiance by S3NS. |
|
The method compute.beta.RegionNetworkPoliciesService.PatchTrafficClassificationRule is not available in Cloud de Confiance by S3NS. |
|
The method compute.beta.RegionNetworkPoliciesService.RemoveAssociation is not available in Cloud de Confiance by S3NS. |
|
The method compute.beta.RegionNetworkPoliciesService.RemoveTrafficClassificationRule is not available in Cloud de Confiance by S3NS. |