diff options
| author | kat <kat@vector35.com> | 2024-11-04 10:22:23 -0500 |
|---|---|---|
| committer | kat <kat@vector35.com> | 2024-11-05 09:05:30 -0500 |
| commit | 519477fbc78b1a29d752c26e7933dfe16e80d360 (patch) | |
| tree | 2253350fad64b0423490e8174560f39418bd9ffb /view/sharedcache/core/ObjC.cpp | |
| parent | df5f53a638ca91b6c5be05d84f76adb157353883 (diff) | |
[SharedCache] Barebones sanity check on ivar list size
Diffstat (limited to 'view/sharedcache/core/ObjC.cpp')
| -rw-r--r-- | view/sharedcache/core/ObjC.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/view/sharedcache/core/ObjC.cpp b/view/sharedcache/core/ObjC.cpp index 265506c2..271e5c94 100644 --- a/view/sharedcache/core/ObjC.cpp +++ b/view/sharedcache/core/ObjC.cpp @@ -889,6 +889,11 @@ void DSCObjCProcessor::ReadIvarList(VMReader* reader, ClassBase& cls, std::strin head.count = reader->Read32(); auto addressSize = m_data->GetAddressSize(); DefineObjCSymbol(DataSymbol, m_typeNames.ivarList, "ivar_list_" + name, start, true); + if (head.count > 0x1000) + { + m_logger->LogError("Ivar list at 0x%llx has an invalid count of 0x%llx", start, head.count); + return; + } for (unsigned i = 0; i < head.count; i++) { try |
