How to Test Outgoing Port Blocking
When you are doing DIY projects that handle network traffics, one of the nuisance is testing the outgoing ports. Be it may your ISP or network manager, as a user you probably don’t have a say on which ports they will block off —only that you need to avoid the ones that are not available. And in about 9 out of 10 cases, management doesn’t write down all the ports that are blocked, and that 1 case is where the management starts starring at you for asking too many questions.
The site in question is portquiz.net. You can test any ports by adding a suffix. The site even has a list of commands you could try to test ports from Terminal. My personal favorite is Python script to test out the ports.
# change START and END before running
# END will not be included (e.g. 0,1 means testing port 0 only)
import requests
for i in range(START, END):
try:
x = requests.get(("http://portquiz.net:" + str(i)), timeout=1)
except:
print(f"port {i} timeout.")
else:
pass
You could test out all 16 bits, but not only will that take quite some time, if your network manager has particular agenda, this prodding might be problematic. Please do keep it to smallest possible window.