LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Other *NIX Forums > *BSD
User Name
Password
*BSD This forum is for the discussion of all BSD variants.
FreeBSD, OpenBSD, NetBSD, etc.

Notices


Closed Thread
  Search this Thread
Old 02-06-2013, 03:22 PM   #1
tontoOz
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?

Regards.

Last edited by tontoOz; 02-06-2013 at 03:23 PM.
 
Old 02-10-2013, 08:25 PM   #2
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
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.

http://www.linuxquestions.org/questi...nd-4175448820/
 
  


Closed Thread



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 10:33 PM
firewall ip tables help pls pvavr Linux - Networking 3 02-28-2007 11:29 AM
Require Linux/Perl equivalent command for windows Command alix123 Programming 7 08-19-2005 02:23 AM
slackware's /etc/rc.d/rc.firewall equivalent ||| firewall script startup win32sux Debian 1 03-06-2004 09:15 PM
IP TABLES Firewall Script problems... Nosram Linux - Networking 2 02-11-2004 04:22 AM

LinuxQuestions.org > Forums > Other *NIX Forums > *BSD

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

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