Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

prevent windows exec unintentional relative pathing #792

Merged
merged 1 commit into from
Jul 12, 2021

Conversation

secjosh
Copy link
Contributor

@secjosh secjosh commented Jul 12, 2021

Hi maintainers! I'm Josh and I work at Bison Trails. We're doing an internal hackathon this week.

Our team loves aws-vault, but it got flagged during a recent security review. Our team voted to use our hackathon time to patch vulnerabilities in our favorite OSS tools and specifically to try to get aws-vault approved for usage within our organization.

What's here:

  • Prevent wrong executable for credential process and exec subcommand on windows by removing current working directory from the beginning of $PATH. see more here https://blog.golang.org/path-security

Impact:

These changes should improve aws-vault's security posture. We identified this vulnerability using Salus and the OSSF scorecard. The specific issues I am hoping to address here are:

  • Preventing wrong executable from being run by replacing os/exec with golang.org/x/sys/execabs on all go files that are built for windows.

What's next:

  • an additional PR for respecting scripts execute permissions on assumerolewithwebidentity

@mtibben
Copy link
Member

mtibben commented Jul 12, 2021

Thanks @secjosh

@mtibben mtibben merged commit 04427f6 into 99designs:master Jul 12, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants