mac_inet.c (172970) | mac_inet.c (173018) |
---|---|
1/*- 2 * Copyright (c) 1999-2002 Robert N. M. Watson 3 * Copyright (c) 2001 Ilmar S. Habibulin 4 * Copyright (c) 2001-2004 Networks Associates Technology, Inc. 5 * Copyright (c) 2006 SPARTA, Inc. 6 * All rights reserved. 7 * 8 * This software was developed by Robert Watson and Ilmar Habibulin for the --- 25 unchanged lines hidden (view full) --- 34 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 35 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 36 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 37 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 38 * SUCH DAMAGE. 39 */ 40 41#include <sys/cdefs.h> | 1/*- 2 * Copyright (c) 1999-2002 Robert N. M. Watson 3 * Copyright (c) 2001 Ilmar S. Habibulin 4 * Copyright (c) 2001-2004 Networks Associates Technology, Inc. 5 * Copyright (c) 2006 SPARTA, Inc. 6 * All rights reserved. 7 * 8 * This software was developed by Robert Watson and Ilmar Habibulin for the --- 25 unchanged lines hidden (view full) --- 34 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 35 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 36 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 37 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 38 * SUCH DAMAGE. 39 */ 40 41#include <sys/cdefs.h> |
42__FBSDID("$FreeBSD: head/sys/security/mac/mac_inet.c 172970 2007-10-25 14:37:37Z rwatson $"); | 42__FBSDID("$FreeBSD: head/sys/security/mac/mac_inet.c 173018 2007-10-26 13:18:38Z rwatson $"); |
43 44#include "opt_mac.h" 45 46#include <sys/param.h> 47#include <sys/kernel.h> 48#include <sys/lock.h> 49#include <sys/malloc.h> 50#include <sys/mutex.h> --- 220 unchanged lines hidden (view full) --- 271{ 272 273 INP_LOCK_ASSERT(inp); 274 SOCK_LOCK_ASSERT(so); 275 MAC_PERFORM(inpcb_sosetlabel, so, so->so_label, inp, inp->inp_label); 276} 277 278void | 43 44#include "opt_mac.h" 45 46#include <sys/param.h> 47#include <sys/kernel.h> 48#include <sys/lock.h> 49#include <sys/malloc.h> 50#include <sys/mutex.h> --- 220 unchanged lines hidden (view full) --- 271{ 272 273 INP_LOCK_ASSERT(inp); 274 SOCK_LOCK_ASSERT(so); 275 MAC_PERFORM(inpcb_sosetlabel, so, so->so_label, inp, inp->inp_label); 276} 277 278void |
279mac_mbuf_create_from_firewall(struct mbuf *m) | 279mac_netinet_firewall_send(struct mbuf *m) |
280{ 281 struct label *label; 282 283 M_ASSERTPKTHDR(m); 284 label = mac_mbuf_to_label(m); | 280{ 281 struct label *label; 282 283 M_ASSERTPKTHDR(m); 284 label = mac_mbuf_to_label(m); |
285 MAC_PERFORM(mbuf_create_from_firewall, m, label); | 285 MAC_PERFORM(netinet_firewall_send, m, label); |
286} 287 288/* 289 * These functions really should be referencing the syncache structure 290 * instead of the label. However, due to some of the complexities associated 291 * with exposing this syncache structure we operate directly on it's label 292 * pointer. This should be OK since we aren't making any access control 293 * decisions within this code directly, we are merely allocating and copying --- 47 unchanged lines hidden --- | 286} 287 288/* 289 * These functions really should be referencing the syncache structure 290 * instead of the label. However, due to some of the complexities associated 291 * with exposing this syncache structure we operate directly on it's label 292 * pointer. This should be OK since we aren't making any access control 293 * decisions within this code directly, we are merely allocating and copying --- 47 unchanged lines hidden --- |