OS X firewall code-signing not working for nginx etc
Not a great solution, but have you tried turning off the firewall?

If that works, then try the following, which may prompt you to allow nginx to bypass the OS X firewall: nginx -g "daemon off;"; this will make nginx run in the foreground instead of with the daemon, which seemed to help OS X recognize that it needs firewall permissions.

If you're not getting that popup, try turning off the Automatically allow signed applications option in System Preferences -> Security &amp; Privacy -> Firewall -> Firewall options..., then toggle the firewall off and back on, and toggle the "lock" off and back on (lower left hand corner if you have it set to require admin password to modify security preferences).

Once I got it to give me the popup and I clicked Allow, I found it would let me access nginx for that session.