angr 9.2.102__py3-none-manylinux2014_x86_64.whl → 9.2.104__py3-none-manylinux2014_x86_64.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of angr might be problematic. Click here for more details.
- angr/__init__.py +1 -1
- angr/analyses/analysis.py +7 -6
- angr/analyses/calling_convention.py +33 -35
- angr/analyses/cdg.py +2 -4
- angr/analyses/cfg/cfb.py +4 -3
- angr/analyses/cfg/cfg_base.py +14 -14
- angr/analyses/cfg/cfg_emulated.py +3 -4
- angr/analyses/cfg/cfg_fast.py +46 -46
- angr/analyses/cfg/cfg_fast_soot.py +1 -2
- angr/analyses/cfg/cfg_job_base.py +2 -2
- angr/analyses/cfg/indirect_jump_resolvers/jumptable.py +14 -13
- angr/analyses/cfg/indirect_jump_resolvers/mips_elf_fast.py +5 -5
- angr/analyses/cfg_slice_to_sink/cfg_slice_to_sink.py +3 -3
- angr/analyses/complete_calling_conventions.py +13 -12
- angr/analyses/data_dep/data_dependency_analysis.py +24 -24
- angr/analyses/data_dep/dep_nodes.py +3 -3
- angr/analyses/ddg.py +1 -2
- angr/analyses/decompiler/ail_simplifier.py +35 -34
- angr/analyses/decompiler/block_io_finder.py +20 -20
- angr/analyses/decompiler/block_similarity.py +4 -6
- angr/analyses/decompiler/block_simplifier.py +17 -16
- angr/analyses/decompiler/callsite_maker.py +25 -10
- angr/analyses/decompiler/ccall_rewriters/amd64_ccalls.py +1 -3
- angr/analyses/decompiler/ccall_rewriters/rewriter_base.py +2 -4
- angr/analyses/decompiler/clinic.py +250 -45
- angr/analyses/decompiler/condition_processor.py +15 -8
- angr/analyses/decompiler/decompilation_cache.py +7 -7
- angr/analyses/decompiler/decompilation_options.py +4 -4
- angr/analyses/decompiler/decompiler.py +19 -15
- angr/analyses/decompiler/expression_counters.py +10 -9
- angr/analyses/decompiler/goto_manager.py +2 -4
- angr/analyses/decompiler/graph_region.py +9 -9
- angr/analyses/decompiler/jump_target_collector.py +1 -2
- angr/analyses/decompiler/optimization_passes/__init__.py +4 -3
- angr/analyses/decompiler/optimization_passes/code_motion.py +5 -6
- angr/analyses/decompiler/optimization_passes/const_derefs.py +4 -4
- angr/analyses/decompiler/optimization_passes/deadblock_remover.py +73 -0
- angr/analyses/decompiler/optimization_passes/engine_base.py +25 -3
- angr/analyses/decompiler/optimization_passes/expr_op_swapper.py +6 -5
- angr/analyses/decompiler/optimization_passes/flip_boolean_cmp.py +2 -2
- angr/analyses/decompiler/optimization_passes/inlined_string_transformation_simplifier.py +3 -0
- angr/analyses/decompiler/optimization_passes/ite_expr_converter.py +2 -2
- angr/analyses/decompiler/optimization_passes/lowered_switch_simplifier.py +17 -17
- angr/analyses/decompiler/optimization_passes/optimization_pass.py +12 -13
- angr/analyses/decompiler/optimization_passes/register_save_area_simplifier.py +25 -21
- angr/analyses/decompiler/optimization_passes/ret_addr_save_simplifier.py +3 -3
- angr/analyses/decompiler/optimization_passes/ret_deduplicator.py +1 -2
- angr/analyses/decompiler/optimization_passes/return_duplicator_base.py +7 -7
- angr/analyses/decompiler/optimization_passes/spilled_register_finder.py +18 -0
- angr/analyses/decompiler/optimization_passes/stack_canary_simplifier.py +2 -3
- angr/analyses/decompiler/optimization_passes/win_stack_canary_simplifier.py +1 -2
- angr/analyses/decompiler/optimization_passes/x86_gcc_getpc_simplifier.py +2 -2
- angr/analyses/decompiler/peephole_optimizations/__init__.py +4 -3
- angr/analyses/decompiler/peephole_optimizations/base.py +13 -15
- angr/analyses/decompiler/peephole_optimizations/bswap.py +1 -3
- angr/analyses/decompiler/peephole_optimizations/cmpord_rewriter.py +72 -0
- angr/analyses/decompiler/peephole_optimizations/const_mull_a_shift.py +1 -2
- angr/analyses/decompiler/peephole_optimizations/eager_eval.py +1 -1
- angr/analyses/decompiler/peephole_optimizations/inlined_strcpy.py +5 -10
- angr/analyses/decompiler/peephole_optimizations/inlined_strcpy_consolidation.py +3 -4
- angr/analyses/decompiler/peephole_optimizations/inlined_wstrcpy.py +7 -10
- angr/analyses/decompiler/peephole_optimizations/rewrite_bit_extractions.py +2 -3
- angr/analyses/decompiler/peephole_optimizations/sar_to_signed_div.py +1 -2
- angr/analyses/decompiler/peephole_optimizations/tidy_stack_addr.py +4 -4
- angr/analyses/decompiler/redundant_label_remover.py +4 -5
- angr/analyses/decompiler/region_identifier.py +4 -5
- angr/analyses/decompiler/region_simplifiers/cascading_cond_transformer.py +1 -2
- angr/analyses/decompiler/region_simplifiers/expr_folding.py +19 -20
- angr/analyses/decompiler/region_simplifiers/goto.py +2 -3
- angr/analyses/decompiler/region_simplifiers/loop.py +1 -2
- angr/analyses/decompiler/region_simplifiers/node_address_finder.py +1 -2
- angr/analyses/decompiler/region_simplifiers/region_simplifier.py +1 -3
- angr/analyses/decompiler/region_simplifiers/switch_cluster_simplifier.py +19 -19
- angr/analyses/decompiler/return_maker.py +1 -2
- angr/analyses/decompiler/structured_codegen/base.py +5 -6
- angr/analyses/decompiler/structured_codegen/c.py +39 -38
- angr/analyses/decompiler/structuring/__init__.py +1 -1
- angr/analyses/decompiler/structuring/dream.py +17 -16
- angr/analyses/decompiler/structuring/phoenix.py +45 -46
- angr/analyses/decompiler/structuring/recursive_structurer.py +4 -4
- angr/analyses/decompiler/structuring/structurer_base.py +16 -15
- angr/analyses/decompiler/structuring/structurer_nodes.py +10 -9
- angr/analyses/decompiler/utils.py +17 -16
- angr/analyses/disassembly.py +7 -6
- angr/analyses/flirt.py +9 -9
- angr/analyses/forward_analysis/forward_analysis.py +15 -14
- angr/analyses/forward_analysis/visitors/function_graph.py +1 -2
- angr/analyses/forward_analysis/visitors/graph.py +16 -15
- angr/analyses/propagator/engine_ail.py +30 -26
- angr/analyses/propagator/outdated_definition_walker.py +8 -7
- angr/analyses/propagator/propagator.py +11 -13
- angr/analyses/proximity_graph.py +21 -21
- angr/analyses/reaching_definitions/__init__.py +3 -3
- angr/analyses/reaching_definitions/call_trace.py +3 -6
- angr/analyses/reaching_definitions/dep_graph.py +41 -48
- angr/analyses/reaching_definitions/engine_ail.py +11 -5
- angr/analyses/reaching_definitions/engine_vex.py +9 -8
- angr/analyses/reaching_definitions/function_handler.py +51 -34
- angr/analyses/reaching_definitions/heap_allocator.py +3 -4
- angr/analyses/reaching_definitions/rd_initializer.py +8 -8
- angr/analyses/reaching_definitions/rd_state.py +57 -58
- angr/analyses/reaching_definitions/reaching_definitions.py +18 -17
- angr/analyses/reaching_definitions/subject.py +2 -3
- angr/analyses/stack_pointer_tracker.py +15 -6
- angr/analyses/typehoon/dfa.py +4 -4
- angr/analyses/typehoon/simple_solver.py +48 -52
- angr/analyses/typehoon/translator.py +3 -6
- angr/analyses/typehoon/typeconsts.py +13 -14
- angr/analyses/typehoon/typehoon.py +9 -9
- angr/analyses/typehoon/typevars.py +18 -17
- angr/analyses/variable_recovery/engine_ail.py +5 -5
- angr/analyses/variable_recovery/engine_base.py +25 -21
- angr/analyses/variable_recovery/irsb_scanner.py +8 -9
- angr/analyses/variable_recovery/variable_recovery.py +1 -2
- angr/analyses/variable_recovery/variable_recovery_base.py +14 -13
- angr/analyses/variable_recovery/variable_recovery_fast.py +8 -8
- angr/analyses/veritesting.py +1 -2
- angr/analyses/vfg.py +57 -56
- angr/analyses/xrefs.py +1 -2
- angr/angrdb/db.py +7 -7
- angr/angrdb/serializers/kb.py +16 -13
- angr/angrdb/serializers/loader.py +1 -2
- angr/angrdb/serializers/structured_code.py +2 -2
- angr/annocfg.py +1 -2
- angr/block.py +16 -6
- angr/calling_conventions.py +28 -27
- angr/code_location.py +8 -8
- angr/codenode.py +1 -2
- angr/concretization_strategies/max.py +1 -3
- angr/distributed/server.py +1 -3
- angr/distributed/worker.py +1 -2
- angr/engines/engine.py +2 -3
- angr/engines/light/engine.py +4 -4
- angr/engines/pcode/behavior.py +20 -2
- angr/engines/pcode/emulate.py +1 -1
- angr/engines/pcode/engine.py +7 -7
- angr/engines/pcode/lifter.py +78 -77
- angr/engines/vex/claripy/ccall.py +1 -2
- angr/engines/vex/claripy/datalayer.py +1 -2
- angr/engines/vex/light/light.py +1 -2
- angr/exploration_techniques/tracer.py +4 -4
- angr/factory.py +12 -15
- angr/flirt/__init__.py +8 -8
- angr/flirt/build_sig.py +2 -3
- angr/keyed_region.py +2 -2
- angr/knowledge_base/knowledge_base.py +3 -3
- angr/knowledge_plugins/callsite_prototypes.py +4 -6
- angr/knowledge_plugins/cfg/cfg_manager.py +19 -6
- angr/knowledge_plugins/cfg/cfg_model.py +26 -27
- angr/knowledge_plugins/cfg/cfg_node.py +2 -2
- angr/knowledge_plugins/cfg/indirect_jump.py +6 -8
- angr/knowledge_plugins/cfg/memory_data.py +8 -9
- angr/knowledge_plugins/custom_strings.py +1 -3
- angr/knowledge_plugins/debug_variables.py +2 -2
- angr/knowledge_plugins/functions/function.py +21 -22
- angr/knowledge_plugins/functions/function_manager.py +5 -5
- angr/knowledge_plugins/indirect_jumps.py +1 -3
- angr/knowledge_plugins/key_definitions/atoms.py +7 -7
- angr/knowledge_plugins/key_definitions/definition.py +14 -14
- angr/knowledge_plugins/key_definitions/environment.py +5 -7
- angr/knowledge_plugins/key_definitions/heap_address.py +1 -3
- angr/knowledge_plugins/key_definitions/key_definition_manager.py +3 -2
- angr/knowledge_plugins/key_definitions/live_definitions.py +60 -59
- angr/knowledge_plugins/key_definitions/liveness.py +16 -16
- angr/knowledge_plugins/key_definitions/rd_model.py +15 -15
- angr/knowledge_plugins/key_definitions/uses.py +11 -11
- angr/knowledge_plugins/patches.py +4 -8
- angr/knowledge_plugins/propagations/prop_value.py +10 -9
- angr/knowledge_plugins/propagations/propagation_manager.py +3 -5
- angr/knowledge_plugins/propagations/propagation_model.py +9 -9
- angr/knowledge_plugins/propagations/states.py +52 -22
- angr/knowledge_plugins/structured_code/manager.py +2 -2
- angr/knowledge_plugins/sync/sync_controller.py +3 -3
- angr/knowledge_plugins/variables/variable_access.py +4 -4
- angr/knowledge_plugins/variables/variable_manager.py +39 -39
- angr/knowledge_plugins/xrefs/xref.py +9 -11
- angr/knowledge_plugins/xrefs/xref_manager.py +3 -4
- angr/misc/ansi.py +1 -2
- angr/misc/autoimport.py +3 -3
- angr/misc/plugins.py +9 -9
- angr/procedures/definitions/__init__.py +16 -16
- angr/procedures/definitions/linux_kernel.py +1 -1
- angr/procedures/definitions/parse_win32json.py +1 -1
- angr/procedures/java_jni/__init__.py +1 -1
- angr/procedures/java_jni/array_operations.py +1 -2
- angr/procedures/java_jni/method_calls.py +1 -2
- angr/procedures/posix/inet_ntoa.py +1 -2
- angr/procedures/stubs/format_parser.py +3 -3
- angr/project.py +13 -11
- angr/sim_manager.py +12 -12
- angr/sim_procedure.py +7 -3
- angr/sim_state.py +2 -2
- angr/sim_type.py +60 -45
- angr/sim_variable.py +5 -5
- angr/simos/simos.py +1 -2
- angr/simos/userland.py +1 -2
- angr/state_plugins/callstack.py +3 -2
- angr/state_plugins/history.py +1 -2
- angr/state_plugins/solver.py +34 -34
- angr/storage/memory_mixins/__init__.py +4 -3
- angr/storage/memory_mixins/actions_mixin.py +1 -3
- angr/storage/memory_mixins/address_concretization_mixin.py +1 -3
- angr/storage/memory_mixins/convenient_mappings_mixin.py +3 -4
- angr/storage/memory_mixins/default_filler_mixin.py +1 -1
- angr/storage/memory_mixins/label_merger_mixin.py +2 -2
- angr/storage/memory_mixins/multi_value_merger_mixin.py +4 -3
- angr/storage/memory_mixins/paged_memory/page_backer_mixins.py +9 -8
- angr/storage/memory_mixins/paged_memory/paged_memory_mixin.py +12 -11
- angr/storage/memory_mixins/paged_memory/pages/cooperation.py +8 -8
- angr/storage/memory_mixins/paged_memory/pages/history_tracking_mixin.py +2 -3
- angr/storage/memory_mixins/paged_memory/pages/list_page.py +10 -11
- angr/storage/memory_mixins/paged_memory/pages/multi_values.py +11 -10
- angr/storage/memory_mixins/paged_memory/pages/mv_list_page.py +18 -17
- angr/storage/memory_mixins/paged_memory/pages/ultra_page.py +12 -11
- angr/storage/memory_mixins/regioned_memory/abstract_address_descriptor.py +3 -3
- angr/storage/memory_mixins/regioned_memory/abstract_merger_mixin.py +3 -2
- angr/storage/memory_mixins/regioned_memory/region_data.py +1 -2
- angr/storage/memory_mixins/regioned_memory/region_meta_mixin.py +2 -2
- angr/storage/memory_mixins/regioned_memory/regioned_address_concretization_mixin.py +3 -3
- angr/storage/memory_mixins/regioned_memory/regioned_memory_mixin.py +18 -21
- angr/storage/memory_mixins/size_resolution_mixin.py +1 -2
- angr/storage/memory_mixins/symbolic_merger_mixin.py +3 -2
- angr/storage/memory_mixins/top_merger_mixin.py +3 -2
- angr/storage/memory_object.py +2 -4
- angr/utils/algo.py +3 -2
- angr/utils/dynamic_dictlist.py +5 -5
- angr/utils/formatting.py +4 -4
- angr/utils/funcid.py +1 -2
- angr/utils/graph.py +5 -6
- angr/utils/library.py +5 -5
- angr/utils/mp.py +5 -4
- angr/utils/segment_list.py +3 -4
- angr/utils/typing.py +3 -2
- {angr-9.2.102.dist-info → angr-9.2.104.dist-info}/METADATA +9 -11
- {angr-9.2.102.dist-info → angr-9.2.104.dist-info}/RECORD +239 -236
- {angr-9.2.102.dist-info → angr-9.2.104.dist-info}/LICENSE +0 -0
- {angr-9.2.102.dist-info → angr-9.2.104.dist-info}/WHEEL +0 -0
- {angr-9.2.102.dist-info → angr-9.2.104.dist-info}/entry_points.txt +0 -0
- {angr-9.2.102.dist-info → angr-9.2.104.dist-info}/top_level.txt +0 -0
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
from typing import TYPE_CHECKING,
|
|
1
|
+
from typing import TYPE_CHECKING, cast, Literal
|
|
2
|
+
from collections.abc import Iterable, Callable
|
|
2
3
|
from dataclasses import dataclass, field
|
|
3
4
|
import logging
|
|
4
5
|
from functools import wraps
|
|
@@ -7,7 +8,7 @@ from cle.backends import ELF
|
|
|
7
8
|
import claripy
|
|
8
9
|
|
|
9
10
|
from angr.storage.memory_mixins.paged_memory.pages.multi_values import MultiValues
|
|
10
|
-
from angr.sim_type import SimTypeBottom
|
|
11
|
+
from angr.sim_type import SimTypeBottom, dereference_simtype
|
|
11
12
|
from angr.knowledge_plugins.key_definitions.atoms import Atom, Register, MemoryLocation, SpOffset
|
|
12
13
|
from angr.knowledge_plugins.key_definitions.tag import Tag
|
|
13
14
|
from angr.calling_conventions import SimCC
|
|
@@ -17,6 +18,7 @@ from angr.knowledge_plugins.functions import Function
|
|
|
17
18
|
from angr.analyses.reaching_definitions.dep_graph import FunctionCallRelationships
|
|
18
19
|
from angr.code_location import CodeLocation, ExternalCodeLocation
|
|
19
20
|
from angr.knowledge_plugins.key_definitions.constants import ObservationPointType
|
|
21
|
+
from angr import SIM_LIBRARIES, SIM_TYPE_COLLECTIONS
|
|
20
22
|
|
|
21
23
|
|
|
22
24
|
if TYPE_CHECKING:
|
|
@@ -51,12 +53,12 @@ class FunctionEffect:
|
|
|
51
53
|
`FunctionCallData.depends` instead.
|
|
52
54
|
"""
|
|
53
55
|
|
|
54
|
-
dest:
|
|
55
|
-
sources:
|
|
56
|
-
value:
|
|
57
|
-
sources_defns:
|
|
56
|
+
dest: Atom | None
|
|
57
|
+
sources: set[Atom]
|
|
58
|
+
value: MultiValues | None = None
|
|
59
|
+
sources_defns: set[Definition] | None = None
|
|
58
60
|
apply_at_callsite: bool = False
|
|
59
|
-
tags:
|
|
61
|
+
tags: set[Tag] | None = None
|
|
60
62
|
|
|
61
63
|
|
|
62
64
|
@dataclass
|
|
@@ -83,21 +85,21 @@ class FunctionCallData:
|
|
|
83
85
|
|
|
84
86
|
callsite_codeloc: CodeLocation
|
|
85
87
|
function_codeloc: CodeLocation
|
|
86
|
-
address_multi:
|
|
87
|
-
address:
|
|
88
|
-
symbol:
|
|
89
|
-
function:
|
|
90
|
-
name:
|
|
91
|
-
cc:
|
|
92
|
-
prototype:
|
|
93
|
-
args_atoms:
|
|
94
|
-
args_values:
|
|
95
|
-
ret_atoms:
|
|
88
|
+
address_multi: MultiValues | None
|
|
89
|
+
address: int | None = None
|
|
90
|
+
symbol: Symbol | None = None
|
|
91
|
+
function: Function | None = None
|
|
92
|
+
name: str | None = None
|
|
93
|
+
cc: SimCC | None = None
|
|
94
|
+
prototype: SimTypeFunction | None = None
|
|
95
|
+
args_atoms: list[set[Atom]] | None = None
|
|
96
|
+
args_values: list[MultiValues] | None = None
|
|
97
|
+
ret_atoms: set[Atom] | None = None
|
|
96
98
|
redefine_locals: bool = True
|
|
97
|
-
visited_blocks:
|
|
98
|
-
effects:
|
|
99
|
-
ret_values:
|
|
100
|
-
ret_values_deps:
|
|
99
|
+
visited_blocks: set[int] | None = None
|
|
100
|
+
effects: list[FunctionEffect] = field(default_factory=lambda: [])
|
|
101
|
+
ret_values: MultiValues | None = None
|
|
102
|
+
ret_values_deps: set[Definition] | None = None
|
|
101
103
|
caller_will_handle_single_ret: bool = False
|
|
102
104
|
guessed_cc: bool = False
|
|
103
105
|
guessed_prototype: bool = False
|
|
@@ -135,11 +137,11 @@ class FunctionCallData:
|
|
|
135
137
|
|
|
136
138
|
def depends(
|
|
137
139
|
self,
|
|
138
|
-
dest:
|
|
139
|
-
*sources:
|
|
140
|
-
value:
|
|
140
|
+
dest: Atom | Iterable[Atom] | None,
|
|
141
|
+
*sources: Atom | Iterable[Atom],
|
|
142
|
+
value: MultiValues | claripy.ast.BV | bytes | int | None = None,
|
|
141
143
|
apply_at_callsite: bool = False,
|
|
142
|
-
tags:
|
|
144
|
+
tags: set[Tag] | None = None,
|
|
143
145
|
):
|
|
144
146
|
"""
|
|
145
147
|
Mark a single effect of the current function, including the atom being modified, the input atoms on which that
|
|
@@ -186,7 +188,7 @@ class FunctionCallData:
|
|
|
186
188
|
|
|
187
189
|
def reset_prototype(
|
|
188
190
|
self, prototype: SimTypeFunction, state: "ReachingDefinitionsState", soft_reset: bool = False
|
|
189
|
-
) ->
|
|
191
|
+
) -> set[Atom]:
|
|
190
192
|
self.prototype = prototype.with_arch(state.arch)
|
|
191
193
|
if not soft_reset:
|
|
192
194
|
self.args_atoms = self.args_values = self.ret_atoms = None
|
|
@@ -222,9 +224,9 @@ class FunctionCallDataUnwrapped(FunctionCallData):
|
|
|
222
224
|
name: str
|
|
223
225
|
cc: SimCC
|
|
224
226
|
prototype: SimTypeFunction
|
|
225
|
-
args_atoms:
|
|
226
|
-
args_values:
|
|
227
|
-
ret_atoms:
|
|
227
|
+
args_atoms: list[set[Atom]]
|
|
228
|
+
args_values: list[MultiValues]
|
|
229
|
+
ret_atoms: set[Atom]
|
|
228
230
|
|
|
229
231
|
def __init__(self, inner: FunctionCallData):
|
|
230
232
|
d = dict(inner.__dict__)
|
|
@@ -268,7 +270,7 @@ class FunctionHandler:
|
|
|
268
270
|
return self
|
|
269
271
|
|
|
270
272
|
def make_function_codeloc(
|
|
271
|
-
self, target:
|
|
273
|
+
self, target: None | int | MultiValues, callsite: CodeLocation, callsite_func_addr: int | None
|
|
272
274
|
):
|
|
273
275
|
"""
|
|
274
276
|
The RDA engine will call this function to transform a callsite CodeLocation into a callee CodeLocation.
|
|
@@ -329,6 +331,7 @@ class FunctionHandler:
|
|
|
329
331
|
data.cc = data.function.calling_convention
|
|
330
332
|
if data.prototype is None and data.function is not None:
|
|
331
333
|
data.prototype = data.function.prototype
|
|
334
|
+
hook_libname = None
|
|
332
335
|
if data.address is not None and (data.cc is None or data.prototype is None):
|
|
333
336
|
hook = (
|
|
334
337
|
None
|
|
@@ -348,6 +351,7 @@ class FunctionHandler:
|
|
|
348
351
|
if data.prototype is None and hook is not None:
|
|
349
352
|
data.prototype = hook.prototype.with_arch(state.arch)
|
|
350
353
|
data.guessed_prototype = hook.guessed_prototype
|
|
354
|
+
hook_libname = hook.library_name
|
|
351
355
|
|
|
352
356
|
# fallback to the default calling convention and prototype
|
|
353
357
|
if data.cc is None:
|
|
@@ -357,6 +361,19 @@ class FunctionHandler:
|
|
|
357
361
|
data.prototype = state.analysis.project.factory.function_prototype()
|
|
358
362
|
data.guessed_prototype = True
|
|
359
363
|
|
|
364
|
+
if data.prototype is not None and data.function is not None:
|
|
365
|
+
# make sure the function prototype is resolved.
|
|
366
|
+
# TODO: Cache resolved function prototypes globally
|
|
367
|
+
prototype_libname = data.function.prototype_libname or hook_libname
|
|
368
|
+
type_collections = []
|
|
369
|
+
if prototype_libname is not None:
|
|
370
|
+
prototype_lib = SIM_LIBRARIES[prototype_libname]
|
|
371
|
+
if prototype_lib.type_collection_names:
|
|
372
|
+
for typelib_name in prototype_lib.type_collection_names:
|
|
373
|
+
type_collections.append(SIM_TYPE_COLLECTIONS[typelib_name])
|
|
374
|
+
if type_collections:
|
|
375
|
+
data.prototype = dereference_simtype(data.prototype, type_collections).with_arch(state.arch)
|
|
376
|
+
|
|
360
377
|
args_atoms_from_values = data.reset_prototype(data.prototype, state, soft_reset=True)
|
|
361
378
|
|
|
362
379
|
# PROCESS
|
|
@@ -512,7 +529,7 @@ class FunctionHandler:
|
|
|
512
529
|
# get_exit_livedefinitions is currently only using ret_sites, but an argument could be made that it should
|
|
513
530
|
# include jumpout sites as well. In the CFG generation tail call sites seem to be treated as return sites
|
|
514
531
|
# and not as jumpout sites, so we are following that convention here.
|
|
515
|
-
return_observation_points:
|
|
532
|
+
return_observation_points: list[ObservationPoint] = [
|
|
516
533
|
(
|
|
517
534
|
cast(Literal["node"], "node"), # pycharm doesn't treat a literal string, as Literal[] by default...
|
|
518
535
|
block.addr,
|
|
@@ -540,7 +557,7 @@ class FunctionHandler:
|
|
|
540
557
|
data.retaddr_popped = True
|
|
541
558
|
|
|
542
559
|
@staticmethod
|
|
543
|
-
def c_args_as_atoms(state: "ReachingDefinitionsState", cc: SimCC, prototype: SimTypeFunction) ->
|
|
560
|
+
def c_args_as_atoms(state: "ReachingDefinitionsState", cc: SimCC, prototype: SimTypeFunction) -> list[set[Atom]]:
|
|
544
561
|
if not prototype.variadic:
|
|
545
562
|
sp_value = state.get_one_value(Register(state.arch.sp_offset, state.arch.bytes), strip_annotations=True)
|
|
546
563
|
sp = state.get_stack_offset(sp_value) if sp_value is not None else None
|
|
@@ -563,7 +580,7 @@ class FunctionHandler:
|
|
|
563
580
|
return [{Register(*state.arch.registers[arg_name], arch=state.arch)} for arg_name in cc.ARG_REGS]
|
|
564
581
|
|
|
565
582
|
@staticmethod
|
|
566
|
-
def c_return_as_atoms(state: "ReachingDefinitionsState", cc: SimCC, prototype: SimTypeFunction) ->
|
|
583
|
+
def c_return_as_atoms(state: "ReachingDefinitionsState", cc: SimCC, prototype: SimTypeFunction) -> set[Atom]:
|
|
567
584
|
if prototype.returnty is not None and not isinstance(prototype.returnty, SimTypeBottom):
|
|
568
585
|
retval = cc.return_val(prototype.returnty)
|
|
569
586
|
if retval is not None:
|
|
@@ -574,7 +591,7 @@ class FunctionHandler:
|
|
|
574
591
|
return set()
|
|
575
592
|
|
|
576
593
|
@staticmethod
|
|
577
|
-
def caller_saved_regs_as_atoms(state: "ReachingDefinitionsState", cc: SimCC) ->
|
|
594
|
+
def caller_saved_regs_as_atoms(state: "ReachingDefinitionsState", cc: SimCC) -> set[Register]:
|
|
578
595
|
return (
|
|
579
596
|
{Register(*state.arch.registers[reg], arch=state.arch) for reg in cc.CALLER_SAVED_REGS}
|
|
580
597
|
if cc.CALLER_SAVED_REGS is not None
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import logging
|
|
2
2
|
|
|
3
|
-
from typing import Union, List
|
|
4
3
|
|
|
5
4
|
from ...knowledge_plugins.key_definitions.heap_address import HeapAddress
|
|
6
5
|
from ...knowledge_plugins.key_definitions.unknown_size import UnknownSize
|
|
@@ -26,10 +25,10 @@ class HeapAllocator:
|
|
|
26
25
|
:param canonical_size: The concrete size an <UNKNOWN_SIZE> defaults to.
|
|
27
26
|
"""
|
|
28
27
|
self._next_heap_address: HeapAddress = HeapAddress(0)
|
|
29
|
-
self._allocated_addresses:
|
|
28
|
+
self._allocated_addresses: list[HeapAddress] = [self._next_heap_address]
|
|
30
29
|
self._canonical_size: int = canonical_size
|
|
31
30
|
|
|
32
|
-
def allocate(self, size:
|
|
31
|
+
def allocate(self, size: int | UnknownSize) -> HeapAddress:
|
|
33
32
|
"""
|
|
34
33
|
Gives an address for a new memory chunck of <size> bytes.
|
|
35
34
|
|
|
@@ -45,7 +44,7 @@ class HeapAllocator:
|
|
|
45
44
|
|
|
46
45
|
return address
|
|
47
46
|
|
|
48
|
-
def free(self, address:
|
|
47
|
+
def free(self, address: Undefined | HeapAddress):
|
|
49
48
|
"""
|
|
50
49
|
Mark the chunck pointed by <address> as freed.
|
|
51
50
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import logging
|
|
2
|
-
from typing import
|
|
2
|
+
from typing import TYPE_CHECKING
|
|
3
3
|
|
|
4
4
|
import claripy
|
|
5
5
|
from archinfo import Arch
|
|
@@ -38,7 +38,7 @@ class RDAStateInitializer:
|
|
|
38
38
|
self.project = project
|
|
39
39
|
|
|
40
40
|
def initialize_function_state(
|
|
41
|
-
self, state: "ReachingDefinitionsState", cc:
|
|
41
|
+
self, state: "ReachingDefinitionsState", cc: SimCC | None, func_addr: int, rtoc_value: int | None = None
|
|
42
42
|
) -> None:
|
|
43
43
|
"""
|
|
44
44
|
This is the entry point to the state initialization logic.
|
|
@@ -71,8 +71,8 @@ class RDAStateInitializer:
|
|
|
71
71
|
state: "ReachingDefinitionsState",
|
|
72
72
|
func_addr: int,
|
|
73
73
|
ex_loc: ExternalCodeLocation,
|
|
74
|
-
cc:
|
|
75
|
-
prototype:
|
|
74
|
+
cc: SimCC | None,
|
|
75
|
+
prototype: SimTypeFunction | None,
|
|
76
76
|
) -> None:
|
|
77
77
|
"""
|
|
78
78
|
This method handles the setup for _all_ arguments of a function.
|
|
@@ -96,7 +96,7 @@ class RDAStateInitializer:
|
|
|
96
96
|
func_addr: int,
|
|
97
97
|
ex_loc: ExternalCodeLocation,
|
|
98
98
|
argument_location: SimFunctionArgument,
|
|
99
|
-
argument_type:
|
|
99
|
+
argument_type: SimType | None = None,
|
|
100
100
|
) -> None:
|
|
101
101
|
"""
|
|
102
102
|
This method handles the setup for _one_ argument of a function.
|
|
@@ -133,7 +133,7 @@ class RDAStateInitializer:
|
|
|
133
133
|
state: "ReachingDefinitionsState",
|
|
134
134
|
func_addr: int,
|
|
135
135
|
ex_loc: ExternalCodeLocation,
|
|
136
|
-
rtoc_value:
|
|
136
|
+
rtoc_value: int | None = None,
|
|
137
137
|
) -> None:
|
|
138
138
|
"""
|
|
139
139
|
Some architectures require initialization that is specific to that architecture.
|
|
@@ -191,7 +191,7 @@ class RDAStateInitializer:
|
|
|
191
191
|
func_addr: int,
|
|
192
192
|
ex_loc: ExternalCodeLocation,
|
|
193
193
|
arg: SimRegArg,
|
|
194
|
-
value:
|
|
194
|
+
value: claripy.ast.Base | None = None,
|
|
195
195
|
):
|
|
196
196
|
# FIXME: implement reg_offset handling in SimRegArg
|
|
197
197
|
reg_offset = self.arch.registers[arg.reg_name][0]
|
|
@@ -218,7 +218,7 @@ class RDAStateInitializer:
|
|
|
218
218
|
state.stack.store(stack_address, ml, endness=self.arch.memory_endness)
|
|
219
219
|
|
|
220
220
|
@staticmethod
|
|
221
|
-
def _generate_call_string(subject: Subject, current_address: int) ->
|
|
221
|
+
def _generate_call_string(subject: Subject, current_address: int) -> tuple[int, ...] | None:
|
|
222
222
|
if isinstance(subject.content, Function):
|
|
223
223
|
return (subject.content.addr,)
|
|
224
224
|
elif isinstance(subject.content, CallTrace):
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
from typing import Optional,
|
|
1
|
+
from typing import Optional, Any, TYPE_CHECKING, overload
|
|
2
|
+
from collections.abc import Iterable, Iterator
|
|
2
3
|
import logging
|
|
3
4
|
|
|
4
5
|
import archinfo
|
|
@@ -84,12 +85,12 @@ class ReachingDefinitionsState:
|
|
|
84
85
|
track_consts: bool = False,
|
|
85
86
|
analysis: Optional["ReachingDefinitionsAnalysis"] = None,
|
|
86
87
|
rtoc_value=None,
|
|
87
|
-
live_definitions:
|
|
88
|
+
live_definitions: LiveDefinitions | None = None,
|
|
88
89
|
canonical_size: int = 8,
|
|
89
90
|
heap_allocator: HeapAllocator = None,
|
|
90
91
|
environment: Environment = None,
|
|
91
92
|
sp_adjusted: bool = False,
|
|
92
|
-
all_definitions:
|
|
93
|
+
all_definitions: set[Definition] | None = None,
|
|
93
94
|
initializer: Optional["RDAStateInitializer"] = None,
|
|
94
95
|
element_limit: int = 5,
|
|
95
96
|
):
|
|
@@ -104,12 +105,12 @@ class ReachingDefinitionsState:
|
|
|
104
105
|
self._sp_adjusted: bool = sp_adjusted
|
|
105
106
|
self._element_limit: int = element_limit
|
|
106
107
|
|
|
107
|
-
self.all_definitions:
|
|
108
|
+
self.all_definitions: set[Definition] = set() if all_definitions is None else all_definitions
|
|
108
109
|
|
|
109
110
|
self.heap_allocator = heap_allocator or HeapAllocator(canonical_size)
|
|
110
111
|
self._environment: Environment = environment or Environment()
|
|
111
112
|
|
|
112
|
-
self.codeloc_uses:
|
|
113
|
+
self.codeloc_uses: set[Definition] = set()
|
|
113
114
|
|
|
114
115
|
# have we observed an exit statement or not during the analysis of the *last instruction* of a block? we should
|
|
115
116
|
# not perform any sp updates if it is the case. this is for handling conditional returns in ARM binaries.
|
|
@@ -149,7 +150,7 @@ class ReachingDefinitionsState:
|
|
|
149
150
|
def is_top(self, *args):
|
|
150
151
|
return self.live_definitions.is_top(*args)
|
|
151
152
|
|
|
152
|
-
def heap_address(self, offset:
|
|
153
|
+
def heap_address(self, offset: int | HeapAddress) -> claripy.ast.BV:
|
|
153
154
|
return self.live_definitions.heap_address(offset)
|
|
154
155
|
|
|
155
156
|
@staticmethod
|
|
@@ -157,7 +158,7 @@ class ReachingDefinitionsState:
|
|
|
157
158
|
return LiveDefinitions.is_heap_address(addr)
|
|
158
159
|
|
|
159
160
|
@staticmethod
|
|
160
|
-
def get_heap_offset(addr: claripy.ast.Base) ->
|
|
161
|
+
def get_heap_offset(addr: claripy.ast.Base) -> int | None:
|
|
161
162
|
return LiveDefinitions.get_heap_offset(addr)
|
|
162
163
|
|
|
163
164
|
def stack_address(self, offset: int) -> claripy.ast.BV:
|
|
@@ -166,7 +167,7 @@ class ReachingDefinitionsState:
|
|
|
166
167
|
def is_stack_address(self, addr: claripy.ast.Base) -> bool:
|
|
167
168
|
return self.live_definitions.is_stack_address(addr)
|
|
168
169
|
|
|
169
|
-
def get_stack_offset(self, addr: claripy.ast.Base) ->
|
|
170
|
+
def get_stack_offset(self, addr: claripy.ast.Base) -> int | None:
|
|
170
171
|
offset = self.live_definitions.get_stack_offset(addr)
|
|
171
172
|
if offset is not None:
|
|
172
173
|
return self._to_signed(offset)
|
|
@@ -278,8 +279,8 @@ class ReachingDefinitionsState:
|
|
|
278
279
|
def _set_initialization_values(
|
|
279
280
|
self,
|
|
280
281
|
subject: Subject,
|
|
281
|
-
rtoc_value:
|
|
282
|
-
initializer:
|
|
282
|
+
rtoc_value: int | None = None,
|
|
283
|
+
initializer: RDAStateInitializer | None = None,
|
|
283
284
|
project=None,
|
|
284
285
|
):
|
|
285
286
|
if initializer is None:
|
|
@@ -321,7 +322,7 @@ class ReachingDefinitionsState:
|
|
|
321
322
|
|
|
322
323
|
return rd
|
|
323
324
|
|
|
324
|
-
def merge(self, *others) ->
|
|
325
|
+
def merge(self, *others) -> tuple["ReachingDefinitionsState", bool]:
|
|
325
326
|
state = self.copy()
|
|
326
327
|
others: Iterable["ReachingDefinitionsState"]
|
|
327
328
|
|
|
@@ -358,12 +359,12 @@ class ReachingDefinitionsState:
|
|
|
358
359
|
atom: Atom,
|
|
359
360
|
data: MultiValues,
|
|
360
361
|
dummy=False,
|
|
361
|
-
tags:
|
|
362
|
+
tags: set[Tag] = None,
|
|
362
363
|
endness=None, # XXX destroy
|
|
363
364
|
annotated: bool = False,
|
|
364
|
-
uses:
|
|
365
|
-
override_codeloc:
|
|
366
|
-
) ->
|
|
365
|
+
uses: set[Definition] | None = None,
|
|
366
|
+
override_codeloc: CodeLocation | None = None,
|
|
367
|
+
) -> tuple[MultiValues | None, set[Definition]]:
|
|
367
368
|
codeloc = override_codeloc or self.codeloc
|
|
368
369
|
existing_defs = self.live_definitions.get_definitions(atom)
|
|
369
370
|
mv = self.live_definitions.kill_and_add_definition(
|
|
@@ -439,86 +440,84 @@ class ReachingDefinitionsState:
|
|
|
439
440
|
|
|
440
441
|
return mv, defs
|
|
441
442
|
|
|
442
|
-
def add_use(self, atom: Atom, expr:
|
|
443
|
+
def add_use(self, atom: Atom, expr: Any | None = None) -> None:
|
|
443
444
|
self.codeloc_uses.update(self.get_definitions(atom))
|
|
444
445
|
self.live_definitions.add_use(atom, self.codeloc, expr=expr)
|
|
445
446
|
|
|
446
|
-
def add_use_by_def(self, definition: Definition, expr:
|
|
447
|
+
def add_use_by_def(self, definition: Definition, expr: Any | None = None) -> None:
|
|
447
448
|
self.codeloc_uses.add(definition)
|
|
448
449
|
self.live_definitions.add_use_by_def(definition, self.codeloc, expr=expr)
|
|
449
450
|
|
|
450
|
-
def add_tmp_use(self, tmp: int, expr:
|
|
451
|
+
def add_tmp_use(self, tmp: int, expr: Any | None = None) -> None:
|
|
451
452
|
defs = self.live_definitions.get_tmp_definitions(tmp)
|
|
452
453
|
self.add_tmp_use_by_defs(defs, expr=expr)
|
|
453
454
|
|
|
454
455
|
def add_tmp_use_by_defs(
|
|
455
|
-
self, defs: Iterable[Definition], expr:
|
|
456
|
+
self, defs: Iterable[Definition], expr: Any | None = None
|
|
456
457
|
) -> None: # pylint:disable=unused-argument
|
|
457
458
|
for definition in defs:
|
|
458
459
|
self.codeloc_uses.add(definition)
|
|
459
460
|
# if track_tmps is False, definitions may not be Tmp definitions
|
|
460
461
|
self.live_definitions.add_use_by_def(definition, self.codeloc, expr=expr)
|
|
461
462
|
|
|
462
|
-
def add_register_use(self, reg_offset: int, size: int, expr:
|
|
463
|
+
def add_register_use(self, reg_offset: int, size: int, expr: Any | None = None) -> None:
|
|
463
464
|
defs = self.live_definitions.get_register_definitions(reg_offset, size)
|
|
464
465
|
self.add_register_use_by_defs(defs, expr=expr)
|
|
465
466
|
|
|
466
|
-
def add_register_use_by_defs(self, defs: Iterable[Definition], expr:
|
|
467
|
+
def add_register_use_by_defs(self, defs: Iterable[Definition], expr: Any | None = None) -> None:
|
|
467
468
|
for definition in defs:
|
|
468
469
|
self.codeloc_uses.add(definition)
|
|
469
470
|
self.live_definitions.add_register_use_by_def(definition, self.codeloc, expr=expr)
|
|
470
471
|
|
|
471
|
-
def add_stack_use(self, stack_offset: int, size: int, expr:
|
|
472
|
+
def add_stack_use(self, stack_offset: int, size: int, expr: Any | None = None) -> None:
|
|
472
473
|
defs = self.live_definitions.get_stack_definitions(stack_offset, size)
|
|
473
474
|
self.add_stack_use_by_defs(defs, expr=expr)
|
|
474
475
|
|
|
475
|
-
def add_stack_use_by_defs(self, defs: Iterable[Definition], expr:
|
|
476
|
+
def add_stack_use_by_defs(self, defs: Iterable[Definition], expr: Any | None = None):
|
|
476
477
|
for definition in defs:
|
|
477
478
|
self.codeloc_uses.add(definition)
|
|
478
479
|
self.live_definitions.add_stack_use_by_def(definition, self.codeloc, expr=expr)
|
|
479
480
|
|
|
480
|
-
def add_heap_use(self, heap_offset: int, size: int, expr:
|
|
481
|
+
def add_heap_use(self, heap_offset: int, size: int, expr: Any | None = None) -> None:
|
|
481
482
|
defs = self.live_definitions.get_heap_definitions(heap_offset, size)
|
|
482
483
|
self.add_heap_use_by_defs(defs, expr=expr)
|
|
483
484
|
|
|
484
|
-
def add_heap_use_by_defs(self, defs: Iterable[Definition], expr:
|
|
485
|
+
def add_heap_use_by_defs(self, defs: Iterable[Definition], expr: Any | None = None):
|
|
485
486
|
for definition in defs:
|
|
486
487
|
self.codeloc_uses.add(definition)
|
|
487
488
|
self.live_definitions.add_heap_use_by_def(definition, self.codeloc, expr=expr)
|
|
488
489
|
|
|
489
|
-
def add_memory_use_by_def(self, definition: Definition, expr:
|
|
490
|
+
def add_memory_use_by_def(self, definition: Definition, expr: Any | None = None):
|
|
490
491
|
self.codeloc_uses.add(definition)
|
|
491
492
|
self.live_definitions.add_memory_use_by_def(definition, self.codeloc, expr=expr)
|
|
492
493
|
|
|
493
|
-
def add_memory_use_by_defs(self, defs: Iterable[Definition], expr:
|
|
494
|
+
def add_memory_use_by_defs(self, defs: Iterable[Definition], expr: Any | None = None):
|
|
494
495
|
for definition in defs:
|
|
495
496
|
self.codeloc_uses.add(definition)
|
|
496
497
|
self.live_definitions.add_memory_use_by_def(definition, self.codeloc, expr=expr)
|
|
497
498
|
|
|
498
|
-
def get_definitions(self, atom:
|
|
499
|
+
def get_definitions(self, atom: Atom | Definition | Iterable[Atom] | Iterable[Definition]) -> set[Definition]:
|
|
499
500
|
return self.live_definitions.get_definitions(atom)
|
|
500
501
|
|
|
501
|
-
def get_values(self, spec:
|
|
502
|
+
def get_values(self, spec: Atom | Definition | Iterable[Atom]) -> MultiValues | None:
|
|
502
503
|
return self.live_definitions.get_values(spec)
|
|
503
504
|
|
|
504
|
-
def get_one_value(
|
|
505
|
-
self, spec: Union[Atom, Definition], strip_annotations: bool = False
|
|
506
|
-
) -> Optional[claripy.ast.bv.BV]:
|
|
505
|
+
def get_one_value(self, spec: Atom | Definition, strip_annotations: bool = False) -> claripy.ast.bv.BV | None:
|
|
507
506
|
return self.live_definitions.get_one_value(spec, strip_annotations=strip_annotations)
|
|
508
507
|
|
|
509
508
|
@overload
|
|
510
509
|
def get_concrete_value(
|
|
511
|
-
self, spec:
|
|
512
|
-
) ->
|
|
510
|
+
self, spec: Atom | Definition[Atom] | Iterable[Atom], cast_to: type[int] = ...
|
|
511
|
+
) -> int | None: ...
|
|
513
512
|
|
|
514
513
|
@overload
|
|
515
514
|
def get_concrete_value(
|
|
516
|
-
self, spec:
|
|
517
|
-
) ->
|
|
515
|
+
self, spec: Atom | Definition[Atom] | Iterable[Atom], cast_to: type[bytes] = ...
|
|
516
|
+
) -> bytes | None: ...
|
|
518
517
|
|
|
519
518
|
def get_concrete_value(
|
|
520
|
-
self, spec:
|
|
521
|
-
) ->
|
|
519
|
+
self, spec: Atom | Definition[Atom] | Iterable[Atom], cast_to: type[int] | type[bytes] = int
|
|
520
|
+
) -> int | bytes | None:
|
|
522
521
|
return self.live_definitions.get_concrete_value(spec, cast_to)
|
|
523
522
|
|
|
524
523
|
def mark_guard(self, target):
|
|
@@ -544,7 +543,7 @@ class ReachingDefinitionsState:
|
|
|
544
543
|
self.live_definitions.reset_uses()
|
|
545
544
|
|
|
546
545
|
@deprecated("deref")
|
|
547
|
-
def pointer_to_atoms(self, pointer: MultiValues, size: int, endness: str) ->
|
|
546
|
+
def pointer_to_atoms(self, pointer: MultiValues, size: int, endness: str) -> set[MemoryLocation]:
|
|
548
547
|
"""
|
|
549
548
|
Given a MultiValues, return the set of atoms that loading or storing to the pointer with that value
|
|
550
549
|
could define or use.
|
|
@@ -559,7 +558,7 @@ class ReachingDefinitionsState:
|
|
|
559
558
|
return result
|
|
560
559
|
|
|
561
560
|
@deprecated("deref")
|
|
562
|
-
def pointer_to_atom(self, value: claripy.ast.base.Base, size: int, endness: str) ->
|
|
561
|
+
def pointer_to_atom(self, value: claripy.ast.base.Base, size: int, endness: str) -> MemoryLocation | None:
|
|
563
562
|
if self.is_top(value):
|
|
564
563
|
return None
|
|
565
564
|
|
|
@@ -582,33 +581,33 @@ class ReachingDefinitionsState:
|
|
|
582
581
|
@overload
|
|
583
582
|
def deref(
|
|
584
583
|
self,
|
|
585
|
-
pointer:
|
|
586
|
-
size:
|
|
584
|
+
pointer: int | claripy.ast.bv.BV | HeapAddress | SpOffset,
|
|
585
|
+
size: int | DerefSize,
|
|
587
586
|
endness: str = ...,
|
|
588
|
-
) ->
|
|
587
|
+
) -> MemoryLocation | None: ...
|
|
589
588
|
|
|
590
589
|
@overload
|
|
591
590
|
def deref(
|
|
592
591
|
self,
|
|
593
|
-
pointer:
|
|
594
|
-
size:
|
|
592
|
+
pointer: MultiValues | Atom | Definition | Iterable[Atom] | Iterable[Definition],
|
|
593
|
+
size: int | DerefSize,
|
|
595
594
|
endness: str = ...,
|
|
596
|
-
) ->
|
|
595
|
+
) -> set[MemoryLocation]: ...
|
|
597
596
|
|
|
598
597
|
def deref(
|
|
599
598
|
self,
|
|
600
|
-
pointer:
|
|
601
|
-
MultiValues
|
|
602
|
-
Atom
|
|
603
|
-
Definition
|
|
604
|
-
Iterable[Atom]
|
|
605
|
-
Iterable[Definition]
|
|
606
|
-
int
|
|
607
|
-
claripy.ast.BV
|
|
608
|
-
HeapAddress
|
|
609
|
-
SpOffset
|
|
610
|
-
|
|
611
|
-
size:
|
|
599
|
+
pointer: (
|
|
600
|
+
MultiValues
|
|
601
|
+
| Atom
|
|
602
|
+
| Definition
|
|
603
|
+
| Iterable[Atom]
|
|
604
|
+
| Iterable[Definition]
|
|
605
|
+
| int
|
|
606
|
+
| claripy.ast.BV
|
|
607
|
+
| HeapAddress
|
|
608
|
+
| SpOffset
|
|
609
|
+
),
|
|
610
|
+
size: int | DerefSize,
|
|
612
611
|
endness: str = archinfo.Endness.BE,
|
|
613
612
|
):
|
|
614
613
|
return self.live_definitions.deref(pointer, size, endness)
|