Skip to main content

JumpCloud AWS CLI Authentication with Device Trust

Project description

JumpCloud AWS CLI Authentication Utility

A Python utility for authenticating with AWS CLI using JumpCloud SAML and Device Trust certificates.

Features

  • Browser-based authentication with JumpCloud
  • Automatic Device Trust certificate handling
  • SAML assertion capture and parsing
  • AWS STS role assumption
  • AWS CLI credential configuration
  • Cross-platform (works on macOS, Windows, and Linux)
  • Built-in ChromeDriver management support

Installation

Basic Installation

pip install jumpcloud-awscli

Installation with Automatic WebDriver Management

pip install jumpcloud-awscli[auto-webdriver]

Requirements

  • Python 3.6+
  • Chrome or Chromium browser

The package will use ChromeDriver in one of these ways:

  1. System-installed ChromeDriver (if available in your PATH)
  2. Automatic download via webdriver-manager (if you installed with [auto-webdriver])

Usage

Basic Usage

# Authenticate with JumpCloud and update AWS credentials
jumpcloud-awscli login --url "https://sso.jumpcloud.com/saml2/yourapp"

All Options

jumpcloud-awscli login --url "https://sso.jumpcloud.com/saml2/yourapp" \
                 --profile "jumpcloud" \
                 --duration 43200 \
                 --region "us-west-2" \
                 --debug

Using Environment Variables

You can set the JumpCloud URL as an environment variable:

# Set the environment variable
export JUMPCLOUD_AWS_URL="https://sso.jumpcloud.com/saml2/yourapp"

# Then you can run without the --url parameter
jumpcloud-awscli login

Help Information

# Show help for all commands
jumpcloud-awscli --help

# Show help for the login command
jumpcloud-awscli login --help

How It Works

  1. Launches a Chrome browser session to authenticate with JumpCloud
  2. The browser automatically presents your Device Trust certificate during authentication
  3. After successful authentication, it captures the SAML assertion
  4. Parses the SAML assertion to extract available AWS roles
  5. Lets you select a role (if multiple are available)
  6. Uses AWS STS to assume the selected role with the SAML assertion
  7. Updates your AWS CLI credentials file with temporary credentials

Troubleshooting

Chrome/ChromeDriver Issues

If you encounter issues with Chrome or ChromeDriver:

  1. First, try installing the package with automatic WebDriver management:

    pip install jumpcloud-awscli[auto-webdriver]
    
  2. If that doesn't work, you can install ChromeDriver manually:

    For macOS:

    brew install --cask chromedriver
    xattr -d com.apple.quarantine $(which chromedriver)
    

    For Windows: Download from ChromeDriver website and add to PATH

    For Linux:

    # Debian/Ubuntu
    sudo apt-get install chromium-chromedriver
    
    # CentOS/RHEL
    sudo yum install chromedriver
    

Debug Mode

For more detailed output, use the --debug flag:

jumpcloud-awscli login --url "https://sso.jumpcloud.com/saml2/yourapp" --debug

macOS SSL Certificate Issues

If you encounter SSL certificate errors on macOS:

# Fix SSL certificates
/Applications/Python*/Install\ Certificates.command

Common Issues

  • Certificate selection problems: If prompted for a certificate and it fails, check that your JumpCloud Device Trust certificate is properly installed.
  • Authentication timeouts: If the process times out during authentication, check your network connection and ensure you're using the correct JumpCloud credentials.
  • No roles found: Verify that your JumpCloud user has the proper AWS application role assignments.

License

MIT License

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

jumpcloud_awscli-0.2.1rc1.tar.gz (11.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

jumpcloud_awscli-0.2.1rc1-py3-none-any.whl (10.9 kB view details)

Uploaded Python 3

File details

Details for the file jumpcloud_awscli-0.2.1rc1.tar.gz.

File metadata

  • Download URL: jumpcloud_awscli-0.2.1rc1.tar.gz
  • Upload date:
  • Size: 11.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for jumpcloud_awscli-0.2.1rc1.tar.gz
Algorithm Hash digest
SHA256 22db4960289b1183b58876b9f44cea2b4693e91714b72fab27f7bd48e25b91a6
MD5 4df04123b64ffe4822780ef683805ed9
BLAKE2b-256 e8c2f14cdb9ce4518598afa63fda21be66f837124c3de5b20d48b6af4c3a212d

See more details on using hashes here.

File details

Details for the file jumpcloud_awscli-0.2.1rc1-py3-none-any.whl.

File metadata

File hashes

Hashes for jumpcloud_awscli-0.2.1rc1-py3-none-any.whl
Algorithm Hash digest
SHA256 ac08f84054e520acad6ce66c5cc583ce3a8457bfc222712325606f46b2950947
MD5 782e6b0f21c54c492c887b5a1067791a
BLAKE2b-256 b707bf9deb5c4723ae5e4d5d1a13919bd6c799997ad311c4fccac279b9d03fff

See more details on using hashes here.

Supported by

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