[rtems-libbsd commit] Add functions used the bridge and tap interfaces.

Chris Johns chrisj at rtems.org
Mon Jun 27 03:48:07 UTC 2016


Module:    rtems-libbsd
Branch:    master
Commit:    a0e49f9ae9ee8e6bcc40e11445208ab11feccc16
Changeset: http://git.rtems.org/rtems-libbsd/commit/?id=a0e49f9ae9ee8e6bcc40e11445208ab11feccc16

Author:    Chris Johns <chrisj at rtems.org>
Date:      Mon Jun 27 13:07:54 2016 +1000

Add functions used the bridge and tap interfaces.

---

 rtemsbsd/rtems/rtems-kernel-jail.c | 21 +++++++++++++++++++++
 1 file changed, 21 insertions(+)

diff --git a/rtemsbsd/rtems/rtems-kernel-jail.c b/rtemsbsd/rtems/rtems-kernel-jail.c
index cf0ca3e..663c934 100644
--- a/rtemsbsd/rtems/rtems-kernel-jail.c
+++ b/rtemsbsd/rtems/rtems-kernel-jail.c
@@ -308,6 +308,27 @@ prison_check_af(struct ucred *cred, int af)
 }
 
 /*
+ * Return the correct hostname (domainname, et al) for the passed credential.
+ */
+void
+getcredhostname(struct ucred *cred, char *buf, size_t size)
+{
+  gethostname(buf, size);
+}
+
+void
+getcreddomainname(struct ucred *cred, char *buf, size_t size)
+{
+  getdomainname(buf, size);
+}
+
+void
+getcredhostid(struct ucred *cred, unsigned long *hostid)
+{
+  *hostid = 0;
+}
+
+/*
  * Return 1 if the passed credential is in a jail, otherwise 0.
  */
 int



More information about the vc mailing list