[webkit-changes] [WebKit/WebKit] bab444: CRASH in CDMInstanceSessionClearKey::requestLicense()
Jer Noble
noreply at github.com
Tue Feb 25 14:41:12 PST 2025
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: bab44461e2fb01e440683597c93800efe4bec399
https://github.com/WebKit/WebKit/commit/bab44461e2fb01e440683597c93800efe4bec399
Author: Jer Noble <jer.noble at apple.com>
Date: 2025-02-25 (Tue, 25 Feb 2025)
Changed paths:
M Source/WebCore/platform/encryptedmedia/clearkey/CDMClearKey.cpp
M Source/WebCore/platform/encryptedmedia/clearkey/CDMClearKey.h
Log Message:
-----------
CRASH in CDMInstanceSessionClearKey::requestLicense()
rdar://145358917
https://bugs.webkit.org/show_bug.cgi?id=288498
Reviewed by Eric Carlson.
`cdmInstanceProxy()` will return a WeakPtr, and since both that class
and CDMInstanceSessionClearKey are reference-counted, their lifetimes
can become decoupled. It is therefore unsafe to dereference that `WeakPtr`
without a null-check. Separately, CDMInstanceClearKey is type specialized
and should be using dynamicDowncast rather than a statci_cast.
* Source/WebCore/platform/encryptedmedia/clearkey/CDMClearKey.cpp:
(WebCore::CDMInstanceSessionClearKey::updateLicense):
(WebCore::CDMInstanceSessionClearKey::protectedParentInstance const):
(WebCore::CDMInstanceSessionClearKey::parentInstance const): Deleted.
* Source/WebCore/platform/encryptedmedia/clearkey/CDMClearKey.h:
Canonical link: https://commits.webkit.org/291062@main
To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications
More information about the webkit-changes
mailing list