Skip to content

Commit

Permalink
oops
Browse files Browse the repository at this point in the history
  • Loading branch information
rhelmot committed Feb 5, 2024
1 parent a521270 commit bdeb7a7
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions rex/crash_tracer/dumb_tracer.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ def _investigate_crash(self, r, testcase, channel, pre_fire_hook, delay=0):
# create a project
self._init_angr_project_bow(self.tracer_bow.target)
project = self.angr_project_bow.fire(core_path=r.core_path)
project.loader.main_object = project.loader.elfcore_object
project.loader._main_object = project.loader.elfcore_object
state = project.factory.blank_state(
mode='tracing',
add_options=add_options
Expand Down Expand Up @@ -169,7 +169,7 @@ def _identify_crash_addr(self, testcase, channel, pre_fire_hook, delay=0, action
# likely because of memory access
self._init_angr_project_bow(self.tracer_bow.target)
project = self.angr_project_bow.fire(core_path=r.core_path)
project.loader.main_object = project.loader.elfcore_object
project.loader._main_object = project.loader.elfcore_object
if project.loader.find_object_containing(r.crash_address):
if investigate:
return self._investigate_crash(r, testcase, channel, pre_fire_hook, delay=delay)
Expand Down Expand Up @@ -207,17 +207,17 @@ def create_project(self, target, **kwargs):
self._init_angr_project_bow(target)
project = self.angr_project_bow.fire(core_path=self.trace_result.halfway_core_path)

project.loader.main_object = project.loader.elfcore_object._main_object
project.loader._main_object = project.loader.elfcore_object._main_object
self.project = project
return project

def create_state(self, target, **kwargs):
self.project.loader.main_object = self.project.loader.elfcore_object
self.project.loader._main_object = self.project.loader.elfcore_object
initial_state = self.project.factory.blank_state(
mode='tracing',
add_options=add_options,
remove_options=remove_options)
self.project.loader.main_object = self.project.loader.elfcore_object._main_object
self.project.loader._main_object = self.project.loader.elfcore_object._main_object
initial_state.fs.mount('/', SimArchrMount(target))
self._initial_state = initial_state.copy()
return initial_state
Expand Down Expand Up @@ -484,7 +484,7 @@ def _is_bad_byte(self, crash, bad_byte):
dsb = archr.arsenal.DataScoutBow(crash.target, analyzer=self.tracer_bow)
angr_project_bow = archr.arsenal.angrProjectBow(crash.target, dsb)
project = angr_project_bow.fire(core_path=r.halfway_core_path)
project.loader.main_object = project.loader.elfcore_object._main_object
project.loader._main_object = project.loader.elfcore_object._main_object

# if the new actions have the same behavior as before, that means there are
# no bad bytes in it
Expand Down

0 comments on commit bdeb7a7

Please sign in to comment.