Redirect boringssl_self_test stdio to kmsg
To aid in debugging if there are failures.
Bug: 137267623
Test: add prints to boringssl_self_test and see them
Change-Id: I34b20225514898911b3f476d4517430433eb379e
diff --git a/private/boringssl_self_test.te b/private/boringssl_self_test.te
index 0ef4b53..4e2d848 100644
--- a/private/boringssl_self_test.te
+++ b/private/boringssl_self_test.te
@@ -10,6 +10,9 @@
allow boringssl_self_test boringssl_self_test_marker:file create_file_perms;
allow boringssl_self_test boringssl_self_test_marker:dir ra_dir_perms;
+# Allow boringsself_self_test to write its stdout/stderr messages to kmsg_debug.
+allow boringssl_self_test kmsg_debug_device:chr_file { w_file_perms getattr ioctl };
+
# No other process should be able to create these files because their existence causes the
# boringssl self test to be skipped.
neverallow {