Android APK JavaScript Enabled Without Clear Cache
Description
Detects Android WebView configurations where JavaScript is enabled together with settings for file or content access.
Detection Strategy
• Reads the bytecode of the classes whose name contains Activity, without decompiling it
• Collects the names that this bytecode uses: the class and its parents, its fields, its methods, and the types, methods, fields and texts that its code refers to. A call with a constant argument counts as a name, such as setJavaScriptEnabled(1)
• Checks if one of these names mentions setJavaScriptEnabled(true) or setJavaScriptEnabled(1), and one mentions setAllowContentAccess, setAllowFileAccess, setAllowFileAccessFromFileURLs or setAllowUniversalAccessFromFileURLs, whatever value they are given
• Reports a vulnerability when both are found
Search for vulnerabilities in your apps for free with Fluid Attacks' automated security testing! Start your 21-day free trial and discover the benefits of the Essential plan. If you prefer the Advanced plan, which includes the expertise of Fluid Attacks' pentesting team, fill out this contact form.