Paul Moore 20e2a86485 cipso: handle CIPSO options correctly when NetLabel is disabled
When NetLabel is not enabled, e.g. CONFIG_NETLABEL=n, and the system
receives a CIPSO tagged packet it is dropped (cipso_v4_validate()
returns non-zero).  In most cases this is the correct and desired
behavior, however, in the case where we are simply forwarding the
traffic, e.g. acting as a network bridge, this becomes a problem.

This patch fixes the forwarding problem by providing the basic CIPSO
validation code directly in ip_options_compile() without the need for
the NetLabel or CIPSO code.  The new validation code can not perform
any of the CIPSO option label/value verification that
cipso_v4_validate() does, but it can verify the basic CIPSO option
format.

The behavior when NetLabel is enabled is unchanged.

Signed-off-by: Paul Moore <pmoore@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2012-06-01 14:18:29 -04:00
..
2011-03-31 11:26:23 -03:00
2012-05-19 01:08:16 -04:00
2012-04-15 12:44:40 -04:00
2012-04-15 12:44:40 -04:00
2010-06-03 03:21:52 -07:00
2012-04-15 12:44:40 -04:00
2012-05-27 01:11:22 -04:00
2010-10-27 11:37:32 -07:00
2011-03-31 11:26:23 -03:00
2012-04-15 12:44:40 -04:00
2011-07-26 16:49:47 -07:00
2012-03-08 00:30:32 -08:00
2012-04-17 22:31:59 -04:00
2010-10-25 13:09:45 -07:00
2012-04-15 12:44:40 -04:00
2012-05-08 19:40:33 +02:00
2012-04-14 14:47:05 -04:00
2012-05-19 01:08:16 -04:00
2011-03-31 11:26:23 -03:00
2012-05-17 18:45:20 -04:00
2011-07-26 16:49:47 -07:00
2012-05-16 15:16:44 -04:00
2010-06-03 03:21:52 -07:00
2011-05-17 14:16:58 -04:00
2011-12-11 18:25:16 -05:00
2009-03-21 19:06:50 -07:00
2012-05-19 01:08:16 -04:00
2012-04-15 12:44:40 -04:00
2012-05-17 14:59:59 -04:00
2009-10-07 16:39:43 -04:00
2012-04-15 12:44:40 -04:00
2012-05-16 15:17:08 -04:00
2012-04-15 12:44:40 -04:00