tilfinltd / aws-extend-switch-roles

Extend your AWS IAM switching roles by Chrome extension, Firefox add-on, or Edge add-on
https://chromewebstore.google.com/detail/aws-extend-switch-roles/jpmkfafbacpgapdghgdpembnojdlgkdl?utm_source=github
MIT License
1.32k stars 141 forks source link

Limit profile length to 47 characters #244

Closed Burekasim closed 1 year ago

Burekasim commented 2 years ago

Hi,

I work for DoiT international and we use this plugin a lot. I would like to thank you for all the hard work you put into the project.

We create the configuration for this plugin automatically, and include a lot of data in the profile name: Internal number, customer name, customer email address

When Switch Role is performed, the profile name in the plugin is entered as the Display name. The display name in AWS is limited to 64 characters (I did not find documentation for this on the AWS website, but when I try with 65 characters I get 400 Bad request error).

In addition, the plugin uses the following structure as the display name: "ProfileName | AccountNumber" (Profile name defined in the configuration, 2 spaces, pipeline char, 2 spaces, AWS account number)

That is, the plugin adds 17 characters to the display name (12 of which are the AWS account number).

I would like to consider adding to the documentation that it is not recommended to exceed 47 characters or check when editing the configuration that the profile length is up to 47 characters.

Best regards Burekasim

tilfin commented 2 years ago

I think that a profile name's maximum is 64 characters if 'Hide account id' option is off. So I'm going to implement validating 64 characters limitation for the profile name. If the option is enabled, I would like to omit the end when it is more than 47 characters.

Burekasim commented 2 years ago

Great,

Thanks for the fast update