.\" -*- mode: troff; coding: utf-8 -*- .\" Automatically generated by Pod::Man 5.01 (Pod::Simple 3.43) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" \*(C` and \*(C' are quotes in nroff, nothing in troff, for use with C<>. .ie n \{\ . ds C` "" . ds C' "" 'br\} .el\{\ . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is >0, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .nr rF 0 .if \n(.g .if rF .nr rF 1 .if (\n(rF:(\n(.g==0)) \{\ . if \nF \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{\ . nr % 0 . nr F 2 . \} . \} .\} .rr rF .\" ======================================================================== .\" .IX Title "IPFIXDUMP 1" .TH IPFIXDUMP 1 %v 2.4.1 libfixbuf .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH NAME ipfixDump \- Print contents of an IPFIX file as human\-readable text .SH SYNOPSIS .IX Header "SYNOPSIS" .Vb 4 \& ipfixDump [\-\-in FILE_NAME] [\-\-out FILE_NAME] \& [\-\-rfc5610] [\-\-element\-file FILE_NAME] [\-\-yaf] \& [\-\-templates] [\-\-data] [\-\-stats] \& [\-\-hexdump[=LEN]] \& \& ipfixDump [\-\-version] \& \& ipfixDump [\-\-help] .Ve .SH DESCRIPTION .IX Header "DESCRIPTION" \&\fBipfixDump\fR is a tool to read an IPFIX file and print its contents as human-readable ASCII to assist the user in analyzing the file. \fBipfixDump\fR prints all message headers, templates, data records, options templates, and options records to the output, plus a one line summary of the file's content. .PP \&\fBipfixDump\fR supports IPFIX structured data in the form of basicLists, subTemplateLists, and subTemplateMultiLists. .PP By default, \fBipfixDump\fR reads the IPFIX file from the standard input and writes the text to the standard output. To specify the input or output file's location, use the \fB\-\-in\fR or \fB\-\-out\fR option, respectively. .PP \&\fBipfixDump\fR requires the input file to contain the IPFIX templates that describe the data records within the file, and the template must appear before the records that use it. Any records that do not have a corresponding template are ignored. .PP The default information model used by \fBipfixDump\fR includes only the standard information elements defined by IANA and provided by libfixbuf. There are three ways to augment the set of elements: .IP 1. 4 The \fB\-\-rfc5610\fR option instructs \fBipfixDump\fR to watch the input for options records that define private enterprise information elements (as defined by RFC5610 ) and to add those elements to the information model. .IP 2. 4 The \fB\-\-element\-file=\fR\f(BIFILE_NAME\fR option tells \fBipfixDump\fR to parse the contents of \fIFILE_NAME\fR and add those information elements to the information model. The argument is an XML file whose schema is that used by IANA's XML Information Element Registry , with the following additions: .RS 4 .IP cert:enterpriseId 4 .IX Item "cert:enterpriseId" A number representing the Private Enterprise Number of the element .IP cert:reversible 4 .IX Item "cert:reversible" A boolean value (\f(CW\*(C`true\*(C'\fR, \f(CW\*(C`yes\*(C'\fR, or \f(CW1\fR for true; \f(CW\*(C`false\*(C'\fR, \f(CW\*(C`no\*(C'\fR, or \f(CW0\fR for false) that specifies whether the element may have a separate identity in a reverse flow. .RE .RS 4 .Sp The \fB\-\-element\-file\fR option may be used multiple times to load multiple files, and the loaded elements replace existing elements with the same identifier. .RE .IP 3. 4 The \fB\-\-yaf\fR option loads the CERT private enterprise information elements into the information model. These elements are used by the NetSA tools \fByaf\|(1)\fR, \&\fBpipeline\|(8)\fR, \fBsuper_mediator\|(1)\fR, and \fBrwsilk2ipfix\|(1)\fR. This option is implemented as a wrapper over the \fB\-\-element\-file\fR option where the file name is \fIcert_ipfix.xml\fR and \fBipfixDump\fR checks several directories to attempt to find this file, stopping once it finds the first file. The list of directories, in search order, is .RS 4 .IP \(bu 4 the directory \fI../share/libfixbuf\fR relative to the directory containing the application .IP \(bu 4 the \fIlibfixbuf\fR subdirectory of the \f(CW\*(C`datadir\*(C'\fR directory specified when \&\fBipfixDump\fR was configured (defaults to \fR\f(CI$prefix\fR\fI/share\fR) .IP \(bu 4 the \fIshare/libfixbuf\fR subdirectory installation folder for the GLib\-2 library .IP \(bu 4 the \fIlibfixbuf\fR subdirectory of the directories specified by the \&\f(CW$XDG_DATA_DIRS\fR environment variable, or \fI/usr/local/share\fR and \&\fI/usr/share/libfixbuf\fR when that variable is empty .RE .RS 4 .Sp \&\fBipfixDump\fR exits with an error if it is unable to find the \fIcert_ipfix.xml\fR file. See for additional information about this file. .RE .SH OPTIONS .IX Header "OPTIONS" The following options are available for \fBipfixDump\fR: .IP "\fB\-\-in\fR \fIFILE_NAME\fR" 4 .IX Item "--in FILE_NAME" Sets the input file name to \fIFILE_NAME\fR. When the option is not specified, \&\fBipfixDump\fR reads from the standard input or exits with an error when the standard input is a terminal. \fBipfixDump\fR reads from the standard input if \&\fIFILE_NAME\fR is '\f(CW\*(C`\-\*(C'\fR'. .IP "\fB\-\-out\fR \fIFILE_NAME\fR" 4 .IX Item "--out FILE_NAME" Sets the output file name to \fIFILE_NAME\fR. If \fIFILE_NAME\fR exists, it is overwritten. The string '\f(CW\*(C`\-\*(C'\fR' may be used to write to standard output (the default). .IP \fB\-\-rfc5610\fR 4 .IX Item "--rfc5610" Tells \fBipfixDump\fR to scan the IPFIX input file for options records that define private enterprise information elements and to add those elements to the information model. .IP "\fB\-\-element\-file\fR \fIFILE_NAME\fR" 4 .IX Item "--element-file FILE_NAME" Loads the XML file \fIFILE_NAME\fR and incorporates information element information found in it. The format of the file is described above. The option may be used multiple times to load multiple files, and later elements replace existing elements when they have the same identifier. .IP \fB\-\-yaf\fR 4 .IX Item "--yaf" Searches for a file named \fIcert_ipfix.xml\fR in several locations and loads that file as if it was an argument to \fB\-\-element\-file\fR. \fBipfixDump\fR exits with an error if it is unable to find the \fIcert_ipfix.xml\fR file. .IP \fB\-\-templates\fR 4 .IX Item "--templates" Suppresses the printing of records, causing the output to contain only message headers, templates, and a summary line. .IP \fB\-\-data\fR 4 .IX Item "--data" Suppresses the printing of templates, causing the output to contain only message headers, records, and a summary line. .IP \fB\-\-stats\fR 4 .IX Item "--stats" Suppresses the printing of all message headers, templates, and records. The output consists of the number of messages, templates, and records present in the input, and a two-column list showing template IDs found in the input and a count of the number of records that used that template. .IP \fB\-\-hexdump\fR 4 .IX Item "--hexdump" For data record elements whose type is octetArray, prints each octet as a 2\-digit hexadecimal value with a no separator between the values. The length of the element precedes the hexadecimal output. \fBipfixDump\fR uses this display for octetArray elements that are variable length or whose length is greater than eight. Without this option, only the length of the octetArray elements are printed. Note that fixed-width octetArray elements whose length is less than or equal to eight are always printed as a decimal number regardless of this option. .IP \fB\-\-hexdump=\fR\f(BILEN\fR 4 .IX Item "--hexdump=LEN" When the optional parameter \fILEN\fR is provided to \fB\-\-hexdump\fR, only the first \&\fILEN\fR octets of the value are printed. If \fILEN\fR is zero, only the length of octetArray values is printed. A \fILEN\fR that is negative or larger than 65535 is treated as the maximum, 65535. .IP \fB\-\-version\fR 4 .IX Item "--version" Prints version and copyright information to standard error and exits. .IP \fB\-\-help\fR 4 .IX Item "--help" Prints a brief usage message to the standard output and exits. .SH Examples .IX Header "Examples" In the following examples, the dollar sign ("$") represents the shell prompt. The text after the dollar sign represents the command line. .Sp .Vb 1 \& $ ipfixDump \-\-in \- \-\-out \- \& \& $ ipfixDump \-\-in /data/ipfix.ipfix \-\-out /data/text.txt \-\-yaf .Ve .SH "Known Issues" .IX Header "Known Issues" Bug reports may be sent directly to the Network Situational Awareness team at . .SH AUTHORS .IX Header "AUTHORS" Emily Sarneso and the CERT Network Situational Awareness Group Engineering Team, . .SH "SEE ALSO" .IX Header "SEE ALSO" \&\fByaf\|(1)\fR, \fByafscii\|(1)\fR, \fByafdpi\|(1)\fR, \fBsuper_mediator\|(1)\fR, \fBpipeline\|(8)\fR, \&\fBrwsilk2ipfix\|(1)\fR, ,