Git Product home page Git Product logo

sshmon's Introduction

SSHMon

SSHMon is a program designed to manage and monitor ssh connections. It has been tested on Linux and OSX with SSH ≥ 6.7.

gui-sample.png

How it works

SSHMon builds on top of the SSH "Control Master" feature, that facilitates port forwarding setup.

Disclaimer

  • SSHMon Features (e.g. SSH host definition and connection) are exposed through the GUI. As a consequence, extreme care should be taken to make sure it is only reachable by you. Use at your own risk.
  • SSHMon is still at an early stage of development, as a result some things might not work and we might introduce some breaking changes... Any feedback will be greatly appreciated!

Features

  • Nice GUI
  • SSH port/socket forwarding management
  • Configuration with YAML file
  • Automatic start and retry of connection and port forwarding
  • HTTP forwarding

Get started

Download the latest release of SSHMon for your system and unpack it. Run the sshmon binary:

./sshmon

Then you can access the web GUI at http://localhost:8377.

Go and have a look at the Tutorial to set up your first host!

Build from source

yarn
yarn build
yarn start

Configure

You can set up SSH connections through the GUI or with a configuration file.

By default, SSHMon will create a config file located at ~/.sshmon/config.yml. You also may specify your own configuration file on the command line.

Head over to the Configuration page for more details.

Logging

Logging is handled by the bunyan library. A bunyan process is launched along with SSHMon and writes logs to stderr.

By default, if stderr is a TTY, the logs are pretty-printed, else they are written in a JSON format. You may use the BUNYAN_OPTS environment variable to choose which args are passed to the bunyan process, e.g.:

BUNYAN_OPTS='-l debug' ./sshmon

Test

Docker and docker-compose are required.

You may run the test suite with:

yarn test

Troubleshooting

  • So far, only public/private key authentication is supported.
  • Before trying to connect to a host through SSHMon, make sure you can connect to it with SSH on the command line.

Built with

SSHMon was developped thanks to the following projects (this list is not exhaustive!):

TODO

  • Allow to change GUI address
  • Offer multiple GUI themes
  • Allow custom global SSH config options
  • Use BatchMode for ProxyJump SSH hosts

sshmon's People

Contributors

dependabot[bot] avatar hpello avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

sshmon's Issues

权限问题

能不能增加一个小的登录功能。登录成功之后才能看到管理界面。虽不是特需要安全的东西,但也想不让任何人都可以看到,谢谢

No real issue here, just compliments

Hey there,

I just wanted to compliment you on the project. It's great, and it works on Bash on Windows 10's WSL too!

This is extremely convenient for managing my home network: I can just connect to my gateway server from anywhere in the world and then easily start tunnels to all my internal home servers.

Thank you for making this!

Cannot execute binary file: Exec format error

Upon attempting to execute the latest release on my laptop, I get this:

$ ./sshmon-linux-x64-v0.4.0.tar.gz 
bash: ./sshmon-linux-x64-v0.4.0.tar.gz: cannot execute binary file: Exec format error

uname -a: Linux Riikaan 4.13.0-41-generic #46-Ubuntu SMP Wed May 2 13:38:30 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux

Interface says "connecting", error on console

I have successfully used sshmon on several machines (it's amazing!). On a new machine, after configuring a host and hitting connect, the GUI reports "connecting" and gets stuck there. The following is written to the console. The temp files are there in /tmp.

[2020-01-22T22:11:55.757Z] DEBUG: sshmon/7298 on hubble: register socket 2f_v_ftfAnSJrydkAAAB (scope=api/socket-notify)
[2020-01-22T22:12:07.620Z] DEBUG: sshmon/7298 on hubble: ssh -N -T -M -o ControlPersist=no -o BatchMode=yes -o StreamLocalBindUnlink=yes -o ServerAliveInterval=5 -o ServerAliveCountMax=3 -S /tmp/sshmon-7298wQE0Ol2Rrm5x/1 predator (scope=host/ssh, childPid=7794)
[2020-01-22T22:12:07.620Z] DEBUG: sshmon/7298 on hubble:  (scope=redux)
    action: {
      "type": "HOST_STATE_CHANGE",
      "id": "predator",
      "status": "connecting",
      "pid": 7794,
      "controlPath": "/tmp/sshmon-7298wQE0Ol2Rrm5x/1",
      "reason": "api"
    }
[2020-01-22T22:12:07.622Z]  INFO: sshmon/7298 on hubble: api call success (scope=api/socket-setup)
    apiCall: {
      "key": "hostConnect",
      "args": {
        "id": "predator"
      }
    }
[2020-01-22T22:12:07.624Z] ERROR: sshmon/7298 on hubble: watcher error (scope=host/thunks/connect-thunks, err.code=ENOSPC)
    Error: watch /tmp/sshmon-7298wQE0Ol2Rrm5x ENOSPC
        at _errnoException (util.js:1031:13)
        at FSWatcher.start (fs.js:1397:19)
        at Object.fs.watch (fs.js:1423:11)
        at createFsWatchInstance (/snapshot/sshmon/server/node_modules/chokidar/lib/nodefs-handler.js:37:15)
        at setFsWatchListener (/snapshot/sshmon/server/node_modules/chokidar/lib/nodefs-handler.js:80:15)
        at FSWatcher.NodeFsHandler._watchWithNodeFs (/snapshot/sshmon/server/node_modules/chokidar/lib/nodefs-handler.js:229:14)
        at FSWatcher.NodeFsHandler._handleDir (/snapshot/sshmon/server/node_modules/chokidar/lib/nodefs-handler.js:408:19)
        at FSWatcher.<anonymous> (/snapshot/sshmon/server/node_modules/chokidar/lib/nodefs-handler.js:456:19)
        at FSWatcher.<anonymous> (/snapshot/sshmon/server/node_modules/chokidar/lib/nodefs-handler.js:461:16)
        at FSReqWrap.oncomplete (fs.js:167:5)

Allow configuration of ~/.sshmon config dir location

On linux, sshmon creates the ~/.sshmon directory. I've got far too many dot-directories in my home folder, so could this directory be configurable? I'd like it to be ~/.config/sshmon (the ~/.config directory is where per-user configuration files should go on Linux).

I'd suggest an environment variable. Maybe SSHMON_HOME or SSMON_DIR?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.