Skip to main content

SSH eXtensions

Project description

sshx (SSH eXtensions)

Build Status codecov license Docs Status

sshx is a lightweight wrapper for ssh/scp command, which has the following features:

  • Remember your ssh accounts safely.
  • Connect to your account without typing password.
  • Set jump hosts for your connection.
  • Create ssh port forwardings without typing password.
  • Create socks5 proxy by ssh dynamic port forwarding.
  • Enable jump hosts for your port forwardings.
  • Copy files from/to your account without typing password.
  • Enable jump hosts for your scp connection.
  • Execute remote command without typing password.
  • Enable jump hosts for executing command.
  • Install ssh public keys to remote server.
  • Enable jump hosts for public key installation.

Read full documentation on ReadTheDocs.

Installation

pip install sshx

Supported platform

  • Linux
  • macOS
  • WSL/cygwin/msys2 on Windows

Attention:

  • Native Windows support was removed.
  • Python 2 support was removed.

Requirements

  • Python >= 3.6
  • openssh-clients: ssh, scp, ssh-keygen

Quick Start

  1. Initialization.

    Perform only once after you've installed sshx.

    sshx init
    
  2. Adding an account.

    sshx add myhost -l test@192.168.9.155
    

    (This command will ask you to type your password and sshx would store the encrypted password.)

  3. Connect to the account.

    sshx connect myhost
    

Changelog

0.32.0

New Features

  • add future-fstrings for compatibility of python < 3.6

0.31.0

New Features

  • add --extras for connect command
  • add command copyid
  • use ssh_config for jump hosts instead of -J/-oProxyJump
  • add ssh_config for jump connection

Fixes

  • fix port for account.to_ssh_config()
  • add retry for SSHPexpect.run to fix retry with background
  • encrypt identity passphrase
  • add --bind for command socks to replace -p

0.27.1

New Features

  • add --forever option to keep ssh connection alive forever
  • add socks via
  • add daemonize for running in background
  • add security option

Fixes

  • set expect() to never timeout for foreground
  • fix timeout of forward & socks
  • fix scp with jump and add tests
  • fix local variable 'p' referenced before assignment

0.23.1

Fixes

  • fix password echo when network is bad

0.23.0

New Features

  • add order for click commands
  • add click cli

Fixes

  • fix tests
  • fix expecting and interact
  • fix password revealing when reconnecting failed

0.21.9

New Features

  • add keep alive & retry config
  • add -b/--background for forward & socks command

Fixes

  • handle_update

0.19.8

New Features

  • add sort and reverse for command list
  • add command exec

Fixes

  • (update): fix rename account
  • fix find_vias
  • fix update error

0.17.5

New Features

  • add socks command
  • add debug switch
  • add command show

Fixes

  • fix unittest
  • fix uploading failure on OSX

0.4.3

New Features

  • remove python 2 support

0.3.1

New Features

  • add logging

Fixes

  • remove prints

0.3.0

New Features

  • add scp via multiple jump hosts
  • add connect via multiple jump hosts
  • add jump host for scp
  • add scp command
  • forward without a shell
  • add sshx forward command

Fixes

  • fix tests.test_connect

0.2.1

New Features

  • add via argument for connect

0.2.0

New Features

  • add jump host in command line
  • add jump connection for pexpect

Fixes

  • fix jump connection error

0.1.0

New Features

  • Add test for add command's abbreviation
  • Add abbrev syntax for add command
  • Add auto-adjust window size

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

sshx-0.32.0.tar.gz (22.3 kB view details)

Uploaded Source

Built Distribution

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

sshx-0.32.0-py2.py3-none-any.whl (38.0 kB view details)

Uploaded Python 2Python 3

File details

Details for the file sshx-0.32.0.tar.gz.

File metadata

  • Download URL: sshx-0.32.0.tar.gz
  • Upload date:
  • Size: 22.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.6.7

File hashes

Hashes for sshx-0.32.0.tar.gz
Algorithm Hash digest
SHA256 84c6861f7a359af491745e796bdde75920450d072f8af0a97466deb20cf06865
MD5 4877a308068eb55b49680933323780e9
BLAKE2b-256 3497234567377114194700956c639d27ab3e91a1d350faa22c4f54bfd04b927b

See more details on using hashes here.

File details

Details for the file sshx-0.32.0-py2.py3-none-any.whl.

File metadata

  • Download URL: sshx-0.32.0-py2.py3-none-any.whl
  • Upload date:
  • Size: 38.0 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.6.7

File hashes

Hashes for sshx-0.32.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 3a2352d4b0b0b529260e16537ef8fdb4a451b39d3ad26a8317267399757e2590
MD5 002c100fc696b195f634212921e0f3ef
BLAKE2b-256 ea71640679e3e8579a69314b0a4cea5078f0ca4ed5990f9aa3e9bfc1a32b5b82

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