import
angr
import
claripy
import
sys
import
logging
logging.getLogger(
'angr.project.factory'
).setLevel(
'DEBUG'
)
if
__name__
=
=
'__main__'
:
p
=
angr.Project(
'./05_angr_symbolic_memory'
)
start
=
0x08049357
state
=
p.factory.blank_state(addr
=
start)
passwd0
=
claripy.BVS(
'passwd0'
,
64
)
passwd1
=
claripy.BVS(
'passwd1'
,
64
)
passwd2
=
claripy.BVS(
'passwd2'
,
64
)
passwd3
=
claripy.BVS(
'passwd3'
,
64
)
passwd_address
=
0x081F98A0
state.memory.store(passwd_address,passwd0)
state.memory.store(passwd_address
+
8
,passwd1)
state.memory.store(passwd_address
+
16
,passwd2)
state.memory.store(passwd_address
+
24
,passwd3)
sm
=
p.factory.simulation_manager(state)
aim
=
0x080493D6
address_avoid
=
0x080493C2
sm.explore(find
=
aim,avoid
=
address_avoid)
import
IPython; IPython.embed()