Giter Club home page Giter Club logo

gossm's Introduction

gossm

gossm is interactive CLI tool that you should select server in AWS and then could connect or send files your AWS server using start-session, ssh, scp under AWS Systems Manger Session Manager.

license Go Report Card

Overview

gossm is interactive CLI tool that is related AWS Systems Manger Session Manager. It can select a ec2 server installed aws-ssm-agent and then can connect its server using start-session, ssh. As well as files can send using scp.
If you will use gossm tool, this mean there will no need to open inbound 22 port in your ec2 server when is using ssh or scp command.
Because AWS Systems Manger Session Manager is using ssh protocol tunneling.

Additionally Features

  • mfa command has added. this command is to authenticate through AWS MFA, and then to save issued a temporary credentials in $HOME/.aws/credentials_mfa. (default expired time is after 6 hours)
    You should export global environment, such as export AWS_SHARED_CREDENTIALS_FILE=$HOME/.aws/credentials_mfa.
    With completed, you can execute AWS CLI and gossm conveniently without mfa authenticated.
    Refer to detail information below.

Prerequisite

ec2

  • [required] Your ec2 servers in aws are installed aws ssm agent.
  • [required] ec2 severs have to attach AmazonSSMManagedInstanceCore iam policy.
  • If you would like to use ssh, scp command using gossm, aws ssm agent version 2.3.672.0 or later is installed on ec2.

user

  • [required] your aws access key, aws secret key
  • [required] ec2:DescribeInstances, ssm:StartSession, ssm:TerminateSession, ssm:DescribeSessions, ssm:DescribeInstanceInformation, ssm:DescribeInstanceProperties, ssm:GetConnectionStatus
  • [optional] It's better to possibly get to additional permission for ec2:DescribeRegions

Install

Homebrew

# install
$ brew tap gjbae1212/gossm
$ brew install gossm

# upgrade
$ brew upgrade gossm

Download

download

How to use

global command args

args Description Default
-c (optional) aws credentials file $HOME/.aws/credentials
-p (optional) if you are having multiple aws profiles in credentials, it is name one of profiles default
-r (optional) region in AWS that would like to connect

If your machine don't exist $HOME/.aws/.credentials, have to pass -c args.

# credentials file format
[default]
aws_access_key_id = AWS ACCESS KEY
aws_secret_access_key = AWS SECRET KEY

-r or -t don't pass args, it can select through interactive CLI.

command

start

$ gossm start 

ssh, scp

-e must pass args when is using scp.
-e args is command and args when usually used to pass ssh or scp.

# ssh(if pem is already registered using ssh-add)
$ gossm ssh -e 'user@server-domain'

# ssh(if pem isn't registered)
$ gossm ssh -e '-i key.pem user@server-domain'

# ssh(if pem is already registered using ssh-add and don't pass -e option) -> select server using interactive cli
$ gossm ssh

# ssh(if pem isn't registered and don't pass -e option) -> select server using interactive cli
$ gossm ssh -i key.pem
 
# scp(if pem is already registered using ssh-add)
$ gossm scp -e 'file user@server-domain:/home/blahblah'

# scp(if pem isn't registered)
$ gossm scp -e '-i key.pem file user@server-domain:/home/blahblah'

ex)

cmd

-e required args, it is a parameter for execute to command on selected servers.

# It is to execute a command("uptime") on selected multiple servers, waiting for a response on its result.
$ gossm cmd -e "uptime" 

fwd

-z Optionally specify the remote port to access -l Optionally specify the local port to forward (If not specified when using -z, then this value defaults to the value of -z)

$ gossm fwd -z 8080 -l 42069

If not specified, you will be prompted to enter a remote and local port after selecting a target.

mfa

-deadline it's to set expire time for temporary credentials. default is 6 hours.
-device it's to set mfa device. default is your virtual mfa device.

$ gossm mfa <your-mfa-code>

Must set to export AWS_SHARED_CREDENTIALS_FILE=$HOME/.aws/credentials_mfa in .bash_profile, .zshrc.

ex)

LICENSE

This project is following The MIT.

gossm's People

Contributors

andymac4182 avatar gjbae1212 avatar jonasneves avatar kdevkr avatar mijndert avatar tonyghita avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

gossm's Issues

The UI is broken when running k9s on the server connected using gossm.

