radareorg / radare2

UNIX-like reverse engineering framework and command-line toolset
https://www.radare.org/
GNU Lesser General Public License v3.0
20.59k stars 3k forks source link

Use : and remove \, ' and =! #16674

Closed radare closed 3 years ago

radare commented 4 years ago

I think that the current use of ':' is not fair enough to be that accessilble, and can be easily delegated to #: for example without making the command parser more complicated.

The idea is to have a single char to run commands thru io->system. this is heavily used in r2frida and will be good to have it easy to use from any keyboard layout.

The problem i see is with .: because we would want to run the output of that command and right now .: is for tcp :

[0x00000000]> .:?
Usage: .:[tcp-port]    run r2 commands for clients

this one can be probably renamed to .=9090 . see also:

servers:
| .:9000                        start the tcp server (echo x|nc ::1 9090 or curl ::1:9090/cmd/x)
| =:port                        start the rap server (o rap://9999)
| =g[?]                         start the gdbserver
| =h[?]                         start the http webserver
| =H[?]                         start the http webserver (and launch the web browser)
| ==[fd]                        open remote session with host 'fd', 'q' to quit

here we have a conflict but maybe we can just ignore the = ones. and make those commands like this: (consistent with = and not using :

| =t 9000                        start the tcp server (echo x|nc ::1 9090 or curl ::1:9090/cmd/x)
| =r [9999]                     start the rap server (o rap://9999)

The problem with =! is that is confusing with != and =!= and !=!. so we can probably remove them despite it is useful to enter into a remote io shell

enovella commented 4 years ago

I really got used to \ for io, especially in r2frida. Not a big fun of suddenly changing all these commands, but any change will be well accepted by me. Why is there this need of changing it? Lets keep only \?

radare commented 4 years ago

\ is used for escaping especial chars, it's problematic for the new shell parser because it makes it more complex (one extra exception.

ret2libc commented 4 years ago

I really got used to \ for io, especially in r2frida. Not a big fun of suddenly changing all these commands, but any change will be well accepted by me. Why is there this need of changing it? Lets keep only \?

@enovella what do you mean? I don't see any command that has \. Does r2frida adds commands with \?

radare commented 4 years ago

I prefer ‘ than . In ES layout is 1 key instead of 2. Backslash conflicts with escaping

On 22 Apr 2020, at 09:22, Riccardo Schirone notifications@github.com wrote:

 I really got used to \ for io, especially in r2frida. Not a big fun of suddenly changing all these commands, but any change will be well accepted by me. Why is there this need of changing it? Lets keep only \?

@enovella what do you mean? I don't see any command that has . Does r2frida adds commands with \?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

trufae commented 3 years ago

I have removed it from the 4.6 milestone because I think it's not an urgent issue to fix and it requires further discussion and feedback from the community.

wtdcode commented 3 years ago

At least \ seems really bad.