strings Command Purpose Finds the printable strings in an object or binary file. Syntax strings [ -a ] [ - ] [ -o ] [ -Number ] File ... Description The strings command looks for printable strings in a binary file. A string is any sequence of 4 or more printing characters ending with a new line or a null. The strings command is useful for identifying random object files. Flags -a or - Searches the entire file, not just data section, for printable strings. -o Lists each string preceded by its offset in the file (in oc- tal). -Number Specifies minimum string length rather than 4. File Binary or object file to be searched. Exit Status This command returns the following exit values: 0 Specifies that the command ran successfully. >0 Specifies that an error occurred. Examples 1. To search a file: strings strings L@(#)strings.c 1.10 com/cmd/scan, 3.1, 8946H 12/14/89 17:00:24 Standard input strings.cat usage: strings [-a] [-o] [-#] [file...] %7o_ 2. Searches for strings at least 12 characters long. strings -12 strings L@(#)strings.c 1.10 com/cmd/scan, 3.1, 8946H 12/14/89 17:00:24 Standard input strings.cat usage: strings [-a] [-o] [-#] [file...] 3. Searches for strings at least 20 characters long and also shows offset in file. strings -o -20 /usr/ccs/bin/strings 7036 1.10 com/cmd/scan, 3.1 8946H 12/14/89 17:00;24 7160 Usage: strings [-a] [-o] [-#] [file...] Implementation Specifics This command is part of Base Operating System (BOS) Runtime. Related Information The od command.