diff options
author | Irene RĂ¼ngeler <I.Ruengeler@fh-muenster.de> | 2012-08-08 14:30:55 +0000 |
---|---|---|
committer | Irene RĂ¼ngeler <I.Ruengeler@fh-muenster.de> | 2012-08-08 14:30:55 +0000 |
commit | 3a3b4a1fdc22685cae11fe4bcb02ac2aafa82c08 (patch) | |
tree | e16b39b68c0d637778978ebbf1682a8ab36ecefd /tshark.c | |
parent | ae5a2f3b6df1c3c02450350e1e1c98488d6d3813 (diff) |
Add -A as command line option to wireshark and tshark.
svn path=/trunk/; revision=44339
Diffstat (limited to 'tshark.c')
-rw-r--r-- | tshark.c | 15 |
1 files changed, 13 insertions, 2 deletions
@@ -270,7 +270,10 @@ print_usage(gboolean print_ver) fprintf(output, " filesize:NUM - switch to next file after NUM KB\n"); fprintf(output, " files:NUM - ringbuffer: replace after NUM files\n"); #endif /* HAVE_LIBPCAP */ - +#ifdef HAVE_PCAP_REMOTE + fprintf(output, "RPCAP options:\n"); + fprintf(output, " -A <user>:<password> use RPCAP password authentication\n"); +#endif /*fprintf(output, "\n");*/ fprintf(output, "Input file:\n"); fprintf(output, " -r <infile> set the filename to read from (no pipes or stdin!)\n"); @@ -840,6 +843,11 @@ main(int argc, char *argv[]) int optind_initial; gchar *output_only = NULL; +#ifdef HAVE_PCAP_REMOTE +#define OPTSTRING_A "A:" +#else +#define OPTSTRING_A "" +#endif #ifdef HAVE_LIBPCAP #if defined(_WIN32) || defined(HAVE_PCAP_CREATE) #define OPTSTRING_B "B:" @@ -856,7 +864,7 @@ main(int argc, char *argv[]) #define OPTSTRING_I "" #endif -#define OPTSTRING "2a:A:b:" OPTSTRING_B "c:C:d:De:E:f:F:G:hH:i:" OPTSTRING_I "K:lLnN:o:O:pPqr:R:s:S:t:T:u:vVw:W:xX:y:z:" +#define OPTSTRING "2a:" OPTSTRING_A "b:" OPTSTRING_B "c:C:d:De:E:f:F:G:hH:i:" OPTSTRING_I "K:lLnN:o:O:pPqr:R:s:S:t:T:u:vVw:W:xX:y:z:" static const char optstring[] = OPTSTRING; @@ -1094,6 +1102,9 @@ main(int argc, char *argv[]) case 'f': /* capture filter */ case 'i': /* Use interface x */ case 'p': /* Don't capture in promiscuous mode */ +#ifdef HAVE_PCAP_REMOTE + case 'A': /* Authentication */ +#endif #ifdef HAVE_PCAP_CREATE case 'I': /* Capture in monitor mode, if available */ #endif |