In
computer software
Software is a set of computer programs and associated documentation and data. This is in contrast to hardware, from which the system is built and which actually performs the work.
At the lowest programming level, executable code consists ...
, strings is a program in
Unix
Unix (; trademarked as UNIX) is a family of multitasking, multiuser computer operating systems that derive from the original AT&T Unix, whose development started in 1969 at the Bell Labs research center by Ken Thompson, Dennis Ritchie, a ...
,
Plan 9 Plan 9 or Plan Nine may refer to:
Music
* Plan 9 (band), a psychedelic rock band from Rhode Island
* ''Plan 9'', an album by Big Guitars From Memphis with Rick Lindy
* "Plan 9", a song on the 1993 album ''Gorgeous'' by electronica band 808 Stat ...
,
Inferno, and
Unix-like
A Unix-like (sometimes referred to as UN*X or *nix) operating system is one that behaves in a manner similar to a Unix system, although not necessarily conforming to or being certified to any version of the Single UNIX Specification. A Unix-li ...
operating system
An operating system (OS) is system software that manages computer hardware, software resources, and provides common daemon (computing), services for computer programs.
Time-sharing operating systems scheduler (computing), schedule tasks for ef ...
s that finds and prints text
strings embedded in
binary files
A binary file is a computer file that is not a text file. The term "binary file" is often used as a term meaning "non-text file". Many binary file formats contain parts that can be interpreted as text; for example, some computer document file ...
such as executables. It can be used on object files and
core dump
In computing, a core dump, memory dump, crash dump, storage dump, system dump, or ABEND dump consists of the recorded state of the working Computer storage, memory of a computer program at a specific time, generally when the program has crash (comp ...
s.
Overview
Strings are recognized by looking for sequences of at least 4 (by default) printable characters terminating in a NUL character (that is,
null-terminated strings). Some implementations provide options for determining what is recognized as a printable character, which is useful for finding non-ASCII and wide character text.
Common usage includes piping its output to and or redirecting the output to a
file.
It is part of the
GNU Binary Utilities (), and has been ported to other operating systems including
Windows
Windows is a group of several proprietary graphical operating system families developed and marketed by Microsoft. Each family caters to a certain sector of the computing industry. For example, Windows NT for consumers, Windows Server for ...
.
[ cygwin]
Example
Using ''strings'' to print sequences of characters that are at least 8 characters long (this command prints the system's
BIOS
In computing, BIOS (, ; Basic Input/Output System, also known as the System BIOS, ROM BIOS, BIOS ROM or PC BIOS) is firmware used to provide runtime services for operating systems and programs and to perform hardware initialization during the ...
information; should be run as root):
dd if=/dev/mem bs=1k skip=768 count=256 2>/dev/null , strings -n 8 , less
See also
*
Cat (Unix)
cat is a standard Unix utility that reads files sequentially, writing them to standard output. The name is derived from its function to (con)catenate files (from Latin ''catenare'', "to chain"). It has been ported to a number of operating syst ...
*
Paste (Unix)
*
GNU Debugger
The GNU Debugger (GDB) is a portable debugger that runs on many Unix-like systems and works for many programming languages, including Ada, C, C++, Objective-C, Free Pascal, Fortran, Go, and partially others.
History
GDB was first writte ...
*
Strip (Unix)
References
External links
*
*
*
Unix text processing utilities
Unix SUS2008 utilities
Plan 9 commands
Inferno (operating system) commands
String (computer science)
{{unix-stub