summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--eth0_dns.sh3
-rw-r--r--sepolicy/shell.te4
2 files changed, 5 insertions, 2 deletions
diff --git a/eth0_dns.sh b/eth0_dns.sh
new file mode 100644
index 0000000..2317931
--- /dev/null
+++ b/eth0_dns.sh
@@ -0,0 +1,3 @@
+#!/system/bin/sh
+/system/bin/ndc resolver setdefaultif eth0
+/system/bin/ndc resolver setifdns eth0 '' 8.8.8.8
diff --git a/sepolicy/shell.te b/sepolicy/shell.te
index b4f6f1b..4069fc1 100644
--- a/sepolicy/shell.te
+++ b/sepolicy/shell.te
@@ -1,7 +1,7 @@
allow shell serial_device:chr_file rw_file_perms;
-# hack for running svc netd setdefaultifdns
-allow shell dalvikcache_data_file:file rw_file_perms;
+# allow to use ndc command to enable dns work
+allow shell netd_socket:sock_file write;
# hack for running netcfg eth0 dhcp/ifconfig/ping on console session
allow shell self:packet_socket create_socket_perms;