Potentially Intent Spoofing

Description

The application is vulnerable to intent spoofing which could result in the access and exploitation of unauthorized components.

Recommendation

It is recommended to apply proper input validation and parameter filtering on intent action.

Technical details
[TAINT] String 'com.afwsamples.testdpc.INSTALL_COMPLETE' ==>>> Sink '['Landroid/content/Intent;', '<init>', '(Ljava/lang/String;)V', '0', 'IPC_SINK']' [[('Lcom/afwsamples/testdpc/cosu/CosuConfig;', 'onDownloadComplete', '(Ljava/lang/Long;)Ljava/lang/Long;'), ('Lcom/afwsamples/testdpc/cosu/CosuUtils;', 'installPackage', '(Landroid/content/Context; Ljava/io/InputStream; Ljava/lang/String;)Z'), ('Lcom/afwsamples/testdpc/cosu/CosuUtils;', 'createIntentSender', '(Landroid/content/Context; I)Landroid/content/IntentSender;'), ('Landroid/content/Intent;', '<init>', '(Ljava/lang/String;)V')]]

Use of a string value com.afwsamples.testdpc.INSTALL_COMPLETE to construct an Intent

Method com.afwsamples.testdpc.cosu.CosuConfig.onDownloadComplete():


    public Long onDownloadComplete(Long p10)
    {
        java.util.Iterator v2 = this.mDownloadApps.iterator();
        while (v2.hasNext()) {
            com.afwsamples.testdpc.cosu.CosuConfig$DownloadAppInfo v0_1 = ((com.afwsamples.testdpc.cosu.CosuConfig$DownloadAppInfo) v2.next());
            if (p10.equals(v0_1.downloadId)) {
                v0_1.downloadCompleted = 1;
                try {
                    com.afwsamples.testdpc.cosu.CosuUtils.installPackage(this.mContext, new java.io.FileInputStream(this.mDownloadManager.openDownloadedFile(p10.longValue()).getFileDescriptor()), v0_1.packageName);
                } catch (java.io.IOException v1) {
                    android.util.Log.e("CosuSetup", new StringBuilder().append("Error installing package: ").append(v0_1.packageName).toString(), v1);
                    v0_1.installCompleted = 1;
                }
                Long v5_1 = v0_1.downloadId;
            }
            return v5_1;
        }
        android.util.Log.w("CosuSetup", new StringBuilder().append("Unknown download id: ").append(p10).toString());
        v5_1 = 0;
        return v5_1;
    }

Method com.afwsamples.testdpc.cosu.CosuUtils.installPackage():


    public static boolean installPackage(android.content.Context p13, java.io.InputStream p14, String p15)
    {
        android.content.pm.PackageInstaller v9 = p13.getPackageManager().getPackageInstaller();
        android.content.pm.PackageInstaller$SessionParams v10_1 = new android.content.pm.PackageInstaller$SessionParams(1);
        v10_1.setAppPackageName(p15);
        int v11 = v9.createSession(v10_1);
        android.content.pm.PackageInstaller$Session v0 = v9.openSession(v11);
        java.io.OutputStream v8 = v0.openWrite("COSU", 0, -1);
        byte[] v6 = new byte[65536];
        while(true) {
            int v7 = p14.read(v6);
            if (v7 == -1) {
                break;
            }
            v8.write(v6, 0, v7);
        }
        v0.fsync(v8);
        p14.close();
        v8.close();
        v0.commit(com.afwsamples.testdpc.cosu.CosuUtils.createIntentSender(p13, v11));
        return 1;
    }

Method com.afwsamples.testdpc.cosu.CosuUtils.createIntentSender():


    private static android.content.IntentSender createIntentSender(android.content.Context p3, int p4)
    {
        return android.app.PendingIntent.getBroadcast(p3, p4, new android.content.Intent("com.afwsamples.testdpc.INSTALL_COMPLETE"), 0).getIntentSender();
    }

