net/netfilter/nf_internals.h

Source file repositories/reference/linux-study-clean/net/netfilter/nf_internals.h

File Facts

System
Linux kernel
Corpus path
net/netfilter/nf_internals.h
Extension
.h
Size
1423 bytes
Lines
44
Domain
Networking Core
Bucket
Sockets, Protocols, Packet Path, And Network Policy
Inferred role
Networking Core: implementation source
Status
source implementation candidate

Why This File Exists

Networking stack implementation surface: socket APIs, protocol dispatch, packet flow, routing, filtering, and network namespaces.

Dependency Surface

Detected Declarations

Annotated Snippet

#ifndef _NF_INTERNALS_H
#define _NF_INTERNALS_H

#include <linux/list.h>
#include <linux/skbuff.h>
#include <linux/netdevice.h>

/* nf_conntrack_netlink.c: applied on tuple filters */
#define CTA_FILTER_F_CTA_IP_SRC			(1 << 0)
#define CTA_FILTER_F_CTA_IP_DST			(1 << 1)
#define CTA_FILTER_F_CTA_TUPLE_ZONE		(1 << 2)
#define CTA_FILTER_F_CTA_PROTO_NUM		(1 << 3)
#define CTA_FILTER_F_CTA_PROTO_SRC_PORT		(1 << 4)
#define CTA_FILTER_F_CTA_PROTO_DST_PORT		(1 << 5)
#define CTA_FILTER_F_CTA_PROTO_ICMP_TYPE	(1 << 6)
#define CTA_FILTER_F_CTA_PROTO_ICMP_CODE	(1 << 7)
#define CTA_FILTER_F_CTA_PROTO_ICMP_ID		(1 << 8)
#define CTA_FILTER_F_CTA_PROTO_ICMPV6_TYPE	(1 << 9)
#define CTA_FILTER_F_CTA_PROTO_ICMPV6_CODE	(1 << 10)
#define CTA_FILTER_F_CTA_PROTO_ICMPV6_ID	(1 << 11)
#define CTA_FILTER_F_MAX			(1 << 12)
#define CTA_FILTER_F_ALL			(CTA_FILTER_F_MAX-1)
#define CTA_FILTER_FLAG(ctattr) CTA_FILTER_F_ ## ctattr

/* nf_queue.c */
void nf_queue_nf_hook_drop(struct net *net);

/* nf_log.c */
int __init netfilter_log_init(void);

#ifdef CONFIG_LWTUNNEL
/* nf_hooks_lwtunnel.c */
int __init netfilter_lwtunnel_init(void);
void netfilter_lwtunnel_fini(void);
#endif

/* core.c */
void nf_hook_entries_delete_raw(struct nf_hook_entries __rcu **pp,
				const struct nf_hook_ops *reg);
int nf_hook_entries_insert_raw(struct nf_hook_entries __rcu **pp,
				const struct nf_hook_ops *reg);
#endif

Annotation

Implementation Notes