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

Unverified Commit 6eb2eeae authored by Michael Bestas's avatar Michael Bestas
Browse files

Merge tag 'android-13.0.0_r13' into staging/lineage-20.0_merge-android-13.0.0_r13

Android 13.0.0 release 13

# -----BEGIN PGP SIGNATURE-----
#
# iF0EABECAB0WIQRDQNE1cO+UXoOBCWTorT+BmrEOeAUCY2mYmAAKCRDorT+BmrEO
# eKafAJwPsWsDThPMNLAOSN/nurdINjGw6wCfTWOqhvi75rGHSfwTQFIg65WNu5A=
# =BnOG
# -----END PGP SIGNATURE-----
# gpg: Signature made Tue Nov  8 01:45:28 2022 EET
# gpg:                using DSA key 4340D13570EF945E83810964E8AD3F819AB10E78
# gpg: Good signature from "The Android Open Source Project <initial-contribution@android.com>" [marginal]
# gpg: initial-contribution@android.com: Verified 1370 signatures in the past
#      12 months.  Encrypted 4 messages in the past 10 months.
# gpg: WARNING: This key is not certified with sufficiently trusted signatures!
# gpg:          It is not certain that the signature belongs to the owner.
# Primary key fingerprint: 4340 D135 70EF 945E 8381  0964 E8AD 3F81 9AB1 0E78

# By Edwin Wong (1) and Wonsik Kim (1)
# Via Android Build Coastguard Worker
* tag 'android-13.0.0_r13':
  FrameDecoder: fix 180 rotation for HDR thumbnails
  [Fix vulnerability] setSecurityLevel in clearkey

Change-Id: I9aa6672c0c2d808c8447262cb1e4a88e33820495
parents 44880aa3 bc8ac069
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -619,6 +619,7 @@ Return<void> DrmPlugin::getSecurityLevel(const hidl_vec<uint8_t>& sessionId,
        return Void();
    }

    Mutex::Autolock lock(mSecurityLevelLock);
    std::map<std::vector<uint8_t>, SecurityLevel>::iterator itr =
            mSecurityLevel.find(sid);
    if (itr == mSecurityLevel.end()) {
@@ -691,6 +692,7 @@ Return<Status> DrmPlugin::setSecurityLevel(const hidl_vec<uint8_t>& sessionId,
        return Status::ERROR_DRM_SESSION_NOT_OPENED;
    }

    Mutex::Autolock lock(mSecurityLevelLock);
    std::map<std::vector<uint8_t>, SecurityLevel>::iterator itr =
            mSecurityLevel.find(sid);
    if (itr != mSecurityLevel.end()) {
+3 −1
Original line number Diff line number Diff line
@@ -414,7 +414,8 @@ private:
    std::map<std::string, std::vector<uint8_t> > mByteArrayProperties;
    std::map<std::string, std::vector<uint8_t> > mReleaseKeysMap;
    std::map<std::vector<uint8_t>, std::string> mPlaybackId;
    std::map<std::vector<uint8_t>, SecurityLevel> mSecurityLevel;
    std::map<std::vector<uint8_t>, SecurityLevel> mSecurityLevel
        GUARDED_BY(mSecurityLevelLock);
    sp<IDrmPluginListener> mListener;
    sp<IDrmPluginListener_V1_2> mListenerV1_2;
    SessionLibrary *mSessionLibrary;
@@ -434,6 +435,7 @@ private:

    DeviceFiles mFileHandle;
    Mutex mSecureStopLock;
    Mutex mSecurityLevelLock;

    CLEARKEY_DISALLOW_COPY_AND_ASSIGN_AND_NEW(DrmPlugin);
};
+8 −5
Original line number Diff line number Diff line
@@ -86,11 +86,14 @@ sp<IMemory> allocVideoFrame(const sp<MetaData>& trackMeta,
        displayHeight = height;
    }

    if (allocRotated && (rotationAngle == 90 || rotationAngle == 270)) {
        int32_t tmp;
        tmp = width; width = height; height = tmp;
        tmp = displayWidth; displayWidth = displayHeight; displayHeight = tmp;
        tmp = tileWidth; tileWidth = tileHeight; tileHeight = tmp;
    if (allocRotated) {
        if (rotationAngle == 90 || rotationAngle == 270) {
            // swap width and height for 90 & 270 degrees rotation
            std::swap(width, height);
            std::swap(displayWidth, displayHeight);
            std::swap(tileWidth, tileHeight);
        }
        // Rotation is already applied.
        rotationAngle = 0;
    }