Skip to main content

AWS-EKS

This Integration is part of the AWS - EKS Pack.#

Supported versions

Supported Cortex XSOAR versions: 6.9.0 and later.

The AWS EKS integration allows for the management and operation of Amazon Elastic Kubernetes Service (EKS) clusters. This integration was integrated and tested with version 1.29 of AWS-EKS.

Configure AWS-EKS on Cortex XSOAR#

  1. Navigate to Settings > Integrations > Servers & Services.

  2. Search for AWS-EKS.

  3. Click Add instance to create and configure a new integration instance.

    ParameterDescriptionRequired
    AWS Default RegionAWS Default RegionTrue
    Access KeyTrue
    Secret KeyTrue
    TimeoutThe time in seconds till a timeout exception is reached. You can specify just the read timeout (for example 60) or also the connect timeout followed after a comma (for example 60,10). If a connect timeout is not specified, a default of 10 seconds will be used.False
    RetriesThe maximum number of retry attempts when connection or throttling errors are encountered. Set to 0 to disable retries. The default value is 5 and the limit is 10. Note: Increasing the number of retries will increase the execution time.False
    Trust any certificate (not secure)Trust any certificate (not secure)False
    Use system proxy settingsUse system proxy settingsFalse
  4. Click Test to validate the URLs, token, and connection.

Commands#

You can execute these commands from the Cortex XSOAR CLI, as part of an automation, or in a playbook. After you successfully execute a command, a DBot message appears in the War Room with the command details.

aws-eks-list-clusters#


Lists the Amazon EKS clusters in your Amazon Web Services account in the specified Amazon Web Services Region.

Base Command#

aws-eks-list-clusters

Input#

Argument NameDescriptionRequired
limitThe maximum number of clusters to return. Default is 50.Optional
next_tokenThe nextToken value returned from a previous paginated request, where maxResults was used and the results exceeded the value of that parameter.Optional
regionThe AWS Region. If not specified, the configured region will be used. Possible values are: us-east-1, us-east-2, us-west-1, us-west-2, ca-central-1, eu-west-1, eu-central-1, eu-west-2, ap-northeast-1, ap-northeast-2, ap-southeast-1, ap-southeast-2, ap-south-1, sa-east-1, eu-north-1, eu-west-3.Optional

Context Output#

PathTypeDescription
AWS.EKS.Cluster.ClustersNamesListA list of all of the clusters for your account in the specified Amazon Web Services Region.
AWS.EKS.Cluster.NextTokenListThe nextToken value returned from a previous paginated request, where maxResults was used and the results exceeded the value of that parameter.

Command example#

!aws-eks-list-clusters

Context Example#

{
"AWS": {
"EKS": {
"Cluster": {
"ClustersNames": [
"cluster_name1",
"cluster_name2"
],
"NextToken": null
}
}
}
}

Human Readable Output#

The list of clusters#

Clusters Names
cluster_name1
cluster_name2

aws-eks-update-cluster-config#


Updates an Amazon EKS cluster configuration. Only one type of update is allowed. Potentially harmful: once the authentication mode is updated to 'API' it is irreversible.

Base Command#

aws-eks-update-cluster-config

Input#

Argument NameDescriptionRequired
cluster_nameThe name of the Amazon EKS cluster to update.Required
resources_vpc_configA JSON representation of the VPC configuration used by the cluster control plane. An example: "{'subnetIds': ['string'], 'securityGroupIds': ['string'], 'endpointPublicAccess': True, 'endpointPrivateAccess': True, 'publicAccessCidrs': ['string']}".Optional
loggingA JSON representation of the logging configuration for the cluster. An example: "{'clusterLogging': [{'types': ['api', 'audit', 'authenticator', 'controllerManager', 'scheduler'], 'enabled': true}]}".Optional
authentication_modeWhether to update the authentication mode to 'API_AND_CONFIG_MAP' or not. Possible values are: true, false.Optional
regionThe AWS Region. If not specified, the configured region will be used. Possible values are: us-east-1, us-east-2, us-west-1, us-west-2, ca-central-1, eu-west-1, eu-central-1, eu-west-2, ap-northeast-1, ap-northeast-2, ap-southeast-1, ap-southeast-2, ap-south-1, sa-east-1, eu-north-1, eu-west-3.Optional

Context Output#

