From 1edf676f6c155dbe05e3d357ffeb1a96a79cb14c Mon Sep 17 00:00:00 2001 From: Stuart Nevans Locke Date: Fri, 20 Sep 2019 08:01:03 -0400 Subject: [PATCH] Change windbg commands to parse data as strings. Fix for #672 (#673) --- pwndbg/commands/windbg.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pwndbg/commands/windbg.py b/pwndbg/commands/windbg.py index 10fe9de0a..143b6cc92 100644 --- a/pwndbg/commands/windbg.py +++ b/pwndbg/commands/windbg.py @@ -135,7 +135,7 @@ def enhex(size, value): parser = argparse.ArgumentParser(description="Write hex bytes at the specified address.") parser.add_argument("address", type=int, help="The address to write to.") -parser.add_argument("data", type=int, nargs="*", help="The bytes to write.") +parser.add_argument("data", type=str, nargs="*", help="The bytes to write.") @pwndbg.commands.ArgparsedCommand(parser) @pwndbg.commands.OnlyWhenRunning def eb(address, data): @@ -147,7 +147,7 @@ def eb(address, data): parser = argparse.ArgumentParser(description="Write hex words at the specified address.") parser.add_argument("address", type=int, help="The address to write to.") -parser.add_argument("data", type=int, nargs="*", help="The words to write.") +parser.add_argument("data", type=str, nargs="*", help="The words to write.") @pwndbg.commands.ArgparsedCommand(parser) @pwndbg.commands.OnlyWhenRunning def ew(address, data): @@ -159,7 +159,7 @@ def ew(address, data): parser = argparse.ArgumentParser(description="Write hex dwords at the specified address.") parser.add_argument("address", type=int, help="The address to write to.") -parser.add_argument("data", type=int, nargs="*", help="The dwords to write.") +parser.add_argument("data", type=str, nargs="*", help="The dwords to write.") @pwndbg.commands.ArgparsedCommand(parser) @pwndbg.commands.OnlyWhenRunning def ed(address, data): @@ -171,7 +171,7 @@ def ed(address, data): parser = argparse.ArgumentParser(description="Write hex qwords at the specified address.") parser.add_argument("address", type=int, help="The address to write to.") -parser.add_argument("data", type=int, nargs="*", help="The qwords to write.") +parser.add_argument("data", type=str, nargs="*", help="The qwords to write.") @pwndbg.commands.ArgparsedCommand(parser) @pwndbg.commands.OnlyWhenRunning def eq(address, data):