IngressSecurityRule

class oci.core.models.IngressSecurityRule(**kwargs)

Bases: object

A rule for allowing inbound IP packets.

Attributes

SOURCE_TYPE_CIDR_BLOCK A constant which can be used with the source_type property of a IngressSecurityRule.
SOURCE_TYPE_SERVICE_CIDR_BLOCK A constant which can be used with the source_type property of a IngressSecurityRule.
description Gets the description of this IngressSecurityRule.
icmp_options Gets the icmp_options of this IngressSecurityRule.
is_stateless Gets the is_stateless of this IngressSecurityRule.
protocol [Required] Gets the protocol of this IngressSecurityRule.
source [Required] Gets the source of this IngressSecurityRule.
source_type Gets the source_type of this IngressSecurityRule.
tcp_options Gets the tcp_options of this IngressSecurityRule.
udp_options Gets the udp_options of this IngressSecurityRule.

Methods

__init__(**kwargs) Initializes a new IngressSecurityRule object with values from keyword arguments.
SOURCE_TYPE_CIDR_BLOCK = 'CIDR_BLOCK'

A constant which can be used with the source_type property of a IngressSecurityRule. This constant has a value of “CIDR_BLOCK”

SOURCE_TYPE_SERVICE_CIDR_BLOCK = 'SERVICE_CIDR_BLOCK'

A constant which can be used with the source_type property of a IngressSecurityRule. This constant has a value of “SERVICE_CIDR_BLOCK”

__init__(**kwargs)

Initializes a new IngressSecurityRule object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class):

Parameters:
  • icmp_options (oci.core.models.IcmpOptions) – The value to assign to the icmp_options property of this IngressSecurityRule.
  • is_stateless (bool) – The value to assign to the is_stateless property of this IngressSecurityRule.
  • protocol (str) – The value to assign to the protocol property of this IngressSecurityRule.
  • source (str) – The value to assign to the source property of this IngressSecurityRule.
  • source_type (str) – The value to assign to the source_type property of this IngressSecurityRule. Allowed values for this property are: “CIDR_BLOCK”, “SERVICE_CIDR_BLOCK”, ‘UNKNOWN_ENUM_VALUE’. Any unrecognized values returned by a service will be mapped to ‘UNKNOWN_ENUM_VALUE’.
  • tcp_options (oci.core.models.TcpOptions) – The value to assign to the tcp_options property of this IngressSecurityRule.
  • udp_options (oci.core.models.UdpOptions) – The value to assign to the udp_options property of this IngressSecurityRule.
  • description (str) – The value to assign to the description property of this IngressSecurityRule.
description

Gets the description of this IngressSecurityRule. An optional description of your choice for the rule.

Returns:The description of this IngressSecurityRule.
Return type:str
icmp_options

Gets the icmp_options of this IngressSecurityRule.

Returns:The icmp_options of this IngressSecurityRule.
Return type:oci.core.models.IcmpOptions
is_stateless

Gets the is_stateless of this IngressSecurityRule. A stateless rule allows traffic in one direction. Remember to add a corresponding stateless rule in the other direction if you need to support bidirectional traffic. For example, if ingress traffic allows TCP destination port 80, there should be an egress rule to allow TCP source port 80. Defaults to false, which means the rule is stateful and a corresponding rule is not necessary for bidirectional traffic.

Returns:The is_stateless of this IngressSecurityRule.
Return type:bool
protocol

[Required] Gets the protocol of this IngressSecurityRule. The transport protocol. Specify either all or an IPv4 protocol number as defined in Protocol Numbers. Options are supported only for ICMP (“1”), TCP (“6”), UDP (“17”), and ICMPv6 (“58”).

Returns:The protocol of this IngressSecurityRule.
Return type:str
source

[Required] Gets the source of this IngressSecurityRule. Conceptually, this is the range of IP addresses that a packet coming into the instance can come from.

Allowed values:

  • IP address range in CIDR notation. For example: 192.168.1.0/24 or 2001:0db8:0123:45::/56. IPv6 addressing is supported for all commercial and government regions. See IPv6 Addresses.
  • The cidrBlock value for a Service, if you’re setting up a security list rule for traffic coming from a particular Service through a service gateway. For example: oci-phx-objectstorage.
Returns:The source of this IngressSecurityRule.
Return type:str
source_type

Gets the source_type of this IngressSecurityRule. Type of source for the rule. The default is CIDR_BLOCK.

  • CIDR_BLOCK: If the rule’s source is an IP address range in CIDR notation.
  • SERVICE_CIDR_BLOCK: If the rule’s source is the cidrBlock value for a Service (the rule is for traffic coming from a particular Service through a service gateway).

Allowed values for this property are: “CIDR_BLOCK”, “SERVICE_CIDR_BLOCK”, ‘UNKNOWN_ENUM_VALUE’. Any unrecognized values returned by a service will be mapped to ‘UNKNOWN_ENUM_VALUE’.

Returns:The source_type of this IngressSecurityRule.
Return type:str
tcp_options

Gets the tcp_options of this IngressSecurityRule.

Returns:The tcp_options of this IngressSecurityRule.
Return type:oci.core.models.TcpOptions
udp_options

Gets the udp_options of this IngressSecurityRule.

Returns:The udp_options of this IngressSecurityRule.
Return type:oci.core.models.UdpOptions