Bug 208873

Summary: Update WTF/WeakLinking.h to work reliably in the face of pointer signing
Product: WebKit Reporter: Sam Weinig <sam>
Component: New BugsAssignee: Sam Weinig <sam>
Status: RESOLVED CONFIGURATION CHANGED    
Severity: Normal CC: benjamin, cdumez, cmarcelo, eric.carlson, ews-watchlist, glenn, hta, jer.noble, mitz, philipj, sergio, tommyw
Priority: P2    
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch none

Description Sam Weinig 2020-03-10 11:54:27 PDT
Update WTF/WeakLinking.h to work reliably in the face of pointer signing
Comment 1 Sam Weinig 2020-03-10 12:03:35 PDT
Created attachment 393171 [details]
Patch
Comment 2 mitz 2020-03-10 12:06:23 PDT
Comment on attachment 393171 [details]
Patch

Nice decrease in code size, too!
Comment 3 mitz 2020-03-11 08:33:16 PDT
Perhaps not as elegant, but to meet the requirement of working with C++ member functions, which can’t be redeclared, you could take an alternate approach of just employing ptrauth_strip(…, ptrauth_key_function_pointer) in the existing isNullFunctionPointer.
Comment 4 Sam Weinig 2020-03-11 14:35:05 PDT
Created attachment 393288 [details]
Patch