Linux command detailed document and directory management file lookup and comparison

Source: Internet
Author: User

1. File Search

1.1 Strings Command

-------to find printable strings in an object file or binary file. The string is any sequence of 4 or more printable, ending with a newline or a null character. The strings command is useful for identifying random object files.

"Syntax":

Strings  [-a|-|--all] [-f|--print-file-name] [-O] [--help] [-v|--version] [-t bfdname |--target=bfdname]
[-N Min-len|-min-len|--bytes=min-len] [-t {O,x,d}[--target=bfdname] |--radix={o,x,d}] File

"Options":

-a|--all: Scans the entire file instead of only the target file initialization and loading segments

-f|--print-file-name: Displays the file name before displaying the string

-t {O,x,d}[--target=bfdname] |--radix={o,x,d}: The position of the output character, based on octal, decimal, hexadecimal

-O: similar to--radix=o;

-: Set the minimum number of characters displayed, default is 4 characters

-N Min-len|-min-len|--bytes=min-len: Finds and outputs all NUL terminator sequences

--HELP: Options for output Strings command

Version number of the-v|--version:strings command

-T Bfdname | --target=bfdname: Specifying binary file formats

Instance  

Find the string containing libc in LS, case-insensitive

[Email protected]:~$ strings/bin/ls|grep-i libclibc.so.6__libc_start_mainglibc_2. -glibc_2.4glibc_2. -glibc_2.3.4glibc_2.2.5glibc_2.3

Look at the effect of the-f option on the above basis:[email protected]-thinkpad-t450:~$ strings-f/bin/ls|grep-I libc/bin/ls: libc.so.6/bin/ls: __libc_start_main/bin/ls: glibc_2. -/bin/ls: glibc_2.4/bin/ls: glibc_2. -/bin/ls: glibc_2.3.4/bin/ls: glibc_2.2.5/bin/ls: glibc_2.3

Linux command detailed document and directory management file lookup and comparison

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.