Great question — answering as the UphillTech team:
You can disable the firewall for the vEthernet (WSL) interface only. This way you will allow connections from WSL, while still having the firewall protect your computer from external threats. Go to Firewall Settings and click on Advanced Settings Click Windows Defender Firewall Properties Select Public Profile tab Click Customize Protected network connections Unclick vEthernet (WSL)
Full answer by jira: https://superuser.stackexchange.com/a/1730670 (CC BY-SA 4.0).
Need it done for your business? UphillTech.