From 0268147366e55f309a3a8fbeffaf72e5d3e9e587 Mon Sep 17 00:00:00 2001 From: tgic Date: Mon, 8 Dec 2014 12:13:07 +0800 Subject: [PATCH] Update README.md --- README.md | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 53 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index f4a67c3e..3a84527d 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,53 @@ -sshpiper -======== +# SSH Piper + +SSh Piper works as a proxy-like ware, and route connections by `username`, `src ip` , etc. + +``` ++---------+ +------------------+ +-----------------+ +| | | | | | +| Bob +----ssh -l bob----+ | SSH Piper +-------------> Bob' machine | +| | | | | | | | ++---------+ | | | | +-----------------+ + +---> pipe-by-name--+ | ++---------+ | | | | +-----------------+ +| | | | | | | | +| Alice +----ssh -l alice--+ | +-------------> Alice' machine | +| | | | | | ++---------+ +------------------+ +-----------------+ + +``` + +## Install + +``` +go get github.com/tg123/sshpiper/sshpiperd +go install github.com/tg123/sshpiper/sshpiperd +``` + +## Quick start + +Just run `showme.sh` in [sshpiperd exmaple directory](sshpiperd/example) +``` +$GOPATH/src/github.com/tg123/sshpiper/sshpiperd/example/showme.sh +``` + +the example script will setup a sshpiper server using +``` +ssh 127.0.0.1 -p 2222 -l github # connect to github.com:22 +ssh 127.0.0.1 -p 2222 -l linode # connect to lish-atlanta.linode.com:22 +``` + +connect to linode + +``` +$ ssh 0 -p 2222 -l linode.com:22 +linode@0's password: +``` + + +connect to github.com:22 + +``` +$ ssh 0 -p 2222 -l github +Permission denied (publickey). +```