summaryrefslogtreecommitdiffstats
path: root/rtemsbsd
diff options
context:
space:
mode:
authorJennifer Averett <jennifer.averett@oarcorp.com>2012-04-02 08:57:05 -0500
committerJennifer Averett <jennifer.averett@oarcorp.com>2012-04-02 08:57:05 -0500
commit761f597d30a399335e32062a704b56dc1e0714ae (patch)
tree8cdea9255c0d77004ec581f022411eb660615598 /rtemsbsd
parentAdd freebsd/machine/elf.h as empty. Improve message for empty file. (diff)
downloadrtems-libbsd-761f597d30a399335e32062a704b56dc1e0714ae.tar.bz2
Added two prison methods to resolve linker errors.
Diffstat (limited to 'rtemsbsd')
-rw-r--r--rtemsbsd/src/rtems-bsd-jail.c27
1 files changed, 27 insertions, 0 deletions
diff --git a/rtemsbsd/src/rtems-bsd-jail.c b/rtemsbsd/src/rtems-bsd-jail.c
index 3fad04b8..2462da53 100644
--- a/rtemsbsd/src/rtems-bsd-jail.c
+++ b/rtemsbsd/src/rtems-bsd-jail.c
@@ -235,3 +235,30 @@ prison_remote_ip6(struct ucred *cred, struct in6_addr *ia6)
{
return 0;
}
+
+/*
+ * Return 1 if we should do proper source address selection or are not jailed.
+ * We will return 0 if we should bypass source address selection in favour
+ * of the primary jail IPv4 address. Only in this case *ia will be updated and
+ * returned in NBO.
+ * Return EAFNOSUPPORT, in case this jail does not allow IPv4.
+ */
+int
+prison_saddrsel_ip4(struct ucred *cred, struct in_addr *ia)
+{
+}
+
+/*
+ * Pass back primary IPv4 address of this jail.
+ *
+ * If not restricted return success but do not alter the address. Caller has
+ * to make sure to initialize it correctly (e.g. INADDR_ANY).
+ *
+ * Returns 0 on success, EAFNOSUPPORT if the jail doesn't allow IPv4.
+ * Address returned in NBO.
+ */
+int
+prison_get_ip4(struct ucred *cred, struct in_addr *ia)
+{
+ return 0;
+}