This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def assume_full_access_role(accountid, user): | |
| """ | |
| start assume session role with full access profile for the provided account ID with user | |
| """ | |
| print("Creating custom Assumerole Session") | |
| boto_session_original = boto3.Session( | |
| profile_name="identity", region_name="<default region name>" | |
| ) | |
| mfa_1 = input("Enter MFA Code: ") | |
| sts_connection = boto_session_original.client("sts") |