I can quickly test hex string arguments in gdb like this:

r $'\x61\x61\x61\x61'

I'd like to do something similar in radare2 but all I can figure out is regular strings:

doo aaaa

I tried this but the argument isn't interpreted as a hex string

doo $'\x61\x61\x61\x61'

How can I format a hex string argument and pass it to doo?

1 Answer 1


There most be a better way than the one I going to show you but this is how I do it:

I make a rarun2 profile. I'm going to call it "tmp.rr2" and it will contain this:


Note: arguments from arg1..arg[N]

Then in the command line type:

 $ r2 -r tmp.rr2 -d crackme02

Note: You can update the file and run ood/doo

UPDATE: I found a better way so you don't have to make a rarun2 profile:
Run r2 as normal and type:

> dor arg1=\x6f\x60\x72\x72\x76\x6e
> doo
  • +1. the rarun2 profile works! the dor + doo combo isn't working for me.
    – user28086
    Apr 16, 2019 at 0:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.