Method android.content.Intent.<init>() not found.

[TAINT] String 'com.afwsamples.testdpc.INSTALL_COMPLETE' ==>>> Sink '['Landroid/content/Intent;', '<init>', '(Ljava/lang/String;)V', '0', 'IPC_SINK']' [[('Lcom/afwsamples/testdpc/cosu/CosuUtils;', 'createIntentSender', '(Landroid/content/Context; I)Landroid/content/IntentSender;'), ('Landroid/content/Intent;', '<init>', '(Ljava/lang/String;)V')]]

Use of a string value com.afwsamples.testdpc.INSTALL_COMPLETE to construct an Intent

Method com.afwsamples.testdpc.cosu.CosuUtils.createIntentSender():


    private static android.content.IntentSender createIntentSender(android.content.Context p3, int p4)
    {
        return android.app.PendingIntent.getBroadcast(p3, p4, new android.content.Intent("com.afwsamples.testdpc.INSTALL_COMPLETE"), 0).getIntentSender();
    }

Method android.content.Intent.<init>() not found.

[TAINT] String 'com.afwsamples.testdpc.INSTALL_COMPLETE' ==>>> Sink '['Landroid/content/Intent;', '<init>', '(Ljava/lang/String;)V', '0', 'IPC_SINK']' [[('Lcom/afwsamples/testdpc/cosu/CosuUtils;', 'installPackage', '(Landroid/content/Context; Ljava/io/InputStream; Ljava/lang/String;)Z'), ('Lcom/afwsamples/testdpc/cosu/CosuUtils;', 'createIntentSender', '(Landroid/content/Context; I)Landroid/content/IntentSender;'), ('Landroid/content/Intent;', '<init>', '(Ljava/lang/String;)V')]]

Use of a string value com.afwsamples.testdpc.INSTALL_COMPLETE to construct an Intent

Method com.afwsamples.testdpc.cosu.CosuUtils.installPackage():


    public static boolean installPackage(android.content.Context p13, java.io.InputStream p14, String p15)
    {
        android.content.pm.PackageInstaller v9 = p13.getPackageManager().getPackageInstaller();
        android.content.pm.PackageInstaller$SessionParams v10_1 = new android.content.pm.PackageInstaller$SessionParams(1);
        v10_1.setAppPackageName(p15);
        int v11 = v9.createSession(v10_1);
        android.content.pm.PackageInstaller$Session v0 = v9.openSession(v11);
        java.io.OutputStream v8 = v0.openWrite("COSU", 0, -1);
        byte[] v6 = new byte[65536];
        while(true) {
            int v7 = p14.read(v6);
            if (v7 == -1) {
                break;
            }
            v8.write(v6, 0, v7);
        }
        v0.fsync(v8);
        p14.close();
        v8.close();
        v0.commit(com.afwsamples.testdpc.cosu.CosuUtils.createIntentSender(p13, v11));
        return 1;
    }

Method com.afwsamples.testdpc.cosu.CosuUtils.createIntentSender():


    private static android.content.IntentSender createIntentSender(android.content.Context p3, int p4)
    {
        return android.app.PendingIntent.getBroadcast(p3, p4, new android.content.Intent("com.afwsamples.testdpc.INSTALL_COMPLETE"), 0).getIntentSender();
    }

Method android.content.Intent.<init>() not found.

