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

Commit f3797c4c authored by Mohammed Althaf T's avatar Mohammed Althaf T 😊
Browse files

Merge branch 'lineage-20.0' into 'v2.4-t'

Lineage security patches sept 2024

See merge request e/os/android_frameworks_base!223
parents fbec5785 60d7470e
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -1388,7 +1388,11 @@ public abstract class Uri implements Parcelable, Comparable<Uri> {
         * @param scheme name or {@code null} if this is a relative Uri
         */
        public Builder scheme(String scheme) {
            this.scheme = scheme;
            if (scheme != null) {
                this.scheme = scheme.replace("://", "");
            } else {
                this.scheme = null;
            }
            return this;
        }

+11 −0
Original line number Diff line number Diff line
@@ -18,6 +18,7 @@ package android.net;

import android.content.ContentUris;
import android.os.Parcel;
import android.platform.test.annotations.AsbSecurityTest;

import androidx.test.filters.SmallTest;

@@ -88,6 +89,16 @@ public class UriTest extends TestCase {
        assertNull(u.getHost());
    }

    @AsbSecurityTest(cveBugId = 261721900)
    @SmallTest
    public void testSchemeSanitization() {
        Uri uri = new Uri.Builder()
                .scheme("http://https://evil.com:/te:st/")
                .authority("google.com").path("one/way").build();
        assertEquals("httphttpsevil.com:/te:st/", uri.getScheme());
        assertEquals("httphttpsevil.com:/te:st/://google.com/one/way", uri.toString());
    }

    @SmallTest
    public void testStringUri() {
        assertEquals("bob lee",
+22 −0
Original line number Diff line number Diff line
@@ -18,8 +18,10 @@ package android.security;

import android.annotation.NonNull;
import android.annotation.Nullable;
import android.os.RemoteException;
import android.os.ServiceManager;
import android.os.ServiceSpecificException;
import android.os.StrictMode;
import android.security.maintenance.IKeystoreMaintenance;
import android.system.keystore2.Domain;
import android.system.keystore2.KeyDescriptor;
@@ -183,4 +185,24 @@ public class AndroidKeyStoreMaintenance {
            return SYSTEM_ERROR;
        }
    }

    /**
    * Deletes all keys in all KeyMint devices.
    * Called by RecoverySystem before rebooting to recovery in order to delete all KeyMint keys,
    * including synthetic password protector keys (used by LockSettingsService), as well as keys
    * protecting DE and metadata encryption keys (used by vold). This ensures that FBE-encrypted
    * data is unrecoverable even if the data wipe in recovery is interrupted or skipped.
    */
    public static void deleteAllKeys() throws KeyStoreException {
        StrictMode.noteDiskWrite();
        try {
            getService().deleteAllKeys();
        } catch (RemoteException | NullPointerException e) {
            throw new KeyStoreException(SYSTEM_ERROR,
                    "Failure to connect to Keystore while trying to delete all keys.");
        } catch (ServiceSpecificException e) {
            throw new KeyStoreException(e.errorCode,
                    "Keystore error while trying to delete all keys.");
        }
    }
}
+1 −0
Original line number Diff line number Diff line
@@ -67,6 +67,7 @@
    <string name="vpn_credentials_dialog_connect">Cysylltu</string>
    <string name="accessibility_dpad_left">Pwyntydd chwith</string>
    <string name="accessibility_dpad_right">Pwyntydd de</string>
    <string name="status_bar_firewall">Mur gwarchod</string>
    <string name="screenshot_delete_label">Dileu</string>
    <string name="screenshot_delete_description">Dileu sgrinlun</string>
</resources>
+11 −3
Original line number Diff line number Diff line
@@ -18,17 +18,22 @@
 */
-->
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
    <string name="status_bar_icons_title">Iconos de la barra de estado</string>
    <string name="clock">Reloj</string>
    <string name="global_action_restart_more">Reiniciar\u2026</string>
    <string name="global_action_restart_system">Sistema</string>
    <string name="global_action_restart_recovery">Recuperación</string>
    <string name="global_action_restart_bootloader">Gestor de arranque</string>
    <string name="global_action_restart_download">Descargar</string>
    <string name="global_action_restart_fastboot">Fastbootd</string>
    <string name="global_action_restart_fastboot">FastbootD</string>
    <string name="global_action_restart_progress">Reiniciando\u2026</string>
    <string name="global_action_restart_recovery_progress">Reiniciando en modo recuperación\u2026</string>
    <string name="global_action_restart_bootloader_progress">Reiniciando en gestor de arranque\u2026</string>
    <string name="global_action_restart_download_progress">Reiniciando en modo descarga\u2026</string>
    <string name="global_action_restart_fastboot_progress">Reiniciando en modo fastbootd\u2026</string>
    <string name="global_action_restart_fastboot_progress">Reiniciando en modo fastbootD\u2026</string>
    <string name="global_action_current_user">Actual</string>
    <string name="global_action_users">Usuarios</string>
    <string name="drag_or_tap_to_add_tiles">Mantén pulsado &amp; arrastra o toca para añadir mosaicos</string>
    <string name="quick_settings_ambient_display_label">Pantalla ambiente</string>
    <string name="accessibility_quick_settings_ambient_display_off">Pantalla ambiente desactivada.</string>
    <string name="accessibility_quick_settings_ambient_display_on">Pantalla ambiente activada.</string>
@@ -56,10 +61,13 @@
    <string name="quick_settings_usb_tether_label">Anclaje de red por USB</string>
    <string name="quick_settings_vpn_label">VPN</string>
    <string name="quick_settings_vpn_connect_dialog_title">Conectar a\u2026</string>
    <string name="vpn_credentials_hint">Por favor, ingrese sus credenciales para conectarse a <xliff:g id="name">%s</xliff:g></string>
    <string name="vpn_credentials_hint">Por favor, ingresa tus credenciales para conectarte a <xliff:g id="name">%s</xliff:g></string>
    <string name="vpn_credentials_username">Nombre de usuario</string>
    <string name="vpn_credentials_password">Contraseña</string>
    <string name="vpn_credentials_dialog_connect">Conectar</string>
    <string name="accessibility_dpad_left">Cursor izquierdo</string>
    <string name="accessibility_dpad_right">Cursor derecho</string>
    <string name="status_bar_firewall">Cortafuegos</string>
    <string name="screenshot_delete_label">Eliminar</string>
    <string name="screenshot_delete_description">Eliminar captura de pantalla</string>
</resources>
Loading