PathTypeDescription
AWS.EKS.UpdateCluster.clusterNameStringThe name of the cluster.
AWS.EKS.UpdateCluster.idIntegerThe ID of the update.
AWS.EKS.UpdateCluster.statusStringThe status of the update.
AWS.EKS.UpdateCluster.typeStringThe type of the update.
AWS.EKS.UpdateCluster.paramsObjectThe parameters of the update.
AWS.EKS.UpdateCluster.createdAtStringThe creation date of the object.
AWS.EKS.UpdateCluster.errorsObjectAny errors associated with a failed update.

Command example#

!aws-eks-update-cluster-config cluster_name=CLUSTER_NAME logging="{'clusterLogging': [{'types': ['api', 'authenticator', 'audit'], 'enabled': false}]}"

Context Example#

{
"AWS": {
"EKS": {
"UpdateCluster": {
"createdAt": "2024-02-26 09:38:11.578000+00:00",
"errors": [],
"id": "11111111-1111-1111-1111-111111111111",
"name": "CLUSTER_NAME",
"params": [
{
"type": "ClusterLogging",
"value": "{\"clusterLogging\":[{\"types\":[\"api\",\"audit\",\"authenticator\"],\"enabled\":false}]}"
}
],
"status": "InProgress",
"type": "LoggingUpdate"
}
}
}
}

Human Readable Output#

Updated Cluster Config Information#

Cluster NameIDStatusTypeParams
CLUSTER_NAME11111111-1111-1111-1111-111111111111InProgressLoggingUpdate{'type': 'ClusterLogging', 'value': '{"clusterLogging":[{"types":["api","audit","authenticator"],"enabled":false}]}'}

aws-eks-describe-cluster#


Describes an Amazon EKS cluster.

Base Command#

aws-eks-describe-cluster

Input#

Argument NameDescriptionRequired
cluster_nameThe name of the cluster to describe.Required
regionThe AWS Region. If not specified, the configured region will be used. Possible values are: us-east-1, us-east-2, us-west-1, us-west-2, ca-central-1, eu-west-1, eu-central-1, eu-west-2, ap-northeast-1, ap-northeast-2, ap-southeast-1, ap-southeast-2, ap-south-1, sa-east-1, eu-north-1, eu-west-3.Optional

Context Output#

