Latest LQ Deal: Linux Power User Bundle
Go Back > Forums > Other *NIX Forums > *BSD
User Name
*BSD This forum is for the discussion of all BSD variants.
FreeBSD, OpenBSD, NetBSD, etc.


Closed Thread
  Search this Thread
Old 02-06-2013, 04:22 PM   #1
LQ Newbie
Registered: Dec 2009
Posts: 15

Rep: Reputation: 0
PF firewall equivalent of IP tables command

I have configured apache in the conf file to work with user: apachez group: groupz.

To block outbound requests by the apache user (to stop naughty behavior RE wget/scripts from external sites) using iptables you would do something like:

iptables -A OUTPUT -m owner --uid-owner apachez -p tcp --dport 80 -j DROP
iptables -A OUTPUT -m owner --uid-owner apachez -p tcp --dport 443 -j DROP

I am not sure whether this should be using --dport (destination port) or --sport (source port) - I am fairly new to this.

However, I need to do this in the PF (packet filter) firewall not iptables.

Could someone please advise the command line(s) that would do the above in PF?


Last edited by tontoOz; 02-06-2013 at 04:23 PM.
Old 02-10-2013, 09:25 PM   #2
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910
Please post your thread in only one forum. Posting a single thread in the most relevant forum will make it easier for members to help you and will keep the discussion in one place. This thread is being closed because it is a duplicate.

Closed Thread

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
PF firewall equivalent of IP tables command tontoOz Linux - Server 13 02-12-2013 11:33 PM
firewall ip tables help pls pvavr Linux - Networking 3 02-28-2007 12:29 PM
Require Linux/Perl equivalent command for windows Command alix123 Programming 7 08-19-2005 03:23 AM
slackware's /etc/rc.d/rc.firewall equivalent ||| firewall script startup win32sux Debian 1 03-06-2004 10:15 PM
IP TABLES Firewall Script problems... Nosram Linux - Networking 2 02-11-2004 05:22 AM > Forums > Other *NIX Forums > *BSD

All times are GMT -5. The time now is 04:04 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration