All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/3] libselinux: renamed andriod label backend source file
@ 2016-09-29 11:39 Janis Danisevskis
  2016-09-29 11:39 ` [PATCH 2/3] libselinux: android: fix lax service context lookup Janis Danisevskis
  2016-09-29 11:39 ` [PATCH 3/3] libselinux: makes android label back ends configurable Janis Danisevskis
  0 siblings, 2 replies; 6+ messages in thread
From: Janis Danisevskis @ 2016-09-29 11:39 UTC (permalink / raw)
  To: selinux, seandroid-list, sds, jwcart2; +Cc: Janis Danisevskis

Signed-off-by: Janis Danisevskis <jdanis@android.com>
---
 libselinux/src/Makefile                 |   2 +-
 libselinux/src/label_android_property.c | 304 --------------------------------
 libselinux/src/label_backends_android.c | 304 ++++++++++++++++++++++++++++++++
 3 files changed, 305 insertions(+), 305 deletions(-)
 delete mode 100644 libselinux/src/label_android_property.c
 create mode 100644 libselinux/src/label_backends_android.c

diff --git a/libselinux/src/Makefile b/libselinux/src/Makefile
index 2c61fad..cba8383 100644
--- a/libselinux/src/Makefile
+++ b/libselinux/src/Makefile
@@ -85,7 +85,7 @@ ifeq ($(ANDROID_HOST),y)
 DISABLE_FLAGS+= -DNO_MEDIA_BACKEND -DNO_DB_BACKEND -DNO_X_BACKEND \
 	-DBUILD_HOST
 SRCS= callbacks.c freecon.c label.c label_file.c \
-	label_android_property.c regex.c label_support.c \
+	label_backends_android.c regex.c label_support.c \
 	matchpathcon.c setrans_client.c sha1.c
 endif
 
