Web SSH 客户端工具

webssh简介
如何在浏览器web页面登录我们的linux机器,这个工具是使用Python开发

官网:https://pypi.org/project/webssh/

webssh这个工具可以干啥??

在linux机器上安装python环境,并且使用命令pip3 install webssh,装上这个模块

功能
支持SSH密码验证,包括空密码。
支持SSH公钥认证,包括DSA RSA ECDSA Ed25519密钥。
支持加密密钥。
支持两要素身份验证(基于时间的一次性密码)
支持全屏终端。
终端窗口可调整大小。
自动检测ssh服务器的默认编码。
现代浏览器支持Chrome,Firefox,Safari,Edge,Opera。

1,安装
pip3 install webssh

[root@centos8 ~]# pip3 install webssh  
WARNING: Running pip install with root privileges is generally not a good idea. Try `pip3 install --user` instead.
Collecting webssh
  Downloading https://files.pythonhosted.org/packages/cf/62/70ec57c40f1eb6d789a19f7af3075d14ad09cf283482d6ae6acfc75be1ea/webssh-1.5.3.tar.gz (182kB)
    100% |████████████████████████████████| 184kB 38kB/s 
Collecting tornado>=4.5.0 (from webssh)
  Downloading https://files.pythonhosted.org/packages/01/d1/8750ad20cbcefb499bb8b405e243f83c2c89f78d139e6f8c8d800640f554/tornado-6.1-cp36-cp36m-manylinux1_x86_64.whl (427kB)
    100% |████████████████████████████████| 430kB 24kB/s 
Requirement already satisfied: paramiko>=2.3.1 in /usr/lib/python3.6/site-packages (from webssh)
Requirement already satisfied: bcrypt>=3.1.3 in /usr/lib64/python3.6/site-packages (from paramiko>=2.3.1->webssh)
Requirement already satisfied: cryptography>=1.5 in /usr/lib64/python3.6/site-packages (from paramiko>=2.3.1->webssh)
Requirement already satisfied: pynacl>=1.0.1 in /usr/lib64/python3.6/site-packages (from paramiko>=2.3.1->webssh)
Requirement already satisfied: pyasn1>=0.1.7 in /usr/lib/python3.6/site-packages (from paramiko>=2.3.1->webssh)
Requirement already satisfied: cffi>=1.1 in /usr/lib64/python3.6/site-packages (from bcrypt>=3.1.3->paramiko>=2.3.1->webssh)
Requirement already satisfied: six>=1.4.1 in /usr/lib/python3.6/site-packages (from bcrypt>=3.1.3->paramiko>=2.3.1->webssh)
Requirement already satisfied: idna>=2.1 in /usr/lib/python3.6/site-packages (from cryptography>=1.5->paramiko>=2.3.1->webssh)
Requirement already satisfied: asn1crypto>=0.21.0 in /usr/lib/python3.6/site-packages (from cryptography>=1.5->paramiko>=2.3.1->webssh)
Requirement already satisfied: pycparser in /usr/lib/python3.6/site-packages (from cffi>=1.1->bcrypt>=3.1.3->paramiko>=2.3.1->webssh)
Installing collected packages: tornado, webssh
  Running setup.py install for webssh ... done
Successfully installed tornado-6.1 webssh-1.5.3

2,启动

#直接运行wssh,使用默认8888端口
wssh

 通过绑定IP地址和端口启动
wssh --address='192.168.43.150' --port=8888
wssh --address='0.0.0.0' --port=8888

 通过绑定IP地址和端口启动,只允许本地地址访问
wssh --address='127.0.0.1' --port=8888
[root@centos8 ~]# wssh --address='192.168.43.150' --port=8888 &
[1] 1393
[root@centos8 ~]# [I 210414 17:05:35 settings:125] WarningPolicy
[I 210414 17:05:35 main:39] Listening on 192.168.43.150:8888 (http)

3,打开web使用
http://192.168.43.150:8888/
Web SSH 客户端工具
Web SSH 客户端工具

上一篇:Intellij IDEA 启动java项目显示端口占用 java.rmi.server.ExportException: Port already in use:...


下一篇:failed to listen server port[127.0.0.1:9501], Error: Address already in use[98]