{"id":15444589,"url":"https://github.com/cariad/wev-awsmfa","last_synced_at":"2025-03-28T08:14:02.236Z","repository":{"id":54870789,"uuid":"319433437","full_name":"cariad/wev-awsmfa","owner":"cariad","description":"A wev plugin to support Amazon Web Services multi-factor authentication on the command line","archived":false,"fork":false,"pushed_at":"2021-01-23T16:38:15.000Z","size":5577,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2024-05-01T18:33:25.741Z","etag":null,"topics":["multi-factor-authentication"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cariad.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null},"funding":{"github":"cariad"}},"created_at":"2020-12-07T20:15:00.000Z","updated_at":"2021-01-23T16:38:18.000Z","dependencies_parsed_at":"2022-08-14T05:20:15.492Z","dependency_job_id":null,"html_url":"https://github.com/cariad/wev-awsmfa","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cariad%2Fwev-awsmfa","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cariad%2Fwev-awsmfa/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cariad%2Fwev-awsmfa/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cariad%2Fwev-awsmfa/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cariad","download_url":"https://codeload.github.com/cariad/wev-awsmfa/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245991585,"owners_count":20706129,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["multi-factor-authentication"],"created_at":"2024-10-01T19:41:56.753Z","updated_at":"2025-03-28T08:14:02.216Z","avatar_url":"https://github.com/cariad.png","language":"Python","funding_links":["https://github.com/sponsors/cariad"],"categories":[],"sub_categories":[],"readme":"# wev-awsmfa\u003cbr /\u003eA wev plugin to support Amazon Web Services multi-factor authentication on the command line\n\n[![codecov](https://codecov.io/gh/cariad/wev-awsmfa/branch/main/graph/badge.svg?token=TS995LZMW1)](https://codecov.io/gh/cariad/wev-awsmfa)\n\n- ⚙️ Plugin for **[wev](https://github.com/cariad/wev)**.\n- 👮 Takes your **one-time token** and creates a **temporary multi-factor authenticated session**.\n- 📋 **Caches** your temporary session to **minimise prompts**.\n\n[![asciicast](https://asciinema.org/a/386493.svg)](https://asciinema.org/a/386493?size=big\u0026speed=1.2)\n\n## 🔥 The Problem\n\nSay your IAM user policy requires you to verify your identity via multi-factor authentication.\n\nThis limits your ability to use the `aws` CLI because you can't provide MFA tokens with your requests.\n\n`wev-awsmfa` extends [wev](https://github.com/cariad/wev) to prompt for your one-time tokens and authenticate you automatically.\n\n## 🎁 Installation\n\n`wev-awsmfa` requires Python 3.8 or later and `wev`.\n\n```bash\npython -m pip install wev\npython -m pip install wev-awsmfa\n```\n\n## ⚙️ Configuration\n\n### Filename and location\n\nSee [wevcli.app/configuration](https://wevcli.app/configuration) for a detailed guide to `wev` configuration files.\n\nIf in doubt, create your configuration file as `wev.yml` in your project directory.\n\n### Keys\n\n`wev-awsmfa` must be configured to resolve three environment variables:\n\n| Index | Description       | Suggested name          |\n|------:|-------------------|-------------------------|\n| 0     | AWS access key ID | `AWS_ACCESS_KEY_ID`     |\n| 1     | AWS secret key    | `AWS_SECRET_ACCESS_KEY` |\n| 2     | AWS session token | `AWS_SESSION_TOKEN`     |\n\n### Properties\n\n`wev-awsmfa` supports two optional properties:\n\n| Property   | Description                                  | Default                                   |\n|------------|----------------------------------------------|-------------------------------------------|\n| duration   | Duration of the temporary session in seconds | 900                                       |\n| mfa_device | ARN of the multi-factor device to use        | _Attempt to discover automatically._ |\n\n### Examples\n\n#### Minimal configuration\n\n```yaml\n[AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY, AWS_SESSION_TOKEN]:\n  plugin:\n    id: wev-awsmfa\n```\n\n#### 30-second sessions\n\n```yaml\n[AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY, AWS_SESSION_TOKEN]:\n  plugin:\n    id: wev-awsmfa\n    duration: 1800\n    mfa_device: arn:aws:iam::123456789012:mfa/foo\n```\n\n## 💻 Usage\n\nRun `wev` with any command that requires a multi-factor authenticated session.\n\nFor example, to run `aws s3 ls` in a multi-factor authenticated session:\n\n```bash\nwev aws s3 ls\n```\n\nYou'll be prompted to enter your one-time token, then `wev` will authenticate you and run the command.\n\nMore examples:\n\n- [Amazon Web Services multi-factor authentication on the command line](https://wevcli.app/examples/aws-mfa-on-command-line/) on [wevcli.app](https://wevcli.app).\n\n\n## FAQs 🙋‍♀️\n\n### Will wev-awsmfa work with my scripts?\n\nYes! `wev-awsmfa` will work with _any_ command line application or script that requires a multi-factor authenticated session\n\n## Thank you! 🎉\n\nMy name is **Cariad**, and I'm an [independent freelance DevOps engineer](https://cariad.me).\n\nI'd love to spend more time working on projects like this, but--as a freelancer--my income is sporadic and I need to chase gigs that pay the rent.\n\nIf this project has value to you, please consider [☕️ sponsoring](https://github.com/sponsors/cariad) me. Sponsorships grant me time to work on _your_ wants rather than _someone else's_.\n\nThank you! ❤️\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcariad%2Fwev-awsmfa","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcariad%2Fwev-awsmfa","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcariad%2Fwev-awsmfa/lists"}