Is it possible to set domain names mapping directly for an executable? As if we edit /etc/hosts/ and then run the executable.
Example:
$ ping google.com
PING google.com (74.125.232.48) 56(84) bytes of data.
$ magic-command -m google.com=127.0.0.1 ping google.com
PING google.com (127.0.0.1) 56(84) bytes of data.