diff --git a/libselinux/src/label_android_property.c b/libselinux/src/label_android_property.c
deleted file mode 100644
index 290b438..0000000
--- a/libselinux/src/label_android_property.c
+++ /dev/null
@@ -1,304 +0,0 @@
-/*
- * Property Service contexts backend for labeling Android
- * property keys
- */
-
-#include <stdarg.h>
-#include <string.h>
-#include <ctype.h>
-#include <errno.h>
-#include <limits.h>
-#include <sys/types.h>
-#include <sys/stat.h>
-#include "callbacks.h"
-#include "label_internal.h"
-
-/* A property security context specification. */
-typedef struct spec {
-	struct selabel_lookup_rec lr;	/* holds contexts for lookup result */
-	char *property_key;		/* property key string */
-} spec_t;
-
-/* Our stored configuration */
-struct saved_data {
-	/*
-	 * The array of specifications is sorted for longest
-	 * prefix match
-	 */
-	spec_t *spec_arr;
-	unsigned int nspec;	/* total number of specifications */
-};
-
-static int cmp(const void *A, const void *B)
-{
-	const struct spec *sp1 = A, *sp2 = B;
-
-	if (strncmp(sp1->property_key, "*", 1) == 0)
-		return 1;
-	if (strncmp(sp2->property_key, "*", 1) == 0)
-		return -1;
-
-	size_t L1 = strlen(sp1->property_key);
-	size_t L2 = strlen(sp2->property_key);
-
-	return (L1 < L2) - (L1 > L2);
-}
-
-/*
- * Warn about duplicate specifications.
- */
-static int nodups_specs(struct saved_data *data, const char *path)
-{
-	int rc = 0;
-	unsigned int ii, jj;
-	struct spec *curr_spec, *spec_arr = data->spec_arr;
-
-	for (ii = 0; ii < data->nspec; ii++) {
-		curr_spec = &spec_arr[ii];
-		for (jj = ii + 1; jj < data->nspec; jj++) {
-			if (!strcmp(spec_arr[jj].property_key,
-					    curr_spec->property_key)) {
-				rc = -1;
-				errno = EINVAL;
-				if (strcmp(spec_arr[jj].lr.ctx_raw,
-						    curr_spec->lr.ctx_raw)) {
-					selinux_log
-						(SELINUX_ERROR,
-						 "%s: Multiple different specifications for %s  (%s and %s).\n",
-						 path, curr_spec->property_key,
-						 spec_arr[jj].lr.ctx_raw,
-						 curr_spec->lr.ctx_raw);
-				} else {
-					selinux_log
-						(SELINUX_ERROR,
-						 "%s: Multiple same specifications for %s.\n",
-						 path, curr_spec->property_key);
-				}
-			}
-		}
-	}
-	return rc;
-}
-
-static int process_line(struct selabel_handle *rec,
-			const char *path, char *line_buf,
-			int pass, unsigned lineno)
-{
-	int items;
-	char *prop = NULL, *context = NULL;
-	struct saved_data *data = (struct saved_data *)rec->data;
-	spec_t *spec_arr = data->spec_arr;
-	unsigned int nspec = data->nspec;
-	const char *errbuf = NULL;
-
-	items = read_spec_entries(line_buf, &errbuf, 2, &prop, &context);
-	if (items < 0) {
-		items = errno;
-		selinux_log(SELINUX_ERROR,
-			"%s:  line %u error due to: %s\n", path,
-			lineno, errbuf ?: strerror(errno));
-		errno = items;
-		return -1;
-	}
-
-	if (items == 0)
-		return items;
-
-	if (items != 2) {
-		selinux_log(SELINUX_ERROR,
-			    "%s:  line %u is missing fields\n", path,
-			    lineno);
-		free(prop);
-		errno = EINVAL;
-		return -1;
-	}
-
-	if (pass == 0) {
-		free(prop);
-		free(context);
-	} else if (pass == 1) {
-		/* On the second pass, process and store the specification in spec. */
-		spec_arr[nspec].property_key = prop;
-		spec_arr[nspec].lr.ctx_raw = context;
-
-		if (rec->validating) {
-			if (selabel_validate(rec, &spec_arr[nspec].lr) < 0) {
-				selinux_log(SELINUX_ERROR,
-					    "%s:  line %u has invalid context %s\n",
-					    path, lineno, spec_arr[nspec].lr.ctx_raw);
-				errno = EINVAL;
-				return -1;
-			}
-		}
-	}
-
-	data->nspec = ++nspec;
-	return 0;
-}
-
-static int init(struct selabel_handle *rec, const struct selinux_opt *opts,
-		unsigned n)
-{
-	struct saved_data *data = (struct saved_data *)rec->data;
-	const char *path = NULL;
-	FILE *fp;
-	char line_buf[BUFSIZ];
-	unsigned int lineno, maxnspec, pass;
-	int status = -1;
-	struct stat sb;
-
-	/* Process arguments */
-	while (n--)
-		switch (opts[n].type) {
-		case SELABEL_OPT_PATH:
-			path = opts[n].value;
-			break;
-		}
-
-	if (!path)
-		return -1;
-
-	/* Open the specification file. */
-	if ((fp = fopen(path, "r")) == NULL)
-		return -1;
-
-	if (fstat(fileno(fp), &sb) < 0)
-		goto finish;
-	errno = EINVAL;
-	if (!S_ISREG(sb.st_mode))
-		goto finish;
-
-	/*
-	 * Two passes of the specification file. First is to get the size.
-	 * After the first pass, the spec array is malloced to the appropriate
-	 * size. Second pass is to populate the spec array and check for
-	 * dups.
-	 */
-	maxnspec = UINT_MAX / sizeof(spec_t);
-	for (pass = 0; pass < 2; pass++) {
-		data->nspec = 0;
-		lineno = 0;
-
-		while (fgets(line_buf, sizeof(line_buf) - 1, fp)
-		       && data->nspec < maxnspec) {
-			if (process_line(rec, path, line_buf, pass, ++lineno)
-									  != 0)
-				goto finish;
-		}
-
-		if (pass == 1) {
-			status = nodups_specs(data, path);
-
-			if (status)
-				goto finish;
-		}
-
-		if (pass == 0) {
-			if (data->nspec == 0) {
-				status = 0;
-				goto finish;
-			}
-
-			if (NULL == (data->spec_arr =
-				     malloc(sizeof(spec_t) * data->nspec)))
-				goto finish;
-
-			memset(data->spec_arr, 0, sizeof(spec_t) * data->nspec);
-			maxnspec = data->nspec;
-			rewind(fp);
-		}
-	}
-
-	qsort(data->spec_arr, data->nspec, sizeof(struct spec), cmp);
-
-	status = digest_add_specfile(rec->digest, fp, NULL, sb.st_size, path);
-	if (status)
-		goto finish;
-
-	digest_gen_hash(rec->digest);
-
-finish:
-	fclose(fp);
-	return status;
-}
-
-/*
- * Backend interface routines
- */
-static void closef(struct selabel_handle *rec)
-{
-	struct saved_data *data = (struct saved_data *)rec->data;
-	struct spec *spec;
-	unsigned int i;
-
-	for (i = 0; i < data->nspec; i++) {
-		spec = &data->spec_arr[i];
-		free(spec->property_key);
-		free(spec->lr.ctx_raw);
-		free(spec->lr.ctx_trans);
-	}
-
-	if (data->spec_arr)
-		free(data->spec_arr);
-
-	free(data);
-}
-
-static struct selabel_lookup_rec *lookup(struct selabel_handle *rec,
-					 const char *key,
-					 int __attribute__((unused)) type)
-{
-	struct saved_data *data = (struct saved_data *)rec->data;
-	spec_t *spec_arr = data->spec_arr;
-	unsigned int i;
-	struct selabel_lookup_rec *ret = NULL;
-
-	if (!data->nspec) {
-		errno = ENOENT;
-		goto finish;
-	}
-
-	for (i = 0; i < data->nspec; i++) {
-		if (strncmp(spec_arr[i].property_key, key,
-			    strlen(spec_arr[i].property_key)) == 0) {
-			break;
-		}
-		if (strncmp(spec_arr[i].property_key, "*", 1) == 0)
-			break;
-	}
-
-	if (i >= data->nspec) {
-		/* No matching specification. */
-		errno = ENOENT;
-		goto finish;
-	}
-
-	ret = &spec_arr[i].lr;
-
-finish:
-	return ret;
-}
-
-static void stats(struct selabel_handle __attribute__((unused)) *rec)
-{
-	selinux_log(SELINUX_WARNING, "'stats' functionality not implemented.\n");
-}
-
-int selabel_property_init(struct selabel_handle *rec,
-			  const struct selinux_opt *opts,
-			  unsigned nopts)
-{
-	struct saved_data *data;
-
-	data = (struct saved_data *)malloc(sizeof(*data));
-	if (!data)
-		return -1;
-	memset(data, 0, sizeof(*data));
-
-	rec->data = data;
-	rec->func_close = &closef;
-	rec->func_stats = &stats;
-	rec->func_lookup = &lookup;
-
-	return init(rec, opts, nopts);
-}
diff --git a/libselinux/src/label_backends_android.c b/libselinux/src/label_backends_android.c
new file mode 100644
index 0000000..290b438
--- /dev/null
+++ b/libselinux/src/label_backends_android.c
@@ -0,0 +1,304 @@
+/*
+ * Property Service contexts backend for labeling Android
+ * property keys
+ */
+
+#include <stdarg.h>
+#include <string.h>
+#include <ctype.h>
+#include <errno.h>
+#include <limits.h>
+#include <sys/types.h>
+#include <sys/stat.h>
+#include "callbacks.h"
+#include "label_internal.h"
+
+/* A property security context specification. */
+typedef struct spec {
+	struct selabel_lookup_rec lr;	/* holds contexts for lookup result */
+	char *property_key;		/* property key string */
+} spec_t;
+
+/* Our stored configuration */
+struct saved_data {
+	/*
+	 * The array of specifications is sorted for longest
+	 * prefix match
+	 */
+	spec_t *spec_arr;
+	unsigned int nspec;	/* total number of specifications */
+};
+
+static int cmp(const void *A, const void *B)
+{
+	const struct spec *sp1 = A, *sp2 = B;
+
+	if (strncmp(sp1->property_key, "*", 1) == 0)
+		return 1;
+	if (strncmp(sp2->property_key, "*", 1) == 0)
+		return -1;
+
+	size_t L1 = strlen(sp1->property_key);
+	size_t L2 = strlen(sp2->property_key);
+
+	return (L1 < L2) - (L1 > L2);
+}
+
+/*
+ * Warn about duplicate specifications.
+ */
+static int nodups_specs(struct saved_data *data, const char *path)
+{
+	int rc = 0;
+	unsigned int ii, jj;
+	struct spec *curr_spec, *spec_arr = data->spec_arr;
+
+	for (ii = 0; ii < data->nspec; ii++) {
+		curr_spec = &spec_arr[ii];
+		for (jj = ii + 1; jj < data->nspec; jj++) {
+			if (!strcmp(spec_arr[jj].property_key,
+					    curr_spec->property_key)) {
+				rc = -1;
+				errno = EINVAL;
+				if (strcmp(spec_arr[jj].lr.ctx_raw,
+						    curr_spec->lr.ctx_raw)) {
+					selinux_log
+						(SELINUX_ERROR,
+						 "%s: Multiple different specifications for %s  (%s and %s).\n",
+						 path, curr_spec->property_key,
+						 spec_arr[jj].lr.ctx_raw,
+						 curr_spec->lr.ctx_raw);
+				} else {
+					selinux_log
+						(SELINUX_ERROR,
+						 "%s: Multiple same specifications for %s.\n",
+						 path, curr_spec->property_key);
+				}
+			}
+		}
+	}
+	return rc;
+}
+
+static int process_line(struct selabel_handle *rec,
+			const char *path, char *line_buf,
+			int pass, unsigned lineno)
+{
+	int items;
+	char *prop = NULL, *context = NULL;
+	struct saved_data *data = (struct saved_data *)rec->data;
+	spec_t *spec_arr = data->spec_arr;
+	unsigned int nspec = data->nspec;
+	const char *errbuf = NULL;
+
+	items = read_spec_entries(line_buf, &errbuf, 2, &prop, &context);
+	if (items < 0) {
+		items = errno;
+		selinux_log(SELINUX_ERROR,
+			"%s:  line %u error due to: %s\n", path,
+			lineno, errbuf ?: strerror(errno));
+		errno = items;
+		return -1;
+	}
+
+	if (items == 0)
+		return items;
+
+	if (items != 2) {
+		selinux_log(SELINUX_ERROR,
+			    "%s:  line %u is missing fields\n", path,
+			    lineno);
+		free(prop);
+		errno = EINVAL;
+		return -1;
+	}
+
+	if (pass == 0) {
+		free(prop);
+		free(context);
+	} else if (pass == 1) {
+		/* On the second pass, process and store the specification in spec. */
+		spec_arr[nspec].property_key = prop;
+		spec_arr[nspec].lr.ctx_raw = context;
+
+		if (rec->validating) {
+			if (selabel_validate(rec, &spec_arr[nspec].lr) < 0) {
+				selinux_log(SELINUX_ERROR,
+					    "%s:  line %u has invalid context %s\n",
+					    path, lineno, spec_arr[nspec].lr.ctx_raw);
+				errno = EINVAL;
+				return -1;
+			}
+		}
+	}
+
+	data->nspec = ++nspec;
+	return 0;
+}
+
+static int init(struct selabel_handle *rec, const struct selinux_opt *opts,
+		unsigned n)
+{
+	struct saved_data *data = (struct saved_data *)rec->data;
+	const char *path = NULL;
+	FILE *fp;
+	char line_buf[BUFSIZ];
+	unsigned int lineno, maxnspec, pass;
+	int status = -1;
+	struct stat sb;
+
+	/* Process arguments */
+	while (n--)
+		switch (opts[n].type) {
+		case SELABEL_OPT_PATH:
+			path = opts[n].value;
+			break;
+		}
+
+	if (!path)
+		return -1;
+
+	/* Open the specification file. */
+	if ((fp = fopen(path, "r")) == NULL)
+		return -1;
+
+	if (fstat(fileno(fp), &sb) < 0)
+		goto finish;
+	errno = EINVAL;
+	if (!S_ISREG(sb.st_mode))
+		goto finish;
+
+	/*
+	 * Two passes of the specification file. First is to get the size.
+	 * After the first pass, the spec array is malloced to the appropriate
+	 * size. Second pass is to populate the spec array and check for
+	 * dups.
+	 */
+	maxnspec = UINT_MAX / sizeof(spec_t);
+	for (pass = 0; pass < 2; pass++) {
+		data->nspec = 0;
+		lineno = 0;
+
+		while (fgets(line_buf, sizeof(line_buf) - 1, fp)
+		       && data->nspec < maxnspec) {
+			if (process_line(rec, path, line_buf, pass, ++lineno)
+									  != 0)
+				goto finish;
+		}
+
+		if (pass == 1) {
+			status = nodups_specs(data, path);
+
+			if (status)
+				goto finish;
+		}
+
+		if (pass == 0) {
+			if (data->nspec == 0) {
+				status = 0;
+				goto finish;
+			}
+
+			if (NULL == (data->spec_arr =
+				     malloc(sizeof(spec_t) * data->nspec)))
+				goto finish;
+
+			memset(data->spec_arr, 0, sizeof(spec_t) * data->nspec);
+			maxnspec = data->nspec;
+			rewind(fp);
+		}
+	}
+
+	qsort(data->spec_arr, data->nspec, sizeof(struct spec), cmp);
+
+	status = digest_add_specfile(rec->digest, fp, NULL, sb.st_size, path);
+	if (status)
+		goto finish;
+
+	digest_gen_hash(rec->digest);
+
+finish:
+	fclose(fp);
+	return status;
+}
+
+/*
+ * Backend interface routines
+ */
+static void closef(struct selabel_handle *rec)
+{
+	struct saved_data *data = (struct saved_data *)rec->data;
+	struct spec *spec;
+	unsigned int i;
+
+	for (i = 0; i < data->nspec; i++) {
+		spec = &data->spec_arr[i];
+		free(spec->property_key);
+		free(spec->lr.ctx_raw);
+		free(spec->lr.ctx_trans);
+	}
+
+	if (data->spec_arr)
+		free(data->spec_arr);
+
+	free(data);
+}
+
+static struct selabel_lookup_rec *lookup(struct selabel_handle *rec,
+					 const char *key,
+					 int __attribute__((unused)) type)
+{
+	struct saved_data *data = (struct saved_data *)rec->data;
+	spec_t *spec_arr = data->spec_arr;
+	unsigned int i;
+	struct selabel_lookup_rec *ret = NULL;
+
+	if (!data->nspec) {
+		errno = ENOENT;
+		goto finish;
+	}
+
+	for (i = 0; i < data->nspec; i++) {
+		if (strncmp(spec_arr[i].property_key, key,
+			    strlen(spec_arr[i].property_key)) == 0) {
+			break;
+		}
+		if (strncmp(spec_arr[i].property_key, "*", 1) == 0)
+			break;
+	}
+
+	if (i >= data->nspec) {
+		/* No matching specification. */
+		errno = ENOENT;
+		goto finish;
+	}
+
+	ret = &spec_arr[i].lr;
+
+finish:
+	return ret;
+}
+
+static void stats(struct selabel_handle __attribute__((unused)) *rec)
+{
+	selinux_log(SELINUX_WARNING, "'stats' functionality not implemented.\n");
+}
+
+int selabel_property_init(struct selabel_handle *rec,
+			  const struct selinux_opt *opts,
+			  unsigned nopts)
+{
+	struct saved_data *data;
+
+	data = (struct saved_data *)malloc(sizeof(*data));
+	if (!data)
+		return -1;
+	memset(data, 0, sizeof(*data));
+
+	rec->data = data;
+	rec->func_close = &closef;
+	rec->func_stats = &stats;
+	rec->func_lookup = &lookup;
+
+	return init(rec, opts, nopts);
+}
-- 
1.9.1

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH 2/3] libselinux: android: fix lax service context lookup
  2016-09-29 11:39 [PATCH 1/3] libselinux: renamed andriod label backend source file Janis Danisevskis
