ipv4.h 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081
  1. /*
  2. * ipv4 in net namespaces
  3. */
  4. #ifndef __NETNS_IPV4_H__
  5. #define __NETNS_IPV4_H__
  6. #include <linux/uidgid.h>
  7. #include <net/inet_frag.h>
  8. struct tcpm_hash_bucket;
  9. struct ctl_table_header;
  10. struct ipv4_devconf;
  11. struct fib_rules_ops;
  12. struct hlist_head;
  13. struct fib_table;
  14. struct sock;
  15. struct netns_ipv4 {
  16. #ifdef CONFIG_SYSCTL
  17. struct ctl_table_header *forw_hdr;
  18. struct ctl_table_header *frags_hdr;
  19. struct ctl_table_header *ipv4_hdr;
  20. struct ctl_table_header *route_hdr;
  21. struct ctl_table_header *xfrm4_hdr;
  22. #endif
  23. struct ipv4_devconf *devconf_all;
  24. struct ipv4_devconf *devconf_dflt;
  25. #ifdef CONFIG_IP_MULTIPLE_TABLES
  26. struct fib_rules_ops *rules_ops;
  27. bool fib_has_custom_rules;
  28. struct fib_table *fib_local;
  29. struct fib_table *fib_main;
  30. struct fib_table *fib_default;
  31. #endif
  32. #ifdef CONFIG_IP_ROUTE_CLASSID
  33. int fib_num_tclassid_users;
  34. #endif
  35. struct hlist_head *fib_table_hash;
  36. struct sock *fibnl;
  37. struct sock **icmp_sk;
  38. struct inet_peer_base *peers;
  39. struct tcpm_hash_bucket *tcp_metrics_hash;
  40. unsigned int tcp_metrics_hash_log;
  41. struct netns_frags frags;
  42. #ifdef CONFIG_NETFILTER
  43. struct xt_table *iptable_filter;
  44. struct xt_table *iptable_mangle;
  45. struct xt_table *iptable_raw;
  46. struct xt_table *arptable_filter;
  47. #ifdef CONFIG_SECURITY
  48. struct xt_table *iptable_security;
  49. #endif
  50. struct xt_table *nat_table;
  51. #endif
  52. int sysctl_icmp_echo_ignore_all;
  53. int sysctl_icmp_echo_ignore_broadcasts;
  54. int sysctl_icmp_ignore_bogus_error_responses;
  55. int sysctl_icmp_ratelimit;
  56. int sysctl_icmp_ratemask;
  57. int sysctl_icmp_errors_use_inbound_ifaddr;
  58. int sysctl_tcp_ecn;
  59. kgid_t sysctl_ping_group_range[2];
  60. long sysctl_tcp_mem[3];
  61. atomic_t dev_addr_genid;
  62. #ifdef CONFIG_IP_MROUTE
  63. #ifndef CONFIG_IP_MROUTE_MULTIPLE_TABLES
  64. struct mr_table *mrt;
  65. #else
  66. struct list_head mr_tables;
  67. struct fib_rules_ops *mr_rules_ops;
  68. #endif
  69. #endif
  70. };
  71. #endif