Skip to contentSkip to conversation

tools/ Exposes Flask XSM AVC functions to user-space

PATCH In review Machon Gregory 2 participants 2 messages Jan 22, 2010 Arm/actions semi architecture

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 tools/ Exposes Flask XSM AVC functions to user-space

This patch exposes the flask_access, flask_avc_cachestats, flask_avc_hashstats, flask_getavc_threshold, flask_setavc_threshold, and flask_policyvers functions to user-space. A python wrapper was created for the flask_access function to facilitate policy based user-space access control decisions. flask.h was renamed to libflask.h to remove a naming conflict.

---

 tools/flask/libflask/Makefile           |    2
 tools/flask/libflask/flask_op.c         |  159
+++++++++++++++++++++++++++++++-
 tools/flask/libflask/include/flask.h    |   43 --------
 tools/flask/libflask/include/libflask.h |   53 ++++++++++
 tools/flask/utils/getenforce.c          |    2
 tools/flask/utils/loadpolicy.c          |    2
 tools/flask/utils/setenforce.c          |    2
 tools/python/xen/lowlevel/flask/flask.c |   60 +++++++++++-
 8 files changed, 274 insertions(+), 49 deletions(-)
tools/flask/libflask/Makefile +1 -1
diff -r c06732ac2392 tools/flask/libflask/Makefile
@@ -38,7 +38,7 @@
 	$(INSTALL_DATA) libflask.a $(DESTDIR)$(LIBDIR)
 	ln -sf libflask.so.$(MAJOR).$(MINOR) $(DESTDIR)$(LIBDIR)/libflask.so.$(MAJOR)
 	ln -sf libflask.so.$(MAJOR) $(DESTDIR)$(LIBDIR)/libflask.so
-	$(INSTALL_DATA) include/flask.h $(DESTDIR)$(INCLUDEDIR)
+	$(INSTALL_DATA) include/libflask.h $(DESTDIR)$(INCLUDEDIR)/xen/xsm
 
 .PHONY: TAGS
 TAGS:
tools/flask/libflask/flask_op.c +158 -1

168 lines not on this page · raw message

tools/flask/libflask/include/flask.h deleted +0 -43

43 lines not on this page · raw message

tools/flask/libflask/include/libflask.h new file +53 -0

53 lines not on this page · raw message

tools/flask/utils/getenforce.c +1 -1
diff -r c06732ac2392 tools/flask/utils/getenforce.c
@@ -16,7 +16,7 @@
 #include <sys/stat.h>
 #include <string.h>
 #include <unistd.h>
-#include <flask.h>
+#include <libflask.h>
 
 static void usage (int argCnt, const char *args[])
 {
tools/flask/utils/loadpolicy.c +1 -1
diff -r c06732ac2392 tools/flask/utils/loadpolicy.c
@@ -17,7 +17,7 @@
 #include <sys/stat.h>
 #include <string.h>
 #include <unistd.h>
-#include <flask.h>
+#include <libflask.h>
 
 #define USE_MMAP
 
tools/flask/utils/setenforce.c +1 -1
diff -r c06732ac2392 tools/flask/utils/setenforce.c
@@ -16,7 +16,7 @@
 #include <sys/stat.h>
 #include <string.h>
 #include <unistd.h>
-#include <flask.h>
+#include <libflask.h>
 
 static void usage (int argCnt, const char *args[])
 {
tools/python/xen/lowlevel/flask/flask.c +59 -1

79 lines not on this page · raw message

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel

#1 lore raw

Is this intended for 4.0.0?

-- Keir

Quoted 24 lines · Machon Gregory

This patch exposes the flask_access, flask_avc_cachestats, flask_avc_hashstats, flask_getavc_threshold, flask_setavc_threshold, and flask_policyvers functions to user-space. A python wrapper was created for the flask_access function to facilitate policy based user-space access control decisions. flask.h was renamed to libflask.h to remove a naming conflict.

---

 tools/flask/libflask/Makefile           |    2
 tools/flask/libflask/flask_op.c         |  159
+++++++++++++++++++++++++++++++-
 tools/flask/libflask/include/flask.h    |   43 --------
 tools/flask/libflask/include/libflask.h |   53 ++++++++++
 tools/flask/utils/getenforce.c          |    2
 tools/flask/utils/loadpolicy.c          |    2
 tools/flask/utils/setenforce.c          |    2
 tools/python/xen/lowlevel/flask/flask.c |   60 +++++++++++-
 8 files changed, 274 insertions(+), 49 deletions(-)