This commit extracts the GPG code used for aws_iam_user_login_profile into a library that can be reused for other resources, and updates the call sites appropriately.