MCPcopy Create free account
hub / github.com/Vector35/binaryninja-api / image_to_api

Function image_to_api

view/sharedcache/api/python/sharedcache.py:82–92  ·  view source on GitHub ↗
(image: CacheImage)

Source from the content-addressed store, hash-verified

80 )
81
82def image_to_api(image: CacheImage) -> sccore.BNSharedCacheImage:
83 region_start_array = (ctypes.c_ulonglong * len(image.region_starts))()
84 for i, region_start in enumerate(image.region_starts):
85 region_start_array[i] = region_start
86 core_region_starts = sccore.BNSharedCacheAllocRegionList(region_start_array, len(region_start_array))
87 return sccore.BNSharedCacheImage(
88 _name=BNAllocString(image.name),
89 headerAddress=image.header_address,
90 regionStartCount=len(region_start_array),
91 regionStarts=core_region_starts
92 )
93
94def symbol_from_api(symbol: sccore.BNSharedCacheSymbol) -> CacheSymbol:
95 return CacheSymbol(

Callers 3

apply_imageMethod · 0.85
is_image_loadedMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected