Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F177728660
D56616.1795144044.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Authored By
Unknown
Size
1 KB
Referenced Files
None
Subscribers
None
D56616.1795144044.diff
View Options
diff --git a/sys/netinet/ip_fw.h b/sys/netinet/ip_fw.h
--- a/sys/netinet/ip_fw.h
+++ b/sys/netinet/ip_fw.h
@@ -78,6 +78,7 @@
#define IP_FW3_OPVER_0 0
#define IP_FW3_OPVER_1 1 /* 32bit rulenum */
#define IP_FW3_OPVER IP_FW3_OPVER_1
+#define IP_FW_KBIVER 1500034
/* IP_FW3 opcodes */
#define IP_FW_TABLE_XADD 86 /* add entry */
diff --git a/sys/netpfil/ipfw/ip_fw_sockopt.c b/sys/netpfil/ipfw/ip_fw_sockopt.c
--- a/sys/netpfil/ipfw/ip_fw_sockopt.c
+++ b/sys/netpfil/ipfw/ip_fw_sockopt.c
@@ -170,6 +170,26 @@
VNET_DEFINE_STATIC(uma_zone_t, ipfw_cntr_zone);
#define V_ipfw_cntr_zone VNET(ipfw_cntr_zone)
+#ifdef SYSCTL_NODE
+
+SYSBEGIN(f5)
+
+/*
+ * KBI version is similar to osreldate representing the Kernel release date
+ * when the last change in KBI was made.
+ *
+ * Used in /sbin/ipfw to detect a KBI change and execve() into a KBI-compatible
+ * binary.
+ */
+
+SYSCTL_DECL(_net_inet_ip_fw);
+SYSCTL_INT(_net_inet_ip_fw, OID_AUTO, kbi_version, CTLFLAG_RD,
+ SYSCTL_NULL_INT_PTR, IP_FW_KBIVER, "KBI version");
+
+SYSEND
+
+#endif /* SYSCTL_NODE */
+
void
ipfw_init_counters(void)
{
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Fri, Nov 20, 3:07 AM (7 h, 31 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
41858276
Default Alt Text
D56616.1795144044.diff (1 KB)
Attached To
Mode
D56616: Add ipfw 32-bit KBI detection via ophandler version
Attached
Detach File
Event Timeline