Skip to content

Use MaxResults/pagination for list_secrets in AWS Secrets Manager - or switch to describe_secret instead #107

Description

@lancenz

In services/aws.py:list_secret_names() there is no MaxResults nor any pagination code - so in any account with a lot of secrets, it may not return the secret being used - which will then cause create_or_update_secret() to fail creating a new secret instead of updating the existing one.

Alternatively, could refactor the code to call describe_secret instead of list_secrets as this would reduce the IAM policy requirements and also fix pagination issues at the same time.

Thanks, this tool is really helpful :)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions