Christian S.J. Peron 31c88a3043 Add the ability to associate ipfw rules with a specific prison ID.
Since the only thing truly unique about a prison is it's ID, I figured
this would be the most granular way of handling this.

This commit makes the following changes:

- Adds tokenizing and parsing for the ``jail'' command line option
  to the ipfw(8) userspace utility.
- Append the ipfw opcode list with O_JAIL.
- While Iam here, add a comment informing others that if they
  want to add additional opcodes, they should append them to the end
  of the list to avoid ABI breakage.
- Add ``fw_prid'' to the ipfw ucred cache structure.
- When initializing ucred cache, if the process is jailed,
  set fw_prid to the prison ID, otherwise set it to -1.
- Update man page to reflect these changes.

This change was a strong motivator behind the ucred caching
mechanism in ipfw.

A sample usage of this new functionality could be:

    ipfw add count ip from any to any jail 2

It should be noted that because ucred based constraints
are only implemented for TCP and UDP packets, the same
applies for jail associations.

Conceptual head nod by:	pjd
Reviewed by:	rwatson
Approved by:	bmilekic (mentor)
2004-08-12 22:06:55 +00:00
..
2004-07-03 00:13:43 +00:00
2004-07-03 00:13:43 +00:00
2004-07-07 19:57:16 +00:00
2004-02-23 20:25:27 +00:00
2004-07-28 05:59:22 +00:00
2004-07-03 00:13:43 +00:00
2004-07-28 05:59:22 +00:00
2004-08-07 07:52:31 +00:00
2004-08-04 00:23:00 +00:00
2004-05-17 21:05:39 +00:00
2004-02-23 20:25:27 +00:00
2004-02-23 20:25:27 +00:00
2004-02-23 20:25:27 +00:00
2004-02-23 20:25:27 +00:00
2004-02-23 20:25:27 +00:00
2004-02-23 20:25:27 +00:00
2004-07-07 19:57:16 +00:00
2004-01-27 19:28:13 +00:00
2004-02-23 20:25:27 +00:00
2004-05-17 21:24:06 +00:00
2004-02-23 20:25:27 +00:00
2004-05-20 16:40:06 +00:00
2004-07-24 19:11:40 +00:00