@ 2016-09-29 11:39 ` Janis Danisevskis
  2016-09-29 11:57   ` William Roberts
  2016-09-29 11:39 ` [PATCH 3/3] libselinux: makes android label back ends configurable Janis Danisevskis
  1 sibling, 1 reply; 6+ messages in thread
From: Janis Danisevskis @ 2016-09-29 11:39 UTC (permalink / raw)
  To: selinux, seandroid-list, sds, jwcart2; +Cc: Janis Danisevskis

We use the same lookup function for service contexts
that we use for property contexts. However, property
contexts are namespace based and only compare the
prefix. This may lead to service associations with
a wrong label.

This patch introduces a new back end for android
services with a stricter lookup function. Now the
service name must match the key of the service label
exactly.

Signed-off-by: Janis Danisevskis <jdanis@android.com>
---
 libselinux/include/selinux/label.h      |  2 ++
 libselinux/src/label.c                  |  1 +
 libselinux/src/label_backends_android.c | 54 +++++++++++++++++++++++++++++++--
 libselinux/src/label_internal.h         |  3 ++
 libselinux/utils/selabel_digest.c       |  2 ++
 libselinux/utils/selabel_lookup.c       |  2 ++
 6 files changed, 62 insertions(+), 2 deletions(-)

diff --git a/libselinux/include/selinux/label.h b/libselinux/include/selinux/label.h
index f0b1e10..277287e 100644
--- a/libselinux/include/selinux/label.h
+++ b/libselinux/include/selinux/label.h
@@ -34,6 +34,8 @@ struct selabel_handle;
 #define SELABEL_CTX_DB		3
 /* Android property service contexts */
 #define SELABEL_CTX_ANDROID_PROP 4
+/* Android service contexts */
+#define SELABEL_CTX_ANDROID_SERVICE 5
 
 /*
  * Available options
diff --git a/libselinux/src/label.c b/libselinux/src/label.c
index 96a4ff1..eb0e766 100644
--- a/libselinux/src/label.c
+++ b/libselinux/src/label.c
@@ -45,6 +45,7 @@ static selabel_initfunc initfuncs[] = {
 	CONFIG_X_BACKEND(selabel_x_init),
 	CONFIG_DB_BACKEND(selabel_db_init),
 	&selabel_property_init,
+	&selabel_service_init,
 };
 
 static void selabel_subs_fini(struct selabel_sub *ptr)
diff --git a/libselinux/src/label_backends_android.c b/libselinux/src/label_backends_android.c
index 290b438..4d6ec86 100644
--- a/libselinux/src/label_backends_android.c
+++ b/libselinux/src/label_backends_android.c
@@ -244,7 +244,7 @@ static void closef(struct selabel_handle *rec)
 	free(data);
 }
 
-static struct selabel_lookup_rec *lookup(struct selabel_handle *rec,
+static struct selabel_lookup_rec *property_lookup(struct selabel_handle *rec,
 					 const char *key,
 					 int __attribute__((unused)) type)
 {
@@ -279,6 +279,38 @@ finish:
 	return ret;
 }
 
+static struct selabel_lookup_rec *service_lookup(struct selabel_handle *rec,
+		const char *key, int __attribute__((unused)) type)
+{
+	struct saved_data *data = (struct saved_data *)rec->data;
+	spec_t *spec_arr = data->spec_arr;
+	unsigned int i;
+	struct selabel_lookup_rec *ret = NULL;
+
+	if (!data->nspec) {
+		errno = ENOENT;
+		goto finish;
+	}
+
+	for (i = 0; i < data->nspec; i++) {
+		if (strcmp(spec_arr[i].property_key, key) == 0)
+			break;
+		if (strcmp(spec_arr[i].property_key, "*") == 0)
+			break;
+	}
+
+	if (i >= data->nspec) {
+		/* No matching specification. */
+		errno = ENOENT;
+		goto finish;
+	}
+
+	ret = &spec_arr[i].lr;
+
+finish:
+	return ret;
+}
+
 static void stats(struct selabel_handle __attribute__((unused)) *rec)
 {
 	selinux_log(SELINUX_WARNING, "'stats' functionality not implemented.\n");
@@ -298,7 +330,25 @@ int selabel_property_init(struct selabel_handle *rec,
 	rec->data = data;
 	rec->func_close = &closef;
 	rec->func_stats = &stats;
-	rec->func_lookup = &lookup;
+	rec->func_lookup = &property_lookup;
+
+	return init(rec, opts, nopts);
+}
+
+int selabel_service_init(struct selabel_handle *rec,
+		const struct selinux_opt *opts, unsigned nopts)
+{
+	struct saved_data *data;
+
+	data = (struct saved_data *)malloc(sizeof(*data));
+	if (!data)
+		return -1;
+	memset(data, 0, sizeof(*data));
+
+	rec->data = data;
+	rec->func_close = &closef;
+	rec->func_stats = &stats;
+	rec->func_lookup = &service_lookup;
 
 	return init(rec, opts, nopts);
 }
diff --git a/libselinux/src/label_internal.h b/libselinux/src/label_internal.h
index 7c55531..6a9481a 100644
--- a/libselinux/src/label_internal.h
+++ b/libselinux/src/label_internal.h
@@ -39,6 +39,9 @@ int selabel_db_init(struct selabel_handle *rec,
 int selabel_property_init(struct selabel_handle *rec,
 			    const struct selinux_opt *opts,
 			    unsigned nopts) hidden;
+int selabel_service_init(struct selabel_handle *rec,
+			    const struct selinux_opt *opts,
+			    unsigned nopts) hidden;
 
 /*
  * Labeling internal structures
diff --git a/libselinux/utils/selabel_digest.c b/libselinux/utils/selabel_digest.c
index 38162a5..e4d84a5 100644
--- a/libselinux/utils/selabel_digest.c
+++ b/libselinux/utils/selabel_digest.c
@@ -92,6 +92,8 @@ int main(int argc, char **argv)
 				backend = SELABEL_CTX_DB;
 			} else if (!strcmp(optarg, "prop")) {
 				backend = SELABEL_CTX_ANDROID_PROP;
+			} else if (!strcmp(optarg, "service")) {
+				backend = SELABEL_CTX_ANDROID_SERVICE;
 			} else {
 				fprintf(stderr, "Unknown backend: %s\n",
 								    optarg);
diff --git a/libselinux/utils/selabel_lookup.c b/libselinux/utils/selabel_lookup.c
index d0b1457..b678a89 100644
--- a/libselinux/utils/selabel_lookup.c
+++ b/libselinux/utils/selabel_lookup.c
@@ -57,6 +57,8 @@ int main(int argc, char **argv)
 				backend = SELABEL_CTX_DB;
 			} else if (!strcmp(optarg, "prop")) {
 				backend = SELABEL_CTX_ANDROID_PROP;
+			} else if (!strcmp(optarg, "service")) {
+				backend = SELABEL_CTX_ANDROID_SERVICE;
 			} else {
 				fprintf(stderr, "Unknown backend: %s\n",
 								    optarg);
-- 
1.9.1

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH 3/3] libselinux: makes android label back ends configurable
  2016-09-29 11:39 [PATCH 1/3] libselinux: renamed andriod label backend source file Janis Danisevskis
  2016-09-29 11:39 ` [PATCH 2/3] libselinux: android: fix lax service context lookup Janis Danisevskis
