/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include #include namespace Aws { namespace Utils { namespace Json { class JsonValue; class JsonView; } // namespace Json } // namespace Utils namespace SecurityHub { namespace Model { /** *

Provided if ActionType is NETWORK_CONNECTION. It * provides details about the attempted network connection that was * detected.

See Also:

AWS * API Reference

*/ class NetworkConnectionAction { public: AWS_SECURITYHUB_API NetworkConnectionAction(); AWS_SECURITYHUB_API NetworkConnectionAction(Aws::Utils::Json::JsonView jsonValue); AWS_SECURITYHUB_API NetworkConnectionAction& operator=(Aws::Utils::Json::JsonView jsonValue); AWS_SECURITYHUB_API Aws::Utils::Json::JsonValue Jsonize() const; /** *

The direction of the network connection request (IN or * OUT).

*/ inline const Aws::String& GetConnectionDirection() const{ return m_connectionDirection; } /** *

The direction of the network connection request (IN or * OUT).

*/ inline bool ConnectionDirectionHasBeenSet() const { return m_connectionDirectionHasBeenSet; } /** *

The direction of the network connection request (IN or * OUT).

*/ inline void SetConnectionDirection(const Aws::String& value) { m_connectionDirectionHasBeenSet = true; m_connectionDirection = value; } /** *

The direction of the network connection request (IN or * OUT).

*/ inline void SetConnectionDirection(Aws::String&& value) { m_connectionDirectionHasBeenSet = true; m_connectionDirection = std::move(value); } /** *

The direction of the network connection request (IN or * OUT).

*/ inline void SetConnectionDirection(const char* value) { m_connectionDirectionHasBeenSet = true; m_connectionDirection.assign(value); } /** *

The direction of the network connection request (IN or * OUT).

*/ inline NetworkConnectionAction& WithConnectionDirection(const Aws::String& value) { SetConnectionDirection(value); return *this;} /** *

The direction of the network connection request (IN or * OUT).

*/ inline NetworkConnectionAction& WithConnectionDirection(Aws::String&& value) { SetConnectionDirection(std::move(value)); return *this;} /** *

The direction of the network connection request (IN or * OUT).

*/ inline NetworkConnectionAction& WithConnectionDirection(const char* value) { SetConnectionDirection(value); return *this;} /** *

Information about the remote IP address that issued the network connection * request.

*/ inline const ActionRemoteIpDetails& GetRemoteIpDetails() const{ return m_remoteIpDetails; } /** *

Information about the remote IP address that issued the network connection * request.

*/ inline bool RemoteIpDetailsHasBeenSet() const { return m_remoteIpDetailsHasBeenSet; } /** *

Information about the remote IP address that issued the network connection * request.

*/ inline void SetRemoteIpDetails(const ActionRemoteIpDetails& value) { m_remoteIpDetailsHasBeenSet = true; m_remoteIpDetails = value; } /** *

Information about the remote IP address that issued the network connection * request.

*/ inline void SetRemoteIpDetails(ActionRemoteIpDetails&& value) { m_remoteIpDetailsHasBeenSet = true; m_remoteIpDetails = std::move(value); } /** *

Information about the remote IP address that issued the network connection * request.

*/ inline NetworkConnectionAction& WithRemoteIpDetails(const ActionRemoteIpDetails& value) { SetRemoteIpDetails(value); return *this;} /** *

Information about the remote IP address that issued the network connection * request.

*/ inline NetworkConnectionAction& WithRemoteIpDetails(ActionRemoteIpDetails&& value) { SetRemoteIpDetails(std::move(value)); return *this;} /** *

Information about the port on the remote IP address.

*/ inline const ActionRemotePortDetails& GetRemotePortDetails() const{ return m_remotePortDetails; } /** *

Information about the port on the remote IP address.

*/ inline bool RemotePortDetailsHasBeenSet() const { return m_remotePortDetailsHasBeenSet; } /** *

Information about the port on the remote IP address.

*/ inline void SetRemotePortDetails(const ActionRemotePortDetails& value) { m_remotePortDetailsHasBeenSet = true; m_remotePortDetails = value; } /** *

Information about the port on the remote IP address.

*/ inline void SetRemotePortDetails(ActionRemotePortDetails&& value) { m_remotePortDetailsHasBeenSet = true; m_remotePortDetails = std::move(value); } /** *

Information about the port on the remote IP address.

*/ inline NetworkConnectionAction& WithRemotePortDetails(const ActionRemotePortDetails& value) { SetRemotePortDetails(value); return *this;} /** *

Information about the port on the remote IP address.

*/ inline NetworkConnectionAction& WithRemotePortDetails(ActionRemotePortDetails&& value) { SetRemotePortDetails(std::move(value)); return *this;} /** *

Information about the port on the EC2 instance.

*/ inline const ActionLocalPortDetails& GetLocalPortDetails() const{ return m_localPortDetails; } /** *

Information about the port on the EC2 instance.

*/ inline bool LocalPortDetailsHasBeenSet() const { return m_localPortDetailsHasBeenSet; } /** *

Information about the port on the EC2 instance.

*/ inline void SetLocalPortDetails(const ActionLocalPortDetails& value) { m_localPortDetailsHasBeenSet = true; m_localPortDetails = value; } /** *

Information about the port on the EC2 instance.

*/ inline void SetLocalPortDetails(ActionLocalPortDetails&& value) { m_localPortDetailsHasBeenSet = true; m_localPortDetails = std::move(value); } /** *

Information about the port on the EC2 instance.

*/ inline NetworkConnectionAction& WithLocalPortDetails(const ActionLocalPortDetails& value) { SetLocalPortDetails(value); return *this;} /** *

Information about the port on the EC2 instance.

*/ inline NetworkConnectionAction& WithLocalPortDetails(ActionLocalPortDetails&& value) { SetLocalPortDetails(std::move(value)); return *this;} /** *

The protocol used to make the network connection request.

*/ inline const Aws::String& GetProtocol() const{ return m_protocol; } /** *

The protocol used to make the network connection request.

*/ inline bool ProtocolHasBeenSet() const { return m_protocolHasBeenSet; } /** *

The protocol used to make the network connection request.

*/ inline void SetProtocol(const Aws::String& value) { m_protocolHasBeenSet = true; m_protocol = value; } /** *

The protocol used to make the network connection request.

*/ inline void SetProtocol(Aws::String&& value) { m_protocolHasBeenSet = true; m_protocol = std::move(value); } /** *

The protocol used to make the network connection request.

*/ inline void SetProtocol(const char* value) { m_protocolHasBeenSet = true; m_protocol.assign(value); } /** *

The protocol used to make the network connection request.

*/ inline NetworkConnectionAction& WithProtocol(const Aws::String& value) { SetProtocol(value); return *this;} /** *

The protocol used to make the network connection request.

*/ inline NetworkConnectionAction& WithProtocol(Aws::String&& value) { SetProtocol(std::move(value)); return *this;} /** *

The protocol used to make the network connection request.

*/ inline NetworkConnectionAction& WithProtocol(const char* value) { SetProtocol(value); return *this;} /** *

Indicates whether the network connection attempt was blocked.

*/ inline bool GetBlocked() const{ return m_blocked; } /** *

Indicates whether the network connection attempt was blocked.

*/ inline bool BlockedHasBeenSet() const { return m_blockedHasBeenSet; } /** *

Indicates whether the network connection attempt was blocked.

*/ inline void SetBlocked(bool value) { m_blockedHasBeenSet = true; m_blocked = value; } /** *

Indicates whether the network connection attempt was blocked.

*/ inline NetworkConnectionAction& WithBlocked(bool value) { SetBlocked(value); return *this;} private: Aws::String m_connectionDirection; bool m_connectionDirectionHasBeenSet = false; ActionRemoteIpDetails m_remoteIpDetails; bool m_remoteIpDetailsHasBeenSet = false; ActionRemotePortDetails m_remotePortDetails; bool m_remotePortDetailsHasBeenSet = false; ActionLocalPortDetails m_localPortDetails; bool m_localPortDetailsHasBeenSet = false; Aws::String m_protocol; bool m_protocolHasBeenSet = false; bool m_blocked; bool m_blockedHasBeenSet = false; }; } // namespace Model } // namespace SecurityHub } // namespace Aws