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

Details about the Kubernetes user involved in a Kubernetes * finding.

See Also:

AWS * API Reference

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

The username of the user who called the Kubernetes API.

*/ inline const Aws::String& GetUsername() const{ return m_username; } /** *

The username of the user who called the Kubernetes API.

*/ inline bool UsernameHasBeenSet() const { return m_usernameHasBeenSet; } /** *

The username of the user who called the Kubernetes API.

*/ inline void SetUsername(const Aws::String& value) { m_usernameHasBeenSet = true; m_username = value; } /** *

The username of the user who called the Kubernetes API.

*/ inline void SetUsername(Aws::String&& value) { m_usernameHasBeenSet = true; m_username = std::move(value); } /** *

The username of the user who called the Kubernetes API.

*/ inline void SetUsername(const char* value) { m_usernameHasBeenSet = true; m_username.assign(value); } /** *

The username of the user who called the Kubernetes API.

*/ inline KubernetesUserDetails& WithUsername(const Aws::String& value) { SetUsername(value); return *this;} /** *

The username of the user who called the Kubernetes API.

*/ inline KubernetesUserDetails& WithUsername(Aws::String&& value) { SetUsername(std::move(value)); return *this;} /** *

The username of the user who called the Kubernetes API.

*/ inline KubernetesUserDetails& WithUsername(const char* value) { SetUsername(value); return *this;} /** *

The user ID of the user who called the Kubernetes API.

*/ inline const Aws::String& GetUid() const{ return m_uid; } /** *

The user ID of the user who called the Kubernetes API.

*/ inline bool UidHasBeenSet() const { return m_uidHasBeenSet; } /** *

The user ID of the user who called the Kubernetes API.

*/ inline void SetUid(const Aws::String& value) { m_uidHasBeenSet = true; m_uid = value; } /** *

The user ID of the user who called the Kubernetes API.

*/ inline void SetUid(Aws::String&& value) { m_uidHasBeenSet = true; m_uid = std::move(value); } /** *

The user ID of the user who called the Kubernetes API.

*/ inline void SetUid(const char* value) { m_uidHasBeenSet = true; m_uid.assign(value); } /** *

The user ID of the user who called the Kubernetes API.

*/ inline KubernetesUserDetails& WithUid(const Aws::String& value) { SetUid(value); return *this;} /** *

The user ID of the user who called the Kubernetes API.

*/ inline KubernetesUserDetails& WithUid(Aws::String&& value) { SetUid(std::move(value)); return *this;} /** *

The user ID of the user who called the Kubernetes API.

*/ inline KubernetesUserDetails& WithUid(const char* value) { SetUid(value); return *this;} /** *

The groups that include the user who called the Kubernetes API.

*/ inline const Aws::Vector& GetGroups() const{ return m_groups; } /** *

The groups that include the user who called the Kubernetes API.

*/ inline bool GroupsHasBeenSet() const { return m_groupsHasBeenSet; } /** *

The groups that include the user who called the Kubernetes API.

*/ inline void SetGroups(const Aws::Vector& value) { m_groupsHasBeenSet = true; m_groups = value; } /** *

The groups that include the user who called the Kubernetes API.

*/ inline void SetGroups(Aws::Vector&& value) { m_groupsHasBeenSet = true; m_groups = std::move(value); } /** *

The groups that include the user who called the Kubernetes API.

*/ inline KubernetesUserDetails& WithGroups(const Aws::Vector& value) { SetGroups(value); return *this;} /** *

The groups that include the user who called the Kubernetes API.

*/ inline KubernetesUserDetails& WithGroups(Aws::Vector&& value) { SetGroups(std::move(value)); return *this;} /** *

The groups that include the user who called the Kubernetes API.

*/ inline KubernetesUserDetails& AddGroups(const Aws::String& value) { m_groupsHasBeenSet = true; m_groups.push_back(value); return *this; } /** *

The groups that include the user who called the Kubernetes API.

*/ inline KubernetesUserDetails& AddGroups(Aws::String&& value) { m_groupsHasBeenSet = true; m_groups.push_back(std::move(value)); return *this; } /** *

The groups that include the user who called the Kubernetes API.

*/ inline KubernetesUserDetails& AddGroups(const char* value) { m_groupsHasBeenSet = true; m_groups.push_back(value); return *this; } /** *

Entity that assumes the IAM role when Kubernetes RBAC permissions are * assigned to that role.

*/ inline const Aws::Vector& GetSessionName() const{ return m_sessionName; } /** *

Entity that assumes the IAM role when Kubernetes RBAC permissions are * assigned to that role.

*/ inline bool SessionNameHasBeenSet() const { return m_sessionNameHasBeenSet; } /** *

Entity that assumes the IAM role when Kubernetes RBAC permissions are * assigned to that role.

*/ inline void SetSessionName(const Aws::Vector& value) { m_sessionNameHasBeenSet = true; m_sessionName = value; } /** *

Entity that assumes the IAM role when Kubernetes RBAC permissions are * assigned to that role.

*/ inline void SetSessionName(Aws::Vector&& value) { m_sessionNameHasBeenSet = true; m_sessionName = std::move(value); } /** *

Entity that assumes the IAM role when Kubernetes RBAC permissions are * assigned to that role.

*/ inline KubernetesUserDetails& WithSessionName(const Aws::Vector& value) { SetSessionName(value); return *this;} /** *

Entity that assumes the IAM role when Kubernetes RBAC permissions are * assigned to that role.

*/ inline KubernetesUserDetails& WithSessionName(Aws::Vector&& value) { SetSessionName(std::move(value)); return *this;} /** *

Entity that assumes the IAM role when Kubernetes RBAC permissions are * assigned to that role.

*/ inline KubernetesUserDetails& AddSessionName(const Aws::String& value) { m_sessionNameHasBeenSet = true; m_sessionName.push_back(value); return *this; } /** *

Entity that assumes the IAM role when Kubernetes RBAC permissions are * assigned to that role.

*/ inline KubernetesUserDetails& AddSessionName(Aws::String&& value) { m_sessionNameHasBeenSet = true; m_sessionName.push_back(std::move(value)); return *this; } /** *

Entity that assumes the IAM role when Kubernetes RBAC permissions are * assigned to that role.

*/ inline KubernetesUserDetails& AddSessionName(const char* value) { m_sessionNameHasBeenSet = true; m_sessionName.push_back(value); return *this; } private: Aws::String m_username; bool m_usernameHasBeenSet = false; Aws::String m_uid; bool m_uidHasBeenSet = false; Aws::Vector m_groups; bool m_groupsHasBeenSet = false; Aws::Vector m_sessionName; bool m_sessionNameHasBeenSet = false; }; } // namespace Model } // namespace GuardDuty } // namespace Aws