File tree Expand file tree Collapse file tree 12 files changed +40
-19
lines changed
ICC_Explicit_NoSrc_NoSink/src/com/ksu/explicit_nosrc_nosink
ICC_Explicit_NoSrc_Sink/src/com/ksu/explicit_nosrc_sink
ICC_Explicit_Src_NoSink/src/com/ksu/explicit_src_nosink
ICC_Explicit_Src_Sink/src/com/ksu/explicit_src_sink
ICC_Implicit_NoSrc_NoSink/src/com/ksu/implicit_nosrc_nosink
ICC_Implicit_NoSrc_Sink/src/com/ksu/implicit_nosrc_sink
ICC_Implicit_Src_NoSink/src/com/ksu/implicit_src_nosink
ICC_Implicit_Src_Sink/src/com/ksu/implicit_src_sink
InterComponentCommunication_DynRegister2/src/com/ksu/dynamicregister2
InterComponentCommunication_Implicit6/src/com/ksu/implicit6 Expand file tree Collapse file tree 12 files changed +40
-19
lines changed Original file line number Diff line number Diff line change 77import android .content .Intent ;
88
99/**
10- * @testcase_name ICC_Explicit1_NoSrc_NoSink
10+ * @testcase_name ICC_Explicit_NoSrc_NoSink
1111 * @author Fengguo Wei & Sankardas Roy
1212 * @author_mail fgwei@ksu.edu & sroy@ksu.edu
1313 *
Original file line number Diff line number Diff line change 77import android .content .Intent ;
88
99/**
10- * @testcase_name InterComponentCommunication_Explicit1
10+ * @testcase_name ICC_Explicit_NoSrc_Sink
1111 * @author Fengguo Wei & Sankardas Roy
1212 * @author_mail fgwei@ksu.edu & sroy@ksu.edu
1313 *
Original file line number Diff line number Diff line change 88import android .content .Intent ;
99
1010/**
11- * @testcase_name InterComponentCommunication_Explicit1
11+ * @testcase_name ICC_Explicit_Src_NoSink
1212 * @author Fengguo Wei & Sankardas Roy
1313 * @author_mail fgwei@ksu.edu & sroy@ksu.edu
1414 *
Original file line number Diff line number Diff line change 88import android .content .Intent ;
99
1010/**
11- * @testcase_name InterComponentCommunication_Explicit1
11+ * @testcase_name ICC_Explicit_Src_Sink
1212 * @author Fengguo Wei & Sankardas Roy
1313 * @author_mail fgwei@ksu.edu & sroy@ksu.edu
1414 *
Original file line number Diff line number Diff line change 88import android .view .Menu ;
99
1010/**
11- * @testcase_name InterComponentCommunication_Implicit1
11+ * @testcase_name ICC_Implicit_NoSrc_NoSink
1212 * @author Fengguo Wei & Sankardas Roy
1313 * @author_mail fgwei@ksu.edu & sroy@ksu.edu
1414 *
Original file line number Diff line number Diff line change 88import android .view .Menu ;
99
1010/**
11- * @testcase_name InterComponentCommunication_Implicit1
11+ * @testcase_name ICC_Implicit_NoSrc_Sink
1212 * @author Fengguo Wei & Sankardas Roy
1313 * @author_mail fgwei@ksu.edu & sroy@ksu.edu
1414 *
1515 * @description Insensitive value v is sent to component FooActivity via implicit ICC.
1616 * In FooActivity, it will retrieve value v and leak it.
17- * @dataflow source -> imei -> MainActivity's intent -> sink (implicit ICC)
18- * source -> imei -> MainActivity's intent -> FooActivity's intent -> imei -> sink
17+ * @dataflow v -> MainActivity's intent -> _
1918 * @number_of_leaks 0
2019 * @challenges The analysis must be able to resolve implicit (Action) ICC calls and handle data flow
2120 * via different components.
Original file line number Diff line number Diff line change 99import android .view .Menu ;
1010
1111/**
12- * @testcase_name InterComponentCommunication_Implicit1
12+ * @testcase_name ICC_Implicit_Src_NoSink
1313 * @author Fengguo Wei & Sankardas Roy
1414 * @author_mail fgwei@ksu.edu & sroy@ksu.edu
1515 *
1616 * @description The value v of a source is sent to component FooActivity via implicit ICC.
1717 * In FooActivity, it will retrieve value v but not leak it.
1818 * @dataflow source -> imei -> MainActivity's intent -> sink (implicit ICC)
19- * source -> imei -> MainActivity's intent -> FooActivity's intent -> imei -> sink
2019 * @number_of_leaks 1
2120 * @challenges The analysis must be able to resolve implicit (Action) ICC calls and handle data flow
2221 * via different components.
Original file line number Diff line number Diff line change 99import android .view .Menu ;
1010
1111/**
12- * @testcase_name InterComponentCommunication_Implicit1
12+ * @testcase_name ICC_Implicit_Src_Sink
1313 * @author Fengguo Wei & Sankardas Roy
1414 * @author_mail fgwei@ksu.edu & sroy@ksu.edu
1515 *
Original file line number Diff line number Diff line change 99import android .view .Menu ;
1010
1111/**
12- * @testcase_name InterComponentCommunication_DynRegister1
12+ * @testcase_name InterComponentCommunication_DynRegister2
1313 * @author Fengguo Wei & Sankardas Roy
1414 * @author_mail fgwei@ksu.edu & sroy@ksu.edu
1515 *
@@ -27,14 +27,15 @@ public class MainActivity extends Activity {
2727 @ Override
2828 protected void onCreate (Bundle savedInstanceState ) {
2929 super .onCreate (savedInstanceState );
30- setContentView (R .layout .activity_main );
30+ setContentView (R .layout .activity_main );
31+ registerReceiver (new MyReceiver (), new IntentFilter ("com.ksu" ));
32+ registerReceiver (new MyReceiver2 (), new IntentFilter ("com.ksu2" ));
33+ TelephonyManager tm = (TelephonyManager ) getSystemService (Context .TELEPHONY_SERVICE );
34+ String id = tm .getDeviceId (); //source
3135 StringBuilder sb = new StringBuilder ();
3236 sb .append ("com." );
3337 sb .append ("ksu" );
34- registerReceiver (new MyReceiver (), new IntentFilter (sb .toString ()));
35- TelephonyManager tm = (TelephonyManager ) getSystemService (Context .TELEPHONY_SERVICE );
36- String id = tm .getDeviceId (); //source
37- Intent i = new Intent ("com.ksu" );
38+ Intent i = new Intent (sb .toString ());
3839 i .putExtra ("id" , id );
3940 sendBroadcast (i ); //leak
4041 }
Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ public class MyReceiver extends BroadcastReceiver
1010
1111 @ Override
1212 public void onReceive (Context arg0 , Intent arg1 ) {
13- Log .d ("Id " , arg1 .getStringExtra ("id" )); //sink
13+ Log .d ("leak " , arg1 .getStringExtra ("id" )); //sink
1414 }
1515
1616}
You can’t perform that action at this time.
0 commit comments