PathTypeDescription
AWS.EKS.DescribeCluster.nameStringThe name of your cluster.
AWS.EKS.DescribeCluster.arnStringThe Amazon Resource Name (ARN) of the cluster.
AWS.EKS.DescribeCluster.createdAtStringThe creation date of the object.
AWS.EKS.DescribeCluster.versionStringThe Kubernetes server version for the cluster.
AWS.EKS.DescribeCluster.endpointStringThe endpoint for your Kubernetes API server.
AWS.EKS.DescribeCluster.roleArnStringThe Amazon Resource Name (ARN) of the IAM role that provides permissions for the Kubernetes control plane to make calls to Amazon Web Services API operations on your behalf.
AWS.EKS.DescribeCluster.resourcesVpcConfig.subnetIdsListThe subnets associated with your cluster.
AWS.EKS.DescribeCluster.resourcesVpcConfig.securityGroupIdsListThe security groups associated with the cross-account elastic network interfaces that are used to allow communication between your nodes and the Kubernetes control plane.
AWS.EKS.DescribeCluster.resourcesVpcConfig.clusterSecurityGroupIdStringThe cluster security group that was created by Amazon EKS for the cluster. Managed node groups use this security group for control-plane-to-data-plane communication.
AWS.EKS.DescribeCluster.resourcesVpcConfig.vpcIdStringThe VPC associated with your cluster.
AWS.EKS.DescribeCluster.resourcesVpcConfig.endpointPublicAccessBooleanWhether the public API server endpoint is enabled.
AWS.EKS.DescribeCluster.resourcesVpcConfig.endpointPrivateAccessBooleanThis parameter indicates whether the Amazon EKS private API server endpoint is enabled.
AWS.EKS.DescribeCluster.resourcesVpcConfig.publicAccessCidrsListThe CIDR blocks that are allowed access to your cluster’s public Kubernetes API server endpoint.
AWS.EKS.DescribeCluster.kubernetesNetworkConfig.serviceIpv4CidrStringThe CIDR block that Kubernetes Pod and Service object IP addresses are assigned from.
AWS.EKS.DescribeCluster.kubernetesNetworkConfig.serviceIpv6CidrStringThe CIDR block that Kubernetes Pod and Service IP addresses are assigned from if you created a 1.21 or later cluster with version 1.10.1 or later of the Amazon VPC CNI add-on and specified ipv6 for ipFamily when you created the cluster.
AWS.EKS.DescribeCluster.kubernetesNetworkConfig.ipFamilyStringThe IP family used to assign Kubernetes Pod and Service objects IP addresses.
AWS.EKS.DescribeCluster.logging.clusterLoggingObjectThe cluster control plane logging configuration for your cluster.
AWS.EKS.DescribeCluster.identityObjectThe identity provider information for the cluster.
AWS.EKS.DescribeCluster.statusStringThe current status of the cluster.
AWS.EKS.DescribeCluster.certificateAuthority.dataStringThe Base64-encoded certificate data required to communicate with your cluster.
AWS.EKS.DescribeCluster.clientRequestTokenStringA unique, case-sensitive identifier that you provide to ensure the idempotency of the request.
AWS.EKS.DescribeCluster.platformVersionStringThe platform version of your Amazon EKS cluster.
AWS.EKS.DescribeCluster.tagsObjectA dictionary containing metadata for categorization and organization.
AWS.EKS.DescribeCluster.encryptionConfig.resourcesListSpecifies the resources to be encrypted. The only supported value is secrets.
AWS.EKS.DescribeCluster.encryptionConfig.providerObjectKey Management Service (KMS) key.
AWS.EKS.DescribeCluster.connectorConfig.activationIdStringA unique ID associated with the cluster for registration purposes.
AWS.EKS.DescribeCluster.connectorConfig.activationCodeStringA unique code associated with the cluster for registration purposes.
AWS.EKS.DescribeCluster.connectorConfig.activationExpiryStringThe expiration time of the connected cluster.
AWS.EKS.DescribeCluster.connectorConfig.providerStringThe cluster’s cloud service provider.
AWS.EKS.DescribeCluster.connectorConfig.roleArnStringThe Amazon Resource Name (ARN) of the role to communicate with services from the connected Kubernetes cluster.
AWS.EKS.DescribeCluster.idStringThe ID of your local Amazon EKS cluster on an Amazon Web Services Outpost.
AWS.EKS.DescribeCluster.health.issuesListAn object representing the health issues of your local Amazon EKS cluster on an Amazon Web Services Outpost.
AWS.EKS.DescribeCluster.outpostConfig.outpostArnsObjectAn object representing the configuration of your local Amazon EKS cluster on an Amazon Web Services Outpost.
AWS.EKS.DescribeCluster.outpostConfig.controlPlaneInstanceTypeStringThe Amazon EC2 instance type used for the control plane.
AWS.EKS.DescribeCluster.outpostConfig.controlPlanePlacementObjectAn object representing the placement configuration for all the control plane instances of your local Amazon EKS cluster on an Amazon Web Services Outpost.
AWS.EKS.DescribeCluster.accessConfig.bootstrapClusterCreatorAdminPermissionsBooleanSpecifies whether or not the cluster creator IAM principal was set as a cluster admin access entry during cluster creation time.
AWS.EKS.DescribeCluster.accessConfig.authenticationModeStringThe current authentication mode of the cluster.

Command example#

!aws-eks-describe-cluster cluster_name=CLUSTER_NAME

Context Example#

{
"AWS": {
"EKS": {
"DescribeCluster": {
"accessConfig": {
"authenticationMode": "API_AND_CONFIG_MAP"
},
"arn": "arn",
"certificateAuthority": {
"data": "data_key"
},
"createdAt": "2024-02-26 09:38:11.578000+00:00",
"endpoint": "endpoint",
"health": {
"issues": []
},
"identity": {
"oidc": {
"issuer": "issuer"
}
},
"kubernetesNetworkConfig": {
"ipFamily": "ipv4",
"serviceIpv4Cidr": "11.111.1.1/11"
},
"logging": {
"clusterLogging": [
{
"enabled": true,
"types": [
"api",
"audit",
"authenticator",
"controllerManager",
"scheduler"
]
}
]
},
"name": "CLUSTER_NAME",
"platformVersion": "eks.1",
"resourcesVpcConfig": {
"clusterSecurityGroupId": "sg-id",
"endpointPrivateAccess": true,
"endpointPublicAccess": true,
"publicAccessCidrs": [
"111.111.111.111/11"
],
"securityGroupIds": [
"sg-id"
],
"subnetIds": [
"subnet-id"
],
"vpcId": "vpc-id"
},
"roleArn": "roleArn",
"status": "ACTIVE",
"tags": {},
"version": "1.29"
}
}
}
}

