binutils: strings
1
1 7 strings
1 *********
1
1 strings [-afovV] [-MIN-LEN]
1 [-n MIN-LEN] [--bytes=MIN-LEN]
1 [-t RADIX] [--radix=RADIX]
1 [-e ENCODING] [--encoding=ENCODING]
1 [-U METHOD] [--unicode=METHOD]
1 [-] [--all] [--print-file-name]
1 [-T BFDNAME] [--target=BFDNAME]
1 [-w] [--include-all-whitespace]
1 [-s] [--output-separatorSEP_STRING]
1 [--help] [--version] FILE...
1
1 For each FILE given, GNU 'strings' prints the printable character
1 sequences that are at least 4 characters long (or the number given with
1 the options below) and are followed by an unprintable character.
1
1 Depending upon how the strings program was configured it will default
1 to either displaying all the printable sequences that it can find in
1 each file, or only those sequences that are in loadable, initialized
1 data sections. If the file type in unrecognizable, or if strings is
1 reading from stdin then it will always display all of the printable
1 sequences that it can find.
1
1 For backwards compatibility any file that occurs after a command line
1 option of just '-' will also be scanned in full, regardless of the
1 presence of any '-d' option.
1
1 'strings' is mainly useful for determining the contents of non-text
1 files.
1
1 '-a'
1 '--all'
1 '-'
1 Scan the whole file, regardless of what sections it contains or
1 whether those sections are loaded or initialized. Normally this is
1 the default behaviour, but strings can be configured so that the
1 '-d' is the default instead.
1
1 The '-' option is position dependent and forces strings to perform
1 full scans of any file that is mentioned after the '-' on the
1 command line, even if the '-d' option has been specified.
1
1 '-d'
1 '--data'
1 Only print strings from initialized, loaded data sections in the
1 file. This may reduce the amount of garbage in the output, but it
1 also exposes the strings program to any security flaws that may be
1 present in the BFD library used to scan and load sections. Strings
1 can be configured so that this option is the default behaviour. In
1 such cases the '-a' option can be used to avoid using the BFD
1 library and instead just print all of the strings found in the
1 file.
1
1 '-f'
1 '--print-file-name'
1 Print the name of the file before each string.
1
1 '--help'
1 Print a summary of the program usage on the standard output and
1 exit.
1
1 '-MIN-LEN'
1 '-n MIN-LEN'
1 '--bytes=MIN-LEN'
1 Print sequences of characters that are at least MIN-LEN characters
1 long, instead of the default 4.
1
1 '-o'
1 Like '-t o'. Some other versions of 'strings' have '-o' act like
1 '-t d' instead. Since we can not be compatible with both ways, we
1 simply chose one.
1
1 '-t RADIX'
1 '--radix=RADIX'
1 Print the offset within the file before each string. The single
1 character argument specifies the radix of the offset--'o' for
1 octal, 'x' for hexadecimal, or 'd' for decimal.
1
1 '-e ENCODING'
1 '--encoding=ENCODING'
1 Select the character encoding of the strings that are to be found.
1 Possible values for ENCODING are: 's' = single-7-bit-byte
1 characters (ASCII, ISO 8859, etc., default), 'S' =
1 single-8-bit-byte characters, 'b' = 16-bit bigendian, 'l' = 16-bit
1 littleendian, 'B' = 32-bit bigendian, 'L' = 32-bit littleendian.
1 Useful for finding wide character strings. ('l' and 'b' apply to,
1 for example, Unicode UTF-16/UCS-2 encodings).
1
1 '-U [D|I|L|E|X|H]'
1 '--unicode=[DEFAULT|INVALID|LOCALE|ESCAPE|HEX|HIGHLIGHT]'
1 Controls the display of UTF-8 encoded mulibyte characters in
1 strings. The default ('--unicode=default') is to give them no
1 special treatment, and instead rely upon the setting of the
1 '--encoding' option. The other values for this option
1 automatically enable '--encoding=S'.
1
1 The '--unicode=invalid' option treats them as non-graphic
1 characters and hence not part of a valid string. All the remaining
1 options treat them as valid string characters.
1
1 The '--unicode=locale' option displays them in the current locale,
1 which may or may not support UTF-8 encoding. The '--unicode=hex'
1 option displays them as hex byte sequences enclosed between <>
1 characters. The '--unicode=escape' option displays them as escape
1 sequences (\UXXXX) and the '--unicode=highlight' option displays
1 them as escape sequences highlighted in red (if supported by the
1 output device). The colouring is intended to draw attention to the
1 presence of unicode sequences where they might not be expected.
1
1 '-T BFDNAME'
1 '--target=BFDNAME'
1 Specify an object code format other than your system's default
1 format. ⇒Target Selection, for more information.
1
1 '-v'
1 '-V'
1 '--version'
1 Print the program version number on the standard output and exit.
1
1 '-w'
1 '--include-all-whitespace'
1 By default tab and space characters are included in the strings
1 that are displayed, but other whitespace characters, such a
1 newlines and carriage returns, are not. The '-w' option changes
1 this so that all whitespace characters are considered to be part of
1 a string.
1
1 '-s'
1 '--output-separator'
1 By default, output strings are delimited by a new-line. This
1 option allows you to supply any string to be used as the output
1 record separator. Useful with -include-all-whitespace where
1 strings may contain new-lines internally.
1