It prevents gimme-aws-creds --configure from setting device_token to an invalid value.
It forces device registration for any user that uses clasic okta with an invalid device token set.
Related Issue
407
Motivation and Context
I was getting double-MFAs. My config file contained device_token=.
After some pondering, I decided the default value for a feature is likely not intended to break said feature.
How Has This Been Tested?
gimme-aws-creds --configure && gimme-aws-creds && gimme-aws-creds without my changes. 2 MFAs on second gimme-creds.
gimme-aws-creds && gimme-aws-creds without my changes. 2 MFAs on second gimme-creds.
gimme-aws-creds --configure && sed -i'.bak' "s/device_token =.*//" ~/.okta_aws_login_config && gimme-aws-creds && gimme-aws-creds without my changes. 1 MFA on second gimme-creds.
gimme-aws-creds --configure && gimme-aws-creds && gimme-aws-creds with my changes. 1 MFA on second gimme-creds.
gimme-aws-creds && gimme-aws-creds with my changes. 1 MFA on second gimme-creds.
Types of changes
[X] Bug fix (non-breaking change which fixes an issue)
[ ] New feature (non-breaking change which adds functionality)
[X] Breaking change (fix or feature that would cause existing functionality to change)
Checklist:
[X] My code follows the code style of this project.
[ ] My change requires a change to the documentation.
Description
This PR does two things:
gimme-aws-creds --configure
from settingdevice_token
to an invalid value.Related Issue
407
Motivation and Context
I was getting double-MFAs. My config file contained
device_token=
. After some pondering, I decided the default value for a feature is likely not intended to break said feature.How Has This Been Tested?
gimme-aws-creds --configure && gimme-aws-creds && gimme-aws-creds
without my changes. 2 MFAs on second gimme-creds.gimme-aws-creds && gimme-aws-creds
without my changes. 2 MFAs on second gimme-creds.gimme-aws-creds --configure && sed -i'.bak' "s/device_token =.*//" ~/.okta_aws_login_config && gimme-aws-creds && gimme-aws-creds
without my changes. 1 MFA on second gimme-creds.gimme-aws-creds --configure && gimme-aws-creds && gimme-aws-creds
with my changes. 1 MFA on second gimme-creds.gimme-aws-creds && gimme-aws-creds
with my changes. 1 MFA on second gimme-creds.Types of changes
Checklist: