File tree Expand file tree Collapse file tree 2 files changed +18
-8
lines changed
java/ql/test/query-tests/security/CWE-094 Expand file tree Collapse file tree 2 files changed +18
-8
lines changed Original file line number Diff line number Diff line change 11edges
22nodes
3- | APKInstallation.java:13:31:13:58 | fromFile(...) | semmle.label | fromFile(...) |
4- | APKInstallation.java:20:31:20:44 | parse(...) | semmle.label | parse(...) |
5- | APKInstallation.java:28:24:28:38 | parse(...) | semmle.label | parse(...) |
6- | APKInstallation.java:35:24:35:51 | fromFile(...) | semmle.label | fromFile(...) |
3+ | APKInstallation.java:14:31:14:58 | fromFile(...) | semmle.label | fromFile(...) |
4+ | APKInstallation.java:21:31:21:44 | parse(...) | semmle.label | parse(...) |
5+ | APKInstallation.java:29:24:29:38 | parse(...) | semmle.label | parse(...) |
6+ | APKInstallation.java:36:24:36:51 | fromFile(...) | semmle.label | fromFile(...) |
7+ | APKInstallation.java:43:31:43:48 | fromFile(...) | semmle.label | fromFile(...) |
78subpaths
89#select
9- | APKInstallation.java:13:31:13:58 | fromFile(...) | APKInstallation.java:13:31:13:58 | fromFile(...) | APKInstallation.java:13:31:13:58 | fromFile(...) | Arbitrary Android APK installation. |
10- | APKInstallation.java:20:31:20:44 | parse(...) | APKInstallation.java:20:31:20:44 | parse(...) | APKInstallation.java:20:31:20:44 | parse(...) | Arbitrary Android APK installation. |
11- | APKInstallation.java:28:24:28:38 | parse(...) | APKInstallation.java:28:24:28:38 | parse(...) | APKInstallation.java:28:24:28:38 | parse(...) | Arbitrary Android APK installation. |
12- | APKInstallation.java:35:24:35:51 | fromFile(...) | APKInstallation.java:35:24:35:51 | fromFile(...) | APKInstallation.java:35:24:35:51 | fromFile(...) | Arbitrary Android APK installation. |
10+ | APKInstallation.java:14:31:14:58 | fromFile(...) | APKInstallation.java:14:31:14:58 | fromFile(...) | APKInstallation.java:14:31:14:58 | fromFile(...) | Arbitrary Android APK installation. |
11+ | APKInstallation.java:21:31:21:44 | parse(...) | APKInstallation.java:21:31:21:44 | parse(...) | APKInstallation.java:21:31:21:44 | parse(...) | Arbitrary Android APK installation. |
12+ | APKInstallation.java:29:24:29:38 | parse(...) | APKInstallation.java:29:24:29:38 | parse(...) | APKInstallation.java:29:24:29:38 | parse(...) | Arbitrary Android APK installation. |
13+ | APKInstallation.java:36:24:36:51 | fromFile(...) | APKInstallation.java:36:24:36:51 | fromFile(...) | APKInstallation.java:36:24:36:51 | fromFile(...) | Arbitrary Android APK installation. |
14+ | APKInstallation.java:43:31:43:48 | fromFile(...) | APKInstallation.java:43:31:43:48 | fromFile(...) | APKInstallation.java:43:31:43:48 | fromFile(...) | Arbitrary Android APK installation. |
Original file line number Diff line number Diff line change 11import android .app .Activity ;
22import android .content .Intent ;
33import android .net .Uri ;
4+ import android .os .Environment ;
45
56import java .io .File ;
67
@@ -35,4 +36,11 @@ public void installAPK3(String path) {
3536 intent .setData (Uri .fromFile (new File (path )));
3637 startActivity (intent );
3738 }
39+
40+ public void installAPK4 (String path ) {
41+ File file = new File (Environment .getExternalStorageDirectory (), path );
42+ Intent intent = new Intent (Intent .ACTION_VIEW );
43+ intent .setDataAndType (Uri .fromFile (file ), APK_MIMETYPE );
44+ startActivity (intent );
45+ }
3846}
You can’t perform that action at this time.
0 commit comments