英文:
Allow golang through Windows firewall for testing purposes
问题
我正在尝试测试一些启动简单TCP服务器并建立连接的Go代码:
net.Listen("tcp", "localhost:8686")
我已经尝试在防火墙应用程序中创建规则,允许所有的TCP连接,无论是入站还是出站的,但是我的测试仍然失败,并且每次运行时都会提示我允许通过防火墙。
英文:
I'm trying to test some go code that starts a simple TCP server and makes a connection using
net.Listen("tcp", "localhost:8686")
I've tried creating rules in the Firewall application to allow all connections, both inbound and outbound, via TCP, but my tests still fail and I'm being prompted to allow it through the firewall each time it runs.
答案1
得分: 2
我刚刚修好了这个问题。显然,我还需要打开UDP端口。
英文:
I actually just fixed this. Apparently I needed to open the UDP ports as well.
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论