Human Readable Output#

Describe Cluster Information#

Cluster NameStatusARNCreated AtVersion
roleArnACTIVEroleArn2024-02-26 09:38:11.578000+00:001.29

aws-eks-create-access-entry#


Creates an access entry.

Base Command#

aws-eks-create-access-entry

Input#

Argument NameDescriptionRequired
cluster_nameThe name of the cluster for which to create an access entry.Required
principal_arnARN of the IAM principal for the AccessEntry.Required
kubernetes_groupsA comma-separated list of names for Kubernetes groups in RoleBindings or ClusterRoleBindings.Optional
tagsA dictionary containing metadata for categorization and organization. Each tag consists of a key and an optional value.Optional
client_request_tokenUnique identifier for idempotency.Optional
usernameUsername for Kubernetes authentication.Optional
typeThe type of access entry to create. Possible values are: Standard, FARGATE_LINUX, EC2_LINUX, EC2_WINDOWS. Default is Standard.Optional
regionThe AWS Region. If not specified, the configured region will be used. Possible values are: us-east-1, us-east-2, us-west-1, us-west-2, ca-central-1, eu-west-1, eu-central-1, eu-west-2, ap-northeast-1, ap-northeast-2, ap-southeast-1, ap-southeast-2, ap-south-1, sa-east-1, eu-north-1, eu-west-3.Optional

Context Output#

PathTypeDescription
AWS.EKS.CreateAccessEntry.clusterNameStringThe name of the cluster.
AWS.EKS.CreateAccessEntry.principalArnStringThe ARN of the IAM principal for the access entry.
AWS.EKS.CreateAccessEntry.kubernetesGroupsStringA list of names that you’ve specified in a Kubernetes RoleBinding or ClusterRoleBinding object so that Kubernetes authorizes the principalARN access to cluster objects.
AWS.EKS.CreateAccessEntry.accessEntryArnStringThe ARN of the access entry.
AWS.EKS.CreateAccessEntry.createdAtStringThe creation date of the object.
AWS.EKS.CreateAccessEntry.modifiedAtStringThe date and time for the last modification to the object.
AWS.EKS.CreateAccessEntry.tagsObjectA dictionary containing metadata for categorization and organization.
AWS.EKS.CreateAccessEntry.usernameStringThe name of a user that can authenticate to the cluster.
AWS.EKS.CreateAccessEntry.typeStringThe type of the access entry.

Command example#

!aws-eks-create-access-entry cluster_name=CLUSTER_NAME principal_arn=principal_arn

Context Example#

{
"AWS": {
"EKS": {
"CreateAccessEntry": {
"ResponseMetadata": {
"clusterName": "clusterName",
"principalArn": "principalArn",
"kubernetesGroups": [
"kubernetesGroups"
],
"accessEntryArn": "accessEntryArn",
"createdAt": "2024-02-26 09:38:11.578000+00:00",
"modifiedAt": "2024-02-26 09:38:11.578000+00:00",
"tags": {
"string": "string"
},
"username": "username",
"type": "STANDARD"
}
}
}
}
}

Human Readable Output#

The newly created access entry#

Cluster NamePrincipal ArnUsernameTypeCreated At
clusterNameprincipalArnusernameSTANDARD2024-02-26 09:38:11.578000+00:00

aws-eks-associate-access-policy#


Associates an access policy and its scope to an access entry.

Base Command#

aws-eks-associate-access-policy

Input#

Argument NameDescriptionRequired
cluster_nameThe name of the cluster for which to create an access entry.Required
principal_arnThe Amazon Resource Name (ARN) of the IAM user or role for the AccessEntry that you’re associating the access policy to.Required
policy_arnThe ARN of the AccessPolicy that you’re associating.Required
typeThe scope type of an access policy. Possible values are: cluster, namespace.Required
namespacesA comma-separated list of Kubernetes namespaces that an access policy is scoped to. A value is required if you specified namespace for type.Optional
regionThe AWS Region. If not specified, the configured region will be used. Possible values are: us-east-1, us-east-2, us-west-1, us-west-2, ca-central-1, eu-west-1, eu-central-1, eu-west-2, ap-northeast-1, ap-northeast-2, ap-southeast-1, ap-southeast-2, ap-south-1, sa-east-1, eu-north-1, eu-west-3.Optional

Context Output#

