From 7145e51972a9d0dc9ed894a2eb655bfaee8c06d6 Mon Sep 17 00:00:00 2001 From: M66B Date: Tue, 7 May 2019 21:14:35 +0200 Subject: [PATCH] Added DNS daemon package info --- app/src/main/java/eu/faircode/netguard/Rule.java | 16 ++++++++++++++++ app/src/main/res/values/strings.xml | 1 + 2 files changed, 17 insertions(+) diff --git a/app/src/main/java/eu/faircode/netguard/Rule.java b/app/src/main/java/eu/faircode/netguard/Rule.java index f9139075..f19b7dc4 100644 --- a/app/src/main/java/eu/faircode/netguard/Rule.java +++ b/app/src/main/java/eu/faircode/netguard/Rule.java @@ -163,6 +163,12 @@ public class Rule { this.internet = true; this.enabled = true; this.pkg = false; + } else if (info.applicationInfo.uid == 1051) { + this.name = context.getString(R.string.title_dnsdaemon); + this.system = true; + this.internet = true; + this.enabled = true; + this.pkg = false; } else if (info.applicationInfo.uid == 9999) { this.name = context.getString(R.string.title_nobody); this.system = true; @@ -307,6 +313,16 @@ public class Rule { gps.applicationInfo.icon = 0; listPI.add(gps); + // Add DNS daemon + PackageInfo dns = new PackageInfo(); + dns.packageName = "android.dns"; + dns.versionCode = Build.VERSION.SDK_INT; + dns.versionName = Build.VERSION.RELEASE; + dns.applicationInfo = new ApplicationInfo(); + dns.applicationInfo.uid = 1051; + dns.applicationInfo.icon = 0; + listPI.add(dns); + // Add nobody PackageInfo nobody = new PackageInfo(); nobody.packageName = "nobody"; diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index a36e868a..a6e78b97 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -279,6 +279,7 @@ Your internet traffic is not being sent to a remote VPN server. root mediaserver GPS daemon + DNS daemon nobody Don\'t ask again