[llvm-branch-commits] [compiler-rt] release/19.x: [PAC][compiler-rt][UBSan] Strip signed vptr instead of authenticating it (#100153) (PR #100219)
via llvm-branch-commits
llvm-branch-commits at lists.llvm.org
Tue Jul 23 14:46:49 PDT 2024
llvmbot wrote:
<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-compiler-rt-sanitizer
Author: None (llvmbot)
<details>
<summary>Changes</summary>
Backport 0a6a3c152faf56e07dd4f9e89e534d2b97eeab56
Requested by: @<!-- -->asl
---
Full diff: https://github.com/llvm/llvm-project/pull/100219.diff
1 Files Affected:
- (modified) compiler-rt/lib/ubsan/ubsan_type_hash_itanium.cpp (+1-1)
``````````diff
diff --git a/compiler-rt/lib/ubsan/ubsan_type_hash_itanium.cpp b/compiler-rt/lib/ubsan/ubsan_type_hash_itanium.cpp
index 468a8fcd603f0..15788574dd995 100644
--- a/compiler-rt/lib/ubsan/ubsan_type_hash_itanium.cpp
+++ b/compiler-rt/lib/ubsan/ubsan_type_hash_itanium.cpp
@@ -207,7 +207,7 @@ struct VtablePrefix {
std::type_info *TypeInfo;
};
VtablePrefix *getVtablePrefix(void *Vtable) {
- Vtable = ptrauth_auth_data(Vtable, ptrauth_key_cxx_vtable_pointer, 0);
+ Vtable = ptrauth_strip(Vtable, ptrauth_key_cxx_vtable_pointer);
VtablePrefix *Vptr = reinterpret_cast<VtablePrefix*>(Vtable);
VtablePrefix *Prefix = Vptr - 1;
if (!IsAccessibleMemoryRange((uptr)Prefix, sizeof(VtablePrefix)))
``````````
</details>
https://github.com/llvm/llvm-project/pull/100219
More information about the llvm-branch-commits
mailing list