PathTypeDescription
AWS.EKS.AssociatedAccessPolicy.clusterNameStringThe name of your cluster.
AWS.EKS.AssociatedAccessPolicy.principalArnStringThe ARN of the IAM principal for the AccessEntry.
AWS.EKS.AssociatedAccessPolicy.policyArnStringThe ARN of the AccessPolicy.
AWS.EKS.AssociatedAccessPolicy.accessScope.typeStringThe scope type of an access policy.
AWS.EKS.AssociatedAccessPolicy.accessScope.namespacesStringA Kubernetes namespace that an access policy is scoped to.
AWS.EKS.AssociatedAccessPolicy.associatedAtStringThe date and time the AccessPolicy was associated with an AccessEntry.
AWS.EKS.AssociatedAccessPolicy.modifiedAtStringThe date and time for the last modification to the object.

Command example#

!aws-eks-associate-access-policy cluster_name=CLUSTER_NAME principal_arn=principal_arn type=cluster

Context Example#

{
"AWS": {
"EKS": {
"AssociatedAccessPolicy": {
"associatedAccessPolicy": {
"accessScope": {
"namespaces": [],
"type": "cluster"
},
"associatedAt": "2024-02-26 09:38:11.578000+00:00",
"modifiedAt": "2024-02-26 09:38:11.578000+00:00",
"policyArn": "policyArn"
},
"clusterName": "CLUSTER_NAME",
"principalArn": "principalArn"
}
}
}
}

Human Readable Output#

The access policy was associated to the access entry successfully.#

Cluster NamePrincipal ArnPolicy Arnassociate At
clusterNameprincipalArnusername2024-02-26 09:38:11.578000+00:00

aws-eks-update-access-entry#


Updates an access entry.

Base Command#

aws-eks-update-access-entry

Input#

Argument NameDescriptionRequired
cluster_nameThe name of the cluster.Required
principal_arnARN of the IAM principal for the AccessEntry.Required
kubernetes_groupsA comma-separated list of names for Kubernetes groups in RoleBindings or ClusterRoleBindings.Optional
client_request_tokenUnique identifier for idempotency.Optional
usernameUsername for Kubernetes authentication.Optional
regionThe AWS Region. If not specified, the configured region will be used. Possible values are: us-east-1, us-east-2, us-west-1, us-west-2, ca-central-1, eu-west-1, eu-central-1, eu-west-2, ap-northeast-1, ap-northeast-2, ap-southeast-1, ap-southeast-2, ap-south-1, sa-east-1, eu-north-1, eu-west-3.Optional

Context Output#

PathTypeDescription
AWS.EKS.UpdateAccessEntry.clusterNameStringThe name of your cluster.
AWS.EKS.UpdateAccessEntry.principalArnStringThe ARN of the IAM principal for the access entry.
AWS.EKS.UpdateAccessEntry.kubernetesGroupsListA list of names that you’ve specified in a Kubernetes RoleBinding or ClusterRoleBinding object so that Kubernetes authorizes the principalARN access to cluster objects.
AWS.EKS.UpdateAccessEntry.accessEntryArnStringThe ARN of the access entry.
AWS.EKS.UpdateAccessEntry.createdAtStringThe creation date of the object.
AWS.EKS.UpdateAccessEntry.modifiedAtStringThe date and time for the last modification to the object.
AWS.EKS.UpdateAccessEntry.tagsObjectMetadata that assists with categorization and organization. Each tag consists of a key and an optional value.
AWS.EKS.UpdateAccessEntry.usernameStringThe name of a user that can authenticate to your cluster.
AWS.EKS.UpdateAccessEntry.typeStringThe type of the access entry.

Command example#

!aws-eks-update-access-entry cluster_name=CLUSTER_NAME principal_arn=principal_arn

Context Example#

{
"AWS": {
"EKS": {
"UpdateAccessEntry": {
"accessEntryArn": "accessEntryArn",
"clusterName": "CLUSTER_NAME",
"createdAt": "2024-02-26 09:38:11.578000+00:00",
"kubernetesGroups": [],
"modifiedAt": "2024-02-26 09:38:11.578000+00:00",
"principalArn": "principalArn",
"tags": {},
"type": "STANDARD",
"username": "username"
}
}
}
}

Human Readable Output#

The updated access entry#

Cluster NamePrincipal ArnUsernameTypeModified At
CLUSTER_NAMEprincipal_arnusernameSTANDARD2024-02-26 09:38:11.578000+00:00