If you connect to the Remote Server with services such as Session Manager and MobaXterm, you can use k9s comfortably.

However, when connecting to EC2 using gossm, the values โ€‹โ€‹of k9s are broken.

Since k9s supports windows, it doesn't seem to be a problem with powershell and cmd

Default the profile to `AWS_PROFILE` environment variable

First off, this is a great tool, thank you for open sourcing it...

The issue I am currently running into is that I have to specify the -p profile for every call I make, because I have multiple accounts I also have multiple profiles, the way I deal with this when using boto3 or the aws-sdk-go directly is I set the AWS_PROFILE environment variable:

By default, the SDK checks the AWS_PROFILE environment variable to determine which profile to use. If no AWS_PROFILE variable is set, the SDK uses the default profile.

It seems gossm is not respecting this environment variable and is instead always defaulting to the default profile. It would be great if this instead first checked to see if the AWS_PROFILE was set and used that instead, like all the AWS SDKs work today.

Thanks again,
-Chris

Cloud security

I'm Juan ,computer engineering student of Italy, i have seen that you know about course Harvard CSCI E-49.
I'm interested because I will do a master thesis about this.
Have you the slide of the course or any other kind of resources or advice?
Thanks for the attention
Bye๐Ÿค—

Error while trying to start a new session on version 1.2.3

I get the following error while trying to start a new session:

$ gossm-1.2.3 start
? Choose a region in AWS: us-east-1
? Choose a target in AWS: <some_instance>	(i-000000000)
[start-session] profile: env, region: us-east-1, target: i-000000000

Starting session with SessionId: <my_session_id>


SessionId: <my_session_id> :
----------ERROR-------
Encountered error while initiating handshake. Handshake timed out. Please ensure that you have the latest version of the session manager plugin.

The session manager plugin version I have installed in my system and for gossm are the latest:
$ session-manager-plugin --version
1.2.30.0
$ ~/.gossm/session-manager-plugin --version
1.2.30.0

Note: I am able to start a session just fine with the AWS CLI command.

Feature Request: SSO auth

This is quite useful.

Wondering if you had considered integrating AWS SSO to grab the names of the accounts in the AWS org > account > role > region > instance.

Idea would be to integrated with AWS SSO auth, enter creds once and then select the above.

Extend support to ECS exec

Hi, recently AWS released the support to ECS exec, a way to open an interactive shell into a running container into ECS + EC2 and Fargate. What do you think to implement this functionality? I'm open to writing the necessary code.

Thanks

get EOF error with fish shell and oh-my-fish

Hello,
I have been using gossm well with fish shell and oh-my-fish.

However, I keep getting EOF error and gossm just closed after I upgrade brew to v3.2.6.
Is there anything I can do for that?

Thank you.

แ„‰แ…ณแ„แ…ณแ„…แ…ตแ†ซแ„‰แ…ฃแ†บ 2021-08-05 แ„‹แ…ฉแ„Œแ…ฅแ†ซ 11 32 20

FilterLimitExceeded: The maximum number of filter values specified on a single call is 200

[err] operation error EC2: DescribeInstances, https response error StatusCode: 400, RequestID: baec71f7-0ec1-4db4-bf27-59cfa6fc3127, api error FilterLimitExceeded: The maximum number of filter values specified on a single call is 200

This was resolved in #31 , However it looks like it was reintroduced with newer releases. End user currently has 1.4.3 installed in an OSX Environment.

์ธ๋ผ์ธ์œผ๋กœ ์ ‘์† ํ• ๋•Œ ์—๋Ÿฌ๊ฐ€ ๋ฐœ์ƒํ•ฉ๋‹ˆ๋‹ค. #7

์•ˆ๋…•ํ•˜์„ธ์š” ๋‹ต๋ณ€๊ฐ์‚ฌ๋“œ๋ฆฝ๋‹ˆ๋‹ค.

