All Projects → flussonic → Ssh Proxy

flussonic / Ssh Proxy

Licence: mit
SSH proxy that allows support agents go to customers servers with using intermediate corporate SSH key

Programming Languages

erlang
1774 projects

Projects that are alternatives of or similar to Ssh Proxy

Bastillion
Bastillion is a web-based SSH console that centrally manages administrative access to systems. Web-based administration is combined with management and distribution of user's public SSH keys.
Stars: ✭ 2,730 (+5050.94%)
Mutual labels:  ssh, ssh-server
Colab Ssh
Connect to Google Colab using SSH
Stars: ✭ 249 (+369.81%)
Mutual labels:  ssh, ssh-server
lobbyboy
A lobby boy will create a VPS server when you need one, and destroy it after using it.
Stars: ✭ 212 (+300%)
Mutual labels:  ssh, ssh-server
Ssh2docker
🐳 standalone SSH server that connects you to your Docker containers
Stars: ✭ 159 (+200%)
Mutual labels:  ssh, ssh-server
Ansible Ssh Hardening
This Ansible role provides numerous security-related ssh configurations, providing all-round base protection.
Stars: ✭ 746 (+1307.55%)
Mutual labels:  ssh, ssh-server
Ssh
Easy SSH servers in Golang
Stars: ✭ 2,254 (+4152.83%)
Mutual labels:  ssh, ssh-server
sshsyrup
A low-to-medium interaction SSH Honeypot with features to capture terminal activity and upload to asciinema.org
Stars: ✭ 84 (+58.49%)
Mutual labels:  ssh, ssh-server
Sshserver
This is a tutorial on how to build a basic SSH Server in C#, but you are welcome to try following in any language.
Stars: ✭ 114 (+115.09%)
Mutual labels:  ssh, ssh-server
Bastillion Ec2
A web-based SSH console to execute commands and manage multiple EC2 instances simultaneously running on Amazon Web Services (AWS).
Stars: ✭ 410 (+673.58%)
Mutual labels:  ssh, ssh-server
Ssh Mitm
ssh mitm server for security audits supporting public key authentication, session hijacking and file manipulation
Stars: ✭ 335 (+532.08%)
Mutual labels:  ssh, ssh-server
Wolfssh
wolfSSH is a small, fast, portable SSH implementation, including support for SCP and SFTP.
Stars: ✭ 142 (+167.92%)
Mutual labels:  ssh, ssh-server
Sshportal
🎩 simple, fun and transparent SSH (and telnet) bastion server
Stars: ✭ 978 (+1745.28%)
Mutual labels:  ssh, ssh-server
Dos ssh
Use BIOS ram hacks to make a SSH server out of any INT 10 13h app (MS-DOS is one of those)
Stars: ✭ 139 (+162.26%)
Mutual labels:  ssh, ssh-server
Secure Wireguard Implementation
A guide on implementing a secure Wireguard server on OVH (or any other Debian VPS) with DNSCrypt, Port Knocking & an SSH-Honeypot
Stars: ✭ 200 (+277.36%)
Mutual labels:  ssh, ssh-server
Coco
Jumpserver ssh/ws server
Stars: ✭ 139 (+162.26%)
Mutual labels:  ssh, ssh-server
tarssh
A simple SSH tarpit inspired by endlessh
Stars: ✭ 98 (+84.91%)
Mutual labels:  ssh, ssh-server
Mockssh
Mock an SSH server and define all commands it supports (Python, Twisted)
Stars: ✭ 107 (+101.89%)
Mutual labels:  ssh, ssh-server
Addon Ssh
SSH & Web Terminal - Home Assistant Community Add-ons
Stars: ✭ 114 (+115.09%)
Mutual labels:  ssh, ssh-server
Docker Sshd
Minimal Alpine Linux Docker image with sshd exposed and rsync installed
Stars: ✭ 291 (+449.06%)
Mutual labels:  ssh, ssh-server
Ssb
Secure Shell Bruteforcer — A faster & simpler way to bruteforce SSH server
Stars: ✭ 832 (+1469.81%)
Mutual labels:  ssh, ssh-server

ssh-proxy

Most simples Secure Shell proxy to control access of your engineering/support team(s) to private servers.

Inspiration

This tool is for a company that provide support to clients, small engineering teams or start-ups. Anyone who needs centralized, secure and simples access governance to private server. It offers an alternative solution to authorized_keys.