@ 2016-09-29 11:39 ` Janis Danisevskis
  2016-09-29 14:23   ` Stephen Smalley
  1 sibling, 1 reply; 6+ messages in thread
From: Janis Danisevskis @ 2016-09-29 11:39 UTC (permalink / raw)
  To: selinux, seandroid-list, sds, jwcart2; +Cc: Janis Danisevskis

Android label back ends are not configurable by NO_ANDROID_BACKEND,
which is set if on ANDROID_HOST != y.

Signed-off-by: Janis Danisevskis <jdanis@android.com>
---
 libselinux/src/Makefile |  3 +++
 libselinux/src/label.c  | 10 ++++++++--
 2 files changed, 11 insertions(+), 2 deletions(-)

diff --git a/libselinux/src/Makefile b/libselinux/src/Makefile
index cba8383..7169230 100644
--- a/libselinux/src/Makefile
+++ b/libselinux/src/Makefile
@@ -87,6 +87,9 @@ DISABLE_FLAGS+= -DNO_MEDIA_BACKEND -DNO_DB_BACKEND -DNO_X_BACKEND \
 SRCS= callbacks.c freecon.c label.c label_file.c \
 	label_backends_android.c regex.c label_support.c \
 	matchpathcon.c setrans_client.c sha1.c
+else
+DISABLE_FLAGS+= -DNO_ANDROID_BACKEND
+SRCS:= $(filter-out label_backends_android.c, $(SRCS))
 endif
 
 SWIG = swig -Wall -python -o $(SWIGCOUT) -outdir ./ $(DISABLE_FLAGS)
