Skip to content

Commit

Permalink
Add /data/data detections & Change some colors
Browse files Browse the repository at this point in the history
  • Loading branch information
Dr-TSNG committed May 12, 2021
1 parent 1cb34c9 commit b5988c5
Show file tree
Hide file tree
Showing 8 changed files with 30 additions and 20 deletions.
4 changes: 2 additions & 2 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ android {
applicationId "com.tsng.hidemyapplist"
minSdkVersion 24
targetSdkVersion 30
versionCode 25
versionName "1.5.4"
versionCode 26
versionName "1.5.4.1"
buildConfigField "int", "SERVICE_VERSION", "25"
}

Expand Down
4 changes: 2 additions & 2 deletions app/src/main/java/com/tsng/hidemyapplist/MainActivity.kt
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,11 @@ class MainActivity : AppCompatActivity(), View.OnClickListener {
val serviceVersion = XposedUtils.getServiceVersion(this)
if (isModuleActivated()) {
if (serviceVersion != 0) {
xposed_status.setCardBackgroundColor(getColor(R.color.teal))
xposed_status.setCardBackgroundColor(getColor(R.color.colorPrimary))
xposed_status_icon.setImageDrawable(getDrawable(R.drawable.ic_activited))
xposed_status_text.text = getString(R.string.xposed_activated)
} else {
xposed_status.setCardBackgroundColor(getColor(R.color.info))
xposed_status.setCardBackgroundColor(getColor(R.color.error))
xposed_status_icon.setImageDrawable(getDrawable(R.drawable.ic_service_not_running))
xposed_status_text.text = getString(R.string.xposed_activated)
}
Expand Down
19 changes: 11 additions & 8 deletions app/src/main/java/com/tsng/hidemyapplist/ui/DetectionActivity.java
Original file line number Diff line number Diff line change
Expand Up @@ -264,14 +264,17 @@ private void method_getPackageUid() {

private void method_file() {
for (String pkg : targets) {
final String path = "/storage/emulated/0/Android/data/" + pkg;
int[] nativeResult = nativeFile(path);
methodStatus[3][M3.get("java File")] |= new File(path).exists() ? 1 : 0;
methodStatus[3][M3.get("libc access")] |= nativeResult[0];
methodStatus[3][M3.get("libc stat")] |= nativeResult[1];
methodStatus[3][M3.get("libc fstat")] |= nativeResult[2];
methodStatus[3][M3.get("syscall stat")] |= nativeResult[3];
methodStatus[3][M3.get("syscall fstat")] |= nativeResult[4];
final String path1 = "/storage/emulated/0/Android/data/" + pkg;
final String path2 = "/data/data/" + pkg;
int[] nativeResult1 = nativeFile(path1);
int[] nativeResult2 = nativeFile(path2);
methodStatus[3][M3.get("java File")] |= new File(path1).exists() ? 1 : 0;
methodStatus[3][M3.get("java File")] |= new File(path2).exists() ? 1 : 0;
methodStatus[3][M3.get("libc access")] |= nativeResult1[0] | nativeResult2[0];
methodStatus[3][M3.get("libc stat")] |= nativeResult1[1] | nativeResult2[1];
methodStatus[3][M3.get("libc fstat")] |= nativeResult1[2] | nativeResult2[2];
methodStatus[3][M3.get("syscall stat")] |= nativeResult1[3] | nativeResult2[3];
methodStatus[3][M3.get("syscall fstat")] |= nativeResult1[4] | nativeResult2[4];
}
}

Expand Down
8 changes: 3 additions & 5 deletions app/src/main/res/values/colors.xml
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color name="gray">#607D8B</color>
<color name="info">#0277BD</color>
<color name="error">#FF1744</color>
<color name="teal">#009688</color>
<color name="colorPrimary">#3F51B5</color>
<color name="colorPrimaryDark">#303F9F</color>
<color name="error">#666600</color>
<color name="colorPrimary">#336699</color>
<color name="colorPrimaryDark">#154A74</color>
</resources>
2 changes: 1 addition & 1 deletion app/src/main/res/values/themes.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
</style>

<style name="AppTheme.About" parent="Theme.MaterialComponents.DayNight.NoActionBar">
<item name="colorPrimary">@color/colorPrimary</item>
<item name="colorPrimary">@color/colorPrimaryDark</item>
<item name="colorPrimaryDark">@color/colorPrimaryDark</item>
</style>

Expand Down
3 changes: 3 additions & 0 deletions updates/beta-en.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
<b>V1.5.4.1</b>
<p>Add /data/data/packagename detections</p>
<p>Change some colors</p>
3 changes: 3 additions & 0 deletions updates/beta-zh.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
<b>V1.5.4.1</b>
<p>加入/data/data/packagename检测</p>
<p>修改一些配色</p>
7 changes: 5 additions & 2 deletions updates/latest_version.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
{
"Stable": {
"VersionCode": "25",
"VersionCode": 25,
"VersionName": "V1.5.4"
},
"Beta": false
"Beta": {
"VersionCode": 26,
"VersionName": "V1.5.4.1"
}
}

0 comments on commit b5988c5

Please sign in to comment.