Skip to main content
edited title
Link
Jeroen Ooms
  • 693
  • 1
  • 6
  • 12

Only allow ssh from current subnet Configure ipfw to filter by ip range

Source Link
Jeroen Ooms
  • 693
  • 1
  • 6
  • 12

Only allow ssh from current subnet

I am a Linux user and very new to OSX. I have an OSX 10.7.5 "Lion" server that I am configuring as a webserver. I only have shell access.

I am tryin to configure the firewall, but ipfw is quite different from iptables. Currently, all ports are open to the world. I would like to add the following rules:

  • port 80/443: allow incoming connections from any IP address.
  • anything else: only allow incoming connections from within current subnet.

How would I accomplish this with ipfw?