Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 0469f410 authored by Maggie Benthall's avatar Maggie Benthall
Browse files

CA cert monitoring: add notifications and actions for dialog

In DevicePolicyManagementService, on boot and when certs are installed,
post notification to tell the user that their traffic may be
monitored.
Have QuickSettings use the MonitoringCertInfoActivity instead
of building the dialog itself.

Bug: 10633199

Change-Id: Ie4b97295a9fc25867c87872feccdb17f4bea071d
parent cdd82540
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1372,7 +1372,7 @@ public class DevicePolicyManager {
     *
     * @hide
     */
    public boolean hasAnyCaCertsInstalled() {
    public static boolean hasAnyCaCertsInstalled() {
        TrustedCertificateStore certStore = new TrustedCertificateStore();
        Set<String> aliases = certStore.userAliases();
        return aliases != null && !aliases.isEmpty();
+32 −0
Original line number Diff line number Diff line
@@ -159,6 +159,38 @@ public final class Settings {
    public static final String ACTION_SECURITY_SETTINGS =
            "android.settings.SECURITY_SETTINGS";

    /**
     * Activity Action: Show trusted credentials settings, opening to the user tab,
     * to allow management of installed credentials.
     * <p>
     * In some cases, a matching Activity may not exist, so ensure you
     * safeguard against this.
     * <p>
     * Input: Nothing.
     * <p>
     * Output: Nothing.
     * @hide
     */
    @SdkConstant(SdkConstantType.ACTIVITY_INTENT_ACTION)
    public static final String ACTION_TRUSTED_CREDENTIALS_USER =
            "com.android.settings.TRUSTED_CREDENTIALS_USER";

    /**
     * Activity Action: Show dialog explaining that an installed CA cert may enable
     * monitoring of encrypted network traffic.
     * <p>
     * In some cases, a matching Activity may not exist, so ensure you
     * safeguard against this.
     * <p>
     * Input: Nothing.
     * <p>
     * Output: Nothing.
     * @hide
     */
    @SdkConstant(SdkConstantType.ACTIVITY_INTENT_ACTION)
    public static final String ACTION_MONITORING_CERT_INFO =
            "com.android.settings.MONITORING_CERT_INFO";

    /**
     * Activity Action: Show settings to allow configuration of privacy options.
     * <p>
+1.38 KiB
Loading image diff...
+930 B
Loading image diff...
+1.9 KiB
Loading image diff...
Loading