xref: /OK3568_Linux_fs/kernel/security/selinux/include/netif.h (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1*4882a593Smuzhiyun /* SPDX-License-Identifier: GPL-2.0-only */
2*4882a593Smuzhiyun /*
3*4882a593Smuzhiyun  * Network interface table.
4*4882a593Smuzhiyun  *
5*4882a593Smuzhiyun  * Network interfaces (devices) do not have a security field, so we
6*4882a593Smuzhiyun  * maintain a table associating each interface with a SID.
7*4882a593Smuzhiyun  *
8*4882a593Smuzhiyun  * Author: James Morris <jmorris@redhat.com>
9*4882a593Smuzhiyun  *
10*4882a593Smuzhiyun  * Copyright (C) 2003 Red Hat, Inc., James Morris <jmorris@redhat.com>
11*4882a593Smuzhiyun  * Copyright (C) 2007 Hewlett-Packard Development Company, L.P.
12*4882a593Smuzhiyun  *                    Paul Moore <paul@paul-moore.com>
13*4882a593Smuzhiyun  */
14*4882a593Smuzhiyun #ifndef _SELINUX_NETIF_H_
15*4882a593Smuzhiyun #define _SELINUX_NETIF_H_
16*4882a593Smuzhiyun 
17*4882a593Smuzhiyun #include <net/net_namespace.h>
18*4882a593Smuzhiyun 
19*4882a593Smuzhiyun void sel_netif_flush(void);
20*4882a593Smuzhiyun 
21*4882a593Smuzhiyun int sel_netif_sid(struct net *ns, int ifindex, u32 *sid);
22*4882a593Smuzhiyun 
23*4882a593Smuzhiyun #endif	/* _SELINUX_NETIF_H_ */
24*4882a593Smuzhiyun 
25