Otto Normalverbraucher · 2017-09-23 21:06
Simple question for you:
Do you know how to make angr use args instead of stdio?
I've been searching for like an hour with no effect
Like
$ ./crackme P A S S W O R D
instead of
$ ./crackme
> PASSWORD
Arisu Mizuki · 2017-09-23 22:05
args[1] is first entered argument after name of program, which is args[0].
Basically args is array of all arguments after, and including, the program itself.
Neo · 2017-09-23 22:18
>>2793
Yeah i know it man ;D
Read my question again
I think I will simply try to patch program
Nemissa · 2017-09-23 23:23
>>2792
Try using a pipe.
$ echo "P A S S W O R D" | ./crackme
Apoc · 2017-09-24 09:44
>>2796
My question is about something completely different: https://github.com/angr/angr
But thanks for your determination
Turner · 2017-09-24 10:08
>>2799
The purpose of pipes is to solve this exact problem. Learn to use your tools correctly instead of asking "how do I bash this screw in with a hammer?"
https://meta.stackexchange.com/questions/66377/what-is-the-xy-problem/66378#66378
Armitage · 2017-09-24 10:22
>>2799
I never used this thing but it seems to be possible to define the args vector with entry_state like here:
https://github.com/angr/angr-doc/blob/master/examples/whitehat_crypto400/solve.py#L42
It took me like 5 minutes to find
Cereal Killer · 2017-09-24 10:37
>>2801
>p.factory.entry_state
Isn't it deprecated?
They recommend using proj.factory.simgr now
HELIOS · 2017-09-27 18:30
>>2792
Presumably you want to do `$ ./crackme "P A S S W O R D"` for the sake of convenience?
If that's the case then `$ echo "P A S S W O R D" | ./crackme` will work without making any source code changes.
Otherwise maybe try to explain what the problem you are trying to solve is instead of explaining what you think the solution should be.
epoch · 2017-10-08 05:09
have you heard about xargs? nifty as fuarrrk.