[TAINT] String 'com.afwsamples.testdpc.policy.locktask.LOCKED_APP_PACKAGE_LIST' ==>>> Sink '['Landroid/content/Intent;', 'putExtra', '(Ljava/lang/String; [Ljava/lang/String;)Landroid/content/Intent;', '0', 'IPC_SINK']' [[('Lcom/afwsamples/testdpc/cosu/EnableCosuActivity$1;', 'handleMessage', '(Landroid/os/Message;)V'), ('Lcom/afwsamples/testdpc/cosu/EnableCosuActivity;', 'access$300', '(Lcom/afwsamples/testdpc/cosu/EnableCosuActivity;)V'), ('Lcom/afwsamples/testdpc/cosu/EnableCosuActivity;', 'startCosuMode', '()V'), ('Landroid/content/Intent;', 'putExtra', '(Ljava/lang/String; [Ljava/lang/String;)Landroid/content/Intent;')]]

Use of a string value com.afwsamples.testdpc.policy.locktask.LOCKED_APP_PACKAGE_LIST to construct an Intent

Method com.afwsamples.testdpc.cosu.EnableCosuActivity$1.handleMessage():


    public void handleMessage(android.os.Message p8)
    {
        switch (p8.what) {
            case 1:
                if (!com.afwsamples.testdpc.cosu.EnableCosuActivity.access$000(this.this$0).equals(p8.obj)) {
                    Long v0_1 = com.afwsamples.testdpc.cosu.EnableCosuActivity.access$200(this.this$0).onDownloadComplete(((Long) p8.obj));
                    if (v0_1 != null) {
                        this.removeMessages(2, v0_1);
                    }
                    if (!com.afwsamples.testdpc.cosu.EnableCosuActivity.access$200(this.this$0).areAllInstallsFinished()) {
                    } else {
                        com.afwsamples.testdpc.cosu.EnableCosuActivity.access$300(this.this$0);
                    }
                } else {
                    com.afwsamples.testdpc.cosu.EnableCosuActivity.access$100(this.this$0);
                    this.removeMessages(2, com.afwsamples.testdpc.cosu.EnableCosuActivity.access$000(this.this$0));
                }
                break;
            case 2:
                Long v0_0 = ((Long) p8.obj).longValue();
                if (v0_0 != com.afwsamples.testdpc.cosu.EnableCosuActivity.access$000(this.this$0).longValue()) {
                    com.afwsamples.testdpc.cosu.EnableCosuActivity v2_12 = com.afwsamples.testdpc.cosu.EnableCosuActivity.access$400(this.this$0);
                    String v3_0 = new long[1];
                    v3_0[0] = v0_0;
                    v2_12.remove(v3_0);
                    android.util.Log.e("CosuSetup", new StringBuilder().append("Time out during app download with id: ").append(v0_0).toString());
                } else {
                    android.util.Log.e("CosuSetup", "Time out during download of config file");
                    com.afwsamples.testdpc.cosu.EnableCosuActivity v2_17 = com.afwsamples.testdpc.cosu.EnableCosuActivity.access$400(this.this$0);
                    String v3_7 = new long[1];
                    v3_7[0] = com.afwsamples.testdpc.cosu.EnableCosuActivity.access$000(this.this$0).longValue();
                    v2_17.remove(v3_7);
                }
                com.afwsamples.testdpc.cosu.EnableCosuActivity.access$500(this.this$0);
                break;
            case 3:
                com.afwsamples.testdpc.cosu.EnableCosuActivity.access$200(this.this$0).onInstallComplete(((String) p8.obj));
                if (!com.afwsamples.testdpc.cosu.EnableCosuActivity.access$200(this.this$0).areAllInstallsFinished()) {
                } else {
                    com.afwsamples.testdpc.cosu.EnableCosuActivity.access$300(this.this$0);
                }
                break;
        }
        return;
    }

Method com.afwsamples.testdpc.cosu.EnableCosuActivity.access$300():


    static synthetic void access$300(com.afwsamples.testdpc.cosu.EnableCosuActivity p0)
    {
        p0.startCosuMode();
        return;
    }

Method com.afwsamples.testdpc.cosu.EnableCosuActivity.startCosuMode():


    private void startCosuMode()
    {
        android.content.Intent v1_1 = 0;
        String v2 = this.mConfig.getMode();
        String[] v0 = this.mConfig.getKioskApps();
        if (v2 == null) {
            v2 = "default";
        }
        if (!"custom".equals(v2)) {
            if (!"single".equals(v2)) {
                v1_1 = new android.content.Intent("android.intent.action.MAIN");
                v1_1.addCategory("android.intent.category.HOME");
            } else {
                if (v0.length != 0) {
                    v1_1 = this.getPackageManager().getLaunchIntentForPackage(v0[0]);
                }
            }
        } else {
            v1_1 = new android.content.Intent(this, com.afwsamples.testdpc.policy.locktask.KioskModeActivity);
            v1_1.putExtra("com.afwsamples.testdpc.policy.locktask.LOCKED_APP_PACKAGE_LIST", v0);
            this.getPackageManager().setComponentEnabledSetting(new android.content.ComponentName(this.getPackageName(), com.afwsamples.testdpc.policy.locktask.KioskModeActivity.getName()), 1, 1);
        }
        if (v1_1 != null) {
            v1_1.addFlags(268435456);
            this.startActivity(v1_1);
            android.widget.Toast.makeText(this, 2131165455, 1).show();
            this.unregisterReceiver(this.mInstallReceiver);
            this.unregisterReceiver(this.mDownloadReceiver);
            if (this.mHandler.hasMessages(2)) {
                android.util.Log.w("CosuSetup", "Download timeout messages remaining on handler thread.");
                this.mHandler.removeMessages(2);
            }
            this.finish();
        } else {
            android.util.Log.e("CosuSetup", new StringBuilder().append("No launch intent specified. Mode=").append(v2).toString());
            this.finishWithFailure();
        }
        return;
    }

Method android.content.Intent.putExtra() not found.

[TAINT] String 'com.afwsamples.testdpc.policy.locktask.LOCKED_APP_PACKAGE_LIST' ==>>> Sink '['Landroid/content/Intent;', 'putExtra', '(Ljava/lang/String; [Ljava/lang/String;)Landroid/content/Intent;', '0', 'IPC_SINK']' [[('Lcom/afwsamples/testdpc/cosu/EnableCosuActivity;', 'access$100', '(Lcom/afwsamples/testdpc/cosu/EnableCosuActivity;)V'), ('Lcom/afwsamples/testdpc/cosu/EnableCosuActivity;', 'onConfigFileDownloaded', '()V'), ('Lcom/afwsamples/testdpc/cosu/EnableCosuActivity;', 'startCosuMode', '()V'), ('Landroid/content/Intent;', 'putExtra', '(Ljava/lang/String; [Ljava/lang/String;)Landroid/content/Intent;')]]

Use of a string value com.afwsamples.testdpc.policy.locktask.LOCKED_APP_PACKAGE_LIST to construct an Intent

Method com.afwsamples.testdpc.cosu.EnableCosuActivity.access$100():


    static synthetic void access$100(com.afwsamples.testdpc.cosu.EnableCosuActivity p0)
    {
        p0.onConfigFileDownloaded();
        return;
    }

Method com.afwsamples.testdpc.cosu.EnableCosuActivity.onConfigFileDownloaded():


    private void onConfigFileDownloaded()
    {
        this.mStatusText.setText(this.getString(2131165454));
        try {
            this.mConfig = com.afwsamples.testdpc.cosu.CosuConfig.createConfig(this, new java.io.FileInputStream(this.mDownloadManager.openDownloadedFile(this.mConfigDownloadId.longValue()).getFileDescriptor()));
        } catch (java.io.FileNotFoundException v0) {
            android.util.Log.e("CosuSetup", "Download file not found.", v0);
            this.finishWithFailure();
            return;
        }
        if (this.mConfig != null) {
            android.util.Log.d("CosuSetup", "CosuConfig:");
            android.util.Log.d("CosuSetup", this.mConfig.toString());
            this.mConfig.applyPolicies(com.afwsamples.testdpc.DeviceAdminReceiver.getComponentName(this));
            this.mConfig.initiateDownloadAndInstall(this.mHandler);
            this.mStatusText.setText(this.getString(2131165452));
            if (!this.mConfig.areAllInstallsFinished()) {
                return;
            } else {
                this.startCosuMode();
                return;
            }
        } else {
            this.finishWithFailure();
            return;
        }
    }

Method com.afwsamples.testdpc.cosu.EnableCosuActivity.startCosuMode():


    private void startCosuMode()
    {
        android.content.Intent v1_1 = 0;
        String v2 = this.mConfig.getMode();
        String[] v0 = this.mConfig.getKioskApps();
        if (v2 == null) {
            v2 = "default";
        }
        if (!"custom".equals(v2)) {
            if (!"single".equals(v2)) {
                v1_1 = new android.content.Intent("android.intent.action.MAIN");
                v1_1.addCategory("android.intent.category.HOME");
            } else {
                if (v0.length != 0) {
                    v1_1 = this.getPackageManager().getLaunchIntentForPackage(v0[0]);
                }
            }
        } else {
            v1_1 = new android.content.Intent(this, com.afwsamples.testdpc.policy.locktask.KioskModeActivity);
            v1_1.putExtra("com.afwsamples.testdpc.policy.locktask.LOCKED_APP_PACKAGE_LIST", v0);
            this.getPackageManager().setComponentEnabledSetting(new android.content.ComponentName(this.getPackageName(), com.afwsamples.testdpc.policy.locktask.KioskModeActivity.getName()), 1, 1);
        }
        if (v1_1 != null) {
            v1_1.addFlags(268435456);
            this.startActivity(v1_1);
            android.widget.Toast.makeText(this, 2131165455, 1).show();
            this.unregisterReceiver(this.mInstallReceiver);
            this.unregisterReceiver(this.mDownloadReceiver);
            if (this.mHandler.hasMessages(2)) {
                android.util.Log.w("CosuSetup", "Download timeout messages remaining on handler thread.");
                this.mHandler.removeMessages(2);
            }
            this.finish();
        } else {
            android.util.Log.e("CosuSetup", new StringBuilder().append("No launch intent specified. Mode=").append(v2).toString());
            this.finishWithFailure();
        }
        return;
    }

Method android.content.Intent.putExtra() not found.

[TAINT] String 'com.afwsamples.testdpc.policy.locktask.LOCKED_APP_PACKAGE_LIST' ==>>> Sink '['Landroid/content/Intent;', 'putExtra', '(Ljava/lang/String; [Ljava/lang/String;)Landroid/content/Intent;', '0', 'IPC_SINK']' [[('Lcom/afwsamples/testdpc/cosu/EnableCosuActivity;', 'access$300', '(Lcom/afwsamples/testdpc/cosu/EnableCosuActivity;)V'), ('Lcom/afwsamples/testdpc/cosu/EnableCosuActivity;', 'startCosuMode', '()V'), ('Landroid/content/Intent;', 'putExtra', '(Ljava/lang/String; [Ljava/lang/String;)Landroid/content/Intent;')]]

Use of a string value com.afwsamples.testdpc.policy.locktask.LOCKED_APP_PACKAGE_LIST to construct an Intent

Method com.afwsamples.testdpc.cosu.EnableCosuActivity.access$300():


    static synthetic void access$300(com.afwsamples.testdpc.cosu.EnableCosuActivity p0)
    {
        p0.startCosuMode();
        return;
    }

Method com.afwsamples.testdpc.cosu.EnableCosuActivity.startCosuMode():


    private void startCosuMode()
    {
        android.content.Intent v1_1 = 0;
        String v2 = this.mConfig.getMode();
        String[] v0 = this.mConfig.getKioskApps();
        if (v2 == null) {
            v2 = "default";
        }
        if (!"custom".equals(v2)) {
            if (!"single".equals(v2)) {
                v1_1 = new android.content.Intent("android.intent.action.MAIN");
                v1_1.addCategory("android.intent.category.HOME");
            } else {
                if (v0.length != 0) {
                    v1_1 = this.getPackageManager().getLaunchIntentForPackage(v0[0]);
                }
            }
        } else {
            v1_1 = new android.content.Intent(this, com.afwsamples.testdpc.policy.locktask.KioskModeActivity);
            v1_1.putExtra("com.afwsamples.testdpc.policy.locktask.LOCKED_APP_PACKAGE_LIST", v0);
            this.getPackageManager().setComponentEnabledSetting(new android.content.ComponentName(this.getPackageName(), com.afwsamples.testdpc.policy.locktask.KioskModeActivity.getName()), 1, 1);
        }
        if (v1_1 != null) {
            v1_1.addFlags(268435456);
            this.startActivity(v1_1);
            android.widget.Toast.makeText(this, 2131165455, 1).show();
            this.unregisterReceiver(this.mInstallReceiver);
            this.unregisterReceiver(this.mDownloadReceiver);
            if (this.mHandler.hasMessages(2)) {
                android.util.Log.w("CosuSetup", "Download timeout messages remaining on handler thread.");
                this.mHandler.removeMessages(2);
            }
            this.finish();
        } else {
            android.util.Log.e("CosuSetup", new StringBuilder().append("No launch intent specified. Mode=").append(v2).toString());
            this.finishWithFailure();
        }
        return;
    }

Method android.content.Intent.putExtra() not found.

[TAINT] String 'com.afwsamples.testdpc.policy.locktask.LOCKED_APP_PACKAGE_LIST' ==>>> Sink '['Landroid/content/Intent;', 'putExtra', '(Ljava/lang/String; [Ljava/lang/String;)Landroid/content/Intent;', '0', 'IPC_SINK']' [[('Lcom/afwsamples/testdpc/cosu/EnableCosuActivity;', 'onConfigFileDownloaded', '()V'), ('Lcom/afwsamples/testdpc/cosu/EnableCosuActivity;', 'startCosuMode', '()V'), ('Landroid/content/Intent;', 'putExtra', '(Ljava/lang/String; [Ljava/lang/String;)Landroid/content/Intent;')]]

Use of a string value com.afwsamples.testdpc.policy.locktask.LOCKED_APP_PACKAGE_LIST to construct an Intent

Method com.afwsamples.testdpc.cosu.EnableCosuActivity.onConfigFileDownloaded():


    private void onConfigFileDownloaded()
    {
        this.mStatusText.setText(this.getString(2131165454));
        try {
            this.mConfig = com.afwsamples.testdpc.cosu.CosuConfig.createConfig(this, new java.io.FileInputStream(this.mDownloadManager.openDownloadedFile(this.mConfigDownloadId.longValue()).getFileDescriptor()));
        } catch (java.io.FileNotFoundException v0) {
            android.util.Log.e("CosuSetup", "Download file not found.", v0);
            this.finishWithFailure();
            return;
        }
        if (this.mConfig != null) {
            android.util.Log.d("CosuSetup", "CosuConfig:");
            android.util.Log.d("CosuSetup", this.mConfig.toString());
            this.mConfig.applyPolicies(com.afwsamples.testdpc.DeviceAdminReceiver.getComponentName(this));
            this.mConfig.initiateDownloadAndInstall(this.mHandler);
            this.mStatusText.setText(this.getString(2131165452));
            if (!this.mConfig.areAllInstallsFinished()) {
                return;
            } else {
                this.startCosuMode();
                return;
            }
        } else {
            this.finishWithFailure();
            return;
        }
    }

Method com.afwsamples.testdpc.cosu.EnableCosuActivity.startCosuMode():


    private void startCosuMode()
    {
        android.content.Intent v1_1 = 0;
        String v2 = this.mConfig.getMode();
        String[] v0 = this.mConfig.getKioskApps();
        if (v2 == null) {
            v2 = "default";
        }
        if (!"custom".equals(v2)) {
            if (!"single".equals(v2)) {
                v1_1 = new android.content.Intent("android.intent.action.MAIN");
                v1_1.addCategory("android.intent.category.HOME");
            } else {
                if (v0.length != 0) {
                    v1_1 = this.getPackageManager().getLaunchIntentForPackage(v0[0]);
                }
            }
        } else {
            v1_1 = new android.content.Intent(this, com.afwsamples.testdpc.policy.locktask.KioskModeActivity);
            v1_1.putExtra("com.afwsamples.testdpc.policy.locktask.LOCKED_APP_PACKAGE_LIST", v0);
            this.getPackageManager().setComponentEnabledSetting(new android.content.ComponentName(this.getPackageName(), com.afwsamples.testdpc.policy.locktask.KioskModeActivity.getName()), 1, 1);
        }
        if (v1_1 != null) {
            v1_1.addFlags(268435456);
            this.startActivity(v1_1);
            android.widget.Toast.makeText(this, 2131165455, 1).show();
            this.unregisterReceiver(this.mInstallReceiver);
            this.unregisterReceiver(this.mDownloadReceiver);
            if (this.mHandler.hasMessages(2)) {
                android.util.Log.w("CosuSetup", "Download timeout messages remaining on handler thread.");
                this.mHandler.removeMessages(2);
            }
            this.finish();
        } else {
            android.util.Log.e("CosuSetup", new StringBuilder().append("No launch intent specified. Mode=").append(v2).toString());
            this.finishWithFailure();
        }
        return;
    }

Method android.content.Intent.putExtra() not found.

[TAINT] String 'com.afwsamples.testdpc.policy.locktask.LOCKED_APP_PACKAGE_LIST' ==>>> Sink '['Landroid/content/Intent;', 'putExtra', '(Ljava/lang/String; [Ljava/lang/String;)Landroid/content/Intent;', '0', 'IPC_SINK']' [[('Lcom/afwsamples/testdpc/cosu/EnableCosuActivity;', 'startCosuMode', '()V'), ('Landroid/content/Intent;', 'putExtra', '(Ljava/lang/String; [Ljava/lang/String;)Landroid/content/Intent;')]]

Use of a string value com.afwsamples.testdpc.policy.locktask.LOCKED_APP_PACKAGE_LIST to construct an Intent

Method com.afwsamples.testdpc.cosu.EnableCosuActivity.startCosuMode():


    private void startCosuMode()
    {
        android.content.Intent v1_1 = 0;
        String v2 = this.mConfig.getMode();
        String[] v0 = this.mConfig.getKioskApps();
        if (v2 == null) {
            v2 = "default";
        }
        if (!"custom".equals(v2)) {
            if (!"single".equals(v2)) {
                v1_1 = new android.content.Intent("android.intent.action.MAIN");
                v1_1.addCategory("android.intent.category.HOME");
            } else {
                if (v0.length != 0) {
                    v1_1 = this.getPackageManager().getLaunchIntentForPackage(v0[0]);
                }
            }
        } else {
            v1_1 = new android.content.Intent(this, com.afwsamples.testdpc.policy.locktask.KioskModeActivity);
            v1_1.putExtra("com.afwsamples.testdpc.policy.locktask.LOCKED_APP_PACKAGE_LIST", v0);
            this.getPackageManager().setComponentEnabledSetting(new android.content.ComponentName(this.getPackageName(), com.afwsamples.testdpc.policy.locktask.KioskModeActivity.getName()), 1, 1);
        }
        if (v1_1 != null) {
            v1_1.addFlags(268435456);
            this.startActivity(v1_1);
            android.widget.Toast.makeText(this, 2131165455, 1).show();
            this.unregisterReceiver(this.mInstallReceiver);
            this.unregisterReceiver(this.mDownloadReceiver);
            if (this.mHandler.hasMessages(2)) {
                android.util.Log.w("CosuSetup", "Download timeout messages remaining on handler thread.");
                this.mHandler.removeMessages(2);
            }
            this.finish();
        } else {
            android.util.Log.e("CosuSetup", new StringBuilder().append("No launch intent specified. Mode=").append(v2).toString());
            this.finishWithFailure();
        }
        return;
    }

Method android.content.Intent.putExtra() not found.

[TAINT] String 'com.afwsamples.testdpc.policy.locktask.LOCKED_APP_PACKAGE_LIST' ==>>> Sink '['Landroid/content/Intent;', 'putExtra', '(Ljava/lang/String; [Ljava/lang/String;)Landroid/content/Intent;', '0', 'IPC_SINK']' [[('Lcom/afwsamples/testdpc/policy/PolicyManagementFragment;', 'access$100', '(Lcom/afwsamples/testdpc/policy/PolicyManagementFragment; [Ljava/lang/String;)V'), ('Lcom/afwsamples/testdpc/policy/PolicyManagementFragment;', 'startKioskMode', '([Ljava/lang/String;)V'), ('Landroid/content/Intent;', 'putExtra', '(Ljava/lang/String; [Ljava/lang/String;)Landroid/content/Intent;')]]

Use of a string value com.afwsamples.testdpc.policy.locktask.LOCKED_APP_PACKAGE_LIST to construct an Intent

Method com.afwsamples.testdpc.policy.PolicyManagementFragment.access$100():


    static synthetic void access$100(com.afwsamples.testdpc.policy.PolicyManagementFragment p0, String[] p1)
    {
        p0.startKioskMode(p1);
        return;
    }

Method com.afwsamples.testdpc.policy.PolicyManagementFragment.startKioskMode():


    private void startKioskMode(String[] p7)
    {
        android.content.Intent v0_1 = new android.content.Intent(this.getActivity(), com.afwsamples.testdpc.policy.locktask.KioskModeActivity);
        v0_1.putExtra("com.afwsamples.testdpc.policy.locktask.LOCKED_APP_PACKAGE_LIST", p7);
        v0_1.addFlags(268435456);
        this.mPackageManager.setComponentEnabledSetting(new android.content.ComponentName(this.mPackageName, com.afwsamples.testdpc.policy.locktask.KioskModeActivity.getName()), 1, 1);
        this.startActivity(v0_1);
        this.getActivity().finish();
        return;
    }

Method android.content.Intent.putExtra() not found.

[TAINT] String 'com.afwsamples.testdpc.policy.locktask.LOCKED_APP_PACKAGE_LIST' ==>>> Sink '['Landroid/content/Intent;', 'putExtra', '(Ljava/lang/String; [Ljava/lang/String;)Landroid/content/Intent;', '0', 'IPC_SINK']' [[('Lcom/afwsamples/testdpc/policy/PolicyManagementFragment;', 'startKioskMode', '([Ljava/lang/String;)V'), ('Landroid/content/Intent;', 'putExtra', '(Ljava/lang/String; [Ljava/lang/String;)Landroid/content/Intent;')]]

Use of a string value com.afwsamples.testdpc.policy.locktask.LOCKED_APP_PACKAGE_LIST to construct an Intent

Method com.afwsamples.testdpc.policy.PolicyManagementFragment.startKioskMode():


    private void startKioskMode(String[] p7)
    {
        android.content.Intent v0_1 = new android.content.Intent(this.getActivity(), com.afwsamples.testdpc.policy.locktask.KioskModeActivity);
        v0_1.putExtra("com.afwsamples.testdpc.policy.locktask.LOCKED_APP_PACKAGE_LIST", p7);
        v0_1.addFlags(268435456);
        this.mPackageManager.setComponentEnabledSetting(new android.content.ComponentName(this.mPackageName, com.afwsamples.testdpc.policy.locktask.KioskModeActivity.getName()), 1, 1);
        this.startActivity(v0_1);
        this.getActivity().finish();
        return;
    }

Method android.content.Intent.putExtra() not found.