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

Commit 1248e620 authored by Jeff Tinker's avatar Jeff Tinker Committed by android-build-merger
Browse files

Fix integer overflow in mediadrmserver am: eb21712f am: 5250bc1b am: d1a854a0 am: 7a22df06

am: 4e339cbc

Change-Id: I8519bf3be2231d04e5ec8d245ee083730cd4cd7d
parents 3899cc3c 4e339cbc
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -109,7 +109,7 @@ android::status_t InitDataParser::parsePssh(const Vector<uint8_t>& initData,
    memcpy(&keyIdCount, &initData[readPosition], sizeof(keyIdCount));
    keyIdCount = ntohl(keyIdCount);
    readPosition += sizeof(keyIdCount);
    if (readPosition + (keyIdCount * kKeyIdSize) !=
    if (readPosition + ((uint64_t)keyIdCount * kKeyIdSize) !=
            initData.size() - sizeof(uint32_t)) {
        return android::ERROR_DRM_CANNOT_HANDLE;
    }