patch-2.3.18 linux/include/linux/netfilter.h
Next file: linux/include/linux/parport.h
Previous file: linux/include/linux/kernel.h
Back to the patch index
Back to the overall index
- Lines: 49
- Date:
Thu Sep 9 22:21:44 1999
- Orig file:
v2.3.17/linux/include/linux/netfilter.h
- Orig date:
Thu Aug 26 13:05:41 1999
diff -u --recursive --new-file v2.3.17/linux/include/linux/netfilter.h linux/include/linux/netfilter.h
@@ -57,23 +57,29 @@
int priority;
};
-struct nf_setsockopt_ops
+struct nf_sockopt_ops
{
struct list_head list;
int pf;
- int optmin;
- int optmax;
- int (*fn)(int optval, void *user, unsigned int len);
+
+ /* Non-inclusive ranges: use 0/0/NULL to never get called. */
+ int set_optmin;
+ int set_optmax;
+ int (*set)(struct sock *sk, int optval, void *user, unsigned int len);
+
+ int get_optmin;
+ int get_optmax;
+ int (*get)(struct sock *sk, int optval, void *user, int *len);
};
/* Function to register/unregister hook points. */
int nf_register_hook(struct nf_hook_ops *reg);
void nf_unregister_hook(struct nf_hook_ops *reg);
-/* Functions to register setsockopt ranges (inclusive). */
-int nf_register_sockopt(struct nf_setsockopt_ops *reg);
-void nf_unregister_sockopt(struct nf_setsockopt_ops *reg);
+/* Functions to register get/setsockopt ranges (non-inclusive). */
+int nf_register_sockopt(struct nf_sockopt_ops *reg);
+void nf_unregister_sockopt(struct nf_sockopt_ops *reg);
extern struct list_head nf_hooks[NPROTO][NF_MAX_HOOKS];
@@ -114,7 +120,10 @@
__u32 packetcount, __u32 bytecount);
/* Call setsockopt() */
-int nf_setsockopt(int pf, int optval, char *opt, unsigned int len);
+int nf_setsockopt(struct sock *sk, int pf, int optval, char *opt,
+ int len);
+int nf_getsockopt(struct sock *sk, int pf, int optval, char *opt,
+ int *len);
struct nf_wakeme
{
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)