Merge cherrypicks of [16615268] into rvc-platform-release. am: 5b74cfce8d

Original change: https://googleplex-android-review.googlesource.com/c/platform/system/sepolicy/+/16674945

Change-Id: Ib82e90c661d43cf46cfb33a40ccae08c28ddca1d
diff --git a/prebuilts/api/30.0/private/adbd.te b/prebuilts/api/30.0/private/adbd.te
index 5531ad4..f6dfdc0 100644
--- a/prebuilts/api/30.0/private/adbd.te
+++ b/prebuilts/api/30.0/private/adbd.te
@@ -162,6 +162,9 @@
 # Allow pulling config.gz for CTS purposes
 allow adbd config_gz:file r_file_perms;
 
+# For CTS listening ports test.
+allow adbd proc_net_tcp_udp:file r_file_perms;
+
 allow adbd gpu_service:service_manager find;
 allow adbd surfaceflinger_service:service_manager find;
 allow adbd bootchart_data_file:dir search;
diff --git a/private/adbd.te b/private/adbd.te
index 5531ad4..f6dfdc0 100644
--- a/private/adbd.te
+++ b/private/adbd.te
@@ -162,6 +162,9 @@
 # Allow pulling config.gz for CTS purposes
 allow adbd config_gz:file r_file_perms;
 
+# For CTS listening ports test.
+allow adbd proc_net_tcp_udp:file r_file_perms;
+
 allow adbd gpu_service:service_manager find;
 allow adbd surfaceflinger_service:service_manager find;
 allow adbd bootchart_data_file:dir search;