about summary refs log tree commit diff stats
path: root/example/symbol_exec
diff options
context:
space:
mode:
Diffstat (limited to 'example/symbol_exec')
-rw-r--r--example/symbol_exec/depgraph.py2
-rw-r--r--example/symbol_exec/dse_crackme.py2
2 files changed, 2 insertions, 2 deletions
diff --git a/example/symbol_exec/depgraph.py b/example/symbol_exec/depgraph.py
index 4d518cb3..c1d6174d 100644
--- a/example/symbol_exec/depgraph.py
+++ b/example/symbol_exec/depgraph.py
@@ -31,7 +31,7 @@ parser.add_argument("--json",
 args = parser.parse_args()
 
 # Get architecture
-with open(args.filename) as fstream:
+with open(args.filename, "rb") as fstream:
     cont = Container.from_stream(fstream)
 
 arch = args.architecture if args.architecture else cont.arch
diff --git a/example/symbol_exec/dse_crackme.py b/example/symbol_exec/dse_crackme.py
index 9ac4d6d1..303447a4 100644
--- a/example/symbol_exec/dse_crackme.py
+++ b/example/symbol_exec/dse_crackme.py
@@ -31,7 +31,7 @@ def xxx_fopen(jitter):
     global my_FILE_ptr
     ret_addr, args = jitter.func_args_systemv(['path', 'mode'])
     fname = jitter.get_str_ansi(args.path)
-    FILE_to_info[my_FILE_ptr] = FInfo(fname, open(fname))
+    FILE_to_info[my_FILE_ptr] = FInfo(fname, open(fname, "rb"))
     my_FILE_ptr += 1
     return jitter.func_ret_stdcall(ret_addr, my_FILE_ptr - 1)