diff --git a/libselinux/src/label.c b/libselinux/src/label.c
index eb0e766..60639cf 100644
--- a/libselinux/src/label.c
+++ b/libselinux/src/label.c
@@ -35,6 +35,12 @@
 #define CONFIG_DB_BACKEND(fnptr) &fnptr
 #endif
 
+#ifdef NO_ANDROID_BACKEND
+#define CONFIG_ANDROID_BACKEND(fnptr) NULL
+#else
+#define CONFIG_ANDROID_BACKEND(fnptr) (&(fnptr))
+#endif
+
 typedef int (*selabel_initfunc)(struct selabel_handle *rec,
 				const struct selinux_opt *opts,
 				unsigned nopts);
@@ -44,8 +50,8 @@ static selabel_initfunc initfuncs[] = {
 	CONFIG_MEDIA_BACKEND(selabel_media_init),
 	CONFIG_X_BACKEND(selabel_x_init),
 	CONFIG_DB_BACKEND(selabel_db_init),
-	&selabel_property_init,
-	&selabel_service_init,
+	CONFIG_ANDROID_BACKEND(selabel_property_init),
+	CONFIG_ANDROID_BACKEND(selabel_service_init),
 };
 
 static void selabel_subs_fini(struct selabel_sub *ptr)
-- 
1.9.1

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH 2/3] libselinux: android: fix lax service context lookup
  2016-09-29 11:39 ` [PATCH 2/3] libselinux: android: fix lax service context lookup Janis Danisevskis
@ 2016-09-29 11:57   ` William Roberts
  2016-09-29 13:01     ` Janis Danisevskis
  0 siblings, 1 reply; 6+ messages in thread
From: William Roberts @ 2016-09-29 11:57 UTC (permalink / raw)
  To: Janis Danisevskis; +Cc: selinux, seandroid-list, Stephen Smalley, James Carter

do you have the corresponding changes to checkfc on AOSP?

On Thu, Sep 29, 2016 at 7:39 AM, Janis Danisevskis <jdanis@android.com> wrote:
> We use the same lookup function for service contexts
> that we use for property contexts. However, property
> contexts are namespace based and only compare the
> prefix. This may lead to service associations with
> a wrong label.
>
> This patch introduces a new back end for android
> services with a stricter lookup function. Now the
> service name must match the key of the service label
> exactly.
>
> Signed-off-by: Janis Danisevskis <jdanis@android.com>
> ---
>  libselinux/include/selinux/label.h      |  2 ++
>  libselinux/src/label.c                  |  1 +
>  libselinux/src/label_backends_android.c | 54 +++++++++++++++++++++++++++++++--
>  libselinux/src/label_internal.h         |  3 ++
>  libselinux/utils/selabel_digest.c       |  2 ++
>  libselinux/utils/selabel_lookup.c       |  2 ++
>  6 files changed, 62 insertions(+), 2 deletions(-)
>
> diff --git a/libselinux/include/selinux/label.h b/libselinux/include/selinux/label.h
> index f0b1e10..277287e 100644
> --- a/libselinux/include/selinux/label.h
> +++ b/libselinux/include/selinux/label.h
> @@ -34,6 +34,8 @@ struct selabel_handle;
>  #define SELABEL_CTX_DB         3
>  /* Android property service contexts */
>  #define SELABEL_CTX_ANDROID_PROP 4
> +/* Android service contexts */
> +#define SELABEL_CTX_ANDROID_SERVICE 5
>
>  /*
>   * Available options
> diff --git a/libselinux/src/label.c b/libselinux/src/label.c
> index 96a4ff1..eb0e766 100644
> --- a/libselinux/src/label.c
> +++ b/libselinux/src/label.c
> @@ -45,6 +45,7 @@ static selabel_initfunc initfuncs[] = {
>         CONFIG_X_BACKEND(selabel_x_init),
>         CONFIG_DB_BACKEND(selabel_db_init),
>         &selabel_property_init,
> +       &selabel_service_init,
>  };
>
>  static void selabel_subs_fini(struct selabel_sub *ptr)
> diff --git a/libselinux/src/label_backends_android.c b/libselinux/src/label_backends_android.c
> index 290b438..4d6ec86 100644
> --- a/libselinux/src/label_backends_android.c
> +++ b/libselinux/src/label_backends_android.c
> @@ -244,7 +244,7 @@ static void closef(struct selabel_handle *rec)
>         free(data);
>  }
>
> -static struct selabel_lookup_rec *lookup(struct selabel_handle *rec,
> +static struct selabel_lookup_rec *property_lookup(struct selabel_handle *rec,
>                                          const char *key,
>                                          int __attribute__((unused)) type)
>  {
> @@ -279,6 +279,38 @@ finish:
>         return ret;
>  }
>
> +static struct selabel_lookup_rec *service_lookup(struct selabel_handle *rec,
> +               const char *key, int __attribute__((unused)) type)
> +{
> +       struct saved_data *data = (struct saved_data *)rec->data;
> +       spec_t *spec_arr = data->spec_arr;
> +       unsigned int i;
> +       struct selabel_lookup_rec *ret = NULL;
> +
> +       if (!data->nspec) {
> +               errno = ENOENT;
> +               goto finish;
> +       }
> +
> +       for (i = 0; i < data->nspec; i++) {
> +               if (strcmp(spec_arr[i].property_key, key) == 0)
> +                       break;
> +               if (strcmp(spec_arr[i].property_key, "*") == 0)
> +                       break;
> +       }
> +
> +       if (i >= data->nspec) {
> +               /* No matching specification. */
> +               errno = ENOENT;
> +               goto finish;
> +       }
> +
> +       ret = &spec_arr[i].lr;
> +
> +finish:
> +       return ret;
> +}
> +
>  static void stats(struct selabel_handle __attribute__((unused)) *rec)
>  {
>         selinux_log(SELINUX_WARNING, "'stats' functionality not implemented.\n");
> @@ -298,7 +330,25 @@ int selabel_property_init(struct selabel_handle *rec,
>         rec->data = data;
>         rec->func_close = &closef;
>         rec->func_stats = &stats;
> -       rec->func_lookup = &lookup;
> +       rec->func_lookup = &property_lookup;
> +
> +       return init(rec, opts, nopts);
> +}
> +
> +int selabel_service_init(struct selabel_handle *rec,
> +               const struct selinux_opt *opts, unsigned nopts)
> +{
> +       struct saved_data *data;
> +
> +       data = (struct saved_data *)malloc(sizeof(*data));
> +       if (!data)
> +               return -1;
> +       memset(data, 0, sizeof(*data));
> +
> +       rec->data = data;
> +       rec->func_close = &closef;
> +       rec->func_stats = &stats;
> +       rec->func_lookup = &service_lookup;
>
>         return init(rec, opts, nopts);
>  }
> diff --git a/libselinux/src/label_internal.h b/libselinux/src/label_internal.h
> index 7c55531..6a9481a 100644
> --- a/libselinux/src/label_internal.h
> +++ b/libselinux/src/label_internal.h
> @@ -39,6 +39,9 @@ int selabel_db_init(struct selabel_handle *rec,
>  int selabel_property_init(struct selabel_handle *rec,
>                             const struct selinux_opt *opts,
>                             unsigned nopts) hidden;
> +int selabel_service_init(struct selabel_handle *rec,
> +                           const struct selinux_opt *opts,
> +                           unsigned nopts) hidden;
>
>  /*
>   * Labeling internal structures
> diff --git a/libselinux/utils/selabel_digest.c b/libselinux/utils/selabel_digest.c
> index 38162a5..e4d84a5 100644
> --- a/libselinux/utils/selabel_digest.c
> +++ b/libselinux/utils/selabel_digest.c
> @@ -92,6 +92,8 @@ int main(int argc, char **argv)
>                                 backend = SELABEL_CTX_DB;
>                         } else if (!strcmp(optarg, "prop")) {
>                                 backend = SELABEL_CTX_ANDROID_PROP;
> +                       } else if (!strcmp(optarg, "service")) {
> +                               backend = SELABEL_CTX_ANDROID_SERVICE;
>                         } else {
>                                 fprintf(stderr, "Unknown backend: %s\n",
>                                                                     optarg);
> diff --git a/libselinux/utils/selabel_lookup.c b/libselinux/utils/selabel_lookup.c
> index d0b1457..b678a89 100644
> --- a/libselinux/utils/selabel_lookup.c
> +++ b/libselinux/utils/selabel_lookup.c
> @@ -57,6 +57,8 @@ int main(int argc, char **argv)
>                                 backend = SELABEL_CTX_DB;
>                         } else if (!strcmp(optarg, "prop")) {
>                                 backend = SELABEL_CTX_ANDROID_PROP;
> +                       } else if (!strcmp(optarg, "service")) {
> +                               backend = SELABEL_CTX_ANDROID_SERVICE;
>                         } else {
>                                 fprintf(stderr, "Unknown backend: %s\n",
>                                                                     optarg);
> --
> 1.9.1
>
> _______________________________________________
> Selinux mailing list
> Selinux@tycho.nsa.gov
> To unsubscribe, send email to Selinux-leave@tycho.nsa.gov.
> To get help, send an email containing "help" to Selinux-request@tycho.nsa.gov.



-- 
Respectfully,

William C Roberts

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH 2/3] libselinux: android: fix lax service context lookup
  2016-09-29 11:57   ` William Roberts
