amazonka-ec2-2.0: Amazon Elastic Compute Cloud SDK.
Copyright(c) 2013-2023 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellSafe-Inferred
LanguageHaskell2010

Amazonka.EC2.CreateTrafficMirrorSession

Description

Creates a Traffic Mirror session.

A Traffic Mirror session actively copies packets from a Traffic Mirror source to a Traffic Mirror target. Create a filter, and then assign it to the session to define a subset of the traffic to mirror, for example all TCP traffic.

The Traffic Mirror source and the Traffic Mirror target (monitoring appliances) can be in the same VPC, or in a different VPC connected via VPC peering or a transit gateway.

By default, no traffic is mirrored. Use CreateTrafficMirrorFilter to create filter rules that specify the traffic to mirror.

Synopsis

Creating a Request

data CreateTrafficMirrorSession Source #

See: newCreateTrafficMirrorSession smart constructor.

Constructors

CreateTrafficMirrorSession' 

Fields

  • clientToken :: Maybe Text

    Unique, case-sensitive identifier that you provide to ensure the idempotency of the request. For more information, see How to ensure idempotency.

  • description :: Maybe Text

    The description of the Traffic Mirror session.

  • dryRun :: Maybe Bool

    Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

  • packetLength :: Maybe Int

    The number of bytes in each packet to mirror. These are bytes after the VXLAN header. Do not specify this parameter when you want to mirror the entire packet. To mirror a subset of the packet, set this to the length (in bytes) that you want to mirror. For example, if you set this value to 100, then the first 100 bytes that meet the filter criteria are copied to the target.

    If you do not want to mirror the entire packet, use the PacketLength parameter to specify the number of bytes in each packet to mirror.

  • tagSpecifications :: Maybe [TagSpecification]

    The tags to assign to a Traffic Mirror session.

  • virtualNetworkId :: Maybe Int

    The VXLAN ID for the Traffic Mirror session. For more information about the VXLAN protocol, see RFC 7348. If you do not specify a VirtualNetworkId, an account-wide unique id is chosen at random.

  • networkInterfaceId :: Text

    The ID of the source network interface.

  • trafficMirrorTargetId :: Text

    The ID of the Traffic Mirror target.

  • trafficMirrorFilterId :: Text

    The ID of the Traffic Mirror filter.

  • sessionNumber :: Int

    The session number determines the order in which sessions are evaluated when an interface is used by multiple sessions. The first session with a matching filter is the one that mirrors the packets.

    Valid values are 1-32766.

Instances

Instances details
ToHeaders CreateTrafficMirrorSession Source # 
Instance details

Defined in Amazonka.EC2.CreateTrafficMirrorSession

ToPath CreateTrafficMirrorSession Source # 
Instance details

Defined in Amazonka.EC2.CreateTrafficMirrorSession

ToQuery CreateTrafficMirrorSession Source # 
Instance details

Defined in Amazonka.EC2.CreateTrafficMirrorSession

AWSRequest CreateTrafficMirrorSession Source # 
Instance details

Defined in Amazonka.EC2.CreateTrafficMirrorSession

Generic CreateTrafficMirrorSession Source # 
Instance details

Defined in Amazonka.EC2.CreateTrafficMirrorSession

Associated Types

type Rep CreateTrafficMirrorSession :: Type -> Type #

Read CreateTrafficMirrorSession Source # 
Instance details

Defined in Amazonka.EC2.CreateTrafficMirrorSession

Show CreateTrafficMirrorSession Source # 
Instance details

Defined in Amazonka.EC2.CreateTrafficMirrorSession

NFData CreateTrafficMirrorSession Source # 
Instance details

Defined in Amazonka.EC2.CreateTrafficMirrorSession

Eq CreateTrafficMirrorSession Source # 
Instance details

Defined in Amazonka.EC2.CreateTrafficMirrorSession

Hashable CreateTrafficMirrorSession Source # 
Instance details

