Skip to main content

Command line tool for AWS CLI authentication

Project description

auther

Auther is a CLI tool which authenticates your AWS CLI using various identity providers - all in one tool!

Currently supported Identity Providers

  • Azure Active Directory - azuread

Installation

Pip

$ pip install auther

Further info on PyPi.

Docker

$ docker run -it --rm -v ~/.aws:/root/.aws trewq34/auther

When looking at usage information, the above command is a direct replacement for auther. Although you may wish to create a command alias with your chosen shell for ease.

Further info on Docker Hub.

Usage

Configure

Before using auther to authenticate your AWS CLI, you need to configure it. This can be done quite using auther configure

# Uses the default options, most importantly: AWS config file path, AWS region, AWS profile and Auther provider
$ auther configure
Your Azure AD Tenant ID: 30e04ef1-fb0d-4844-87a5-8720745de01b
Your Azure AD Application ID: 94ab3a5d-1b99-416a-bcaf-669f7b6bcaba
The username you use to sign in: someone@company.com

If you need to use a different AWS CLI profile or AWS region, you can override these by passing in options to the configure command

$ auther configure --profile saml --region us-east-1

This will create/update a CLI profile called saml for use in the us-east-1 region.

For all available configuration options and their defaults, you can use the following command

$ auther configure --help

Login

Once you have configured your AWS CLI profile for use with auther for authentication, you can login simply using the following command

# Uses the default options, most importantly: AWS config file path, AWS credential file path, AWS profile and Auther provider
$ auther login

If you wish to override override any of the defaults, you can do so by passing in options to the login command. A list of available options and their defailts is available using the following command

$ auther login --help

Troubleshooting

Chromium failed to download

A common cause for this is a corporate proxy/firewall blocking such downloads. To work around this, you can set the CHROME_BIN environment variable pointing to your preinstalled Google Chrome, Chromium or Microsoft Edge installation (this will probably work with other Chromium based browsers too, although hasn't been tested).

Some examples per OS can be seen below

macOS

# Google Chrome
$ export CHROME_BIN="/Applications/Google Chrome.app/Contents/MacOS/Google Chrome"

# Microsoft Edge
$ export CHROME_BIN="/Applications/Microsoft Edge.app/Contents/MacOS/Microsoft Edge"

# Chromium
$ export CHROME_BIN="/Applications/Chromium.app/Contents/MacOS/Chromium"

Windows

# Google Chrome
PS C:\Users\username> $env:CHROME_BIN="C:\Program Files\Google\Chrome\Application\chrome.exe"

# Microsoft Edge
PS C:\Users\username> $env:CHROME_BIN="C:\Program Files (x86)\Microsoft\Edge\Application\msedge.exe"

# Chromium - this depends on how you installed it. Assuming you installed it the same way I did, the path will be
PS C:\Users\username> $env:CHROME_BIN="C:\Users\username\AppData\Local\Chromium\Application\chrome.exe"

Linux

This will vary vastly depending on which distro you use. I've tested on RHEL 7.9, so this may not be the same as your distro. In any case, you can verify the path using the which command.

# Google Chrome
$ export CHROME_BIN="/usr/bin/google-chrome"

# Microsoft Edge
$ export CHROME_BIN="/usr/bin/microsoft-edge"

# Chromium
$ export CHROME_BIN="/usr/bin/chromium-browser"

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

auther-0.0.5.tar.gz (10.7 kB view details)

Uploaded Source

Built Distribution

auther-0.0.5-py3-none-any.whl (11.0 kB view details)

Uploaded Python 3

File details

Details for the file auther-0.0.5.tar.gz.

File metadata

  • Download URL: auther-0.0.5.tar.gz
  • Upload date:
  • Size: 10.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.13

File hashes

Hashes for auther-0.0.5.tar.gz
Algorithm Hash digest
SHA256 3a98b449e3b56c4e0201e453f8717eacd3791cbb22ffddad3f437fe2c7962dab
MD5 48decfdf4b4274b5fdc3634cd712882c
BLAKE2b-256 6430f5baf2ae0f211974d89e9ac70a1ef3f606cedf239eaa119c9f0c1474f997

See more details on using hashes here.

File details

Details for the file auther-0.0.5-py3-none-any.whl.

File metadata

  • Download URL: auther-0.0.5-py3-none-any.whl
  • Upload date:
  • Size: 11.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.13

File hashes

Hashes for auther-0.0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 6dd7fd1d9dd06f41fca93a1382f8d533feddd9165fa2bdf620748e10c2f0ee6f
MD5 de2645efbc2e578439a7fd0574a05c2c
BLAKE2b-256 f100122e605c09f8ea0a269840ba031cb80cda6eb6adf1d01ab186c3ec5b5a20

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page