# Switch Role fails when only one side was fixed

A cross-account role switch needs both sides to allow it. If you fix the trust policy and wait for
the user to confirm, the half-fix hides for months while people route around it with worse
workarounds.

A delivery engineer could not switch from his SSO session into a role in a different org to renew
licences. The fix from months earlier had added a trust statement on the target role. The open item,
verify the user can assume via SSO and waiting for confirmation, was never closed. Nine months later
the switch still failed, and a colleague had worked around it with local IAM users that were created
and then deleted.

I re-read the trust policy first. It was intact, so that side was fine. The problem sat in the
caller's own permission set. Its only allow on the switch action pointed at a different role. A
cross-account AssumeRole needs both sides: the target role's trust policy and the caller's identity
policy. The earlier fix had changed one side only.

The repair was one read, one write and one reprovision: add the target role to that statement and
reprovision the permission set. I backed up the old policy first, and a CloudTrail check showed
nobody had touched the permission set in 90 days, so the gap had sat there since the original fix.
The user signed out of the SSO portal and back in, then switched. It worked first try.

Close the loop yourself when you grant a role switch: change and test both sides in the same change,
and don't close the ticket on waiting for confirmation. The permission set is shared by the whole SSO
group, so the identity-side grant lives as long as the trust statement and must be removed with it.
