所以我只是想创建一些网络钓鱼网站来尝试一下,但现在每当我尝试通过 ngrok 创建一个网站或启动 ngrok ./ngrok http 80
然后访问它向我显示的网站时这个-
Failed to complete tunnel connection
The connection to https://xxx.xxx.ngrok.io was successfully tunneled to your ngrok client, but the client failed to establish a connection to the local address localhost:80.
Make sure that a web service is running on localhost:80 and that it is a valid address the error encountered was: dial tcp [::1]:80:Connect:connection refused.
每当我访问它们时,谷歌都会向它们显示警告
有什么建议吗?
最佳答案
您应该在端口 80 上创建本地服务器。使用php或python创建本地服务器。
PHP
~$ php -S localhost:80
Python
~$ python -m http.server 80
启动本地服务器后打开一个新的终端 session 并启动ngrok
~$ ./ngrok http 80
您也可以使用 ssh
创建链接。请确保您已安装 ssh。
~$ php -S localhost:80 | ssh -R 80:localhost:80 ssh.localhost.run
或
~$ python -m http.server 80 | ssh -R 80:localhost:80 ssh.localhost.run
顺便说一句,chrome 会自动检测网络钓鱼页面。
关于linux - ngrok 中的错误 - 无法完成隧道连接,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/70503113/