You can get more info about socketfilterfw by running it with -h:
# /usr/libexec/ApplicationFirewall/socketfilterfw -h
usage: /usr/libexec/ApplicationFirewall/socketfilterfw [-c] [-w] [-d] [-l] [-T] [-U] [-B] [-L] [-a listen or accept] [-s file to sign] [-v file to verify] [-p pid to write] [--getglobalstate] [--setglobalstate on | off] [--getblockall] [--setblockall on | off] [--listapps] [--getappblocked <path>] [--blockapp <path>] [--unblockapp <path>] [--add <path>] [--remove <path>] [--getallowsigned] [--setallowsigned] [--getstealthmode] [--setstealthmode on | off] [--getloggingmode] [--setloggingmode on | off]
...
--unblockapp <path> unblock the application at <path>
So in your case you can do:
# /usr/libexec/ApplicationFirewall/socketfilterfw --unblockapp /Applications/another.app
If you still can't hit it make sure to check ipfw:
# ipfw -a l
65535 0 0 allow ip from any to any
If you have other rules in there you can:
# ipfw flush
To remove them.
If none of that works try disabling them both and seeing if you are still unable to connect:
# sysctl -w net.inet.ip.fw.enable=0
# /usr/libexec/ApplicationFirewall/socketfilterfw --setglobalstate off
Firewall already disabled
If you are still having problems then theres probably a config issue with apache.