- Go to AWS console,
IAM
service,Users
, locate your user and select it then selectSecurity credentials
- Assign new MFA device by clinking
Assigned MFA device
andA virtual MFA device
- On
configuration information screen
configure your favourite token generation tool with the provided QR code graphic and click onShow secret key for manual configuration
- Copy the secret configuration key to
~/.assume-role.properties
, usemfa.secret
property - Use your token generation tool to finish token validation(
Authentication Code 1
andAuthentication Code 2
) or executeassume-role --generate-token
- Done
Note: If you are already using MFA device you have to deactivate it first