./gossm ๋กœ ์ ‘์†์„ ํ•ด์„œ ๋ฐฉํ–ฅํ‚ค๋ฅผ ์‚ฌ์šฉ์„ ํ•˜์—ฌ ๋ฆฌ์ฆŒ๊ณผ ์„œ๋ฒ„๋ฅผ ๊ณ ๋ฅด๋ฉด privaate subnet์— ์žˆ๋Š” ์„œ๋ฒ„ ์ ‘์†์ด ๊ฐ€๋Šฅํ•ฉ๋‹ˆ๋‹ค.
์ œ๊ฐ€ ์•Œ๊ธฐ๋กœ๋Š” Client๊ฐ€ ์„œ๋ฒ„์— ์ง์ ‘ ๋ถ™๋Š”๊ฒŒ ์•„๋‹Œ AWS๋ฅผ ํ†ตํ•ด ๋„˜์–ด๊ฐ€๋Š” ๊ฑธ๋กœ ์•Œ๊ณ ์žˆ์Šต๋‹ˆ๋‹ค.

๊ทธ๋ž˜์„œ public subnet๋ฅผ ๋ฐ˜๋“œ์‹œ ์‚ฌ์šฉํ•ด์•ผ ํ•  ํ•„์š”๊ฐ€ ์—†์„ ๋“ฏ ํ•ฉ๋‹ˆ๋‹ค.

Originally posted by @MintChocoO2C in #7 (comment)

authenticate with aws credential_process

We use the AWS SSM and when we run start-session we authenticate by sourcing credentials with an external process which does not seem to work with gossm. We have tested with other, more normal, profiles containing key and secret key definitions and those work just fine. We are wondering whether we are missing something or whether gossm just doesn't supports the credential_process way of authenticating at all?

Our ~/.aws/config file is configured something like this:

[profile my-profile]
region=us-east-1 
credential_process = "/Users/zaro0508/creds.sh" "https://acme.org" "eyJ0eXAiO...2GLQg"

creds.sh makes a request to our service and returns a json like so:

โžœ ~/creds.sh "https://acme.org" "eyJ0eXAiO...2GLQg"
{"SessionToken":"FwoGZXI...lOW6uY=","Version":1,"AccessKeyId":"XXXXXX1234","SecretAccessKey":"XXXXXXXXXX6789","Expiration":"2021-07-21T22:02:17Z"}

This setup works with the AWS CLI aws ssm start-session just fine. However when we run with gossm it does not work.

โžœ  gossm start --profile my-profile
[err] ProcessProviderParseError: parse failed of credential_process output:

caused by: unexpected end of JSON input

AWS_SHARED_CREDENTIALS_FILE Overwritten By Default

I believe AWS_SHARED_CREDENTIALS_FILE is being overwritten by default here in order to support the new MFA feature added recently.

Would it be possible to make this an optional feature? This makes the application interact with the AWS SDK in an unexpected fashion.

In order to avoid this, users have to export AWS_SHARED_CREDENTIALS_FILE=$HOME/.aws/credentials, which forces the shared credentials file to be the default expected for use with the AWS SDK for go.

ssh and scp not working using GOSSM

Hi Team,

I am trying to use scp and ssh using gossm(latest version)
For SCP, I am running below command:

gossm scp -e '-i mykey.pem provider.tf [email protected]:/home/ec2-user/provider.tf'

I am getting below error:

