user_1 (master *) 1_EchoServer $ python -m http.server 8000
Serving HTTP on 0.0.0.0 port 8000 (http://0.0.0.0:8000/) ...
127.0.0.1 - - [30/Sep/2017 18:57:11] "GET / HTTP/1.1" 200 -
Run Code Online (Sandbox Code Playgroud)
设置一个简单的服务器。我想用ncat连接它来学习HTTP。
我安装 ncat(pip install nmap):
user_1 Documents $ pip install nmap
Requirement already satisfied: nmap in c:\python36\lib\site-packages
Run Code Online (Sandbox Code Playgroud)
然后,当我尝试连接时,找不到 cmd。它更早工作。不知道我是怎么弄坏的。
user_1 Documents $ pip install nmap
Requirement already satisfied: nmap in c:\python36\lib\site-packages
user_1 Documents $ ncat -l 9999
bash: ncat: command not found
Run Code Online (Sandbox Code Playgroud)
我在 Windows 上使用 git bash,我在 c 驱动器上设置了 python36 并相应地更改了 env 变量和路径。
您安装的Python“nmap”包pip install nmap只是一个输出解析库。它不包括 Nmap 二进制文件。适用于 Linux 的 Windows 子系统(又名 Windows 上的 Bash、Windows 上的 Ubuntu)中提供的“nmap”软件包当前无法正常工作且不受支持。
在 Windows 上获取即用格式(二进制可执行文件)的 Nmap(和 Ncat)的唯一地方是直接从 nmap.org。
| 归档时间: |
|
| 查看次数: |
8707 次 |
| 最近记录: |