@ 2016-09-29 13:01     ` Janis Danisevskis
  0 siblings, 0 replies; 6+ messages in thread
From: Janis Danisevskis @ 2016-09-29 13:01 UTC (permalink / raw)
  To: William Roberts; +Cc: selinux, seandroid-list, Stephen Smalley, James Carter

[-- Attachment #1: Type: text/plain, Size: 7453 bytes --]

William: Good thing you mention checkfc. I added you as a reviewer.

On Thu, Sep 29, 2016 at 12:57 PM, William Roberts <bill.c.roberts@gmail.com>
wrote:

> do you have the corresponding changes to checkfc on AOSP?
>
> On Thu, Sep 29, 2016 at 7:39 AM, Janis Danisevskis <jdanis@android.com>
> wrote:
> > We use the same lookup function for service contexts
> > that we use for property contexts. However, property
> > contexts are namespace based and only compare the
> > prefix. This may lead to service associations with
> > a wrong label.
> >
> > This patch introduces a new back end for android
> > services with a stricter lookup function. Now the
> > service name must match the key of the service label
> > exactly.
> >
> > Signed-off-by: Janis Danisevskis <jdanis@android.com>
> > ---
> >  libselinux/include/selinux/label.h      |  2 ++
> >  libselinux/src/label.c                  |  1 +
> >  libselinux/src/label_backends_android.c | 54
> +++++++++++++++++++++++++++++++--
> >  libselinux/src/label_internal.h         |  3 ++
> >  libselinux/utils/selabel_digest.c       |  2 ++
> >  libselinux/utils/selabel_lookup.c       |  2 ++
> >  6 files changed, 62 insertions(+), 2 deletions(-)
> >
> > diff --git a/libselinux/include/selinux/label.h
> b/libselinux/include/selinux/label.h
> > index f0b1e10..277287e 100644
> > --- a/libselinux/include/selinux/label.h
> > +++ b/libselinux/include/selinux/label.h
> > @@ -34,6 +34,8 @@ struct selabel_handle;
> >  #define SELABEL_CTX_DB         3
> >  /* Android property service contexts */
> >  #define SELABEL_CTX_ANDROID_PROP 4
> > +/* Android service contexts */
> > +#define SELABEL_CTX_ANDROID_SERVICE 5
> >
> >  /*
> >   * Available options
> > diff --git a/libselinux/src/label.c b/libselinux/src/label.c
> > index 96a4ff1..eb0e766 100644
> > --- a/libselinux/src/label.c
> > +++ b/libselinux/src/label.c
> > @@ -45,6 +45,7 @@ static selabel_initfunc initfuncs[] = {
> >         CONFIG_X_BACKEND(selabel_x_init),
> >         CONFIG_DB_BACKEND(selabel_db_init),
> >         &selabel_property_init,
> > +       &selabel_service_init,
> >  };
> >
> >  static void selabel_subs_fini(struct selabel_sub *ptr)
> > diff --git a/libselinux/src/label_backends_android.c
> b/libselinux/src/label_backends_android.c
> > index 290b438..4d6ec86 100644
> > --- a/libselinux/src/label_backends_android.c
> > +++ b/libselinux/src/label_backends_android.c
> > @@ -244,7 +244,7 @@ static void closef(struct selabel_handle *rec)
> >         free(data);
> >  }
> >
> > -static struct selabel_lookup_rec *lookup(struct selabel_handle *rec,
> > +static struct selabel_lookup_rec *property_lookup(struct selabel_handle
> *rec,
> >                                          const char *key,
> >                                          int __attribute__((unused))
> type)
> >  {
> > @@ -279,6 +279,38 @@ finish:
> >         return ret;
> >  }
> >
> > +static struct selabel_lookup_rec *service_lookup(struct selabel_handle
> *rec,
> > +               const char *key, int __attribute__((unused)) type)
> > +{
> > +       struct saved_data *data = (struct saved_data *)rec->data;
> > +       spec_t *spec_arr = data->spec_arr;
> > +       unsigned int i;
> > +       struct selabel_lookup_rec *ret = NULL;
> > +
> > +       if (!data->nspec) {
> > +               errno = ENOENT;
> > +               goto finish;
> > +       }
> > +
> > +       for (i = 0; i < data->nspec; i++) {
> > +               if (strcmp(spec_arr[i].property_key, key) == 0)
> > +                       break;
> > +               if (strcmp(spec_arr[i].property_key, "*") == 0)
> > +                       break;
> > +       }
> > +
> > +       if (i >= data->nspec) {
> > +               /* No matching specification. */
> > +               errno = ENOENT;
> > +               goto finish;
> > +       }
> > +
> > +       ret = &spec_arr[i].lr;
> > +
> > +finish:
> > +       return ret;
> > +}
> > +
> >  static void stats(struct selabel_handle __attribute__((unused)) *rec)
> >  {
> >         selinux_log(SELINUX_WARNING, "'stats' functionality not
> implemented.\n");
> > @@ -298,7 +330,25 @@ int selabel_property_init(struct selabel_handle
> *rec,
> >         rec->data = data;
> >         rec->func_close = &closef;
> >         rec->func_stats = &stats;
> > -       rec->func_lookup = &lookup;
> > +       rec->func_lookup = &property_lookup;
> > +
> > +       return init(rec, opts, nopts);
> > +}
> > +
> > +int selabel_service_init(struct selabel_handle *rec,
> > +               const struct selinux_opt *opts, unsigned nopts)
> > +{
> > +       struct saved_data *data;
> > +
> > +       data = (struct saved_data *)malloc(sizeof(*data));
> > +       if (!data)
> > +               return -1;
> > +       memset(data, 0, sizeof(*data));
> > +
> > +       rec->data = data;
> > +       rec->func_close = &closef;
> > +       rec->func_stats = &stats;
> > +       rec->func_lookup = &service_lookup;
> >
> >         return init(rec, opts, nopts);
> >  }
> > diff --git a/libselinux/src/label_internal.h b/libselinux/src/label_
> internal.h
> > index 7c55531..6a9481a 100644
> > --- a/libselinux/src/label_internal.h
> > +++ b/libselinux/src/label_internal.h
> > @@ -39,6 +39,9 @@ int selabel_db_init(struct selabel_handle *rec,
> >  int selabel_property_init(struct selabel_handle *rec,
> >                             const struct selinux_opt *opts,
> >                             unsigned nopts) hidden;
> > +int selabel_service_init(struct selabel_handle *rec,
> > +                           const struct selinux_opt *opts,
> > +                           unsigned nopts) hidden;
> >
> >  /*
> >   * Labeling internal structures
> > diff --git a/libselinux/utils/selabel_digest.c
> b/libselinux/utils/selabel_digest.c
> > index 38162a5..e4d84a5 100644
> > --- a/libselinux/utils/selabel_digest.c
> > +++ b/libselinux/utils/selabel_digest.c
> > @@ -92,6 +92,8 @@ int main(int argc, char **argv)
> >                                 backend = SELABEL_CTX_DB;
> >                         } else if (!strcmp(optarg, "prop")) {
> >                                 backend = SELABEL_CTX_ANDROID_PROP;
> > +                       } else if (!strcmp(optarg, "service")) {
> > +                               backend = SELABEL_CTX_ANDROID_SERVICE;
> >                         } else {
> >                                 fprintf(stderr, "Unknown backend: %s\n",
> >
>  optarg);
> > diff --git a/libselinux/utils/selabel_lookup.c
> b/libselinux/utils/selabel_lookup.c
> > index d0b1457..b678a89 100644
> > --- a/libselinux/utils/selabel_lookup.c
> > +++ b/libselinux/utils/selabel_lookup.c
> > @@ -57,6 +57,8 @@ int main(int argc, char **argv)
> >                                 backend = SELABEL_CTX_DB;
> >                         } else if (!strcmp(optarg, "prop")) {
> >                                 backend = SELABEL_CTX_ANDROID_PROP;
> > +                       } else if (!strcmp(optarg, "service")) {
> > +                               backend = SELABEL_CTX_ANDROID_SERVICE;
> >                         } else {
> >                                 fprintf(stderr, "Unknown backend: %s\n",
> >
>  optarg);
> > --
> > 1.9.1
> >
> > _______________________________________________
> > Selinux mailing list
> > Selinux@tycho.nsa.gov
> > To unsubscribe, send email to Selinux-leave@tycho.nsa.gov.
> > To get help, send an email containing "help" to
> Selinux-request@tycho.nsa.gov.
>
>
>
> --
> Respectfully,
>
> William C Roberts
>

[-- Attachment #2: Type: text/html, Size: 10282 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH 3/3] libselinux: makes android label back ends configurable
  2016-09-29 11:39 ` [PATCH 3/3] libselinux: makes android label back ends configurable Janis Danisevskis
