I'm running macOS Sierra 10.12.4 and am trying to open a port (12345). I can't use the GUI firewall tool as it's app specific, not port specific.
I have tried the following this article, but it did not work. When I run
sudo pfctl -f /etc/pf.conf I get:
pfctl: Use of -f option, could result in flushing of rules present in the main ruleset added by the system at startup. See /etc/pf.conf for further details. No ALTQ support in kernel ALTQ related functions disabled
It may also help to note that in my firewall (GUI) options I have blocked pretty much all options as shown below.