Defined in Amazonka.EC2.CreateTrafficMirrorSession

type AWSResponse CreateTrafficMirrorSession Source # 
Instance details

Defined in Amazonka.EC2.CreateTrafficMirrorSession

type Rep CreateTrafficMirrorSession Source # 
Instance details

Defined in Amazonka.EC2.CreateTrafficMirrorSession

type Rep CreateTrafficMirrorSession = D1 ('MetaData "CreateTrafficMirrorSession" "Amazonka.EC2.CreateTrafficMirrorSession" "amazonka-ec2-2.0-48L9RAJvmvzAdBkRegqWCL" 'False) (C1 ('MetaCons "CreateTrafficMirrorSession'" 'PrefixI 'True) (((S1 ('MetaSel ('Just "clientToken") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: S1 ('MetaSel ('Just "description") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text))) :*: (S1 ('MetaSel ('Just "dryRun") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Bool)) :*: (S1 ('MetaSel ('Just "packetLength") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Int)) :*: S1 ('MetaSel ('Just "tagSpecifications") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe [TagSpecification]))))) :*: ((S1 ('MetaSel ('Just "virtualNetworkId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Int)) :*: S1 ('MetaSel ('Just "networkInterfaceId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Text)) :*: (S1 ('MetaSel ('Just "trafficMirrorTargetId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Text) :*: (S1 ('MetaSel ('Just "trafficMirrorFilterId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Text) :*: S1 ('MetaSel ('Just "sessionNumber") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Int))))))

newCreateTrafficMirrorSession Source #

Create a value of CreateTrafficMirrorSession with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

CreateTrafficMirrorSession, createTrafficMirrorSession_clientToken - Unique, case-sensitive identifier that you provide to ensure the idempotency of the request. For more information, see How to ensure idempotency.

CreateTrafficMirrorSession, createTrafficMirrorSession_description - The description of the Traffic Mirror session.

$sel:dryRun:CreateTrafficMirrorSession', createTrafficMirrorSession_dryRun - Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

CreateTrafficMirrorSession, createTrafficMirrorSession_packetLength - The number of bytes in each packet to mirror. These are bytes after the VXLAN header. Do not specify this parameter when you want to mirror the entire packet. To mirror a subset of the packet, set this to the length (in bytes) that you want to mirror. For example, if you set this value to 100, then the first 100 bytes that meet the filter criteria are copied to the target.

If you do not want to mirror the entire packet, use the PacketLength parameter to specify the number of bytes in each packet to mirror.

CreateTrafficMirrorSession, createTrafficMirrorSession_tagSpecifications - The tags to assign to a Traffic Mirror session.

CreateTrafficMirrorSession, createTrafficMirrorSession_virtualNetworkId - The VXLAN ID for the Traffic Mirror session. For more information about the VXLAN protocol, see RFC 7348. If you do not specify a VirtualNetworkId, an account-wide unique id is chosen at random.

CreateTrafficMirrorSession, createTrafficMirrorSession_networkInterfaceId - The ID of the source network interface.

CreateTrafficMirrorSession, createTrafficMirrorSession_trafficMirrorTargetId - The ID of the Traffic Mirror target.

CreateTrafficMirrorSession, createTrafficMirrorSession_trafficMirrorFilterId - The ID of the Traffic Mirror filter.

CreateTrafficMirrorSession, createTrafficMirrorSession_sessionNumber - The session number determines the order in which sessions are evaluated when an interface is used by multiple sessions. The first session with a matching filter is the one that mirrors the packets.

Valid values are 1-32766.

Request Lenses

createTrafficMirrorSession_clientToken :: Lens' CreateTrafficMirrorSession (Maybe Text) Source #

Unique, case-sensitive identifier that you provide to ensure the idempotency of the request. For more information, see How to ensure idempotency.

createTrafficMirrorSession_description :: Lens' CreateTrafficMirrorSession (Maybe Text) Source #

The description of the Traffic Mirror session.

createTrafficMirrorSession_dryRun :: Lens' CreateTrafficMirrorSession (Maybe Bool) Source #

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

createTrafficMirrorSession_packetLength :: Lens' CreateTrafficMirrorSession (Maybe Int) Source #

The number of bytes in each packet to mirror. These are bytes after the VXLAN header. Do not specify this parameter when you want to mirror the entire packet. To mirror a subset of the packet, set this to the length (in bytes) that you want to mirror. For example, if you set this value to 100, then the first 100 bytes that meet the filter criteria are copied to the target.

If you do not want to mirror the entire packet, use the PacketLength parameter to specify the number of bytes in each packet to mirror.

createTrafficMirrorSession_virtualNetworkId :: Lens' CreateTrafficMirrorSession (Maybe Int) Source #

The VXLAN ID for the Traffic Mirror session. For more information about the VXLAN protocol, see RFC 7348. If you do not specify a VirtualNetworkId, an account-wide unique id is chosen at random.

createTrafficMirrorSession_sessionNumber :: Lens' CreateTrafficMirrorSession Int Source #

The session number determines the order in which sessions are evaluated when an interface is used by multiple sessions. The first session with a matching filter is the one that mirrors the packets.

Valid values are 1-32766.

Destructuring the Response

data CreateTrafficMirrorSessionResponse Source #

Constructors

CreateTrafficMirrorSessionResponse' 

Fields

Instances

Instances details
Generic CreateTrafficMirrorSessionResponse Source # 
Instance details

Defined in Amazonka.EC2.CreateTrafficMirrorSession

Associated Types

type Rep CreateTrafficMirrorSessionResponse :: Type -> Type #

Read CreateTrafficMirrorSessionResponse Source # 
Instance details

Defined in Amazonka.EC2.CreateTrafficMirrorSession

Show CreateTrafficMirrorSessionResponse Source # 
Instance details

Defined in Amazonka.EC2.CreateTrafficMirrorSession

NFData CreateTrafficMirrorSessionResponse Source # 
Instance details

Defined in Amazonka.EC2.CreateTrafficMirrorSession

Eq CreateTrafficMirrorSessionResponse Source # 
Instance details

Defined in Amazonka.EC2.CreateTrafficMirrorSession

type Rep CreateTrafficMirrorSessionResponse Source # 
Instance details

Defined in Amazonka.EC2.CreateTrafficMirrorSession

type Rep CreateTrafficMirrorSessionResponse = D1 ('MetaData "CreateTrafficMirrorSessionResponse" "Amazonka.EC2.CreateTrafficMirrorSession" "amazonka-ec2-2.0-48L9RAJvmvzAdBkRegqWCL" 'False) (C1 ('MetaCons "CreateTrafficMirrorSessionResponse'" 'PrefixI 'True) (S1 ('MetaSel ('Just "clientToken") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: (S1 ('MetaSel ('Just "trafficMirrorSession") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe TrafficMirrorSession)) :*: S1 ('MetaSel ('Just "httpStatus") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Int))))

newCreateTrafficMirrorSessionResponse Source #

Create a value of CreateTrafficMirrorSessionResponse with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

CreateTrafficMirrorSession, createTrafficMirrorSessionResponse_clientToken - Unique, case-sensitive identifier that you provide to ensure the idempotency of the request. For more information, see How to ensure idempotency.

$sel:trafficMirrorSession:CreateTrafficMirrorSessionResponse', createTrafficMirrorSessionResponse_trafficMirrorSession - Information about the Traffic Mirror session.

$sel:httpStatus:CreateTrafficMirrorSessionResponse', createTrafficMirrorSessionResponse_httpStatus - The response's http status code.

Response Lenses

createTrafficMirrorSessionResponse_clientToken :: Lens' CreateTrafficMirrorSessionResponse (Maybe Text) Source #

Unique, case-sensitive identifier that you provide to ensure the idempotency of the request. For more information, see How to ensure idempotency.