Why not authorized_keys on server?

Imagine that you need to ask for root access on client's server. If you put public keys of all your engineers on client's server, then you need to maintain list of client's servers to delete these keys and you need to disclose list of your people.

All this is a bad idea, especially when you will corrupt authorized_keys on server by running your automation tool and client's simultaneously.

This tool will allow to put only one public key on server and maintain access through this key.

Secondly, it solves a problem of SSH access provision in the ad-hoc cloud environment, where new servers automatically comes and goes.

As benefits, you gets

  1. No LDAP, Kerberos or any other nightmare technologies
  2. No need to share private key with all your team including fired people
  3. All actions are logged so that you will be able to find, who have dropped production database

Please be aware that solution is still under development.

Key features

  • Secure shell proxy.
  • Secure port forwarding via stdio.
  • Of-the-shelf deployment to docker-based environments.

Getting started

SSH proxy is a daemon that helps you to control access of your support team to customers servers with following workflow:

  1. You create your team key pair
  2. Give public key to all customers
  3. Store private key on a private server that runs a proxy. The access to this server has to be limited to yourself
  4. Take public key from your support personnel
  5. Upload them on that proxy server
  6. Now your support stuff can login to customer server unless you revoke this access

Use the proxy to control access of your engineering team to cloud servers with similar workflow

  1. Use the console to generate key pair(s) for your environment.
  2. Upload the private key to a ssh-proxy server.
  3. Take public key from your engineers (e.g. github identity)
  4. Upload public keys on that proxy server.
  5. Now your support stuff can login to cloud servers unless you revoke this access

Running the proxy

The easiest way to run Secure Shell proxy is Docker containers, there are available pre-build images at flussonic/ssh-proxy. Alternatively, you can use Erlang escript to spawn a daemon but it requires an installation of Erlang OTP/19 or later release.

docker run -it --rm --name ssh-proxy \
    -p ${CONFIG_SSH_PORT}:2022 \
    -v ${CONFIG_SSH_AUTH}:/opt/data/auth \
    -v ${CONFIG_SSH_USERS}:/opt/data/users \
    flussonic/ssh-proxy

Use environment variables or other means to configure the proxy container

## defines a port used by proxy
export CONFIG_SSH_PORT=2022

## location of server's private key
export CONFIG_SSH_AUTH=/tmp/ssh/auth

## location of user's publick key. Only these user will be able to build a tunnel
export CONFIG_SSH_USERS=/tmp/ssh/users

Configure a private key

Upload a team private key (the key that provisions access to all private servers) id_rsa to ${CONFIG_SSH_AUTH} folder on ssh-proxy server.

Add/revoke users access

Upload users public key to ${CONFIG_SSH_USERS} folder on ssh-proxy server. Name the file after the users name. User's access is revoked if you delete this key from the proxy.

Establish Secure Shell session

Your team needs to update ~/.ssh/config file with details of ssh proxy

Host ssh-proxy
   HostName 127.0.0.1
   Port 2022
   User my-user-name
   IdentityFile ~/.ssh/my-public-key

Please note that proxy has a special syntax to identify private servers. Username, host and ports have to be specified like user/host/port.

ssh user/[email protected]

Port forwarding

Erlang SSH subsystem do not supports a standard ssh port forwarding. The proxy daemon implements a port forwarding using standard I/O. Using a special syntax:

ssh user/private-host~forward-host/[email protected]

Once SSH connection is established, any stdin is delivered to forward-host/port and its response available at stdout of your local ssh process. A following scripts helps you to attach ssh stdio to any local port.

mkfifo pipe
while [ 1 ]
do

nc -l 8080 < pipe | ssh -T user/private-host~forward-host/[email protected] | tee pipe > /dev/null

done

How To Contribute

The project accepts contributions via GitHub pull requests.

  1. Fork it
  2. Create your feature branch git checkout -b my-new-feature
  3. Commit your changes git commit -am 'Added some feature'
  4. Push to the branch git push origin my-new-feature
  5. Create new Pull Request

The proxy development requires Erlang OTP/19 or later release.

Use the following command to run the proxy locally for RnD purposes

escript ssh-proxy.erl \
   -p 2022 \
   -i /tmp/ssh/auth \
   -u /tmp/ssh/users \
   -t /tmp/ssh/server
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].