I suspected that additional information might be included in the intent used to launch the app. Through debugging, I discovered that a bundle named activity_options
is passed as this additional information.
While investigating the values in this bundle, I found that the key android:activity.packageName
contains the value com.samsung.knox.securefolder
.
// Activity
val packageName = intent.getBundleExtra("activity_options")
?.getString("android:activity.packageName", "empty")
?: "empty"
![image](https://private-user-images.githubusercontent.com/7759511/298175528-41ad2ed3-9ff4-42d7-90bf-1a3e310336db.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MTkwMTIzMTMsIm5iZiI6MTcxOTAxMjAxMywicGF0aCI6Ii83NzU5NTExLzI5ODE3NTUyOC00MWFkMmVkMy05ZmY0LTQyZDctOTBiZi0xYTNlMzEwMzM2ZGIucG5nP1gtQW16LUFsZ29yaXRobT1BV1M0LUhNQUMtU0hBMjU2JlgtQW16LUNyZWRlbnRpYWw9QUtJQVZDT0RZTFNBNTNQUUs0WkElMkYyMDI0MDYyMSUyRnVzLWVhc3QtMSUyRnMzJTJGYXdzNF9yZXF1ZXN0JlgtQW16LURhdGU9MjAyNDA2MjFUMjMyMDEzWiZYLUFtei1FeHBpcmVzPTMwMCZYLUFtei1TaWduYXR1cmU9MDY5M2Y3YWZlMGM5ODZlODFkYjFlNTg0MmQ4ZTQ0Y2FkM2M0ZDlmZDc1ZDI3NDNhMjg3NjkxZDE5N2EyZWFkOSZYLUFtei1TaWduZWRIZWFkZXJzPWhvc3QmYWN0b3JfaWQ9MCZrZXlfaWQ9MCZyZXBvX2lkPTAifQ.d1iKRf8RbEkIV5fJ7_ZNzwDbo49Tqoj2Il1652aT35w)
android:activity.packageName
is defined in the ActivityOptions.java
file under the name KEY_PACKAGE_NAME
. As indicated in the description, the value for this key represents the package that created these options, which allows us to understand that the app was launched from Secure Folder
.
Default | Secure Folder |
---|---|
![]() |
![]() |
This is a fact discovered through reverse engineering, and it may not function correctly following future updates to `Secure Folder.