angr 9.2.120__py3-none-win_amd64.whl → 9.2.122__py3-none-win_amd64.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/cfg/cfg_fast.py +2 -1
- angr/analyses/cfg/indirect_jump_resolvers/__init__.py +2 -0
- angr/analyses/cfg/indirect_jump_resolvers/default_resolvers.py +2 -0
- angr/analyses/cfg/indirect_jump_resolvers/jumptable.py +10 -6
- angr/analyses/cfg/indirect_jump_resolvers/mips_elf_fast.py +138 -367
- angr/analyses/cfg/indirect_jump_resolvers/mips_elf_got.py +148 -0
- angr/analyses/decompiler/callsite_maker.py +11 -1
- angr/analyses/decompiler/ccall_rewriters/amd64_ccalls.py +20 -0
- angr/analyses/typehoon/typevars.py +37 -16
- angr/angrdb/db.py +1 -1
- angr/block.py +9 -1
- angr/calling_conventions.py +1 -1
- angr/engines/engine.py +8 -15
- angr/engines/pcode/lifter.py +8 -0
- angr/engines/successors.py +1 -1
- angr/engines/vex/claripy/ccall.py +1 -1
- angr/engines/vex/claripy/datalayer.py +7 -10
- angr/engines/vex/heavy/actions.py +19 -24
- angr/engines/vex/heavy/heavy.py +7 -1
- angr/engines/vex/lifter.py +3 -1
- angr/engines/vex/light/light.py +2 -2
- angr/factory.py +5 -0
- angr/knowledge_plugins/cfg/memory_data.py +1 -0
- angr/lib/angr_native.dll +0 -0
- angr/protos/cfg_pb2.py +23 -15
- angr/protos/function_pb2.py +19 -21
- angr/protos/primitives_pb2.py +46 -112
- angr/protos/variables_pb2.py +38 -114
- angr/protos/xrefs_pb2.py +17 -18
- angr/sim_state.py +2 -78
- angr/sim_type.py +53 -18
- angr/state_plugins/solver.py +72 -15
- angr/storage/__init__.py +1 -2
- angr/storage/memory_mixins/__init__.py +5 -160
- angr/storage/memory_mixins/actions_mixin.py +1 -1
- angr/storage/memory_mixins/address_concretization_mixin.py +1 -1
- angr/storage/memory_mixins/bvv_conversion_mixin.py +1 -1
- angr/storage/memory_mixins/clouseau_mixin.py +2 -1
- angr/storage/memory_mixins/conditional_store_mixin.py +1 -1
- angr/storage/memory_mixins/convenient_mappings_mixin.py +1 -1
- angr/storage/memory_mixins/default_filler_mixin.py +1 -1
- angr/storage/memory_mixins/dirty_addrs_mixin.py +2 -1
- angr/storage/memory_mixins/hex_dumper_mixin.py +1 -1
- angr/storage/memory_mixins/javavm_memory_mixin.py +1 -1
- angr/storage/memory_mixins/keyvalue_memory_mixin.py +1 -1
- angr/storage/memory_mixins/label_merger_mixin.py +1 -1
- angr/storage/memory_mixins/memory_mixin.py +163 -0
- angr/storage/memory_mixins/multi_value_merger_mixin.py +1 -1
- angr/storage/memory_mixins/name_resolution_mixin.py +3 -1
- angr/storage/memory_mixins/paged_memory/paged_memory_mixin.py +1 -1
- angr/storage/memory_mixins/paged_memory/paged_memory_multivalue_mixin.py +2 -1
- angr/storage/memory_mixins/paged_memory/pages/__init__.py +1 -1
- angr/storage/memory_mixins/paged_memory/pages/history_tracking_mixin.py +1 -1
- angr/storage/memory_mixins/paged_memory/pages/ispo_mixin.py +2 -1
- angr/storage/memory_mixins/paged_memory/pages/permissions_mixin.py +1 -1
- angr/storage/memory_mixins/paged_memory/pages/refcount_mixin.py +2 -1
- angr/storage/memory_mixins/paged_memory/pages/ultra_page.py +1 -1
- angr/storage/memory_mixins/regioned_memory/abstract_merger_mixin.py +1 -2
- angr/storage/memory_mixins/regioned_memory/region_category_mixin.py +2 -1
- angr/storage/memory_mixins/regioned_memory/region_meta_mixin.py +1 -1
- angr/storage/memory_mixins/regioned_memory/regioned_address_concretization_mixin.py +1 -1
- angr/storage/memory_mixins/regioned_memory/regioned_memory_mixin.py +2 -2
- angr/storage/memory_mixins/simple_interface_mixin.py +2 -1
- angr/storage/memory_mixins/simplification_mixin.py +2 -1
- angr/storage/memory_mixins/size_resolution_mixin.py +1 -1
- angr/storage/memory_mixins/slotted_memory.py +2 -2
- angr/storage/memory_mixins/smart_find_mixin.py +1 -1
- angr/storage/memory_mixins/symbolic_merger_mixin.py +2 -1
- angr/storage/memory_mixins/top_merger_mixin.py +3 -2
- angr/storage/memory_mixins/underconstrained_mixin.py +4 -2
- angr/storage/memory_mixins/unwrapper_mixin.py +2 -1
- {angr-9.2.120.dist-info → angr-9.2.122.dist-info}/METADATA +7 -7
- {angr-9.2.120.dist-info → angr-9.2.122.dist-info}/RECORD +78 -76
- {angr-9.2.120.dist-info → angr-9.2.122.dist-info}/LICENSE +0 -0
- {angr-9.2.120.dist-info → angr-9.2.122.dist-info}/WHEEL +0 -0
- {angr-9.2.120.dist-info → angr-9.2.122.dist-info}/entry_points.txt +0 -0
- {angr-9.2.120.dist-info → angr-9.2.122.dist-info}/top_level.txt +0 -0
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
from __future__ import annotations
|
|
2
|
-
import pyvex
|
|
3
2
|
|
|
4
|
-
|
|
3
|
+
import pyvex
|
|
5
4
|
|
|
6
|
-
from angr.state_plugins.sim_action import SimActionObject, SimActionData, SimActionExit, SimActionOperation
|
|
7
5
|
from angr import sim_options as o
|
|
6
|
+
from angr.state_plugins.sim_action import SimActionData, SimActionExit, SimActionObject, SimActionOperation
|
|
7
|
+
|
|
8
|
+
from .heavy import HeavyVEXMixin
|
|
8
9
|
|
|
9
10
|
|
|
10
11
|
class TrackActionsMixin(HeavyVEXMixin):
|
|
@@ -15,12 +16,6 @@ class TrackActionsMixin(HeavyVEXMixin):
|
|
|
15
16
|
|
|
16
17
|
__tls = ("__tmp_deps",)
|
|
17
18
|
|
|
18
|
-
def _is_true(self, v):
|
|
19
|
-
return super()._is_true(v[0])
|
|
20
|
-
|
|
21
|
-
def _is_false(self, v):
|
|
22
|
-
return super()._is_false(v[0])
|
|
23
|
-
|
|
24
19
|
def _optimize_guarded_addr(self, addr, guard):
|
|
25
20
|
addr, addr_deps = addr
|
|
26
21
|
guard, _ = guard
|
|
@@ -97,8 +92,8 @@ class TrackActionsMixin(HeavyVEXMixin):
|
|
|
97
92
|
a = self.__tmp_deps.get(tmp, frozenset())
|
|
98
93
|
return result, a
|
|
99
94
|
|
|
100
|
-
def _perform_vex_expr_Get(self,
|
|
101
|
-
offset, offset_deps =
|
|
95
|
+
def _perform_vex_expr_Get(self, offset, ty, **kwargs):
|
|
96
|
+
offset, offset_deps = offset
|
|
102
97
|
result = super()._perform_vex_expr_Get(offset, ty, **kwargs)
|
|
103
98
|
|
|
104
99
|
if o.TRACK_REGISTER_ACTIONS in self.state.options:
|
|
@@ -117,15 +112,15 @@ class TrackActionsMixin(HeavyVEXMixin):
|
|
|
117
112
|
a = frozenset()
|
|
118
113
|
return result, a
|
|
119
114
|
|
|
120
|
-
def _perform_vex_expr_Load(self,
|
|
121
|
-
addr, addr_deps =
|
|
115
|
+
def _perform_vex_expr_Load(self, addr, ty, endness, condition=None, **kwargs):
|
|
116
|
+
addr, addr_deps = addr
|
|
122
117
|
|
|
123
118
|
if condition is not None:
|
|
124
119
|
condition, condition_deps = condition
|
|
125
120
|
else:
|
|
126
121
|
condition_deps = None
|
|
127
122
|
|
|
128
|
-
result = super()._perform_vex_expr_Load(addr, ty,
|
|
123
|
+
result = super()._perform_vex_expr_Load(addr, ty, endness, condition=condition, **kwargs)
|
|
129
124
|
|
|
130
125
|
if o.TRACK_MEMORY_ACTIONS in self.state.options:
|
|
131
126
|
addr_ao = SimActionObject(addr, deps=addr_deps, state=self.state)
|
|
@@ -162,9 +157,9 @@ class TrackActionsMixin(HeavyVEXMixin):
|
|
|
162
157
|
self.__tmp_deps[tmp] = data_deps
|
|
163
158
|
super()._perform_vex_stmt_WrTmp(tmp, data, deps=data_deps)
|
|
164
159
|
|
|
165
|
-
def _perform_vex_stmt_Put(self,
|
|
166
|
-
offset,
|
|
167
|
-
data, data_deps =
|
|
160
|
+
def _perform_vex_stmt_Put(self, offset, data, **kwargs):
|
|
161
|
+
offset, _ = offset
|
|
162
|
+
data, data_deps = data
|
|
168
163
|
# track the put
|
|
169
164
|
if o.TRACK_REGISTER_ACTIONS in self.state.options:
|
|
170
165
|
data_ao = SimActionObject(data, deps=data_deps, state=self.state)
|
|
@@ -178,9 +173,9 @@ class TrackActionsMixin(HeavyVEXMixin):
|
|
|
178
173
|
|
|
179
174
|
super()._perform_vex_stmt_Put(offset, data, action=a, **kwargs)
|
|
180
175
|
|
|
181
|
-
def _perform_vex_stmt_Store(self,
|
|
182
|
-
addr, addr_deps =
|
|
183
|
-
data, data_deps =
|
|
176
|
+
def _perform_vex_stmt_Store(self, addr, data, endness, condition=None, **kwargs):
|
|
177
|
+
addr, addr_deps = addr
|
|
178
|
+
data, data_deps = data
|
|
184
179
|
|
|
185
180
|
if condition is not None:
|
|
186
181
|
condition, condition_deps = condition
|
|
@@ -210,11 +205,11 @@ class TrackActionsMixin(HeavyVEXMixin):
|
|
|
210
205
|
else:
|
|
211
206
|
a = None
|
|
212
207
|
|
|
213
|
-
super()._perform_vex_stmt_Store(addr, data,
|
|
208
|
+
super()._perform_vex_stmt_Store(addr, data, endness, action=a, condition=condition, **kwargs)
|
|
214
209
|
|
|
215
|
-
def _perform_vex_stmt_Exit(self,
|
|
216
|
-
guard, guard_deps =
|
|
217
|
-
target, target_deps =
|
|
210
|
+
def _perform_vex_stmt_Exit(self, guard, expr, jumpkind):
|
|
211
|
+
guard, guard_deps = guard
|
|
212
|
+
target, target_deps = expr
|
|
218
213
|
|
|
219
214
|
if o.TRACK_JMP_ACTIONS in self.state.options:
|
|
220
215
|
guard_ao = SimActionObject(guard, deps=guard_deps, state=self.state)
|
angr/engines/vex/heavy/heavy.py
CHANGED
|
@@ -251,7 +251,13 @@ class HeavyVEXMixin(SuccessorsMixin, ClaripyDataMixin, SimStateStorageMixin, VEX
|
|
|
251
251
|
|
|
252
252
|
# Raise an exception if we're suddenly in self-modifying code
|
|
253
253
|
if (self.project is None or self.project.selfmodifying_code) and self.state.scratch.dirty_addrs:
|
|
254
|
-
|
|
254
|
+
instruction_len = stmt.len
|
|
255
|
+
if instruction_len == 0:
|
|
256
|
+
# We don't know how long this instruction is.
|
|
257
|
+
# Conservatively assume it is the maximum instruction
|
|
258
|
+
# length for the purpose of dirty checks.
|
|
259
|
+
instruction_len = self.project.arch.max_inst_bytes
|
|
260
|
+
for subaddr in range(instruction_len):
|
|
255
261
|
if subaddr + stmt.addr in self.state.scratch.dirty_addrs:
|
|
256
262
|
raise errors.SimReliftException(self.state)
|
|
257
263
|
|
angr/engines/vex/lifter.py
CHANGED
|
@@ -93,6 +93,7 @@ class VEXLifter(SimEngineBase):
|
|
|
93
93
|
collect_data_refs=False,
|
|
94
94
|
cross_insn_opt=None,
|
|
95
95
|
load_from_ro_regions=False,
|
|
96
|
+
const_prop=False,
|
|
96
97
|
):
|
|
97
98
|
"""
|
|
98
99
|
Lift an IRSB.
|
|
@@ -170,7 +171,7 @@ class VEXLifter(SimEngineBase):
|
|
|
170
171
|
have_patches = self.project and self.project.kb.patches.items()
|
|
171
172
|
|
|
172
173
|
# FIXME: cache ignores provided state
|
|
173
|
-
use_cache = self._use_cache and not (skip_stmts or collect_data_refs or have_patches)
|
|
174
|
+
use_cache = self._use_cache and not (skip_stmts or collect_data_refs or have_patches or const_prop)
|
|
174
175
|
|
|
175
176
|
# phase 2: thumb normalization
|
|
176
177
|
thumb = int(thumb)
|
|
@@ -261,6 +262,7 @@ class VEXLifter(SimEngineBase):
|
|
|
261
262
|
collect_data_refs=collect_data_refs,
|
|
262
263
|
load_from_ro_regions=load_from_ro_regions,
|
|
263
264
|
cross_insn_opt=cross_insn_opt,
|
|
265
|
+
const_prop=const_prop,
|
|
264
266
|
)
|
|
265
267
|
|
|
266
268
|
if subphase == 0 and irsb.statements is not None:
|
angr/engines/vex/light/light.py
CHANGED
|
@@ -394,7 +394,7 @@ class VEXMixin(SimEngineBase):
|
|
|
394
394
|
# guarded address). This way we get rid of the redundant load that should have existed in the first place.
|
|
395
395
|
|
|
396
396
|
ty, cvt_op = cvt_properties[cvt]
|
|
397
|
-
if self.
|
|
397
|
+
if self.state.solver.is_true(guard[0] == 0):
|
|
398
398
|
self._perform_vex_stmt_LoadG_wrtmp(dst, alt)
|
|
399
399
|
return
|
|
400
400
|
load_result = self._perform_vex_stmt_LoadG_load(
|
|
@@ -436,7 +436,7 @@ class VEXMixin(SimEngineBase):
|
|
|
436
436
|
|
|
437
437
|
def _perform_vex_stmt_StoreG(self, addr, data, guard, ty, endness, **kwargs):
|
|
438
438
|
# perform the same optimization as in _perform_vex_stmt_LoadG
|
|
439
|
-
if self.
|
|
439
|
+
if self.state.solver.is_true(guard[0] == 0):
|
|
440
440
|
return
|
|
441
441
|
self._perform_vex_stmt_StoreG_store(
|
|
442
442
|
addr, data, endness, condition=self._perform_vex_stmt_StoreG_guard_condition(guard), **kwargs
|
angr/factory.py
CHANGED
|
@@ -289,6 +289,7 @@ class AngrObjectFactory:
|
|
|
289
289
|
collect_data_refs=False,
|
|
290
290
|
cross_insn_opt=True,
|
|
291
291
|
load_from_ro_regions=False,
|
|
292
|
+
const_prop=False,
|
|
292
293
|
initial_regs=None,
|
|
293
294
|
skip_stmts=False,
|
|
294
295
|
) -> Block: ...
|
|
@@ -312,6 +313,8 @@ class AngrObjectFactory:
|
|
|
312
313
|
insn_text=None, # backward compatibility
|
|
313
314
|
strict_block_end=None,
|
|
314
315
|
collect_data_refs=False,
|
|
316
|
+
load_from_ro_regions=False,
|
|
317
|
+
const_prop=False,
|
|
315
318
|
cross_insn_opt=True,
|
|
316
319
|
skip_stmts=False,
|
|
317
320
|
) -> SootBlock: ...
|
|
@@ -335,6 +338,7 @@ class AngrObjectFactory:
|
|
|
335
338
|
collect_data_refs=False,
|
|
336
339
|
cross_insn_opt=True,
|
|
337
340
|
load_from_ro_regions=False,
|
|
341
|
+
const_prop=False,
|
|
338
342
|
initial_regs=None,
|
|
339
343
|
skip_stmts=False,
|
|
340
344
|
):
|
|
@@ -372,6 +376,7 @@ class AngrObjectFactory:
|
|
|
372
376
|
collect_data_refs=collect_data_refs,
|
|
373
377
|
cross_insn_opt=cross_insn_opt,
|
|
374
378
|
load_from_ro_regions=load_from_ro_regions,
|
|
379
|
+
const_prop=const_prop,
|
|
375
380
|
initial_regs=initial_regs,
|
|
376
381
|
skip_stmts=skip_stmts,
|
|
377
382
|
)
|
|
@@ -31,6 +31,7 @@ _SORT_TO_IDX = {
|
|
|
31
31
|
MemoryDataSort.GOTPLTEntry: cfg_pb2.MemoryData.GOTPLTEntry,
|
|
32
32
|
MemoryDataSort.ELFHeader: cfg_pb2.MemoryData.ELFHeader,
|
|
33
33
|
MemoryDataSort.FloatingPoint: cfg_pb2.MemoryData.FloatingPoint,
|
|
34
|
+
MemoryDataSort.Alignment: cfg_pb2.MemoryData.Alignment,
|
|
34
35
|
}
|
|
35
36
|
|
|
36
37
|
_IDX_TO_SORT = {v: k for k, v in _SORT_TO_IDX.items()}
|
angr/lib/angr_native.dll
CHANGED
|
Binary file
|
angr/protos/cfg_pb2.py
CHANGED
|
@@ -1,10 +1,16 @@
|
|
|
1
1
|
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
2
|
+
# NO CHECKED-IN PROTOBUF GENCODE
|
|
2
3
|
# source: protos/cfg.proto
|
|
4
|
+
# Protobuf Python Version: 5.28.2
|
|
3
5
|
"""Generated protocol buffer code."""
|
|
4
|
-
|
|
6
|
+
|
|
5
7
|
from google.protobuf import descriptor as _descriptor
|
|
6
8
|
from google.protobuf import descriptor_pool as _descriptor_pool
|
|
9
|
+
from google.protobuf import runtime_version as _runtime_version
|
|
7
10
|
from google.protobuf import symbol_database as _symbol_database
|
|
11
|
+
from google.protobuf.internal import builder as _builder
|
|
12
|
+
|
|
13
|
+
_runtime_version.ValidateProtobufRuntimeVersion(_runtime_version.Domain.PUBLIC, 5, 28, 2, "", "protos/cfg.proto")
|
|
8
14
|
# @@protoc_insertion_point(imports)
|
|
9
15
|
|
|
10
16
|
_sym_db = _symbol_database.Default()
|
|
@@ -13,19 +19,21 @@ _sym_db = _symbol_database.Default()
|
|
|
13
19
|
from . import primitives_pb2 as protos_dot_primitives__pb2
|
|
14
20
|
|
|
15
21
|
|
|
16
|
-
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
_builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'protos.cfg_pb2', globals())
|
|
20
|
-
if _descriptor._USE_C_DESCRIPTORS == False:
|
|
22
|
+
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(
|
|
23
|
+
b'\n\x10protos/cfg.proto\x12\x0b\x61ngr.protos\x1a\x17protos/primitives.proto"]\n\x07\x43\x46GNode\x12\n\n\x02\x65\x61\x18\x01 \x01(\x04\x12\x0c\n\x04size\x18\x02 \x01(\r\x12\x10\n\x08\x62lock_id\x18\x03 \x03(\x03\x12\x11\n\treturning\x18\x04 \x01(\x08\x12\x13\n\x0binstr_addrs\x18\x05 \x03(\x04"\x9d\x01\n\x03\x43\x46G\x12\r\n\x05ident\x18\x01 \x01(\t\x12#\n\x05nodes\x18\x02 \x03(\x0b\x32\x14.angr.protos.CFGNode\x12 \n\x05\x65\x64ges\x18\x03 \x03(\x0b\x32\x11.angr.protos.Edge\x12,\n\x0bmemory_data\x18\x04 \x03(\x0b\x32\x17.angr.protos.MemoryData\x12\x12\n\nnormalized\x18\x05 \x01(\x08"\xfb\x02\n\nMemoryData\x12\n\n\x02\x65\x61\x18\x01 \x01(\x04\x12\x11\n\x04size\x18\x02 \x01(\rH\x00\x88\x01\x01\x12\x34\n\x04type\x18\x03 \x01(\x0e\x32&.angr.protos.MemoryData.MemoryDataType\x12\x1b\n\x0ereference_size\x18\x04 \x01(\rH\x01\x88\x01\x01"\xde\x01\n\x0eMemoryDataType\x12\x13\n\x0fUnknownDataType\x10\x00\x12\x0f\n\x0bUnspecified\x10\x01\x12\x0b\n\x07Integer\x10\x02\x12\x10\n\x0cPointerArray\x10\x03\x12\n\n\x06String\x10\x04\x12\x11\n\rUnicodeString\x10\x05\x12\x13\n\x0fSegmentBoundary\x10\x06\x12\x11\n\rCodeReference\x10\x07\x12\x0f\n\x0bGOTPLTEntry\x10\x08\x12\r\n\tELFHeader\x10\t\x12\x11\n\rFloatingPoint\x10\n\x12\r\n\tAlignment\x10\x0b\x42\x07\n\x05_sizeB\x11\n\x0f_reference_sizeb\x06proto3'
|
|
24
|
+
)
|
|
21
25
|
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
26
|
+
_globals = globals()
|
|
27
|
+
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
|
|
28
|
+
_builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, "protos.cfg_pb2", _globals)
|
|
29
|
+
if not _descriptor._USE_C_DESCRIPTORS:
|
|
30
|
+
DESCRIPTOR._loaded_options = None
|
|
31
|
+
_globals["_CFGNODE"]._serialized_start = 58
|
|
32
|
+
_globals["_CFGNODE"]._serialized_end = 151
|
|
33
|
+
_globals["_CFG"]._serialized_start = 154
|
|
34
|
+
_globals["_CFG"]._serialized_end = 311
|
|
35
|
+
_globals["_MEMORYDATA"]._serialized_start = 314
|
|
36
|
+
_globals["_MEMORYDATA"]._serialized_end = 693
|
|
37
|
+
_globals["_MEMORYDATA_MEMORYDATATYPE"]._serialized_start = 443
|
|
38
|
+
_globals["_MEMORYDATA_MEMORYDATATYPE"]._serialized_end = 665
|
|
31
39
|
# @@protoc_insertion_point(module_scope)
|
angr/protos/function_pb2.py
CHANGED
|
@@ -1,11 +1,16 @@
|
|
|
1
1
|
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
2
|
+
# NO CHECKED-IN PROTOBUF GENCODE
|
|
2
3
|
# source: protos/function.proto
|
|
4
|
+
# Protobuf Python Version: 5.28.2
|
|
3
5
|
"""Generated protocol buffer code."""
|
|
6
|
+
|
|
4
7
|
from google.protobuf import descriptor as _descriptor
|
|
5
8
|
from google.protobuf import descriptor_pool as _descriptor_pool
|
|
6
|
-
from google.protobuf import
|
|
7
|
-
from google.protobuf import reflection as _reflection
|
|
9
|
+
from google.protobuf import runtime_version as _runtime_version
|
|
8
10
|
from google.protobuf import symbol_database as _symbol_database
|
|
11
|
+
from google.protobuf.internal import builder as _builder
|
|
12
|
+
|
|
13
|
+
_runtime_version.ValidateProtobufRuntimeVersion(_runtime_version.Domain.PUBLIC, 5, 28, 2, "", "protos/function.proto")
|
|
9
14
|
# @@protoc_insertion_point(imports)
|
|
10
15
|
|
|
11
16
|
_sym_db = _symbol_database.Default()
|
|
@@ -14,24 +19,17 @@ _sym_db = _symbol_database.Default()
|
|
|
14
19
|
from . import primitives_pb2 as protos_dot_primitives__pb2
|
|
15
20
|
|
|
16
21
|
|
|
17
|
-
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
_FUNCTION = DESCRIPTOR.message_types_by_name['Function']
|
|
22
|
-
_FUNCTION_SIGNATURESOURCE = _FUNCTION.enum_types_by_name['SignatureSource']
|
|
23
|
-
Function = _reflection.GeneratedProtocolMessageType('Function', (_message.Message,), {
|
|
24
|
-
'DESCRIPTOR' : _FUNCTION,
|
|
25
|
-
'__module__' : 'protos.function_pb2'
|
|
26
|
-
# @@protoc_insertion_point(class_scope:angr.protos.Function)
|
|
27
|
-
})
|
|
28
|
-
_sym_db.RegisterMessage(Function)
|
|
29
|
-
|
|
30
|
-
if _descriptor._USE_C_DESCRIPTORS == False:
|
|
22
|
+
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(
|
|
23
|
+
b'\n\x15protos/function.proto\x12\x0b\x61ngr.protos\x1a\x17protos/primitives.proto"\x99\x03\n\x08\x46unction\x12\n\n\x02\x65\x61\x18\x01 \x01(\x04\x12\x15\n\ris_entrypoint\x18\x03 \x01(\x08\x12"\n\x06\x62locks\x18\x02 \x03(\x0b\x32\x12.angr.protos.Block\x12\x0c\n\x04name\x18\x04 \x01(\t\x12\x0e\n\x06is_plt\x18\x07 \x01(\x08\x12\x12\n\nis_syscall\x18\x08 \x01(\x08\x12\x17\n\x0fis_simprocedure\x18\t \x01(\x08\x12\x11\n\treturning\x18\n \x01(\x08\x12\x13\n\x0b\x62inary_name\x18\x0b \x01(\t\x12&\n\x05graph\x18\x0c \x01(\x0b\x32\x17.angr.protos.BlockGraph\x12\x1a\n\x12\x65xternal_functions\x18\r \x03(\x04\x12\x11\n\talignment\x18\x0e \x01(\x08\x12\x12\n\nnormalized\x18\x0f \x01(\x08\x12;\n\x0cmatched_from\x18\x10 \x01(\x0e\x32%.angr.protos.Function.SignatureSource"+\n\x0fSignatureSource\x12\r\n\tUNMATCHED\x10\x00\x12\t\n\x05\x46LIRT\x10\x01\x62\x06proto3'
|
|
24
|
+
)
|
|
31
25
|
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
26
|
+
_globals = globals()
|
|
27
|
+
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
|
|
28
|
+
_builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, "protos.function_pb2", _globals)
|
|
29
|
+
if not _descriptor._USE_C_DESCRIPTORS:
|
|
30
|
+
DESCRIPTOR._loaded_options = None
|
|
31
|
+
_globals["_FUNCTION"]._serialized_start = 64
|
|
32
|
+
_globals["_FUNCTION"]._serialized_end = 473
|
|
33
|
+
_globals["_FUNCTION_SIGNATURESOURCE"]._serialized_start = 430
|
|
34
|
+
_globals["_FUNCTION_SIGNATURESOURCE"]._serialized_end = 473
|
|
37
35
|
# @@protoc_insertion_point(module_scope)
|
angr/protos/primitives_pb2.py
CHANGED
|
@@ -1,124 +1,58 @@
|
|
|
1
1
|
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
2
|
+
# NO CHECKED-IN PROTOBUF GENCODE
|
|
2
3
|
# source: protos/primitives.proto
|
|
4
|
+
# Protobuf Python Version: 5.28.2
|
|
3
5
|
"""Generated protocol buffer code."""
|
|
6
|
+
|
|
4
7
|
from google.protobuf import descriptor as _descriptor
|
|
5
8
|
from google.protobuf import descriptor_pool as _descriptor_pool
|
|
6
|
-
from google.protobuf import
|
|
7
|
-
from google.protobuf import reflection as _reflection
|
|
9
|
+
from google.protobuf import runtime_version as _runtime_version
|
|
8
10
|
from google.protobuf import symbol_database as _symbol_database
|
|
11
|
+
from google.protobuf.internal import builder as _builder
|
|
12
|
+
|
|
13
|
+
_runtime_version.ValidateProtobufRuntimeVersion(_runtime_version.Domain.PUBLIC, 5, 28, 2, "", "protos/primitives.proto")
|
|
9
14
|
# @@protoc_insertion_point(imports)
|
|
10
15
|
|
|
11
16
|
_sym_db = _symbol_database.Default()
|
|
12
17
|
|
|
13
18
|
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
_CODEREFERENCE_TARGETTYPE =
|
|
29
|
-
_CODEREFERENCE_OPERANDTYPE =
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
_sym_db.RegisterMessage(Block)
|
|
54
|
-
|
|
55
|
-
ExternalFunction = _reflection.GeneratedProtocolMessageType('ExternalFunction', (_message.Message,), {
|
|
56
|
-
'DESCRIPTOR' : _EXTERNALFUNCTION,
|
|
57
|
-
'__module__' : 'protos.primitives_pb2'
|
|
58
|
-
# @@protoc_insertion_point(class_scope:angr.protos.ExternalFunction)
|
|
59
|
-
})
|
|
60
|
-
_sym_db.RegisterMessage(ExternalFunction)
|
|
61
|
-
|
|
62
|
-
ExternalVariable = _reflection.GeneratedProtocolMessageType('ExternalVariable', (_message.Message,), {
|
|
63
|
-
'DESCRIPTOR' : _EXTERNALVARIABLE,
|
|
64
|
-
'__module__' : 'protos.primitives_pb2'
|
|
65
|
-
# @@protoc_insertion_point(class_scope:angr.protos.ExternalVariable)
|
|
66
|
-
})
|
|
67
|
-
_sym_db.RegisterMessage(ExternalVariable)
|
|
68
|
-
|
|
69
|
-
Edge = _reflection.GeneratedProtocolMessageType('Edge', (_message.Message,), {
|
|
70
|
-
|
|
71
|
-
'DataEntry' : _reflection.GeneratedProtocolMessageType('DataEntry', (_message.Message,), {
|
|
72
|
-
'DESCRIPTOR' : _EDGE_DATAENTRY,
|
|
73
|
-
'__module__' : 'protos.primitives_pb2'
|
|
74
|
-
# @@protoc_insertion_point(class_scope:angr.protos.Edge.DataEntry)
|
|
75
|
-
})
|
|
76
|
-
,
|
|
77
|
-
'DESCRIPTOR' : _EDGE,
|
|
78
|
-
'__module__' : 'protos.primitives_pb2'
|
|
79
|
-
# @@protoc_insertion_point(class_scope:angr.protos.Edge)
|
|
80
|
-
})
|
|
81
|
-
_sym_db.RegisterMessage(Edge)
|
|
82
|
-
_sym_db.RegisterMessage(Edge.DataEntry)
|
|
83
|
-
|
|
84
|
-
BlockGraph = _reflection.GeneratedProtocolMessageType('BlockGraph', (_message.Message,), {
|
|
85
|
-
'DESCRIPTOR' : _BLOCKGRAPH,
|
|
86
|
-
'__module__' : 'protos.primitives_pb2'
|
|
87
|
-
# @@protoc_insertion_point(class_scope:angr.protos.BlockGraph)
|
|
88
|
-
})
|
|
89
|
-
_sym_db.RegisterMessage(BlockGraph)
|
|
90
|
-
|
|
91
|
-
if _descriptor._USE_C_DESCRIPTORS == False:
|
|
92
|
-
|
|
93
|
-
DESCRIPTOR._options = None
|
|
94
|
-
_EDGE_DATAENTRY._options = None
|
|
95
|
-
_EDGE_DATAENTRY._serialized_options = b'8\001'
|
|
96
|
-
_CODEREFERENCE._serialized_start=41
|
|
97
|
-
_CODEREFERENCE._serialized_end=688
|
|
98
|
-
_CODEREFERENCE_TARGETTYPE._serialized_start=409
|
|
99
|
-
_CODEREFERENCE_TARGETTYPE._serialized_end=470
|
|
100
|
-
_CODEREFERENCE_OPERANDTYPE._serialized_start=472
|
|
101
|
-
_CODEREFERENCE_OPERANDTYPE._serialized_end=598
|
|
102
|
-
_CODEREFERENCE_LOCATION._serialized_start=600
|
|
103
|
-
_CODEREFERENCE_LOCATION._serialized_end=638
|
|
104
|
-
_CODEREFERENCE_REFERENCETYPE._serialized_start=640
|
|
105
|
-
_CODEREFERENCE_REFERENCETYPE._serialized_end=688
|
|
106
|
-
_INSTRUCTION._serialized_start=690
|
|
107
|
-
_INSTRUCTION._serialized_end=797
|
|
108
|
-
_BLOCK._serialized_start=799
|
|
109
|
-
_BLOCK._serialized_end=895
|
|
110
|
-
_EXTERNALFUNCTION._serialized_start=898
|
|
111
|
-
_EXTERNALFUNCTION._serialized_end=1175
|
|
112
|
-
_EXTERNALFUNCTION_CALLINGCONVENTION._serialized_start=1104
|
|
113
|
-
_EXTERNALFUNCTION_CALLINGCONVENTION._serialized_end=1175
|
|
114
|
-
_EXTERNALVARIABLE._serialized_start=1177
|
|
115
|
-
_EXTERNALVARIABLE._serialized_end=1277
|
|
116
|
-
_EDGE._serialized_start=1280
|
|
117
|
-
_EDGE._serialized_end=1765
|
|
118
|
-
_EDGE_DATAENTRY._serialized_start=1465
|
|
119
|
-
_EDGE_DATAENTRY._serialized_end=1508
|
|
120
|
-
_EDGE_JUMPKIND._serialized_start=1511
|
|
121
|
-
_EDGE_JUMPKIND._serialized_end=1765
|
|
122
|
-
_BLOCKGRAPH._serialized_start=1767
|
|
123
|
-
_BLOCKGRAPH._serialized_end=1813
|
|
19
|
+
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(
|
|
20
|
+
b'\n\x17protos/primitives.proto\x12\x0b\x61ngr.protos"\x87\x05\n\rCodeReference\x12:\n\x0btarget_type\x18\x01 \x01(\x0e\x32%.angr.protos.CodeReference.TargetType\x12<\n\x0coperand_type\x18\x02 \x01(\x0e\x32&.angr.protos.CodeReference.OperandType\x12\x35\n\x08location\x18\x03 \x01(\x0e\x32#.angr.protos.CodeReference.Location\x12\n\n\x02\x65\x61\x18\x04 \x01(\x04\x12\x0c\n\x04mask\x18\x05 \x01(\x04\x12\x0c\n\x04name\x18\x06 \x01(\t\x12\x0f\n\x07\x64\x61ta_ea\x18\x07 \x01(\x04\x12\x10\n\x08\x62lock_ea\x18\x08 \x01(\x04\x12\x10\n\x08stmt_idx\x18\t \x01(\x05\x12\x13\n\x0boperand_idx\x18\n \x01(\x05\x12:\n\x08ref_type\x18\x0b \x01(\x0e\x32(.angr.protos.CodeReference.ReferenceType"=\n\nTargetType\x12\x0e\n\nCodeTarget\x10\x00\x12\x0e\n\nDataTarget\x10\x01\x12\x0f\n\x0bStackTarget\x10\x02"~\n\x0bOperandType\x12\x14\n\x10ImmediateOperand\x10\x00\x12\x11\n\rMemoryOperand\x10\x01\x12\x1d\n\x19MemoryDisplacementOperand\x10\x02\x12\x16\n\x12\x43ontrolFlowOperand\x10\x03\x12\x0f\n\x0bOffsetTable\x10\x04"&\n\x08Location\x12\x0c\n\x08Internal\x10\x00\x12\x0c\n\x08\x45xternal\x10\x01"0\n\rReferenceType\x12\n\n\x06offset\x10\x00\x12\x08\n\x04read\x10\x01\x12\t\n\x05write\x10\x02"k\n\x0bInstruction\x12\n\n\x02\x65\x61\x18\x01 \x01(\x04\x12\r\n\x05\x62ytes\x18\x02 \x01(\x0c\x12)\n\x05xrefs\x18\x03 \x01(\x0b\x32\x1a.angr.protos.CodeReference\x12\x16\n\x0elocal_noreturn\x18\x04 \x01(\x08"`\n\x05\x42lock\x12\n\n\x02\x65\x61\x18\x01 \x01(\x04\x12.\n\x0cinstructions\x18\x02 \x01(\x0b\x32\x18.angr.protos.Instruction\x12\x0c\n\x04size\x18\x04 \x01(\r\x12\r\n\x05\x62ytes\x18\x05 \x01(\x0c"\x95\x02\n\x10\x45xternalFunction\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\n\n\x02\x65\x61\x18\x02 \x01(\x04\x12;\n\x02\x63\x63\x18\x03 \x01(\x0e\x32/.angr.protos.ExternalFunction.CallingConvention\x12\x12\n\nhas_return\x18\x04 \x01(\x08\x12\x11\n\tno_return\x18\x05 \x01(\x08\x12\x16\n\x0e\x61rgument_count\x18\x06 \x01(\x05\x12\x0f\n\x07is_weak\x18\x07 \x01(\x08\x12\x11\n\tprototype\x18\x08 \x01(\t"G\n\x11\x43\x61llingConvention\x12\x11\n\rCallerCleanup\x10\x00\x12\x11\n\rCalleeCleanup\x10\x01\x12\x0c\n\x08\x46\x61stCall\x10\x02"d\n\x10\x45xternalVariable\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\n\n\x02\x65\x61\x18\x02 \x01(\x04\x12\x0c\n\x04size\x18\x03 \x01(\r\x12\x0f\n\x07is_weak\x18\x04 \x01(\x08\x12\x17\n\x0fis_thread_local\x18\x05 \x01(\x08"\xe5\x03\n\x04\x45\x64ge\x12\x0e\n\x06src_ea\x18\x01 \x01(\x04\x12\x0e\n\x06\x64st_ea\x18\x02 \x01(\x04\x12,\n\x08jumpkind\x18\x03 \x01(\x0e\x32\x1a.angr.protos.Edge.JumpKind\x12\x12\n\nis_outside\x18\x04 \x01(\x08\x12\x10\n\x08ins_addr\x18\x05 \x01(\x04\x12\x10\n\x08stmt_idx\x18\x06 \x01(\x03\x12)\n\x04\x64\x61ta\x18\x07 \x03(\x0b\x32\x1b.angr.protos.Edge.DataEntry\x1a+\n\tDataEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\x0c:\x02\x38\x01"\xfe\x01\n\x08JumpKind\x12\x13\n\x0fUnknownJumpkind\x10\x00\x12\n\n\x06\x42oring\x10\x01\x12\x08\n\x04\x43\x61ll\x10\x02\x12\n\n\x06Return\x10\x03\x12\x0e\n\nFakeReturn\x10\x04\x12\x0b\n\x07Syscall\x10\x05\x12\x0f\n\x0bSys_syscall\x10\x06\x12\x0e\n\nSys_int128\x10\x07\x12\x0c\n\x08NoDecode\x10\x08\x12\n\n\x06\x45mWarn\x10\t\x12\x11\n\rSigFPE_IntDiv\x10\n\x12\x0b\n\x07SigTRAP\x10\x0b\x12\x0b\n\x07SigSEGV\x10\x0c\x12\x0b\n\x07MapFail\x10\r\x12\x0b\n\x07NoRedir\x10\x0e\x12\r\n\tClientReq\x10\x0f\x12\r\n\tException\x10\x10".\n\nBlockGraph\x12 \n\x05\x65\x64ges\x18\x01 \x03(\x0b\x32\x11.angr.protos.Edgeb\x06proto3'
|
|
21
|
+
)
|
|
22
|
+
|
|
23
|
+
_globals = globals()
|
|
24
|
+
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
|
|
25
|
+
_builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, "protos.primitives_pb2", _globals)
|
|
26
|
+
if not _descriptor._USE_C_DESCRIPTORS:
|
|
27
|
+
DESCRIPTOR._loaded_options = None
|
|
28
|
+
_globals["_EDGE_DATAENTRY"]._loaded_options = None
|
|
29
|
+
_globals["_EDGE_DATAENTRY"]._serialized_options = b"8\001"
|
|
30
|
+
_globals["_CODEREFERENCE"]._serialized_start = 41
|
|
31
|
+
_globals["_CODEREFERENCE"]._serialized_end = 688
|
|
32
|
+
_globals["_CODEREFERENCE_TARGETTYPE"]._serialized_start = 409
|
|
33
|
+
_globals["_CODEREFERENCE_TARGETTYPE"]._serialized_end = 470
|
|
34
|
+
_globals["_CODEREFERENCE_OPERANDTYPE"]._serialized_start = 472
|
|
35
|
+
_globals["_CODEREFERENCE_OPERANDTYPE"]._serialized_end = 598
|
|
36
|
+
_globals["_CODEREFERENCE_LOCATION"]._serialized_start = 600
|
|
37
|
+
_globals["_CODEREFERENCE_LOCATION"]._serialized_end = 638
|
|
38
|
+
_globals["_CODEREFERENCE_REFERENCETYPE"]._serialized_start = 640
|
|
39
|
+
_globals["_CODEREFERENCE_REFERENCETYPE"]._serialized_end = 688
|
|
40
|
+
_globals["_INSTRUCTION"]._serialized_start = 690
|
|
41
|
+
_globals["_INSTRUCTION"]._serialized_end = 797
|
|
42
|
+
_globals["_BLOCK"]._serialized_start = 799
|
|
43
|
+
_globals["_BLOCK"]._serialized_end = 895
|
|
44
|
+
_globals["_EXTERNALFUNCTION"]._serialized_start = 898
|
|
45
|
+
_globals["_EXTERNALFUNCTION"]._serialized_end = 1175
|
|
46
|
+
_globals["_EXTERNALFUNCTION_CALLINGCONVENTION"]._serialized_start = 1104
|
|
47
|
+
_globals["_EXTERNALFUNCTION_CALLINGCONVENTION"]._serialized_end = 1175
|
|
48
|
+
_globals["_EXTERNALVARIABLE"]._serialized_start = 1177
|
|
49
|
+
_globals["_EXTERNALVARIABLE"]._serialized_end = 1277
|
|
50
|
+
_globals["_EDGE"]._serialized_start = 1280
|
|
51
|
+
_globals["_EDGE"]._serialized_end = 1765
|
|
52
|
+
_globals["_EDGE_DATAENTRY"]._serialized_start = 1465
|
|
53
|
+
_globals["_EDGE_DATAENTRY"]._serialized_end = 1508
|
|
54
|
+
_globals["_EDGE_JUMPKIND"]._serialized_start = 1511
|
|
55
|
+
_globals["_EDGE_JUMPKIND"]._serialized_end = 1765
|
|
56
|
+
_globals["_BLOCKGRAPH"]._serialized_start = 1767
|
|
57
|
+
_globals["_BLOCKGRAPH"]._serialized_end = 1813
|
|
124
58
|
# @@protoc_insertion_point(module_scope)
|