@ 2016-09-29 14:23   ` Stephen Smalley
  0 siblings, 0 replies; 6+ messages in thread
From: Stephen Smalley @ 2016-09-29 14:23 UTC (permalink / raw)
  To: Janis Danisevskis, selinux, seandroid-list, jwcart2

On 09/29/2016 07:39 AM, Janis Danisevskis wrote:
> Android label back ends are not configurable by NO_ANDROID_BACKEND,
> which is set if on ANDROID_HOST != y.
> 
> Signed-off-by: Janis Danisevskis <jdanis@android.com>

Thanks, applied all three.

> ---
>  libselinux/src/Makefile |  3 +++
>  libselinux/src/label.c  | 10 ++++++++--
>  2 files changed, 11 insertions(+), 2 deletions(-)
> 
> diff --git a/libselinux/src/Makefile b/libselinux/src/Makefile
> index cba8383..7169230 100644
> --- a/libselinux/src/Makefile
> +++ b/libselinux/src/Makefile
> @@ -87,6 +87,9 @@ DISABLE_FLAGS+= -DNO_MEDIA_BACKEND -DNO_DB_BACKEND -DNO_X_BACKEND \
>  SRCS= callbacks.c freecon.c label.c label_file.c \
>  	label_backends_android.c regex.c label_support.c \
>  	matchpathcon.c setrans_client.c sha1.c
> +else
> +DISABLE_FLAGS+= -DNO_ANDROID_BACKEND
> +SRCS:= $(filter-out label_backends_android.c, $(SRCS))
>  endif
>  
>  SWIG = swig -Wall -python -o $(SWIGCOUT) -outdir ./ $(DISABLE_FLAGS)
> diff --git a/libselinux/src/label.c b/libselinux/src/label.c
> index eb0e766..60639cf 100644
> --- a/libselinux/src/label.c
> +++ b/libselinux/src/label.c
> @@ -35,6 +35,12 @@
>  #define CONFIG_DB_BACKEND(fnptr) &fnptr
>  #endif
>  
> +#ifdef NO_ANDROID_BACKEND
> +#define CONFIG_ANDROID_BACKEND(fnptr) NULL
> +#else
> +#define CONFIG_ANDROID_BACKEND(fnptr) (&(fnptr))
> +#endif
> +
>  typedef int (*selabel_initfunc)(struct selabel_handle *rec,
>  				const struct selinux_opt *opts,
>  				unsigned nopts);
> @@ -44,8 +50,8 @@ static selabel_initfunc initfuncs[] = {
>  	CONFIG_MEDIA_BACKEND(selabel_media_init),
>  	CONFIG_X_BACKEND(selabel_x_init),
>  	CONFIG_DB_BACKEND(selabel_db_init),
> -	&selabel_property_init,
> -	&selabel_service_init,
> +	CONFIG_ANDROID_BACKEND(selabel_property_init),
> +	CONFIG_ANDROID_BACKEND(selabel_service_init),
>  };
>  
>  static void selabel_subs_fini(struct selabel_sub *ptr)
> 

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2016-09-29 14:23 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-09-29 11:39 [PATCH 1/3] libselinux: renamed andriod label backend source file Janis Danisevskis
2016-09-29 11:39 ` [PATCH 2/3] libselinux: android: fix lax service context lookup Janis Danisevskis
2016-09-29 11:57   ` William Roberts
2016-09-29 13:01     ` Janis Danisevskis
2016-09-29 11:39 ` [PATCH 3/3] libselinux: makes android label back ends configurable Janis Danisevskis
2016-09-29 14:23   ` Stephen Smalley

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.