[update] aws ssm plugin
region (eu-west-1)
[โ†[32mscpโ†[0m] region: โ†[33meu-west-1โ†[0m, target: โ†[33mi-00edc94f4fd92b568โ†[0m
scp -i mykey.pem provider.tf [email protected]:/home/ec2-user/provider.tf
panic: interface conversion: interface {} is nil, not string

goroutine 1 [running]:
github.com/aws/SSMCLI/src/sessionmanagerplugin/session.ValidateInputAndStartSession(0xc000114000, 0x6, 0x8, 0xdd6b20, 0xc000006018)
/session-manager-plugin/build/private/src/github.com/aws/SSMCLI/src/sessionmanagerplugin/session/session.go:155 +0xc95
main.main()
/session-manager-plugin/src/sessionmanagerplugin-main/main.go:26 +0x65
kex_exchange_identification: Connection closed by remote host
lost connection
[err][internal.CallProcess:579] exit status 1
๏ฟฝ[33mDelete Session๏ฟฝ[0m ๏ฟฝ[33mvault-1649585555-4314-0e86e1ae247e7b16d๏ฟฝ[0m

===================================================

For ssh also I am getting similar error:

PS C:\Users\dipander.goyal\Downloads> gossm ssh -e '-i session-mgr-euwest1.pem [email protected]'
region (eu-west-1)
[๏ฟฝ[32mssh๏ฟฝ[0m] region: ๏ฟฝ[33meu-west-1๏ฟฝ[0m, target: ๏ฟฝ[33mi-00edc94f4fd92b568๏ฟฝ[0m
ssh -i session-mgr-euwest1.pem [email protected]
panic: interface conversion: interface {} is nil, not string

goroutine 1 [running]:
github.com/aws/SSMCLI/src/sessionmanagerplugin/session.ValidateInputAndStartSession(0xc000114000, 0x6, 0x8, 0xdd6b20, 0xc000006018)
/session-manager-plugin/build/private/src/github.com/aws/SSMCLI/src/sessionmanagerplugin/session/session.go:155 +0xc95
main.main()
/session-manager-plugin/src/sessionmanagerplugin-main/main.go:26 +0x65
kex_exchange_identification: Connection closed by remote host
[err][internal.CallProcess:579] exit status 255

33mDelete Session๏ฟฝ[0m ๏ฟฝ[33mvault-1649585555-4314-054d509536243be49๏ฟฝ[0m

=================================================

Please advise! Thanks in advance.

Feature Request: Add Command for Port-Forwarding

On top of the already useful command set of this tool, I think it can be improved even further by adding a Port-Forwarding command.

Making use of the AWS-StartPortForwardingSession SSM Document we can start a Port-Forwarding session entirely over SSM (See here for an overview).

I have spiked this locally where I've added the fwd command. It prompts the user for the remote port to access and the local port to forward after selecting a target.

image
image

Ports can be specified before selecting a target too, using the -z and -l args.

image

I already have this written up and ready for a PR. Are there any objections to adding this to the existing command set?

Can't start a new session, NoCredentialProviders: no valid providers in chain. Deprecated.

$ gossm start -p aws-292
[err] NoCredentialProviders: no valid providers in chain. Deprecated.
	For verbose messaging see aws.Config.CredentialsChainVerboseErrors
$ gossm --version
gossm version 1.3.1
$ ~/.gossm/session-manager-plugin --version
1.2.30.0

This only happens when I'm using AWS in SSO mode, it works if I copy temporary credentials from the web interface.

Possible regression from v1.2.0 onwards when using aws-vault

I think I just found a regression from version 1.2.0 onwards when using environment variables for the authentication.

Output with version v1.2.0

[aws:devops-test] [pb:~/Downloads]$ gossm start 
[update] aws ssm plugin
[profile] default
NoCredentialProviders: no valid providers in chain. Deprecated.
	For verbose messaging see aws.Config.CredentialsChainVerboseErrors

Output with version v1.1.1

[aws:devops-test] [pb:~/Downloads]$ gossm start
[update] aws ssm plugin
? Choose a target in AWS:  [Use arrows to move, type to filter]
> xxxxx	(i-xxxxxxxxxxxxxxxxxx)
  xxxxx	(i-xxxxxxxxxxxxxxxxxx)

Did something major change with the new version?

I've got a fairly basic AWS configuration with aws-vault profile injections

[profile prod]
include_profile=default
source_profile=default
role_arn=arn:aws:iam::0123456789012:role/role-name

[profile test]
include_profile=default
source_profile=default
role_arn=arn:aws:iam::0123456789012:role/role-name

[default]
region=eu-central-1
mfa_serial=arn:aws:iam::0123456789012:mfa/[email protected]

Bug: Can't start an encrypted session

I get the following error when I try to start a session on version >=v1.1.0

----------ERROR-------
Encountered error while initiating handshake. KMSEncryption failed on client with status 2 error: Failed to process action KMSEncryption: Error calling KMS GenerateDataKey API: UnrecognizedClientException: The security token included in the request is invalid.
	status code: 400, request id: b3ebe283-c1bf-4722-b553-8f08693a9694

gossm v1.0.5 works without any problem.

[err] Incorrect function. when running on windows 10

Hi
I use gossm all the time on my mac. Trying to get it working on my widows machine. Looks like it connects b/c it lists all my instances correctly but then crashes with "err incorrect function" so i cant choose one to connect to. Anyone seen this before?

Feature request: list and connect to on prem instances

Currently the app only lists the EC2 instances, but lacks the possibility to list and connect managed instances that exist only in SSM, not in EC2. It would be great if those instances could be listed in the gossm start subcommand.

Feature Request: Support for StartPortForwardingSessionToRemoteHost

AWS has announced a new functionality to perform portwarding to remote hosts via System Manager Start Session. It would be great to add this new functionality in news versions of gossm

Thanks in advance and thanks for this great tool called gossm!

Release 1.3.0 checks in with version 1.2.3

Some internal version component appears to not have been updated for the 1.3.0 release:

$ tar xf gossm_1.3.0_Linux_x86_64.tar.gz 
$ ./gossm --version
gossm version 1.2.3

Would love to have gossm report the version correctly ๐Ÿ™‚

Feature Request: Support for Amazon ECS Exec to access containers on AWS Fargate and Amazon EC2

AWS has announced a new functionality to access your containers on AWS Fargate and Amazon EC2. ECS Exec leverages AWS Systems Manager (SSM), and specifically SSM Session Manager, to create a secure channel between the device you use to initiate the โ€œexecโ€œ command and the target container.

Announce: https://aws.amazon.com/pt/blogs/containers/new-using-amazon-ecs-exec-access-your-containers-fargate-ec2/
Documentation: https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ecs-exec.html

Thanks in advance and thanks for this great tool

Add functionality to get current version from binary

For packaging reasons it would be ideal to be able to tell which version of the binary is currently installed. This is usually achieved by adding a --version switch. I'd love for gossm to have such a switch.

Add non-interactive flag to enable using gossm in CI/CDs

Hello,

gossm is an ideal candidate to use SSM for CI/CD. It will be a very good wrapper for having running commands and watch its output, it only lacks non-interactive flags. Using a flag to select the instance instead of selecting it interactively going to make this tool very useful.

I will try to add a PR

session-manager-plugin incorrect arch for arm64

Hi,

I am trying to use the gossm package on an arm64 machine, but I am getting the error:

[err][internal.CallProcess:575] fork/exec /.gossm/session-manager-plugin: bad CPU type in executable

When checking the file in my homedir, it is indeed a x86_64 plugin.

Checking the file in the assets directory, it is also an x86_64.

assets/plugin/darwin_arm64
โฏ file session-manager-plugin 
session-manager-plugin: Mach-O 64-bit executable x86_64

Overwriting this with the AWS installed session-manager-plugin in the directory and installing gossm that way solves the issue.

Solution: Add proper ARM64 Arch plugin to the assets.

Document Permissions Required for gossm

Hello!

First of all, thanks for gossm. This tool is awesome!

We've recently run into permissions issues after upgrading to gossm 1.4.0, due to the added API call to ssm:DescribeInstanceInformation. Would it be possible to document the permissions required to utilize gossm so that developers can be assigned minimal privileges to work with it?

Also, in our testing, it seems like the following permissions need to be granted on all resources without restriction in order to use gossm:

      "ssm:GetConnectionStatus",
      "ec2:DescribeInstances",
      "ssm:DescribeSessions",
      "ssm:DescribeInstanceProperties",
      "ssm:DescribeInstanceInformation"

Is there any way to reduce the permissions required to use this tool?

Cannot get the aws credentials from the environment variables

I usually use the STS assume role or MFA verification that gives the session token. After that, I put it to the environment variable and use the AWS CLI. However, this application cannot get the env. variables, just read the ~/.aws/credentials file only. Can you add this feature?

Brew upgrade states a deprecation

Warning: Calling bottle :unneeded is deprecated! There is no replacement.
Please report this issue to the gjbae1212/gossm tap (not Homebrew/brew or Homebrew/core):
  /home/linuxbrew/.linuxbrew/Homebrew/Library/Taps/gjbae1212/homebrew-gossm/gossm.rb:9

Environment variables not being used

Something seems to have changed with v1.2.0 and environment variables aren't being picked up.
The account defined in my ~/.aws/credentials file basically has no permissions other than the ability to assume roles in other accounts.

I use assume-role which sets all the environment variables for me (debug snippet below).

โžœ assume-role <aws_account> <role_name>
Success! IAM session envars are exported.
AWS_CONFIG_REGION="ap-southeast-2";
AWS_USERNAME="xxxxxxx";
MFA_DEVICE_ARGS="--user-name xxxxxxxxx --query MFADevices[0].SerialNumber --output text --profile default";
MFA_DEVICE="arn:aws:iam::xxxxxxxxxx:mfa/xxxxxxxxxx";
SESSION_ARGS="";
SESSION="";
ROLE_SESSION_ARGS="--role-arn arn:aws:iam::xxxxxxxxxx:role/xxxxxxxx --external-id xxxxxxxxxxx --duration-seconds 3600 --role-session-name 1609835656";
ROLE_SESSION="{
    "Credentials": {
        "AccessKeyId": "xxxxxxxxxxxxxxx",
        "SecretAccessKey": "xxxxxxxxxxxxx",
        "SessionToken": "xxxxxxxxxxxxxxx",
        "Expiration": "2021-01-05T09:34:17+00:00"
    },
    "AssumedRoleUser": {
        "AssumedRoleId": "xxxxxxxxxxxxx",
        "Arn": "arn:aws:sts::xxxxxxxxxx:assumed-role/xxxxxxxx/1609835656"
    }
}";
SESSION_TIMEOUT="43200";
ROLE_SESSION_TIMEOUT="3600";
AWS_PROFILE_ASSUME_ROLE="";

But then when I use gossm v1.2.0 it's still using the default account defined in ~/.aws/credentials - if I use v1.1.1 it works as expected.

โžœ gossm start
AccessDeniedException: User: arn:aws:iam::xxxxxxxxxxxx:user/xxxxxxxxxxx is not authorized to perform: ssm:DescribeInstanceInformation on resource: arn:aws:ssm:ap-southeast-2:xxxxxxxxxxxx:*
	status code: 400, request id: c73de091-f822-4189-b4f8-0abf646b6edb

Better documentation around how gossm looks for creds

Just had an issue here (and I haven't had time to confirm it) but it looks like the user had some AWS_ environment vars set and gossm wasn't attempting to pick up ~/.aws/credentials

Would be nice to have a note on how gossm looks for creds (pretty sure it just uses the AWS lib, right?)

์ธ๋ผ์ธ์œผ๋กœ ์ ‘์† ํ• ๋•Œ ์—๋Ÿฌ๊ฐ€ ๋ฐœ์ƒํ•ฉ๋‹ˆ๋‹ค.

์ธ๋ผ์ธ์œผ๋กœ ์ ‘์† ํ• ๋•Œ ์—๋Ÿฌ๋ฅผ ๋ฐœ์ƒํ•ฉ๋‹ˆ๋‹ค.

./gossm -r ap-northeast-1 -t i-XXXXXXXXXXX
[err] don't exist running instances

๋””๋ฒ„๊น…์„ ํ•ด ๋ณด๋‹ˆ PublicDNS๊ฐ€ ์—†๋Š” ์„œ๋ฒ„์— ์ ‘์†ํ• ๋•Œ๋งŒ ๋ฐœ์ƒํ•˜๋Š”๊ฑธ ํ™•์ธํ•˜์˜€์Šต๋‹ˆ๋‹ค.

No MFA support?

Hi,

Today I downloaded gossm to see if it works for us.

But when I run:

gossm -p ****REDACTED**** start

It immediately fails with this error:

AssumeRoleTokenProviderNotSetError: assume role with MFA enabled, but AssumeRoleTokenProvider session option not set.

The profile I use, looks like:

[profile ****REDACTED****]
region = eu-west-1
source_profile = ****REDACTED****
role_arn = arn:aws:iam::****REDACTED****:role/****REDACTED****
mfa_serial = arn:aws:iam::****REDACTED****:mfa/****REDACTED****
cli_pager =

How can I make this work?

Kind regards

Wim

Connection times out

Started getting this error:

Encountered error while initiating handshake. KMSEncryption failed on client with status 2 error: Failed to process action KMSEncryption: Error calling KMS GenerateDataKey API: NoCredentialProviders: no valid providers in chain. Deprecated.
        For verbose messaging see aws.Config.CredentialsChainVerboseErrors

However, starting a session through aws cli connects successsfully.

FilterLimitExceeded when starting a session

gossm start
? Choose a region in AWS: us-east-1
FilterLimitExceeded: The maximum number of filter values specified on a single call is 200
status code: 400, request id: 4732950f-40c4-4c2a-a613-XXXXXXXXXXXXXXXXX

Is this an issue with the API or is this something that can be resolved on your side?

Not working for hybrid images

Hello, as I see in code you're using ec2 describe-instances to filter running instances. But in my case my hybrid instances doesn't appear as ec2 instances but are still available for connection.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.