-
-
Notifications
You must be signed in to change notification settings - Fork 100
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
R2Pipe Python Fails Sometimes #28
Comments
cant reproduce on mac with /bin/ls
can you provide more details, like version of r2, which binary are you using, which OS, version of python, version of the r2pipe module, etc ?
… On 18 Aug 2017, at 23:10, Julian Tuminaro ***@***.***> wrote:
So, I can't seem to figure out why and what is causing r2pipe to fail for me.
I am writing a program to essential go a list of binaries, get the functions, and select certain functions that I have marked as of interest and run ag [func] to obtain their dot graph.
Yet, I have not been able to figure out why my code will return NoneType object errors with ag [func] on all of the functions except main when I simple comment out handle.cmd('aaa') and uncomment the other one command. Yet, the current implementation below works 100% of the time. Why and how would a previous command impact other commands?
def openBinary(file):
handle = r2pipe.open(file)
handle.cmd('aaa')
#handle.cmd('e anal.jmptbl=true;e anal.jmpref=true;e anal.jmpabove=true;aaa')
return handle
I am also positive that the only command in my code that appears to fail is ag [func]. Other commands such as af had to be commented out as well as they seemed to impact both my aflj and ag command.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub <#28>, or mute the thread <https://github.com/notifications/unsubscribe-auth/AA3-lkvO6V4-7lBMnTruEapWBZ_XcvCoks5sZf3AgaJpZM4O8DFq>.
|
Unfortunately I can not give complete details on the exact binaries or the full program I am using but I tested this on /bin/cat and obtain the same issue. I am on Ubuntu 16.04 using Python 2.7.12
I might be able to pull up a smaller script a little later that outputs with the same error. |
Here is a full python script that causes my issue along with a compiled version of cat and the output of running my script on cat. Let me know if you are able to reproduce it |
Oops. After analyzing the code/issue I wrote up for the previous post it is not caused by r2pipe but radareorg/radare2#8258. I do believe though that i am still running into another error in my larger code that may or not be caused by r2pipe. I am going to take some more time to analyze and see if I can reproduce a smaller case of this error. |
So I figured out my issue. It is occurring due to radare2 asking "Do you want to print x lines?" after a command. Is there a way to disable this? If not I believe this would be useful to implement especially for those using r2pipe to interact with radare. |
Hi @Stormys , Thanks, |
e scr.interactive=0
But in r2pipe mode this shouldnt be needed
… On 16 Jan 2020, at 09:22, lzina ***@***.***> wrote:
Hi @Stormys ,
Did you find any way to disable "Do you want to print x lines?" message?
Thanks,
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
So, I can't seem to figure out why and what is causing r2pipe to fail for me.
I am writing a program to essential go a list of binaries, get the functions, and select certain functions that I have marked as of interest and run
ag [func]
to obtain their dot graph.Yet, I have not been able to figure out why my code will return NoneType object errors with
ag [func]
on all of the functions except main when I simple comment outhandle.cmd('aaa')
and uncomment the other one command. Yet, the current implementation below works 100% of the time. Why and how would a previous command impact other commands?I am also positive that the only command in my code that appears to fail is
ag [func]
. Other commands such asaf
had to be commented out as well as they seemed to impact both myaflj
andag
command.The text was updated successfully, but these errors were encountered: