nowsecure / frida-trace

Trace APIs declaratively through Frida.
MIT License
221 stars 28 forks source link

Can't spawn frida-trace on targets that have flags or arguments #27

Closed jnwilson closed 2 years ago

jnwilson commented 2 years ago

I can frida-trace programs that don't have argument, but, I want to trace a program that must take non-trivial arguments. Consider this example. When I try to

frida-trace --decorate -i *read* /bin/ls -la

I get this result:

usage: frida-trace [options] target frida-trace: error: unrecognized arguments: -la

I thought about trying to start the program in the background, immediately suspend it, let frida-trace figure out the handlers, etc., but frida-trace won't attach to a stopped process.

Is there any thought to allowing the args following the target to be passed to the target instead of eaten by frida? Or is there some other way to achieve my goal?

(BTW, I can't escape the arguments with \, because there is no corresponding unescape in the program I want to trace.)

jnwilson commented 2 years ago

I realize this is not the right place for this concern. Sorry.