angr 9.2.111__py3-none-manylinux2014_x86_64.whl → 9.2.112__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 CHANGED
@@ -1,7 +1,7 @@
1
1
  # pylint: disable=wildcard-import
2
2
  # pylint: disable=wrong-import-position
3
3
 
4
- __version__ = "9.2.111"
4
+ __version__ = "9.2.112"
5
5
 
6
6
  if bytes is str:
7
7
  raise Exception(
@@ -7,7 +7,6 @@ import networkx
7
7
  from sortedcontainers import SortedDict
8
8
 
9
9
  import pyvex
10
- from claripy.utils.orderedset import OrderedSet
11
10
  from cle import ELF, PE, Blob, TLSObject, MachO, ExternObject, KernelObject, FunctionHintSource, Hex, Coff, SRec, XBE
12
11
  from cle.backends import NamedRegion
13
12
  import archinfo
@@ -34,6 +33,7 @@ from angr.codenode import HookNode, BlockNode
34
33
  from angr.engines.vex.lifter import VEX_IRSB_MAX_SIZE, VEX_IRSB_MAX_INST
35
34
  from angr.analyses import Analysis
36
35
  from angr.analyses.stack_pointer_tracker import StackPointerTracker
36
+ from angr.utils.orderedset import OrderedSet
37
37
  from .indirect_jump_resolvers.default_resolvers import default_indirect_jump_resolvers
38
38
 
39
39
  if TYPE_CHECKING:
@@ -7,8 +7,8 @@ import networkx
7
7
 
8
8
  from cle.backends.elf.compilation_unit import CompilationUnit
9
9
  from cle.backends.elf.variable import Variable
10
- from claripy.utils.orderedset import OrderedSet
11
10
 
11
+ from angr.utils.orderedset import OrderedSet
12
12
  from ...protos import variables_pb2
13
13
  from ...serializable import Serializable
14
14
  from ...sim_variable import SimVariable, SimStackVariable, SimMemoryVariable, SimRegisterVariable
@@ -1,8 +1,12 @@
1
1
  import functools
2
2
  import time
3
3
  import logging
4
+ import os
4
5
  from typing import TypeVar, overload
5
6
 
7
+ from angr import sim_options as o
8
+ from angr.errors import SimValueError, SimUnsatError, SimSolverModeError, SimSolverOptionError
9
+ import claripy
6
10
  from claripy import backend_manager
7
11
 
8
12
  from .plugin import SimStatePlugin
@@ -72,8 +76,6 @@ def disable_timing():
72
76
  _timing_enabled = False
73
77
 
74
78
 
75
- import os
76
-
77
79
  if os.environ.get("SOLVER_TIMING", False):
78
80
  enable_timing()
79
81
  else:
@@ -191,8 +193,6 @@ def concrete_path_list(f):
191
193
  # The main event
192
194
  #
193
195
 
194
- import claripy
195
-
196
196
 
197
197
  class SimSolver(SimStatePlugin):
198
198
  """
@@ -306,13 +306,7 @@ class SimSolver(SimStatePlugin):
306
306
  elif "smtlib_abc" in backend_manager.backends._backends_by_name:
307
307
  our_backend = backend_manager.backends.smtlib_abc
308
308
  else:
309
- l.error(
310
- "Cannot find a suitable string solver. Please ensure you have installed a string solver that "
311
- "angr supports, and have imported the corresponding solver backend in claripy. You can try "
312
- 'adding "from claripy.backends.backend_smtlib_solvers import *" at the beginning of your '
313
- "script."
314
- )
315
- raise ValueError("Cannot find a suitable string solver")
309
+ our_backend = backend_manager.backends.z3
316
310
  if o.COMPOSITE_SOLVER in self.state.options:
317
311
  self._stored_solver = claripy.SolverComposite(
318
312
  template_solver_string=claripy.SolverCompositeChild(backend=our_backend, track=track)
@@ -1124,6 +1118,4 @@ from angr.sim_state import SimState
1124
1118
 
1125
1119
  SimState.register_default("solver", SimSolver)
1126
1120
 
1127
- from .. import sim_options as o
1128
1121
  from .inspect import BP_AFTER
1129
- from ..errors import SimValueError, SimUnsatError, SimSolverModeError, SimSolverOptionError
@@ -35,7 +35,7 @@ class MultiValueMergerMixin(MemoryMixin):
35
35
  # python implicitly calls __eq__ to determine if the two objects are actually the same
36
36
  # and that just results in a new AST for a BV. Python then tries to convert that AST to a bool
37
37
  # which fails with the safeguard in claripy.ast.bool.Bool.__bool__.
38
- stripped_values_set = {v._apply_to_annotations(lambda alist: None).cache_key for v in values_set}
38
+ stripped_values_set = {v.clear_annotations().cache_key for v in values_set}
39
39
  if len(stripped_values_set) > 1:
40
40
  ret_val = self._top_func(merged_size * self.state.arch.byte_width)
41
41
  else:
@@ -0,0 +1,70 @@
1
+ import collections.abc
2
+
3
+
4
+ class OrderedSet(collections.abc.MutableSet):
5
+ """
6
+ Adapted from http://code.activestate.com/recipes/576694/
7
+ Originally created by Raymond Hettinger and licensed under MIT.
8
+ """
9
+
10
+ def __init__(self, iterable=None):
11
+ self.end = end = []
12
+ end += [None, end, end] # sentinel node for doubly linked list
13
+ self.map = {} # key --> [key, prev, next]
14
+ if iterable is not None:
15
+ self |= iterable
16
+
17
+ def __len__(self):
18
+ return len(self.map)
19
+
20
+ def __contains__(self, key):
21
+ return key in self.map
22
+
23
+ def add(self, value):
24
+ if value not in self.map:
25
+ end = self.end
26
+ curr = end[1]
27
+ curr[2] = end[1] = self.map[value] = [value, curr, end]
28
+
29
+ def discard(self, value):
30
+ if value in self.map:
31
+ value, prev, next_ = self.map.pop(value)
32
+ prev[2] = next_
33
+ next_[1] = prev
34
+
35
+ def __iter__(self):
36
+ end = self.end
37
+ curr = end[2]
38
+ while curr is not end:
39
+ yield curr[0]
40
+ curr = curr[2]
41
+
42
+ def __reversed__(self):
43
+ end = self.end
44
+ curr = end[1]
45
+ while curr is not end:
46
+ yield curr[0]
47
+ curr = curr[1]
48
+
49
+ def pop(self, last=True): # pylint:disable=arguments-differ
50
+ if not self:
51
+ raise KeyError("set is empty")
52
+ key = self.end[1][0] if last else self.end[2][0]
53
+ self.discard(key)
54
+ return key
55
+
56
+ def __repr__(self):
57
+ if not self:
58
+ return f"{self.__class__.__name__}()"
59
+ return f"{self.__class__.__name__}({list(self)!r})"
60
+
61
+ def __eq__(self, other):
62
+ if isinstance(other, OrderedSet):
63
+ return len(self) == len(other) and list(self) == list(other)
64
+ return set(self) == set(other)
65
+
66
+ def __getstate__(self):
67
+ return list(self)
68
+
69
+ def __setstate__(self, state):
70
+ self.__init__(state)
angr/vaults.py CHANGED
@@ -88,7 +88,6 @@ class Vault(collections.abc.MutableMapping):
88
88
  claripy.ast.BV,
89
89
  claripy.ast.FP,
90
90
  claripy.ast.Bool,
91
- claripy.ast.Int,
92
91
  claripy.ast.Bits,
93
92
  }
94
93
  self.module_dedup = set() # {'claripy', 'angr', 'archinfo', 'pyvex' } # cle causes recursion
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: angr
3
- Version: 9.2.111
3
+ Version: 9.2.112
4
4
  Summary: A multi-architecture binary analysis toolkit, with the ability to perform dynamic symbolic execution and various static analyses on binaries
5
5
  Home-page: https://github.com/angr/angr
6
6
  License: BSD-2-Clause
@@ -15,13 +15,13 @@ Description-Content-Type: text/markdown
15
15
  License-File: LICENSE
16
16
  Requires-Dist: CppHeaderParser
17
17
  Requires-Dist: GitPython
18
- Requires-Dist: ailment ==9.2.111
19
- Requires-Dist: archinfo ==9.2.111
18
+ Requires-Dist: ailment ==9.2.112
19
+ Requires-Dist: archinfo ==9.2.112
20
20
  Requires-Dist: cachetools
21
21
  Requires-Dist: capstone ==5.0.0.post1
22
22
  Requires-Dist: cffi >=1.14.0
23
- Requires-Dist: claripy ==9.2.111
24
- Requires-Dist: cle ==9.2.111
23
+ Requires-Dist: claripy ==9.2.112
24
+ Requires-Dist: cle ==9.2.112
25
25
  Requires-Dist: dpkt
26
26
  Requires-Dist: itanium-demangler
27
27
  Requires-Dist: mulpyplexer
@@ -31,7 +31,7 @@ Requires-Dist: protobuf >=3.19.0
31
31
  Requires-Dist: psutil
32
32
  Requires-Dist: pycparser >=2.18
33
33
  Requires-Dist: pyformlang
34
- Requires-Dist: pyvex ==9.2.111
34
+ Requires-Dist: pyvex ==9.2.112
35
35
  Requires-Dist: rich >=13.1.0
36
36
  Requires-Dist: rpyc
37
37
  Requires-Dist: sortedcontainers
@@ -1,4 +1,4 @@
1
- angr/__init__.py,sha256=Kf0h-gf3w0Msnfqn-ZlTg2_pLo9i_vygjYlrf1-vibA,3708
1
+ angr/__init__.py,sha256=7GtszOzKM8MNvheOzxnDDovJkFtQptSuglD58PO1S1M,3708
2
2
  angr/__main__.py,sha256=kaO56Te6h73SM94BVtASF00q5QbBbC3eBs9poVc9sVI,1887
3
3
  angr/annocfg.py,sha256=1tnBfxgLJh9I6Brm1JDdsWLHGmCQYdD6PTC_bFTOMrg,10775
4
4
  angr/blade.py,sha256=B8QXVQ93jz1YCIlb-dZLeBqYmVFdMXI5GleP1Wnxjrw,15519
@@ -25,7 +25,7 @@ angr/sim_variable.py,sha256=FC2FHlMWeBDYrFI_pK6C5WuqmImvxRdTQDFTAC-q4qY,17203
25
25
  angr/slicer.py,sha256=kbLKMAjf2kC6ov-OiGb95BqLmgV0QRl5mmEANcvzuAk,10640
26
26
  angr/state_hierarchy.py,sha256=w_5Tl-7h9xUXBsIKZRAWw8Xh0we8GIAaN6nbKgYH_Qo,8467
27
27
  angr/tablespecs.py,sha256=RRtYqHneKd1ZHhnm9sUdLflplk_K3EP7_gBJaSlX6UY,3239
28
- angr/vaults.py,sha256=A9vhsvbPpem6HpcA4u4HmOt8dR5vJH9Vd5rK5ugXV90,9701
28
+ angr/vaults.py,sha256=qtSdOBpgQ2Qopkh1y0QgEvPtqpbBj-gRq_2Xxc2Q1PM,9672
29
29
  angr/analyses/__init__.py,sha256=lYtaal5RD-EWBW4oScD3Yob1Jk1ZYYqUUCBeTxH7IpE,1773
30
30
  angr/analyses/analysis.py,sha256=BNpBoQOkgbtV9cmMiO8e0WcTgIJKraikYISLDQ-cC6w,12301
31
31
  angr/analyses/backward_slice.py,sha256=grgjobcuTGq-rporwoBLNWf6aEoemCB7BvwE0dDeMp0,27287
@@ -63,7 +63,7 @@ angr/analyses/cfg/__init__.py,sha256=DRCry4KO2k5VJLyfxD_O6dWAdi21IUoaN5TqCnukJJs
63
63
  angr/analyses/cfg/cfb.py,sha256=e-Jlf9B7gkx0GpKl2TvK8VdTWZU8s-A9U9id5MP-R10,15456
64
64
  angr/analyses/cfg/cfg.py,sha256=1JpPGlqXXRFwE0tk26xjabT_-dq-kqAxMv7o6-DUhp4,3146
65
65
  angr/analyses/cfg/cfg_arch_options.py,sha256=YONHg6y-h6BCsBkJK9tuxb94DDfeOoy9CUS-LVyyDyg,3112
66
- angr/analyses/cfg/cfg_base.py,sha256=6FWPJtfJGtvdtVSN_5TPYpppgYZhkcgQwh_nATAoUEE,123076
66
+ angr/analyses/cfg/cfg_base.py,sha256=aaLtljuGeqccd4IO8Zi5CLvSc8Yr-7YevHE7Mb3DdFQ,123073
67
67
  angr/analyses/cfg/cfg_emulated.py,sha256=Bi5PJzv0-0iQoCHzexSGAtkUAp6npb_RSODwW0Nv7zk,152812
68
68
  angr/analyses/cfg/cfg_fast.py,sha256=yeCEAlJTuz4jyFCZvUU6olaAMS07bA9tGg1lFBVn-BY,218149
69
69
  angr/analyses/cfg/cfg_fast_soot.py,sha256=dQglRl4h10i8DNd5oCSJ4umpSotMthjKc5E03bd3BJI,26023
@@ -484,7 +484,7 @@ angr/knowledge_plugins/sync/__init__.py,sha256=RN3y0UhYax-GdPyAhondMXEBuWIu-enHj
484
484
  angr/knowledge_plugins/sync/sync_controller.py,sha256=gZ1NUg8iJWu2EaOYY6WYj_W13tRtreIu5CA1VvpTmTA,9270
485
485
  angr/knowledge_plugins/variables/__init__.py,sha256=tmh_2i0X6Y41TkEgxHRQ4y-kVEGZnlDIpJZ_wUkCISI,60
486
486
  angr/knowledge_plugins/variables/variable_access.py,sha256=RzT-6C3cPXqSlWpQ_vZUf6s4tfYXp2lfOvgfYWkTLyo,3726
487
- angr/knowledge_plugins/variables/variable_manager.py,sha256=r8w2xIP-VN1_DS3r9y2GK3LAy8fMndL1m-7_obiIsbY,47315
487
+ angr/knowledge_plugins/variables/variable_manager.py,sha256=5tESKmGiHLSSQRmyBjbmQ0oMMO1_TDN1tDo8Sj1J5yo,47312
488
488
  angr/knowledge_plugins/xrefs/__init__.py,sha256=-5A2h048WTRu6Et7q7bqlc-AyBXNuJ9AF9nE9zc3M4I,94
489
489
  angr/knowledge_plugins/xrefs/xref.py,sha256=1BMphrr8iViDtVWPXWidmY1_uNmw9LRvEwwZLt3Zqw8,4907
490
490
  angr/knowledge_plugins/xrefs/xref_manager.py,sha256=a4uvTJkdM0PQIuyYcd7t76IddrrVjPGe9SZrRaqp2II,3980
@@ -1206,7 +1206,7 @@ angr/state_plugins/scratch.py,sha256=7j-J4xq8A9Axh6fJzQoUpLpobtIe0va7eeX-glGfYk0
1206
1206
  angr/state_plugins/sim_action.py,sha256=IDPLtcqN04APpStuVYarv00LF2u6JVFfdxEBEw_v_a0,9763
1207
1207
  angr/state_plugins/sim_action_object.py,sha256=4_f7ry76pG4XBnF7O48_7krt_ibG4DZkIMrjmmk_MGg,4268
1208
1208
  angr/state_plugins/sim_event.py,sha256=pRQtMet5g--GmH97BMrS3bDErgUOWAOocjPLGNzmelU,2061
1209
- angr/state_plugins/solver.py,sha256=HrEQgqNJtzdB8I8Qu8XG_3LjMBt6OdbAIewUFZiNZHk,45179
1209
+ angr/state_plugins/solver.py,sha256=YnuLKze1Ls-NWJZVIiH41yhvAVWyBBdaGyBinmQKh-I,44755
1210
1210
  angr/state_plugins/symbolizer.py,sha256=3UAfStON-0GuuHhkD4JD6Y5WveqEfTD3JLK3uj0R-co,11039
1211
1211
  angr/state_plugins/trace_additions.py,sha256=LRcgdGKY2QtzOwsVa-FYLGRFcl0ISOnq-WzCMayiM-8,30091
1212
1212
  angr/state_plugins/uc_manager.py,sha256=9yEE10rrGXTVncLzVOpgvSAGA2RdzApUu_fq_lUksDs,2643
@@ -1235,7 +1235,7 @@ angr/storage/memory_mixins/default_filler_mixin.py,sha256=Hlub-HcakhrNWWwJ0PbBYq
1235
1235
  angr/storage/memory_mixins/dirty_addrs_mixin.py,sha256=-UDDtjEkh19Dd5paf-62NBvSiIHTmQXPM0QtriJ5eig,317
1236
1236
  angr/storage/memory_mixins/hex_dumper_mixin.py,sha256=ciMIrmfTmxWPWVUUiIw5h8YNdHmrWg_GsK6Bzg5omzE,3668
1237
1237
  angr/storage/memory_mixins/label_merger_mixin.py,sha256=22eu5aNM-MUhBjUrqhz02sPF3T74uR6NYVmKv8dSnl0,848
1238
- angr/storage/memory_mixins/multi_value_merger_mixin.py,sha256=3YRS_9NBP1DiRWDst4HlI1nFkd3vQ-7TKdaldfX2Y18,3043
1238
+ angr/storage/memory_mixins/multi_value_merger_mixin.py,sha256=T344CdsUX6-Iw3QkZ10cu-39VwVgRssq8ilwiFruZgE,3021
1239
1239
  angr/storage/memory_mixins/name_resolution_mixin.py,sha256=YOM3yDjTmybDgAVvJGHuVWUgkDqsbFsWRgkJP8vI9ho,3412
1240
1240
  angr/storage/memory_mixins/simple_interface_mixin.py,sha256=KTHvca8MXCWF4W8dbnQLFd7uJ-Gsab03_3kJGfFTAyY,2596
1241
1241
  angr/storage/memory_mixins/simplification_mixin.py,sha256=stTzmaoa0IHxhDSWsYdzKGSt2n37XRjJ7kgZdoa5Uu0,502
@@ -1290,12 +1290,13 @@ angr/utils/lazy_import.py,sha256=VgN0-cMsr6XdGIq56Js1X8YecfPdW9Z4NrB3d2jD-5Y,308
1290
1290
  angr/utils/library.py,sha256=6RKKn7Hm-YEw0AoTFIjL86kCdvglKI_5KtSysDAE06Q,7170
1291
1291
  angr/utils/loader.py,sha256=QdkatPiyRfz5KdfCzRI1Xp3TJL_Pa75wY0dsILgMbwk,1944
1292
1292
  angr/utils/mp.py,sha256=cv_NeysxLgyCdE-Euefnfv078ia5maHSnUn9f23zz88,1882
1293
+ angr/utils/orderedset.py,sha256=6SRZz6PkOVavOzlUd2cIiqZQyWtKO72F2he_cG0aP9Q,1943
1293
1294
  angr/utils/segment_list.py,sha256=5nnuVtdZk9NS2y_xUBVA9khWPueP_zagNtPSjaoMHbA,20410
1294
1295
  angr/utils/timing.py,sha256=uOowCP8kotDrKDOjlAod-guBuYkAA8zEtiAwpdwMlIU,1334
1295
1296
  angr/utils/typing.py,sha256=pCjA7JZAzcvrk-iyIE2cRHc1G66AMSGEON3aFfjtPVc,431
1296
- angr-9.2.111.dist-info/LICENSE,sha256=cgL_ho5B1NH8UxwtBuqThRWdjear8b7hktycaS1sz6g,1327
1297
- angr-9.2.111.dist-info/METADATA,sha256=kLfhkitl-nsiu_raFAO--tkzI7Ot9NZUEa3yG2hC5GU,4703
1298
- angr-9.2.111.dist-info/WHEEL,sha256=iufSf1KKWRBx2aJd9Qq5NmBm_pHichurGAybHCyxUJA,108
1299
- angr-9.2.111.dist-info/entry_points.txt,sha256=Vjh1C8PMyr5dZFMnik5WkEP01Uwr2T73I3a6N32sgQU,44
1300
- angr-9.2.111.dist-info/top_level.txt,sha256=dKw0KWTbwLXytFvv15oAAG4sUs3ey47tt6DorJG9-hw,5
1301
- angr-9.2.111.dist-info/RECORD,,
1297
+ angr-9.2.112.dist-info/LICENSE,sha256=cgL_ho5B1NH8UxwtBuqThRWdjear8b7hktycaS1sz6g,1327
1298
+ angr-9.2.112.dist-info/METADATA,sha256=sFscmmamBc-1J83Ys64gmhGM1IPhQdpB4GyNiE7Mvtc,4703
1299
+ angr-9.2.112.dist-info/WHEEL,sha256=CWGrIEhAIhnaesk6GZ5rPGMzRtXxh4Yj8uPaSQGkP14,108
1300
+ angr-9.2.112.dist-info/entry_points.txt,sha256=Vjh1C8PMyr5dZFMnik5WkEP01Uwr2T73I3a6N32sgQU,44
1301
+ angr-9.2.112.dist-info/top_level.txt,sha256=dKw0KWTbwLXytFvv15oAAG4sUs3ey47tt6DorJG9-hw,5
1302
+ angr-9.2.112.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: setuptools (70.3.0)
2
+ Generator: setuptools (71.1.0)
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-manylinux2014_x86_64
5
5