summaryrefslogtreecommitdiff
path: root/sbin/isakmpd/sysdep
diff options
context:
space:
mode:
authorNiklas Hallqvist <niklas@cvs.openbsd.org>2001-06-05 00:17:50 +0000
committerNiklas Hallqvist <niklas@cvs.openbsd.org>2001-06-05 00:17:50 +0000
commit8e6c3e7c8786612ca32cd1b37fe373994f13ac4b (patch)
tree0d88ee4fd328942c00afd4789a231dc476155521 /sbin/isakmpd/sysdep
parent47dae9154b0226f4c96808a892e9a390cbe0c28d (diff)
Make our pfkeyv2.h more RFC2367 compliant. Also fix some backwards
compatibility problems in isakmpd, at least 2.8 stable can compile current isakmpd now. angelos@ ok
Diffstat (limited to 'sbin/isakmpd/sysdep')
-rw-r--r--sbin/isakmpd/sysdep/openbsd/sysdep-os.h30
1 files changed, 26 insertions, 4 deletions
diff --git a/sbin/isakmpd/sysdep/openbsd/sysdep-os.h b/sbin/isakmpd/sysdep/openbsd/sysdep-os.h
index c427ed683ec..aca2bce41be 100644
--- a/sbin/isakmpd/sysdep/openbsd/sysdep-os.h
+++ b/sbin/isakmpd/sysdep/openbsd/sysdep-os.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: sysdep-os.h,v 1.4 1999/07/08 17:49:35 niklas Exp $ */
+/* $OpenBSD: sysdep-os.h,v 1.5 2001/06/05 00:17:47 niklas Exp $ */
/* $EOM: sysdep-os.h,v 1.3 1999/07/08 16:48:40 niklas Exp $ */
/*
@@ -37,10 +37,12 @@
#ifndef _SYSDEP_OS_H_
#define _SYSDEP_OS_H_
-#ifdef SADB_EXT_X_SRC_MASK
-
-/* Non-conformant PF_KEYv2 extensions, transform them into being conformant. */
+/*
+ * OpenBSD has at various times had non-conformant PF_KEYv2 definitions.
+ * Here we transform them into being conformant.
+ */
+#ifdef SADB_EXT_X_SRC_MASK
#define SADB_X_EXT_SRC_MASK SADB_EXT_X_SRC_MASK
#define SADB_X_EXT_DST_MASK SADB_EXT_X_DST_MASK
#define SADB_X_EXT_PROTOCOL SADB_EXT_X_PROTOCOL
@@ -69,4 +71,24 @@
#endif /* SADB_EXT_X_SRC_MASK */
+#if defined (SADB_IDENTTYPE_MBOX) && !defined (SADB_IDENTTYPE_USERFQDN)
+#define SADB_IDENTTYPE_USERFQDN SADB_IDENTTYPE_MBOX
+#endif
+
+#ifdef FLOW_X_TYPE_USE
+#define SADB_X_FLOW_TYPE_USE FLOW_X_TYPE_USE
+#define SADB_X_FLOW_TYPE_ACQUIRE FLOW_X_TYPE_ACQUIRE
+#define SADB_X_FLOW_TYPE_REQUIRE FLOW_X_TYPE_REQUIRE
+#define SADB_X_FLOW_TYPE_BYPASS FLOW_X_TYPE_BYPASS
+#define SADB_X_FLOW_TYPE_DENY FLOW_X_TYPE_DENY
+#define SADB_X_FLOW_TYPE_DONTACQ FLOW_X_TYPE_DONTACQ
+#endif
+
+#if OPENBSD_IPSEC_API_VERSION == 1
+#define sadb_x_policy sadb_policy
+#define sadb_x_policy_len sadb_policy_len
+#define sadb_x_policy_exttype sadb_policy_exttype
+#define sadb_x_policy_seq sadb_policy_seq
+#endif
+
#endif /* _SYSDEP_OS_H_ */