Skip to content

SecureWindowsShell/SWSH

Repository files navigation


Build status
GitHub issues GitHub forks GitHub stars GitHub license Latest release Top language Website

SWSH is a console application that offers SSH-like connectivity with ease to users which grants them the ability to operate remotely on SSH protocol. It is also Open source, so feel free to contribute.

If you are not using a prebuilt SWSH binary, you will see SWSH complain about a checksum mismatch and exit, use --IgnoreChecksumMismatch to stop it from exiting.

SWSH, just doing its thing SWSH, just doing its thing

Getting Started

Generating SSH keys

SSH keys serve as a means of identifying yourself to an SSH server. To Generate your private and public key, SWSH uses an add-on, swsh-keygen. You can build swsh-keygen yourself if you want and place the executable (.exe) in SWSH's root (installation) directory.

Use command keygen to tell SWSH that you want to generate a new RSA key pair for SSH connection after that just follow the prompts. You'll be asked for locations to store your keys, leave it blank if you want it to be default. Output will be similar to this:

/users/muzzammil:swsh> keygen

Generating public/private rsa key pair.
exit or -e to cancel.
Enter absolute path to save private key (%appdata%/SWSH/swsh.private):
Enter absolute path to save public key (%appdata%/SWSH/swsh.public):
Your public key:

ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAAAgQCt2MxdswuuUvmaY4JK6kP4lYIqGy0KeHCqcx1NEjB4EcqH7+MIeXGbdikACvP3wlOAEAt+7PMEhBHf7nL2S2SsOybpegJw0piiMeOIPJwQxIQFaRWyz3xn0ESItzBizsQ4yxfQiG37sFkMeQVnP5fHuc2+Z4JZ5SD56Dh1xxgnEw==

Importing SSH keys

If you already have SSH keys and want to use them instead of creating a new pair, you can! Use keygen import command to do so and just follow the prompts.

NOTE: DO NOT SHARE YOUR PRIVATE KEY!

Connecting to a host

To connect run connect username@host.

To use a password connection, use tag -p like this: connect username@host -p.

If done properly, output would be similar to the following:

Waiting for response from username@host...
Connected to username@host...
~:/ $

Commands

Command Description
version Check the version of swsh.
connect [user@host] (-p) Connects to Server over SSH.
keygen (options) Generates SSH RSA key pair.
help [command] Displays this help or command details.
clear Clears the console.
pwd Prints working directory.
computehash [(>/>>) path] Uses SHA-1 hash function to generate hashes for SWSH and swsh-keygen.
exit Exits.
ls Lists all files and directories in working directory.
cd [arg] Changes directory to 'arg'. arg = directory name.
upload [arguments] Uploads files and directories. 'upload -h' for help.

For more, see our documentation.

License

GPL v3

Copyright (C) 2017 Muhammad Muzzammil