Skip to content

Zsh script for assuming an AWS IAM role using MFA authentication

Notifications You must be signed in to change notification settings

dedoussis/AWS-Assume-Role

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 

Repository files navigation

Assume IAM role script for AWS

As a user of an AWS account, use this zsh script to assume any given IAM role within the account.
Includes step of MFA authentication.

Usage

# Replace {role} with the ARN of the target IAM role. 
# Then run:
role_arn={role} source aws_assume_role.sh

Script will export AWS_ACCESS_KEY, AWS_SECRET_ACCESS_KEY and AWS_SESSION_TOKEN in the current shell.

Background

Further info on temporary security credentials can be found here.

About

Zsh script for assuming an AWS IAM role using MFA authentication

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages