Small changes

- Fixup CVE-2020-36386 breakage
- Move some cherrypicks in tree (gerrit down right now, pulled from reflog)
- Update cherrypicks
This commit is contained in:
Tad 2021-06-14 16:43:04 -04:00
parent 8af1c6a2ee
commit d42c8f033d
41 changed files with 1020 additions and 128 deletions

View File

@ -0,0 +1,104 @@
From 32ebb8bb7abd2fc6031a68d9eec70d83e218b79d Mon Sep 17 00:00:00 2001
From: DJAB HipHop <mweb71@yahoo.com>
Date: Wed, 26 May 2021 20:19:17 +0200
Subject: [PATCH] Backgrounds: Optimize builtin wallpaper loading code
Test in 16.0 by adding extra 4k paper wallpaper I took with my iPhone 11 pro max & opening the app
Change-Id: Ic3901bda473aaa9872baeb8a89958eb1339113fa
Signed-off-by: DJAB HipHop <mweb71@yahoo.com>
---
.../factory/BuiltInWallpaperFactory.java | 7 +++-
.../lineageos/backgrounds/util/UiUtils.java | 40 +++++++++++++++++++
2 files changed, 45 insertions(+), 2 deletions(-)
diff --git a/app/src/main/java/org/lineageos/backgrounds/factory/BuiltInWallpaperFactory.java b/app/src/main/java/org/lineageos/backgrounds/factory/BuiltInWallpaperFactory.java
index 7508d3c..264fa6b 100644
--- a/app/src/main/java/org/lineageos/backgrounds/factory/BuiltInWallpaperFactory.java
+++ b/app/src/main/java/org/lineageos/backgrounds/factory/BuiltInWallpaperFactory.java
@@ -18,6 +18,7 @@ package org.lineageos.backgrounds.factory;
import android.app.WallpaperManager;
import android.content.res.Resources;
import android.graphics.drawable.Drawable;
+import android.graphics.drawable.BitmapDrawable;
import androidx.annotation.DrawableRes;
import androidx.annotation.NonNull;
@@ -25,6 +26,7 @@ import androidx.annotation.NonNull;
import org.lineageos.backgrounds.R;
import org.lineageos.backgrounds.bundle.WallpaperBundle;
import org.lineageos.backgrounds.bundle.WallpaperType;
+import org.lineageos.backgrounds.util.UiUtils;
public final class BuiltInWallpaperFactory {
@@ -33,8 +35,9 @@ public final class BuiltInWallpaperFactory {
public static WallpaperBundle build(@NonNull final String name,
@NonNull final Resources res,
- @DrawableRes final int drawableRes) {
- Drawable drawable = res.getDrawable(drawableRes, res.newTheme());
+ @DrawableRes final int drawableRes) {
+ Drawable drawable = new BitmapDrawable(res, UiUtils.decodeSampledBitmapFromResource(res, drawableRes, 250, 500));
+
return new WallpaperBundle(name, drawable, drawableRes, WallpaperType.BUILT_IN);
}
diff --git a/app/src/main/java/org/lineageos/backgrounds/util/UiUtils.java b/app/src/main/java/org/lineageos/backgrounds/util/UiUtils.java
index 2d5b798..b0de83b 100644
--- a/app/src/main/java/org/lineageos/backgrounds/util/UiUtils.java
+++ b/app/src/main/java/org/lineageos/backgrounds/util/UiUtils.java
@@ -17,6 +17,9 @@ package org.lineageos.backgrounds.util;
import android.view.View;
import android.view.Window;
+import android.content.res.Resources;
+import android.graphics.Bitmap;
+import android.graphics.BitmapFactory;
import androidx.annotation.ColorInt;
import androidx.annotation.NonNull;
@@ -38,4 +41,41 @@ public final class UiUtils {
window.getDecorView().setSystemUiVisibility(flags);
}
+
+ public static int calculateInSampleSize(BitmapFactory.Options options, int reqWidth, int reqHeight) {
+ // Raw height and width of image
+ final int height = options.outHeight;
+ final int width = options.outWidth;
+ int inSampleSize = 1;
+
+ if (height > reqHeight || width > reqWidth) {
+
+ final int halfHeight = height / 2;
+ final int halfWidth = width / 2;
+
+ // Calculate the largest inSampleSize value that is a power of 2 and keeps both
+ // height and width larger than the requested height and width.
+ while ((halfHeight / inSampleSize) >= reqHeight
+ && (halfWidth / inSampleSize) >= reqWidth) {
+ inSampleSize *= 2;
+ }
+ }
+
+ return inSampleSize;
+ }
+
+ public static Bitmap decodeSampledBitmapFromResource(Resources res, int resId, int reqWidth, int reqHeight) {
+
+ // First decode with inJustDecodeBounds=true to check dimensions
+ final BitmapFactory.Options options = new BitmapFactory.Options();
+ options.inJustDecodeBounds = true;
+ BitmapFactory.decodeResource(res, resId, options);
+
+ // Calculate inSampleSize
+ options.inSampleSize = calculateInSampleSize(options, reqWidth, reqHeight);
+
+ // Decode bitmap with inSampleSize set
+ options.inJustDecodeBounds = false;
+ return BitmapFactory.decodeResource(res, resId, options);
+ }
}
--
2.31.1

View File

@ -0,0 +1,36 @@
From bf409d1c39b7f880db5bcc7e417f6ac9d6cbecf0 Mon Sep 17 00:00:00 2001
From: Bruno Martins <bgcngm@gmail.com>
Date: Mon, 14 Jun 2021 15:21:28 +0100
Subject: [PATCH] msm8974-common: Extend RIL shim to all variants
Commit edfa6c3 missed to account for VZW and SPR variants.
Change-Id: I3cc0a885c11670cb67a33f5272d23cea41e0ec13
---
BoardConfigCommon.mk | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/BoardConfigCommon.mk b/BoardConfigCommon.mk
index 5fad8c7..647eab8 100644
--- a/BoardConfigCommon.mk
+++ b/BoardConfigCommon.mk
@@ -1,6 +1,6 @@
#
# Copyright (C) 2015-2016 The CyanogenMod Project
-# 2017-2020 The LineageOS Project
+# 2017-2021 The LineageOS Project
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
@@ -131,6 +131,8 @@ BOARD_SEPOLICY_DIRS += $(PLATFORM_PATH)/sepolicy
TARGET_LD_SHIM_LIBS := \
/system/lib/liblog.so|liblog_htc.so \
/system/vendor/lib/hw/camera.vendor.msm8974.so|libshim_camera.so \
+ /system/vendor/lib/libril_vzw-qc-qmi-1.so|libshim_ril.so \
+ /system/vendor/lib/libril_spr-qc-qmi-1.so|libshim_ril.so \
/system/vendor/lib/libril-qc-qmi-1.so|libshim_ril.so
# Wifi
--
2.31.1

View File

@ -0,0 +1,59 @@
From 653c059e47ea39766d7ab62f6408351d9fc7e9d7 Mon Sep 17 00:00:00 2001
From: Bruno Martins <bgcngm@gmail.com>
Date: Sun, 6 Jun 2021 14:18:24 +0100
Subject: [PATCH] profiles: Add FLAG_IMMUTABLE flag for security purposes
Prevent the intent to be altered by a malicious app.
Change-Id: Id5144fb3f11fc98380de0188df0f32330e976398
---
.../lineageos/lineageparts/profiles/NFCProfileWriter.java | 5 +++--
.../lineageparts/profiles/triggers/NfcTriggerFragment.java | 4 ++--
2 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/src/org/lineageos/lineageparts/profiles/NFCProfileWriter.java b/src/org/lineageos/lineageparts/profiles/NFCProfileWriter.java
index d477d69..d651e9b 100644
--- a/src/org/lineageos/lineageparts/profiles/NFCProfileWriter.java
+++ b/src/org/lineageos/lineageparts/profiles/NFCProfileWriter.java
@@ -1,6 +1,6 @@
/*
* Copyright (C) 2012 The CyanogenMod Project
- * 2017-2018 The LineageOS Project
+ * 2017-2018,2021 The LineageOS Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -84,7 +84,8 @@ public class NFCProfileWriter extends Activity {
private PendingIntent getPendingIntent() {
return PendingIntent.getActivity(this, 0,
- new Intent(this, getClass()).addFlags(Intent.FLAG_ACTIVITY_SINGLE_TOP), 0);
+ new Intent(this, getClass()).addFlags(Intent.FLAG_ACTIVITY_SINGLE_TOP),
+ PendingIntent.FLAG_IMMUTABLE);
}
private void disableTagWriteMode() {
diff --git a/src/org/lineageos/lineageparts/profiles/triggers/NfcTriggerFragment.java b/src/org/lineageos/lineageparts/profiles/triggers/NfcTriggerFragment.java
index adb684c..aac9839 100644
--- a/src/org/lineageos/lineageparts/profiles/triggers/NfcTriggerFragment.java
+++ b/src/org/lineageos/lineageparts/profiles/triggers/NfcTriggerFragment.java
@@ -1,6 +1,6 @@
/*
* Copyright (C) 2014 The CyanogenMod Project
- * 2017 The LineageOS Project
+ * 2017,2021 The LineageOS Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -89,7 +89,7 @@ public class NfcTriggerFragment extends Fragment implements NFCProfileTagCallbac
private PendingIntent getPendingIntent() {
Intent intent = new Intent(getActivity(), getActivity().getClass())
.addFlags(Intent.FLAG_ACTIVITY_SINGLE_TOP);
- return PendingIntent.getActivity(getActivity(), 0, intent, 0);
+ return PendingIntent.getActivity(getActivity(), 0, intent, PendingIntent.FLAG_IMMUTABLE);
}
private void disableTagWriteMode() {
--
2.31.1

View File

@ -0,0 +1,81 @@
From 519ce7dd4887a31a9a8dc60ebae589234aab9e1d Mon Sep 17 00:00:00 2001
From: Bruno Martins <bgcngm@gmail.com>
Date: Sun, 6 Jun 2021 14:26:57 +0100
Subject: [PATCH] SoundRecorderService: Flag all pending intents as immutable
Following Google's approach to fix these vulnerabilities,
require that the PendingIntent be immutable so that a malicious app
isn't able to hijack and mutate any of the details.
Change-Id: Id1ebbfabb7e6282f371d10d0a9648aa99822cadc
---
.../service/SoundRecorderService.java | 21 ++++++++++++-------
1 file changed, 13 insertions(+), 8 deletions(-)
diff --git a/app/src/main/java/org/lineageos/recorder/service/SoundRecorderService.java b/app/src/main/java/org/lineageos/recorder/service/SoundRecorderService.java
index 20bf748..b28763f 100644
--- a/app/src/main/java/org/lineageos/recorder/service/SoundRecorderService.java
+++ b/app/src/main/java/org/lineageos/recorder/service/SoundRecorderService.java
@@ -13,6 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
+
package org.lineageos.recorder.service;
import android.app.Notification;
@@ -277,10 +278,11 @@ public class SoundRecorderService extends Service {
}
Intent intent = new Intent(this, RecorderActivity.class);
- PendingIntent pi = PendingIntent.getActivity(this, 0, intent, 0);
+ PendingIntent pi = PendingIntent.getActivity(this, 0, intent,
+ PendingIntent.FLAG_IMMUTABLE);
PendingIntent stopPIntent = PendingIntent.getService(this, 0,
new Intent(this, SoundRecorderService.class).setAction(ACTION_STOP),
- 0);
+ PendingIntent.FLAG_IMMUTABLE);
String duration = DateUtils.formatElapsedTime(mSbRecycle, mElapsedTime.get());
NotificationCompat.Builder nb = new NotificationCompat.Builder(this, NOTIFICATION_CHANNEL)
@@ -293,11 +295,13 @@ public class SoundRecorderService extends Service {
if (mIsPaused) {
PendingIntent resumePIntent = PendingIntent.getService(this, 0,
- new Intent(this, SoundRecorderService.class).setAction(ACTION_RESUME), 0);
+ new Intent(this, SoundRecorderService.class).setAction(ACTION_RESUME),
+ PendingIntent.FLAG_IMMUTABLE);
nb.addAction(R.drawable.ic_resume, getString(R.string.resume), resumePIntent);
} else {
PendingIntent pausePIntent = PendingIntent.getService(this, 0,
- new Intent(this, SoundRecorderService.class).setAction(ACTION_PAUSE), 0);
+ new Intent(this, SoundRecorderService.class).setAction(ACTION_PAUSE),
+ PendingIntent.FLAG_IMMUTABLE);
nb.addAction(R.drawable.ic_pause, getString(R.string.pause), pausePIntent);
}
nb.addAction(R.drawable.ic_stop, getString(R.string.stop), stopPIntent);
@@ -314,16 +318,17 @@ public class SoundRecorderService extends Service {
String mimeType = mRecorder.getMimeType();
Intent intent = new Intent(this, ListActivity.class);
- PendingIntent pi = PendingIntent.getActivity(this, 0, intent, 0);
+ PendingIntent pi = PendingIntent.getActivity(this, 0, intent,
+ PendingIntent.FLAG_IMMUTABLE);
PendingIntent playPIntent = PendingIntent.getActivity(this, 0,
LastRecordHelper.getOpenIntent(fileUri, mimeType),
- PendingIntent.FLAG_CANCEL_CURRENT);
+ PendingIntent.FLAG_CANCEL_CURRENT | PendingIntent.FLAG_IMMUTABLE);
PendingIntent sharePIntent = PendingIntent.getActivity(this, 0,
LastRecordHelper.getShareIntent(fileUri, mimeType),
- PendingIntent.FLAG_CANCEL_CURRENT);
+ PendingIntent.FLAG_CANCEL_CURRENT | PendingIntent.FLAG_IMMUTABLE);
PendingIntent deletePIntent = PendingIntent.getActivity(this, 0,
LastRecordHelper.getDeleteIntent(this),
- PendingIntent.FLAG_CANCEL_CURRENT);
+ PendingIntent.FLAG_CANCEL_CURRENT | PendingIntent.FLAG_IMMUTABLE);
String duration = DateUtils.formatElapsedTime(mSbRecycle, mElapsedTime.get());
Notification notification = new NotificationCompat.Builder(this, NOTIFICATION_CHANNEL)
--
2.31.1

View File

@ -0,0 +1,137 @@
From 187d72f4843939180e9978d6ec0f0f8d7ea1e66e Mon Sep 17 00:00:00 2001
From: Mattias Nilsson <mattias.nilsson@sony.com>
Date: Fri, 13 Nov 2020 22:30:08 +0100
Subject: [PATCH] Mcc and mnc from xml in RRO may be integers
Mcc and mnc in an xml from overlays built in current android build
system are integers to the contrary of the apns-full-conf.xml
where they are strings. The telephony provider uses the same parsing
mechanism in both cases which makes the full apn list get
correct values whereas the provider misjudge what it should
insert in the database when there is an apns.xml in an overlay.
For the newly built android RROs mnc="01" becomes mnc="1" and no
match is found when the sim card is inserted.
To not risk the large APN list we only change the behavior for the
overlay handling.
Solution is to format the mcc value to have 3 digits and use the
carrier id table to get correct mnc. Sim cards missing
in the carrier id table need to be added there.
Test: Manual
Test: adb shell content query --uri content://telephony/carriers
Bug: 175620622
Change-Id: I244ad0f76f360a0635343187e455b54c90ec45b4
---
.../telephony/TelephonyProvider.java | 35 ++++++++++++-------
1 file changed, 23 insertions(+), 12 deletions(-)
diff --git a/src/com/android/providers/telephony/TelephonyProvider.java b/src/com/android/providers/telephony/TelephonyProvider.java
index 3cb4abe..b1b3146 100644
--- a/src/com/android/providers/telephony/TelephonyProvider.java
+++ b/src/com/android/providers/telephony/TelephonyProvider.java
@@ -128,6 +128,7 @@ import java.io.FileNotFoundException;
import java.io.FileReader;
import java.io.IOException;
import java.io.InputStream;
+import java.lang.Integer;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.concurrent.atomic.AtomicBoolean;
@@ -752,7 +753,7 @@ public class TelephonyProvider extends ContentProvider
try {
XmlUtils.beginDocument(parser, "apns");
publicversion = Integer.parseInt(parser.getAttributeValue(null, "version"));
- loadApns(db, parser);
+ loadApns(db, parser, true);
} catch (Exception e) {
loge("Got exception while loading APN database." + e);
} finally {
@@ -782,7 +783,7 @@ public class TelephonyProvider extends ContentProvider
+ confFile.getAbsolutePath());
}
- loadApns(db, confparser);
+ loadApns(db, confparser, false);
} catch (FileNotFoundException e) {
// It's ok if the file isn't found. It means there isn't a confidential file
// Log.e(TAG, "File not found: '" + confFile.getAbsolutePath() + "'");
@@ -1665,7 +1666,7 @@ public class TelephonyProvider extends ContentProvider
try {
XmlUtils.nextElement(parser);
while (parser.getEventType() != XmlPullParser.END_DOCUMENT) {
- ContentValues row = getRow(parser);
+ ContentValues row = getRow(parser, false);
if (row == null) {
throw new XmlPullParserException("Expected 'apn' tag", parser, null);
}
@@ -2072,9 +2073,10 @@ public class TelephonyProvider extends ContentProvider
* Gets the next row of apn values.
*
* @param parser the parser
+ * @param isOverlay If the xml file comes from an overlay MCC/MNC are treated as integers
* @return the row or null if it's not an apn
*/
- private ContentValues getRow(XmlPullParser parser) {
+ private ContentValues getRow(XmlPullParser parser, boolean isOverlay) {
if (!"apn".equals(parser.getName())) {
return null;
}
@@ -2083,11 +2085,21 @@ public class TelephonyProvider extends ContentProvider
String mcc = parser.getAttributeValue(null, "mcc");
String mnc = parser.getAttributeValue(null, "mnc");
- String numeric = mcc + mnc;
-
+ String mccString = mcc;
+ String mncString = mnc;
+ // Since an mnc can have both two and three digits and it is hard to verify
+ // all OEM's Global APN lists we only do this for overlays.
+ if (isOverlay) {
+ mccString = String.format("%03d", Integer.parseInt(mcc));
+ // Looks up a two digit mnc in the carrier id DB
+ // if not found a three digit mnc value is chosen
+ mncString = getBestStringMnc(mContext, mccString, Integer.parseInt(mnc));
+ }
+
+ String numeric = mccString + mncString;
map.put(NUMERIC, numeric);
- map.put(MCC, mcc);
- map.put(MNC, mnc);
+ map.put(MCC, mccString);
+ map.put(MNC, mncString);
map.put(NAME, parser.getAttributeValue(null, "carrier"));
// do not add NULL to the map so that default values can be inserted in db
@@ -2156,7 +2168,6 @@ public class TelephonyProvider extends ContentProvider
map.put(MVNO_MATCH_DATA, mvno_match_data);
}
}
-
return map;
}
@@ -2189,15 +2200,15 @@ public class TelephonyProvider extends ContentProvider
*
* @param db the sqlite database to write to
* @param parser the xml parser
- *
+ * @param isOverlay, if we are parsing an xml in an overlay
*/
- private void loadApns(SQLiteDatabase db, XmlPullParser parser) {
+ private void loadApns(SQLiteDatabase db, XmlPullParser parser, boolean isOverlay) {
if (parser != null) {
try {
db.beginTransaction();
XmlUtils.nextElement(parser);
while (parser.getEventType() != XmlPullParser.END_DOCUMENT) {
- ContentValues row = getRow(parser);
+ ContentValues row = getRow(parser, isOverlay);
if (row == null) {
throw new XmlPullParserException("Expected 'apn' tag", parser, null);
}
--
2.31.1

View File

@ -0,0 +1,109 @@
From d459c7003584f6a47bb6723238d77a1c8cb4b5dd Mon Sep 17 00:00:00 2001
From: Mattias Nilsson <Mattias.Nilsson@sony.com>
Date: Thu, 15 Apr 2021 17:11:27 +0200
Subject: [PATCH] MNCs not in carrier_list can get the wrong MNC value
Mobile Network Codes that belong to SIM cards not specified
in carrier_list sometimes get the wrong MNC value.
This change aims to improve the likelihood of a
correct MNC.
Test: Install an RRO with apns.xml and look at the DB.
Bug: 186542894
Change-Id: I1dbccf9d75a7a8ae896ca483935bc5e007843e75
---
.../telephony/TelephonyProvider.java | 68 ++++++++++++++++---
1 file changed, 58 insertions(+), 10 deletions(-)
diff --git a/src/com/android/providers/telephony/TelephonyProvider.java b/src/com/android/providers/telephony/TelephonyProvider.java
index b1b3146..6bddde9 100644
--- a/src/com/android/providers/telephony/TelephonyProvider.java
+++ b/src/com/android/providers/telephony/TelephonyProvider.java
@@ -260,6 +260,40 @@ public class TelephonyProvider extends ContentProvider
private boolean mManagedApnEnforced;
+ /**
+ * Mobile country codes where there is a high likelyhood that the MNC has 3 digits
+ * and need one more prefix zero to set correct mobile network code value.
+ *
+ * Please note! The best solution is to add the MCCMNC combo to carrier id
+ * carrier_list, this is just a best effort.
+ */
+ private static final String[] COUNTRY_MCC_WITH_THREE_DIGIT_MNC = {
+ "302" // Canada
+ ,"310" // Guam, USA
+ ,"311" // USA
+ ,"312" // USA
+ ,"313" // USA
+ ,"316" // USA
+ ,"334" // Mexico
+ ,"338" // Bermuda, Jamaica
+ ,"342" // Barbados
+ ,"344" // Antigua and Barbuda
+ ,"346" // Cayman Islands
+ ,"348" // British Virgin Islands
+ ,"356" // Saint Kitts and Nevis
+ ,"358" // Saint Lucia
+ ,"360" // Saint Vincent and the Grenadines
+ ,"365" // Anguilla
+ ,"366" // Dominica
+ ,"376" // Turks and Caicos Islands
+ ,"405" // India
+ ,"708" // Honduras
+ ,"722" // Argentina
+ ,"732" // Colombia
+ ,"738" // Guyana
+ ,"750" // Falkland Islands
+ };
+
/**
* Available radio technologies for GSM, UMTS and CDMA.
* Duplicates the constants from hardware/radio/include/ril.h
@@ -4151,18 +4185,32 @@ public class TelephonyProvider extends ContentProvider
}
String twoDigitMnc = String.format(Locale.getDefault(), "%02d", mnc);
String threeDigitMnc = "0" + twoDigitMnc;
+ boolean threeDigitNetworkCode =
+ Arrays.asList(COUNTRY_MCC_WITH_THREE_DIGIT_MNC).contains(mcc);
+ int twoDigitResult = countMccMncInCarrierList(context, mcc + twoDigitMnc);
+ int threeDigitResult = countMccMncInCarrierList(context, mcc + threeDigitMnc);
- try (
- Cursor twoDigitMncCursor = context.getContentResolver().query(
- Telephony.CarrierId.All.CONTENT_URI,
- /* projection */ null,
- /* selection */ Telephony.CarrierId.All.MCCMNC + "=?",
- /* selectionArgs */ new String[]{mcc + twoDigitMnc}, null)
- ) {
- if (twoDigitMncCursor.getCount() > 0) {
- return twoDigitMnc;
- }
+ if ((threeDigitResult > twoDigitResult) ||
+ (threeDigitNetworkCode && (twoDigitResult == threeDigitResult))) {
return threeDigitMnc;
+ } else {
+ return twoDigitMnc;
+ }
+ }
+
+ /**
+ * Check carrier_list how many mcc mnc combo matches there are
+ */
+ private static int countMccMncInCarrierList(Context ctx, String mccMncCombo) {
+ try (
+ Cursor mccMncCursor = ctx.getContentResolver().query(
+ Telephony.CarrierId.All.CONTENT_URI,
+ /* projection */ null,
+ /* selection */ Telephony.CarrierId.All.MCCMNC + "=?",
+ /* selectionArgs */ new String[]{mccMncCombo}, null);
+ )
+ {
+ return mccMncCursor.getCount();
}
}
--
2.31.1

View File

@ -0,0 +1,442 @@
From 4b95e44cd67c162f193de73668c57a8d63573728 Mon Sep 17 00:00:00 2001
From: cnx421 <cnx421@gmail.com>
Date: Fri, 6 Nov 2020 15:35:04 +0800
Subject: [PATCH 1/5] Fix for Multiplication overflow will be crash btstack
When a2dp using LDAC ecoding PCM,if encoding thread is runned by deley after 2 secends,
btstack will overflow .System will abort to crash by arm gcc code.
Bug: 172590955
Tag: #stability
Test: compile & verify basic functions working
Test: pair to a support LDAC ecode BT headset
Change-Id: Ie470bd51bfd7951d0c674b37aa6af7554cf9faa8
---
stack/a2dp/a2dp_vendor_ldac_encoder.cc | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/stack/a2dp/a2dp_vendor_ldac_encoder.cc b/stack/a2dp/a2dp_vendor_ldac_encoder.cc
index ca6c2fc98..9240df222 100644
--- a/stack/a2dp/a2dp_vendor_ldac_encoder.cc
+++ b/stack/a2dp/a2dp_vendor_ldac_encoder.cc
@@ -592,8 +592,8 @@ static void a2dp_ldac_get_num_frame_iteration(uint8_t* num_of_iterations,
a2dp_ldac_encoder_cb.ldac_feeding_state.last_frame_us = now_us;
a2dp_ldac_encoder_cb.ldac_feeding_state.counter +=
- a2dp_ldac_encoder_cb.ldac_feeding_state.bytes_per_tick * us_this_tick /
- (A2DP_LDAC_ENCODER_INTERVAL_MS * 1000);
+ a2dp_ldac_encoder_cb.ldac_feeding_state.bytes_per_tick * (us_this_tick /
+ (float) (A2DP_LDAC_ENCODER_INTERVAL_MS * 1000));
result =
a2dp_ldac_encoder_cb.ldac_feeding_state.counter / pcm_bytes_per_frame;
--
2.31.1
From e4d6d8779f4838a68def4c10aaab55b170dbe165 Mon Sep 17 00:00:00 2001
From: Daren Liao <daren.liao@mediatek.com>
Date: Fri, 20 Nov 2020 14:23:17 +0800
Subject: [PATCH 2/5] Fix A2dp encoder counter deviation.
[Description]
Fix A2dp encoder counter deviation.
[Test Report]
Pass
Bug: 176783467
Test: Measure audio/video latency before and after 7 hours of playback
Change-Id: I6116ca81a223d305128f6c75f262375fed2f90bc
---
stack/a2dp/a2dp_aac_encoder.cc | 42 +++++++++-----------------
stack/a2dp/a2dp_sbc_encoder.cc | 41 ++++++++-----------------
stack/a2dp/a2dp_vendor_ldac_encoder.cc | 8 ++---
3 files changed, 31 insertions(+), 60 deletions(-)
diff --git a/stack/a2dp/a2dp_aac_encoder.cc b/stack/a2dp/a2dp_aac_encoder.cc
index 8f32c1f2e..c1e41e332 100644
--- a/stack/a2dp/a2dp_aac_encoder.cc
+++ b/stack/a2dp/a2dp_aac_encoder.cc
@@ -56,9 +56,9 @@ typedef struct {
} tA2DP_AAC_ENCODER_PARAMS;
typedef struct {
- uint32_t counter;
- uint32_t bytes_per_tick; // pcm bytes read each media task tick
- uint64_t last_frame_timestamp_100ns; // values in 1/10 microseconds
+ float counter;
+ uint32_t bytes_per_tick; /* pcm bytes read each media task tick */
+ uint64_t last_frame_us;
} tA2DP_AAC_FEEDING_STATE;
typedef struct {
@@ -521,7 +521,7 @@ void a2dp_aac_feeding_reset(void) {
}
void a2dp_aac_feeding_flush(void) {
- a2dp_aac_encoder_cb.aac_feeding_state.counter = 0;
+ a2dp_aac_encoder_cb.aac_feeding_state.counter = 0.0f;
}
uint64_t a2dp_aac_get_encoder_interval_ms(void) {
@@ -560,30 +560,16 @@ static void a2dp_aac_get_num_frame_iteration(uint8_t* num_of_iterations,
LOG_VERBOSE(LOG_TAG, "%s: pcm_bytes_per_frame %u", __func__,
pcm_bytes_per_frame);
- uint32_t hecto_ns_this_tick = a2dp_aac_encoder_interval_ms * 10000;
- uint64_t* last_100ns =
- &a2dp_aac_encoder_cb.aac_feeding_state.last_frame_timestamp_100ns;
- uint64_t now_100ns = timestamp_us * 10;
- if (*last_100ns != 0) {
- hecto_ns_this_tick = (now_100ns - *last_100ns);
- }
- *last_100ns = now_100ns;
-
- uint32_t bytes_this_tick =
- a2dp_aac_encoder_cb.aac_feeding_state.bytes_per_tick *
- hecto_ns_this_tick / (a2dp_aac_encoder_interval_ms * 10000);
- a2dp_aac_encoder_cb.aac_feeding_state.counter += bytes_this_tick;
- // Without this erratum, there was a three microseocnd shift per tick which
- // would cause one frame mismatched after every 180 seconds
- uint32_t erratum_100ns =
- ceil(1.0f * bytes_this_tick * a2dp_aac_encoder_interval_ms * 10000 /
- a2dp_aac_encoder_cb.aac_feeding_state.bytes_per_tick);
- if (erratum_100ns < hecto_ns_this_tick) {
- LOG_VERBOSE(LOG_TAG,
- "%s: hecto_ns_this_tick=%d, bytes=%d, erratum_100ns=%d",
- __func__, hecto_ns_this_tick, bytes_this_tick, erratum_100ns);
- *last_100ns -= hecto_ns_this_tick - erratum_100ns;
- }
+ uint32_t us_this_tick = A2DP_AAC_ENCODER_INTERVAL_MS * 1000;
+ uint64_t now_us = timestamp_us;
+ if (a2dp_aac_encoder_cb.aac_feeding_state.last_frame_us != 0)
+ us_this_tick =
+ (now_us - a2dp_aac_encoder_cb.aac_feeding_state.last_frame_us);
+ a2dp_aac_encoder_cb.aac_feeding_state.last_frame_us = now_us;
+
+ a2dp_aac_encoder_cb.aac_feeding_state.counter +=
+ (float)a2dp_aac_encoder_cb.aac_feeding_state.bytes_per_tick * us_this_tick /
+ (A2DP_AAC_ENCODER_INTERVAL_MS * 1000);
result = a2dp_aac_encoder_cb.aac_feeding_state.counter / pcm_bytes_per_frame;
a2dp_aac_encoder_cb.aac_feeding_state.counter -= result * pcm_bytes_per_frame;
diff --git a/stack/a2dp/a2dp_sbc_encoder.cc b/stack/a2dp/a2dp_sbc_encoder.cc
index ddcd1f87c..052ad3bd3 100644
--- a/stack/a2dp/a2dp_sbc_encoder.cc
+++ b/stack/a2dp/a2dp_sbc_encoder.cc
@@ -95,9 +95,9 @@ typedef struct {
uint32_t aa_frame_counter;
int32_t aa_feed_counter;
int32_t aa_feed_residue;
- uint32_t counter;
- uint32_t bytes_per_tick; // pcm bytes read each media task tick
- uint64_t last_frame_timestamp_100ns; // values in 1/10 microseconds
+ float counter;
+ uint32_t bytes_per_tick; /* pcm bytes read each media task tick */
+ uint64_t last_frame_us;
} tA2DP_SBC_FEEDING_STATE;
typedef struct {
@@ -417,7 +417,7 @@ void a2dp_sbc_feeding_reset(void) {
}
void a2dp_sbc_feeding_flush(void) {
- a2dp_sbc_encoder_cb.feeding_state.counter = 0;
+ a2dp_sbc_encoder_cb.feeding_state.counter = 0.0f;
a2dp_sbc_encoder_cb.feeding_state.aa_feed_residue = 0;
}
@@ -458,30 +458,15 @@ static void a2dp_sbc_get_num_frame_iteration(uint8_t* num_of_iterations,
LOG_VERBOSE(LOG_TAG, "%s: pcm_bytes_per_frame %u", __func__,
pcm_bytes_per_frame);
- uint32_t hecto_ns_this_tick = A2DP_SBC_ENCODER_INTERVAL_MS * 10000;
- uint64_t* last_100ns =
- &a2dp_sbc_encoder_cb.feeding_state.last_frame_timestamp_100ns;
- uint64_t now_100ns = timestamp_us * 10;
- if (*last_100ns != 0) {
- hecto_ns_this_tick = (now_100ns - *last_100ns);
- }
- *last_100ns = now_100ns;
-
- uint32_t bytes_this_tick = a2dp_sbc_encoder_cb.feeding_state.bytes_per_tick *
- hecto_ns_this_tick /
- (A2DP_SBC_ENCODER_INTERVAL_MS * 10000);
- a2dp_sbc_encoder_cb.feeding_state.counter += bytes_this_tick;
- // Without this erratum, there was a three microseocnd shift per tick which
- // would cause one SBC frame mismatched after every 20 seconds
- uint32_t erratum_100ns =
- ceil(1.0f * A2DP_SBC_ENCODER_INTERVAL_MS * 10000 * bytes_this_tick /
- a2dp_sbc_encoder_cb.feeding_state.bytes_per_tick);
- if (erratum_100ns < hecto_ns_this_tick) {
- LOG_VERBOSE(LOG_TAG,
- "%s: hecto_ns_this_tick=%d, bytes=%d, erratum_100ns=%d",
- __func__, hecto_ns_this_tick, bytes_this_tick, erratum_100ns);
- *last_100ns -= hecto_ns_this_tick - erratum_100ns;
- }
+ uint32_t us_this_tick = A2DP_SBC_ENCODER_INTERVAL_MS * 1000;
+ uint64_t now_us = timestamp_us;
+ if (a2dp_sbc_encoder_cb.feeding_state.last_frame_us != 0)
+ us_this_tick = (now_us - a2dp_sbc_encoder_cb.feeding_state.last_frame_us);
+ a2dp_sbc_encoder_cb.feeding_state.last_frame_us = now_us;
+
+ a2dp_sbc_encoder_cb.feeding_state.counter +=
+ (float)a2dp_sbc_encoder_cb.feeding_state.bytes_per_tick * us_this_tick /
+ (A2DP_SBC_ENCODER_INTERVAL_MS * 1000);
/* Calculate the number of frames pending for this media tick */
projected_nof =
diff --git a/stack/a2dp/a2dp_vendor_ldac_encoder.cc b/stack/a2dp/a2dp_vendor_ldac_encoder.cc
index 9240df222..0e184d7b6 100644
--- a/stack/a2dp/a2dp_vendor_ldac_encoder.cc
+++ b/stack/a2dp/a2dp_vendor_ldac_encoder.cc
@@ -124,7 +124,7 @@ typedef struct {
} tA2DP_LDAC_ENCODER_PARAMS;
typedef struct {
- uint32_t counter;
+ float counter;
uint32_t bytes_per_tick; /* pcm bytes read each media task tick */
uint64_t last_frame_us;
} tA2DP_LDAC_FEEDING_STATE;
@@ -532,7 +532,7 @@ void a2dp_vendor_ldac_feeding_reset(void) {
}
void a2dp_vendor_ldac_feeding_flush(void) {
- a2dp_ldac_encoder_cb.ldac_feeding_state.counter = 0;
+ a2dp_ldac_encoder_cb.ldac_feeding_state.counter = 0.0f;
}
uint64_t a2dp_vendor_ldac_get_encoder_interval_ms(void) {
@@ -592,8 +592,8 @@ static void a2dp_ldac_get_num_frame_iteration(uint8_t* num_of_iterations,
a2dp_ldac_encoder_cb.ldac_feeding_state.last_frame_us = now_us;
a2dp_ldac_encoder_cb.ldac_feeding_state.counter +=
- a2dp_ldac_encoder_cb.ldac_feeding_state.bytes_per_tick * (us_this_tick /
- (float) (A2DP_LDAC_ENCODER_INTERVAL_MS * 1000));
+ (float)a2dp_ldac_encoder_cb.ldac_feeding_state.bytes_per_tick * us_this_tick /
+ (A2DP_LDAC_ENCODER_INTERVAL_MS * 1000);
result =
a2dp_ldac_encoder_cb.ldac_feeding_state.counter / pcm_bytes_per_frame;
--
2.31.1
From ee7c93c27d273b977e429f2b9384ada92baaea88 Mon Sep 17 00:00:00 2001
From: Cheney Ni <cheneyni@google.com>
Date: Tue, 26 Jan 2021 11:43:21 +0800
Subject: [PATCH 3/5] BluetoothAudioHAL: MTU not exceed an AVDTP packet
Fix the MTU value not to be greater than an AVDTP packet, so the data
encoded by A2DP hardware encoder can be fitted into one AVDTP packet
without fragmented.
Bug: 177205770
Tag: #compatibility
Test: A2DP playback and check the MTU that Audio HAL receiving
Change-Id: I9104b699448b55fb2ec981aecb6ce1913d494821
---
audio_hal_interface/a2dp_encoding.cc | 3 +++
1 file changed, 3 insertions(+)
diff --git a/audio_hal_interface/a2dp_encoding.cc b/audio_hal_interface/a2dp_encoding.cc
index 456ba60f1..90ef1c2bf 100644
--- a/audio_hal_interface/a2dp_encoding.cc
+++ b/audio_hal_interface/a2dp_encoding.cc
@@ -278,6 +278,9 @@ bool a2dp_get_selected_hal_codec_config(CodecConfiguration* codec_config) {
} else {
codec_config->peerMtu = peer_param.peer_mtu;
}
+ if (codec_config->peerMtu > MAX_3MBPS_AVDTP_MTU) {
+ codec_config->peerMtu = MAX_3MBPS_AVDTP_MTU;
+ }
LOG(INFO) << __func__ << ": CodecConfiguration=" << toString(*codec_config);
return true;
}
--
2.31.1
From 072b33e584102c0aaa9870535f55fcdd59e75d67 Mon Sep 17 00:00:00 2001
From: Cheney Ni <cheneyni@google.com>
Date: Fri, 5 Feb 2021 21:55:52 +0800
Subject: [PATCH 4/5] A2DP: AAC encoder uses same value in tick interval and
feeding data
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
The tick that AAC encoder wakes up is based on its codec configuration,
but usually is not that fixed 20 ms. The user would hear choppy sound if
using wrong values to calculate the data size, so have to correct.
Fixes: 179268075
Tag: #compatibility
Test: check the bitrate from BTSnoop and no overrun
Change-Id: Iaaddcbd305d4b5383b707b9e0d50e8fe116c043d
---
stack/a2dp/a2dp_aac_encoder.cc | 7 +++----
stack/a2dp/a2dp_sbc_encoder.cc | 1 -
2 files changed, 3 insertions(+), 5 deletions(-)
diff --git a/stack/a2dp/a2dp_aac_encoder.cc b/stack/a2dp/a2dp_aac_encoder.cc
index c1e41e332..a4e033c7d 100644
--- a/stack/a2dp/a2dp_aac_encoder.cc
+++ b/stack/a2dp/a2dp_aac_encoder.cc
@@ -19,7 +19,6 @@
#include "a2dp_aac_encoder.h"
#include <inttypes.h>
-#include <math.h>
#include <stdio.h>
#include <string.h>
@@ -560,7 +559,7 @@ static void a2dp_aac_get_num_frame_iteration(uint8_t* num_of_iterations,
LOG_VERBOSE(LOG_TAG, "%s: pcm_bytes_per_frame %u", __func__,
pcm_bytes_per_frame);
- uint32_t us_this_tick = A2DP_AAC_ENCODER_INTERVAL_MS * 1000;
+ uint32_t us_this_tick = a2dp_aac_encoder_interval_ms * 1000;
uint64_t now_us = timestamp_us;
if (a2dp_aac_encoder_cb.aac_feeding_state.last_frame_us != 0)
us_this_tick =
@@ -568,8 +567,8 @@ static void a2dp_aac_get_num_frame_iteration(uint8_t* num_of_iterations,
a2dp_aac_encoder_cb.aac_feeding_state.last_frame_us = now_us;
a2dp_aac_encoder_cb.aac_feeding_state.counter +=
- (float)a2dp_aac_encoder_cb.aac_feeding_state.bytes_per_tick * us_this_tick /
- (A2DP_AAC_ENCODER_INTERVAL_MS * 1000);
+ (float)a2dp_aac_encoder_cb.aac_feeding_state.bytes_per_tick *
+ us_this_tick / (a2dp_aac_encoder_interval_ms * 1000);
result = a2dp_aac_encoder_cb.aac_feeding_state.counter / pcm_bytes_per_frame;
a2dp_aac_encoder_cb.aac_feeding_state.counter -= result * pcm_bytes_per_frame;
diff --git a/stack/a2dp/a2dp_sbc_encoder.cc b/stack/a2dp/a2dp_sbc_encoder.cc
index 052ad3bd3..a4f0f5310 100644
--- a/stack/a2dp/a2dp_sbc_encoder.cc
+++ b/stack/a2dp/a2dp_sbc_encoder.cc
@@ -22,7 +22,6 @@
#include "a2dp_sbc_encoder.h"
#include <limits.h>
-#include <math.h>
#include <stdio.h>
#include <string.h>
--
2.31.1
From e01b90ec1925507e8c3c4991446130fcd4ab3bfc Mon Sep 17 00:00:00 2001
From: Cheney Ni <cheneyni@google.com>
Date: Thu, 20 May 2021 18:58:48 +0800
Subject: [PATCH 5/5] A2DP: Restrict MTU while using SBC middle quality
When SBC headsets report middle quality bitpool under a larger MTU, we
reduce the packet size to prevent the hardware encoder from putting too
many frames in one packet.
Bug: 188020925
Tag: #compatibility
Test: A2DP playback with SBC manually
Change-Id: I164c0c1fe37d6852718889e2946207471b26e5bd
---
audio_hal_interface/a2dp_encoding.cc | 7 ++++++-
bta/av/bta_av_aact.cc | 4 +---
stack/a2dp/a2dp_sbc_encoder.cc | 17 +++++++++++++++++
stack/include/a2dp_sbc_constants.h | 1 +
4 files changed, 25 insertions(+), 4 deletions(-)
diff --git a/audio_hal_interface/a2dp_encoding.cc b/audio_hal_interface/a2dp_encoding.cc
index 90ef1c2bf..cb95b80b4 100644
--- a/audio_hal_interface/a2dp_encoding.cc
+++ b/audio_hal_interface/a2dp_encoding.cc
@@ -18,6 +18,7 @@
#include "client_interface.h"
#include "codec_status.h"
+#include "a2dp_sbc_constants.h"
#include "btif_a2dp_source.h"
#include "btif_av.h"
#include "btif_av_co.h"
@@ -278,7 +279,11 @@ bool a2dp_get_selected_hal_codec_config(CodecConfiguration* codec_config) {
} else {
codec_config->peerMtu = peer_param.peer_mtu;
}
- if (codec_config->peerMtu > MAX_3MBPS_AVDTP_MTU) {
+ if (current_codec.codec_type == BTAV_A2DP_CODEC_INDEX_SOURCE_SBC &&
+ codec_config->config.sbcConfig().maxBitpool <=
+ A2DP_SBC_BITPOOL_MIDDLE_QUALITY) {
+ codec_config->peerMtu = MAX_2MBPS_AVDTP_MTU;
+ } else if (codec_config->peerMtu > MAX_3MBPS_AVDTP_MTU) {
codec_config->peerMtu = MAX_3MBPS_AVDTP_MTU;
}
LOG(INFO) << __func__ << ": CodecConfiguration=" << toString(*codec_config);
diff --git a/bta/av/bta_av_aact.cc b/bta/av/bta_av_aact.cc
index 29dcea07b..7430c2b91 100644
--- a/bta/av/bta_av_aact.cc
+++ b/bta/av/bta_av_aact.cc
@@ -79,8 +79,6 @@
/* ACL quota we are letting FW use for A2DP Offload Tx. */
#define BTA_AV_A2DP_OFFLOAD_XMIT_QUOTA 4
-#define BTIF_A2DP_MAX_BITPOOL_MQ 35
-
static void bta_av_offload_codec_builder(tBTA_AV_SCB* p_scb,
tBT_A2DP_OFFLOAD* p_a2dp_offload);
static void bta_av_st_rc_timer(tBTA_AV_SCB* p_scb,
@@ -3257,7 +3255,7 @@ static void bta_av_offload_codec_builder(tBTA_AV_SCB* p_scb,
case BTAV_A2DP_CODEC_INDEX_SOURCE_SBC:
codec_type = BTA_AV_CODEC_TYPE_SBC;
if (A2DP_GetMaxBitpoolSbc(p_scb->cfg.codec_info) <=
- BTIF_A2DP_MAX_BITPOOL_MQ) {
+ A2DP_SBC_BITPOOL_MIDDLE_QUALITY) {
APPL_TRACE_WARNING("%s: Restricting streaming MTU size for MQ Bitpool",
__func__);
mtu = MAX_2MBPS_AVDTP_MTU;
diff --git a/stack/a2dp/a2dp_sbc_encoder.cc b/stack/a2dp/a2dp_sbc_encoder.cc
index a4f0f5310..053f76d1c 100644
--- a/stack/a2dp/a2dp_sbc_encoder.cc
+++ b/stack/a2dp/a2dp_sbc_encoder.cc
@@ -962,6 +962,23 @@ void A2dpCodecConfigSbcSource::debug_codec_dump(int fd) {
A2dpCodecConfig::debug_codec_dump(fd);
+ uint8_t codec_info[AVDT_CODEC_SIZE];
+ if (copyOutOtaCodecConfig(codec_info)) {
+ dprintf(fd,
+ " Block length : %d\n",
+ A2DP_GetNumberOfBlocksSbc(codec_info));
+ dprintf(fd,
+ " Number of subbands : %d\n",
+ A2DP_GetNumberOfSubbandsSbc(codec_info));
+ dprintf(fd,
+ " Allocation method : %d\n",
+ A2DP_GetAllocationMethodCodeSbc(codec_info));
+ dprintf(
+ fd,
+ " Bitpool (min/max) : %d / %d\n",
+ A2DP_GetMinBitpoolSbc(codec_info), A2DP_GetMaxBitpoolSbc(codec_info));
+ }
+
dprintf(fd,
" Packet counts (expected/dropped) : %zu / "
"%zu\n",
diff --git a/stack/include/a2dp_sbc_constants.h b/stack/include/a2dp_sbc_constants.h
index 87b9eb981..7426688f6 100644
--- a/stack/include/a2dp_sbc_constants.h
+++ b/stack/include/a2dp_sbc_constants.h
@@ -61,6 +61,7 @@
#define A2DP_SBC_IE_MIN_BITPOOL 2
#define A2DP_SBC_IE_MAX_BITPOOL 250
+#define A2DP_SBC_BITPOOL_MIDDLE_QUALITY 35
/* for media payload header */
#define A2DP_SBC_HDR_F_MSK 0x80
--
2.31.1

@ -1 +1 @@
Subproject commit 880f21d611c3b68a62712a84a61838907160a99d
Subproject commit 1ed1dada1dd1fd1ca8f95086681e7ece419a5e1b

View File

@ -718,8 +718,8 @@ deblobDevice() {
echo "type vendor_timekeep_prop, property_type;" >> sepolicy/property.te;
echo "persist.vendor.timeadjust u:object_r:vendor_timekeep_prop:s0" >> sepolicy/property_contexts;
echo "user=system seinfo=platform name=com.sony.timekeep domain=timekeep_app type=app_data_file" >> sepolicy/seapp_contexts;
cp "$DOS_PATCHES_COMMON/timekeep.te" sepolicy/;
cp "$DOS_PATCHES_COMMON/timekeep_app.te" sepolicy/;
cp "$DOS_PATCHES_COMMON/android_timekeep_sepolicy/timekeep.te" sepolicy/;
cp "$DOS_PATCHES_COMMON/android_timekeep_sepolicy/timekeep_app.te" sepolicy/;
fi;
fi;
fi;

View File

@ -607,7 +607,6 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29371/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29661/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35508/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36158/3.18/0008.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36386/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0512/^5.10/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3178/3.18/0008.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3428/3.18/0001.patch
@ -629,5 +628,5 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2015-4002/3.18/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2016-9178/3.18/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-14283/3.18/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-0466/3.18/0003.patch
editKernelLocalversion "-dos.p629"
editKernelLocalversion "-dos.p628"
cd "$DOS_BUILD_BASE"

View File

@ -562,7 +562,6 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-28974/3.18/0008.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29371/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29661/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35508/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36386/^5.7/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0399/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0512/^5.10/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3178/3.18/0008.patch
@ -590,5 +589,5 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2017-7542/3.18/0003.patch
#git apply $DOS_PATCHES_LINUX_CVES/CVE-2017-15951/3.18/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-14283/3.18/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-0466/3.18/0003.patch
editKernelLocalversion "-dos.p590"
editKernelLocalversion "-dos.p589"
cd "$DOS_BUILD_BASE"

View File

@ -453,7 +453,6 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29661/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35508/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36158/3.18/0008.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36312/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36386/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0399/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0512/^5.10/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0605/3.18/0001.patch
@ -472,5 +471,5 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-30002/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2017-0610/ANY/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-14283/3.18/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-0466/3.18/0003.patch
editKernelLocalversion "-dos.p472"
editKernelLocalversion "-dos.p471"
cd "$DOS_BUILD_BASE"

View File

@ -518,7 +518,6 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29661/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35508/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36158/3.18/0008.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36312/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36386/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0399/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0512/^5.10/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0605/3.18/0001.patch
@ -538,5 +537,5 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2017-0610/ANY/0001.patch
#git apply $DOS_PATCHES_LINUX_CVES/CVE-2017-15951/3.18/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-14283/3.18/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-0466/3.18/0003.patch
editKernelLocalversion "-dos.p538"
editKernelLocalversion "-dos.p537"
cd "$DOS_BUILD_BASE"

View File

@ -290,7 +290,6 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35508/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35519/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36158/3.18/0008.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36312/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36386/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0399/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0512/^5.10/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0605/3.18/0001.patch
@ -310,5 +309,5 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-30002/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2017-0610/ANY/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-14283/3.18/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-0466/3.18/0003.patch
editKernelLocalversion "-dos.p310"
editKernelLocalversion "-dos.p309"
cd "$DOS_BUILD_BASE"

View File

@ -258,7 +258,6 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35508/4.9/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35519/4.9/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36158/4.9/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36312/4.9/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36386/4.9/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-UNKNOWN/ANY/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0399/4.9/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0512/^5.10/0001.patch
@ -308,5 +307,5 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-0466/4.9/0011.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-24586/4.9/0009.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29660/4.9/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3587/4.9/0005.patch
editKernelLocalversion "-dos.p308"
editKernelLocalversion "-dos.p307"
cd "$DOS_BUILD_BASE"

View File

@ -74,7 +74,6 @@ patchWorkspace() {
source build/envsetup.sh;
#repopick -it pie-firewall;
repopick -i 308977; #Backgrounds: Optimize builtin wallpaper loading code
repopick -it P_asb_2021-06;
source "$DOS_SCRIPTS/Patch.sh";

View File

@ -148,6 +148,9 @@ enterAndClear "lineage-sdk";
awk -i inplace '!/LineageWeatherManagerService/' lineage/res/res/values/config.xml; #Disable Weather
if [ "$DOS_DEBLOBBER_REMOVE_AUDIOFX" = true ]; then awk -i inplace '!/LineageAudioService/' lineage/res/res/values/config.xml; fi;
enterAndClear "packages/apps/Backgrounds";
patch -p1 < "$DOS_PATCHES_COMMON/android_packages_apps_Backgrounds/308977.patch"; #Optimize builtin wallpaper loading code
enterAndClear "packages/apps/Contacts";
patch -p1 < "$DOS_PATCHES_COMMON/android_packages_apps_Contacts/0001-No_Google_Links.patch"; #Remove Privacy Policy and Terms of Service links (GrapheneOS)

View File

@ -188,7 +188,6 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35508/4.9/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35519/4.9/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36158/4.9/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36312/4.9/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36386/4.9/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0512/^5.10/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0605/4.9/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3178/4.9/0005.patch
@ -238,5 +237,5 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-0466/4.9/0011.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-24586/4.9/0009.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29660/4.9/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3587/4.9/0005.patch
editKernelLocalversion "-dos.p238"
editKernelLocalversion "-dos.p237"
cd "$DOS_BUILD_BASE"

View File

@ -353,7 +353,6 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35508/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35519/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36158/3.18/0008.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36312/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36386/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0399/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0512/^5.10/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0605/3.18/0001.patch
@ -376,5 +375,5 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2016-5853/3.18/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2017-0610/ANY/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-14283/3.18/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-0466/3.18/0003.patch
editKernelLocalversion "-dos.p376"
editKernelLocalversion "-dos.p375"
cd "$DOS_BUILD_BASE"

View File

@ -231,7 +231,6 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35508/4.9/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35519/4.9/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36158/4.9/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36312/4.9/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36386/4.9/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-UNKNOWN/ANY/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0512/^5.10/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0605/4.9/0006.patch
@ -281,5 +280,5 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-0466/4.9/0011.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-24586/4.9/0009.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29660/4.9/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3587/4.9/0005.patch
editKernelLocalversion "-dos.p281"
editKernelLocalversion "-dos.p280"
cd "$DOS_BUILD_BASE"

View File

@ -409,7 +409,6 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29661/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35508/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36158/3.18/0008.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36312/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36386/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0399/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0512/^5.10/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0605/3.18/0001.patch
@ -429,5 +428,5 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-30002/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2017-0610/ANY/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-14283/3.18/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-0466/3.18/0003.patch
editKernelLocalversion "-dos.p429"
editKernelLocalversion "-dos.p428"
cd "$DOS_BUILD_BASE"

View File

@ -265,7 +265,6 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35508/4.19/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35519/4.19/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36158/4.19/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36312/4.19/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36386/4.19/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-BleedingToothExtras/^5.10/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-UNKNOWN/ANY/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0342/4.19/0002.patch
@ -321,5 +320,5 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-27830/4.19/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29660/4.19/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3428/4.19/0011.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3587/4.19/0003.patch
editKernelLocalversion "-dos.p321"
editKernelLocalversion "-dos.p320"
cd "$DOS_BUILD_BASE"

View File

@ -339,7 +339,6 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35508/4.14/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35519/4.14/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36158/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36312/4.14/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36386/4.14/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-BleedingToothExtras/^5.10/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-UNKNOWN/ANY/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0512/^5.10/0001.patch
@ -384,5 +383,5 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-0466/4.14/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-24586/4.14/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-27830/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29660/4.14/0002.patch
editKernelLocalversion "-dos.p384"
editKernelLocalversion "-dos.p383"
cd "$DOS_BUILD_BASE"

View File

@ -204,7 +204,6 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35508/4.4/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35519/4.4/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36158/4.4/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36312/4.4/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36386/4.4/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-UNKNOWN/ANY/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0399/4.4/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0512/^5.10/0001.patch
@ -254,5 +253,5 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-0429/4.4/0012.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-24586/4.4/0007.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29660/4.4/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3587/4.4/0004.patch
editKernelLocalversion "-dos.p254"
editKernelLocalversion "-dos.p253"
cd "$DOS_BUILD_BASE"

View File

@ -203,7 +203,6 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35508/4.4/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35519/4.4/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36158/4.4/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36312/4.4/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36386/4.4/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-UNKNOWN/ANY/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0399/4.4/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0512/^5.10/0001.patch
@ -253,5 +252,5 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-0429/4.4/0012.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-24586/4.4/0007.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29660/4.4/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3587/4.4/0004.patch
editKernelLocalversion "-dos.p253"
editKernelLocalversion "-dos.p252"
cd "$DOS_BUILD_BASE"

View File

@ -91,9 +91,8 @@ export -f buildAll;
patchWorkspace() {
if [ "$DOS_MALWARE_SCAN_ENABLED" = true ]; then scanForMalware false "$DOS_PREBUILT_APPS $DOS_BUILD_BASE/build $DOS_BUILD_BASE/device $DOS_BUILD_BASE/vendor/lineage"; fi;
source build/envsetup.sh;
#source build/envsetup.sh;
#repopick -it ten-firewall;
repopick -it Q_asb_2021-06;
source "$DOS_SCRIPTS/Patch.sh";
source "$DOS_SCRIPTS_COMMON/Copy_Keys.sh";

View File

@ -69,9 +69,6 @@ enterAndClear "device/qcom/sepolicy-legacy";
patch -p1 < "$DOS_PATCHES/android_device_qcom_sepolicy-legacy/0001-Camera_Fix.patch"; #Fix camera on -user builds XXX: REMOVE THIS TRASH
echo "SELINUX_IGNORE_NEVERALLOWS := true" >> sepolicy.mk; #necessary for -user builds of legacy devices
enterAndClear "external/chromium-libpac";
git pull "https://github.com/LineageOS/android_external_chromium-libpac" refs/changes/04/312104/1; #Q_asb_2021-06
enterAndClear "external/chromium-webview";
git pull "https://github.com/LineageOS/android_external_chromium-webview" refs/changes/11/310811/3; #update webview

View File

@ -1,6 +1,5 @@
#!/bin/bash
cd "$DOS_BUILD_BASE""kernel/essential/msm8998"
git apply $DOS_PATCHES_LINUX_CVES/0001-LinuxIncrementals/4.4/4.4.0271-0272.patch --exclude=Makefile
git apply $DOS_PATCHES_LINUX_CVES/0007-Accelerated_AES/3.10+/0016.patch
git apply $DOS_PATCHES_LINUX_CVES/0007-Accelerated_AES/3.10+/0020.patch
git apply $DOS_PATCHES_LINUX_CVES/0008-Graphene-Kernel_Hardening/4.4/0002.patch
@ -94,12 +93,9 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-15291/4.4/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-16994/^5.0/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-19051/4.4/0012.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-19068/4.4/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-11267/ANY/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-11267/ANY/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-11608/4.4/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-11608/^5.6.1/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-14386/3.10-^4.4/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-16119/^5.10/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36386/4.4/0005.patch
editKernelLocalversion "-dos.p101"
editKernelLocalversion "-dos.p97"
cd "$DOS_BUILD_BASE"

View File

@ -49,6 +49,5 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-11608/4.4/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-11608/^5.6.1/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-14386/3.10-^4.4/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-16119/^5.10/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36386/4.4/0005.patch
editKernelLocalversion "-dos.p50"
editKernelLocalversion "-dos.p49"
cd "$DOS_BUILD_BASE"

View File

@ -1,9 +1,6 @@
#!/bin/bash
cd "$DOS_BUILD_BASE""kernel/google/coral"
git apply $DOS_PATCHES_LINUX_CVES/0001-LinuxIncrementals/4.14/4.14.0201-0202.patch --exclude=Makefile
git apply $DOS_PATCHES_LINUX_CVES/0001-LinuxIncrementals/4.14/4.14.0205-0206.patch --exclude=Makefile
git apply $DOS_PATCHES_LINUX_CVES/0001-LinuxIncrementals/4.14/4.14.0207-0208.patch --exclude=Makefile
git apply $DOS_PATCHES_LINUX_CVES/0001-LinuxIncrementals/4.14/4.14.0210-0211.patch --exclude=Makefile
git apply $DOS_PATCHES_LINUX_CVES/0001-LinuxIncrementals/4.14/4.14.0216-0217.patch --exclude=Makefile
git apply $DOS_PATCHES_LINUX_CVES/0001-LinuxIncrementals/4.14/4.14.0219-0220.patch --exclude=Makefile
git apply $DOS_PATCHES_LINUX_CVES/0003-syzkaller-Misc/ANY/0008.patch
git apply $DOS_PATCHES_LINUX_CVES/0003-syzkaller-Misc2/ANY/0001.patch
@ -47,8 +44,6 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2017-18232/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2018-5897/ANY/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2018-9415/ANY/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2018-20855/^4.18.7/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-0145/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-0148/4.14/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-3874/ANY/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-9444/ANY/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-10520/ANY/0001.patch
@ -56,46 +51,33 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-11191/^5.0.7/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-12378/^5.1.5/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-12455/^5.1.5/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-12456/^5.1.5/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-14034/ANY/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-15291/4.14/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-16921/^4.17/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-19051/4.14/0008.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-19060/4.14/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-19068/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-19318/4.14/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-19602/^5.4.2/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-19816/4.14/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-20908/^5.4/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-11146/ANY/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-11608/4.14/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-11608/^5.6.1/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-12352/ANY/0011.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-14351/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-14386/4.14/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-15780/^5.7.7/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-16119/^5.10/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-24588/^5.12/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-25643/4.14/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-25645/4.14/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-25668/4.14/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-25670/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-25671/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-25672/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-25673/4.14/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-25704/4.14/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-26139/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-26147/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-26558/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-27170/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-27171/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-27777/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-27815/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-27825/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-28374/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-28915/4.14/0007.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-28915/4.14/0008.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-28915/4.14/0009.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-28941/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-28974/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29372/^5.7/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29374/4.14/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29568/4.14/0006.patch
@ -104,16 +86,8 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29568/4.14/0008.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29568/4.14/0009.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29568/4.14/0010.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29569/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29661/4.14/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35508/4.14/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36158/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36312/4.14/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36386/4.14/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-BleedingToothExtras/^5.10/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0512/^5.10/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0605/4.14/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0606/4.14/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3178/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3348/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3428/4.14/0007.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3428/4.14/0008.patch
@ -153,8 +127,6 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-32399/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-33033/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-33034/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-24586/4.14/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-27830/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29660/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3587/4.14/0002.patch
editKernelLocalversion "-dos.p156"
editKernelLocalversion "-dos.p128"
cd "$DOS_BUILD_BASE"

View File

@ -1,9 +1,6 @@
#!/bin/bash
cd "$DOS_BUILD_BASE""kernel/google/msm-4.9"
git apply $DOS_PATCHES_LINUX_CVES/0001-LinuxIncrementals/4.9/4.9.0239-0240.patch --exclude=Makefile
git apply $DOS_PATCHES_LINUX_CVES/0001-LinuxIncrementals/4.9/4.9.0242-0243.patch --exclude=Makefile
git apply $DOS_PATCHES_LINUX_CVES/0001-LinuxIncrementals/4.9/4.9.0244-0245.patch --exclude=Makefile
git apply $DOS_PATCHES_LINUX_CVES/0001-LinuxIncrementals/4.9/4.9.0247-0248.patch --exclude=Makefile
git apply $DOS_PATCHES_LINUX_CVES/0001-LinuxIncrementals/4.9/4.9.0252-0253.patch --exclude=Makefile
git apply $DOS_PATCHES_LINUX_CVES/0007-Accelerated_AES/3.10+/0016.patch
git apply $DOS_PATCHES_LINUX_CVES/0007-Accelerated_AES/3.10+/0020.patch
git apply $DOS_PATCHES_LINUX_CVES/0008-Graphene-Kernel_Hardening/4.9/0025.patch
@ -39,7 +36,6 @@ git apply $DOS_PATCHES_LINUX_CVES/0008-Graphene-Kernel_Hardening/4.9/0054.patch
git apply $DOS_PATCHES_LINUX_CVES/0008-Graphene-Kernel_Hardening/4.9/0055.patch
git apply $DOS_PATCHES_LINUX_CVES/0008-Graphene-Kernel_Hardening/4.9/0056.patch
git apply $DOS_PATCHES_LINUX_CVES/0008-Graphene-Kernel_Hardening/4.9/0057.patch
git apply $DOS_PATCHES_LINUX_CVES/0008-Graphene-Kernel_Hardening/4.9/0058.patch
git apply $DOS_PATCHES_LINUX_CVES/0008-Graphene-Kernel_Hardening/ANY/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2015-7837/ANY/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2016-3695/ANY/0001.patch
@ -59,9 +55,6 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2018-9415/ANY/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2018-9462/ANY/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2018-9519/ANY/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2018-20855/^4.18.7/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-0145/4.9/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-0148/4.9/0007.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-8912/^4.20.11/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-10503/ANY/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-12378/^5.1.5/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-12455/^5.1.5/0001.patch
@ -74,25 +67,18 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-16994/4.9/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-19051/4.9/0013.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-19060/4.9/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-19061/4.9/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-19068/4.9/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-19318/4.9/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-19813/4.9/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-19816/4.9/0007.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-20908/^5.4/0001.patch
#git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-0067/ANY/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-0427/4.9/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-3674/ANY/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-3693/ANY/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-11608/4.9/0007.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-11608/^5.6.1/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-12352/ANY/0011.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-14351/4.9/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-14386/4.9/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-16119/^5.10/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-24394/^5.7.8/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-24588/4.9/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-25643/4.9/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-25645/4.9/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-25668/4.9/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-25670/4.9/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-25671/4.9/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-25672/4.9/0005.patch
@ -102,10 +88,6 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-26147/4.9/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-26558/4.9/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-27815/4.9/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-27825/4.9/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-28915/4.9/0016.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-28915/4.9/0017.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-28915/4.9/0018.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-28974/4.9/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29368/4.9/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29568/4.9/0031.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29568/4.9/0032.patch
@ -113,13 +95,7 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29568/4.9/0033.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29568/4.9/0034.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29568/4.9/0035.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29569/4.9/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35508/4.9/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36158/4.9/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36312/4.9/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36386/4.9/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0512/^5.10/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0605/4.9/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3178/4.9/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3347/4.9/0036.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3347/4.9/0037.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3347/4.9/0038.patch
@ -164,5 +140,5 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-32399/4.9/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-33034/4.9/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-24586/4.9/0009.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3587/4.9/0005.patch
editKernelLocalversion "-dos.p164"
editKernelLocalversion "-dos.p140"
cd "$DOS_BUILD_BASE"

View File

@ -101,8 +101,6 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-10135/4.4/0011.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-10135/4.4/0012.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-10711/4.4/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-10766/4.4/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-11267/ANY/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-11267/ANY/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-11608/4.4/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-11608/^5.6.1/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-12352/3.6-^5.10/0001.patch
@ -113,7 +111,6 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-12769/4.4/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-12770/4.4/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-12771/4.4/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-13974/4.4/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-14305/4.4/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-14314/4.4/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-14331/4.4/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-14351/4.4/0004.patch
@ -156,9 +153,6 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35508/4.4/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35519/4.4/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36158/4.4/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36312/4.4/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36386/4.4/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0512/^5.10/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0605/4.4/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3178/4.4/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3347/4.4/0046.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3347/4.4/0047.patch
@ -202,5 +196,5 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-31916/4.4/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-32399/4.4/0007.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-24586/4.4/0007.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3587/4.4/0004.patch
editKernelLocalversion "-dos.p202"
editKernelLocalversion "-dos.p196"
cd "$DOS_BUILD_BASE"

View File

@ -441,7 +441,6 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29661/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35508/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36158/3.18/0008.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36312/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36386/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0399/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0512/^5.10/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0605/3.18/0001.patch
@ -460,5 +459,5 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-30002/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2017-0610/ANY/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-14283/3.18/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-0466/3.18/0003.patch
editKernelLocalversion "-dos.p460"
editKernelLocalversion "-dos.p459"
cd "$DOS_BUILD_BASE"

View File

@ -353,7 +353,6 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29661/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35508/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36158/3.18/0008.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36312/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36386/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0399/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0512/^5.10/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0605/3.18/0001.patch
@ -373,5 +372,5 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-30002/3.18/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2017-0610/ANY/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2019-14283/3.18/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-0466/3.18/0003.patch
editKernelLocalversion "-dos.p373"
editKernelLocalversion "-dos.p372"
cd "$DOS_BUILD_BASE"

View File

@ -53,7 +53,6 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-16119/^5.10/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-26139/4.4/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-26147/4.4/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-26558/4.4/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36386/4.4/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-1906/ANY/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3564/4.4/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-23133/4.4/0007.patch
@ -64,5 +63,5 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-31916/4.4/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-32399/4.4/0007.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-24586/4.4/0007.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3587/4.4/0004.patch
editKernelLocalversion "-dos.p64"
editKernelLocalversion "-dos.p63"
cd "$DOS_BUILD_BASE"

View File

@ -154,7 +154,6 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35508/4.9/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35519/4.9/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36158/4.9/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36312/4.9/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36386/4.9/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0512/^5.10/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0605/4.9/0006.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3178/4.9/0005.patch
@ -205,5 +204,5 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-0466/4.9/0011.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-24586/4.9/0009.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29660/4.9/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3587/4.9/0005.patch
editKernelLocalversion "-dos.p205"
editKernelLocalversion "-dos.p204"
cd "$DOS_BUILD_BASE"

View File

@ -132,7 +132,6 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29661/4.14/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-35508/4.14/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36158/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36312/4.14/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36386/4.14/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-BleedingToothExtras/^5.10/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0512/^5.10/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-0605/4.14/0003.patch
@ -181,5 +180,5 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-24586/4.14/0003.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-27830/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-29660/4.14/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-3587/4.14/0002.patch
editKernelLocalversion "-dos.p181"
editKernelLocalversion "-dos.p180"
cd "$DOS_BUILD_BASE"

View File

@ -51,9 +51,8 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-14386/3.10-^4.4/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-16119/^5.10/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-26139/4.4/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-26147/4.4/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36386/4.4/0005.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-29650/4.4/0004.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2021-32399/4.4/0007.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-24586/4.4/0007.patch
editKernelLocalversion "-dos.p55"
editKernelLocalversion "-dos.p54"
cd "$DOS_BUILD_BASE"

View File

@ -66,6 +66,5 @@ git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-11608/4.9/0007.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-11608/^5.6.1/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-16119/^5.10/0002.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-24394/^5.7.8/0001.patch
git apply $DOS_PATCHES_LINUX_CVES/CVE-2020-36386/4.9/0006.patch
editKernelLocalversion "-dos.p67"
editKernelLocalversion "-dos.p66"
cd "$DOS_BUILD_BASE"

View File

@ -103,11 +103,7 @@ export -f buildAll;
patchWorkspace() {
if [ "$DOS_MALWARE_SCAN_ENABLED" = true ]; then scanForMalware false "$DOS_PREBUILT_APPS $DOS_BUILD_BASE/build $DOS_BUILD_BASE/device $DOS_BUILD_BASE/vendor/lineage"; fi;
source build/envsetup.sh;
repopick -it a2dp-master-fixes;
repopick -i 311606 311607; #intent security fix
repopick -i 304614 312102; #apn fix
#repopick -it android-11.0.0_r38;
#source build/envsetup.sh;
source "$DOS_SCRIPTS/Patch.sh";
source "$DOS_SCRIPTS_COMMON/Copy_Keys.sh";

View File

@ -134,10 +134,14 @@ patch -p1 < "$DOS_PATCHES_COMMON/android_packages_apps_Contacts/0001-No_Google_L
enterAndClear "packages/apps/LineageParts";
rm -rf src/org/lineageos/lineageparts/lineagestats/ res/xml/anonymous_stats.xml res/xml/preview_data.xml; #Nuke part of the analytics
patch -p1 < "$DOS_PATCHES/android_packages_apps_LineageParts/0001-Remove_Analytics.patch"; #Remove analytics
patch -p1 < "$DOS_PATCHES/android_packages_apps_LineageParts/311606.patch"; #intent security fix
enterAndClear "packages/apps/PermissionController";
if [ "$DOS_MICROG_INCLUDED" = "FULL" ]; then patch -p1 < "$DOS_PATCHES/android_packages_apps_PermissionController/0001-Signature_Spoofing.patch"; fi; #Allow packages to spoof their signature (microG)
enterAndClear "packages/apps/Recorder";
patch -p1 < "$DOS_PATCHES/android_packages_apps_Recorder/311607.patch"; #intent security fix
enterAndClear "packages/apps/Settings";
sed -i 's/if (isFullDiskEncrypted()) {/if (false) {/' src/com/android/settings/accessibility/*AccessibilityService*.java; #Never disable secure start-up when enabling an accessibility service
if [ "$DOS_MICROG_INCLUDED" = "FULL" ]; then sed -i 's/GSETTINGS_PROVIDER = "com.google.settings";/GSETTINGS_PROVIDER = "com.google.oQuae4av";/' src/com/android/settings/backup/PrivacySettingsUtils.java; fi; #microG doesn't support Backup, hide the options
@ -157,10 +161,17 @@ sed -i 's/PROP_BUILD_VERSION_INCREMENTAL);/PROP_BUILD_VERSION_INCREMENTAL).repla
enterAndClear "packages/inputmethods/LatinIME";
patch -p1 < "$DOS_PATCHES_COMMON/android_packages_inputmethods_LatinIME/0001-Voice.patch"; #Remove voice input key
enterAndClear "packages/providers/TelephonyProvider";
patch -p1 < "$DOS_PATCHES/android_packages_providers_TelephonyProvider/304614.patch"; #mcc/mnc fix
patch -p1 < "$DOS_PATCHES/android_packages_providers_TelephonyProvider/312102.patch"; #mnc fix
#enterAndClear "packages/services/Telephony";
#patch -p1 < "$DOS_PATCHES/android_packages_services_Telephony/0001-PREREQ_Handle_All_Modes.patch"; #XXX 18REBASE
#patch -p1 < "$DOS_PATCHES/android_packages_services_Telephony/0002-More_Preferred_Network_Modes.patch"; #XXX 18REBASE
enterAndClear "system/bt";
patch -p1 < "$DOS_PATCHES/android_system_bt/a2dp-master-fixes.patch"; #topic
enterAndClear "system/core";
if [ "$DOS_HOSTS_BLOCKING" = true ]; then cat "$DOS_HOSTS_FILE" >> rootdir/etc/hosts; fi; #Merge in our HOSTS file
git revert --no-edit e8dcabaf6b55ec55eb73c4585501ddbafc04fc9b 79f606ece6b74652d374eb4f79de309a0aa81360; #insanity
@ -237,6 +248,9 @@ enableVerity; #Resurrect dm-verity
enterAndClear "device/htc/m8-common";
awk -i inplace '!/TARGET_RELEASETOOLS_EXTENSIONS/' BoardConfigCommon.mk; #broken releasetools
enterAndClear "device/htc/msm8974-common";
patch -p1 < "$DOS_PATCHES/android_device_htc_msm8974-common/312412.patch"; #shim all the rils
enterAndClear "device/lge/g2-common";
sed -i '3itypeattribute hwaddrs misc_block_device_exception;' sepolicy/hwaddrs.te;
awk -i inplace '!/TARGET_RELEASETOOLS_EXTENSIONS/' BoardConfigCommon.mk; #broken releasetools