sshdump: fix bug in --remote-sudo.

Fix documentation as well.

Bug: 15845
Change-Id: I1b4e50c21887afa6a60b76de6cc169a1d0b5067a
Reviewed-on: https://code.wireshark.org/review/33658
Petri-Dish: Dario Lombardo <lomato@gmail.com>
Tested-by: Petri Dish Buildbot
Reviewed-by: Anders Broman <a.broman58@gmail.com>
This commit is contained in:
Dario Lombardo 2019-06-19 14:15:34 +02:00 committed by Anders Broman
parent dd15b203c7
commit ed34c3de14
2 changed files with 3 additions and 2 deletions

View File

@ -27,6 +27,7 @@ S<[ B<--remote-password>=E<lt>passwordE<gt> ]>
S<[ B<--sshkey>=E<lt>public key path<gt> ]>
S<[ B<--remote-interface>=E<lt>interfaceE<gt> ]>
S<[ B<--remote-capture-command>=E<lt>capture commandE<gt> ]>
S<[ B<--remote-sudo> ]>
B<sshdump>
S<B<--extcap-interfaces>>

View File

@ -59,7 +59,7 @@ static struct option longopts[] = {
{ "version", no_argument, NULL, OPT_VERSION},
SSH_BASE_OPTIONS,
{ "remote-capture-command", required_argument, NULL, OPT_REMOTE_CAPTURE_COMMAND},
{ "remote-sudo", required_argument, NULL, OPT_REMOTE_SUDO },
{ "remote-sudo", no_argument, NULL, OPT_REMOTE_SUDO },
{ "remote-noprom", no_argument, NULL, OPT_REMOTE_NOPROM },
{ 0, 0, 0, 0}
};
@ -396,7 +396,7 @@ int main(int argc, char *argv[])
extcap_help_add_option(extcap_conf, "--proxycommand <proxy command>", "the command to use as proxy the the ssh connection");
extcap_help_add_option(extcap_conf, "--remote-interface <iface>", "the remote capture interface");
extcap_help_add_option(extcap_conf, "--remote-capture-command <capture command>", "the remote capture command");
extcap_help_add_option(extcap_conf, "--remote-sudo yes", "use sudo on the remote machine to capture");
extcap_help_add_option(extcap_conf, "--remote-sudo", "use sudo on the remote machine to capture");
extcap_help_add_option(extcap_conf, "--remote-noprom", "don't use promiscuous mode on the remote machine");
extcap_help_add_option(extcap_conf, "--remote-filter <filter>", "a filter for remote capture (default: don't "
"listen on local interfaces IPs)");