linux include 파일 찾기
$ grep -r "struct iphdr" /usr/include
'OS > linux' 카테고리의 다른 글
| /proc/self/cwd (0) | 2019.05.09 |
|---|---|
| 프로세스에서 사용중인 파일 디스크립터 찾기 (0) | 2018.07.20 |
| 리눅스 넘버링? (0) | 2018.03.27 |
| 리눅스 세션 연결 시 history 자동 삭제하기 (0) | 2018.03.20 |
| vim 화면 스크롤 (0) | 2018.02.15 |
| /proc/self/cwd (0) | 2019.05.09 |
|---|---|
| 프로세스에서 사용중인 파일 디스크립터 찾기 (0) | 2018.07.20 |
| 리눅스 넘버링? (0) | 2018.03.27 |
| 리눅스 세션 연결 시 history 자동 삭제하기 (0) | 2018.03.20 |
| vim 화면 스크롤 (0) | 2018.02.15 |
'/proc/self/cwd'는 현재 실행중인 프로세스의 디렉토리 표시하는 명령어다.

ctf때 쓸 수 있을 것 같다.
| linux include 파일 찾기 (0) | 2020.07.02 |
|---|---|
| 프로세스에서 사용중인 파일 디스크립터 찾기 (0) | 2018.07.20 |
| 리눅스 넘버링? (0) | 2018.03.27 |
| 리눅스 세션 연결 시 history 자동 삭제하기 (0) | 2018.03.20 |
| vim 화면 스크롤 (0) | 2018.02.15 |
실행중인 프로세스의 pid 확인
pid = 7915
proc에서 해당 pid의 fd 확인
ls -l /proc/[pid]/fd
Ref.http://mintnlatte.tistory.com/377
| linux include 파일 찾기 (0) | 2020.07.02 |
|---|---|
| /proc/self/cwd (0) | 2019.05.09 |
| 리눅스 넘버링? (0) | 2018.03.27 |
| 리눅스 세션 연결 시 history 자동 삭제하기 (0) | 2018.03.20 |
| vim 화면 스크롤 (0) | 2018.02.15 |
우연히 알게된 리눅스 스킬이다.
{start..end} 이렇게 이름을 주면 자동으로 넘버링을 해준다. 개신기.
| /proc/self/cwd (0) | 2019.05.09 |
|---|---|
| 프로세스에서 사용중인 파일 디스크립터 찾기 (0) | 2018.07.20 |
| 리눅스 세션 연결 시 history 자동 삭제하기 (0) | 2018.03.20 |
| vim 화면 스크롤 (0) | 2018.02.15 |
| [명령어] strings (0) | 2016.07.28 |
.bash_history를 실행시마다 지워주도록 하면 된다.
$ln -s /dev/null .bash_history| /proc/self/cwd (0) | 2019.05.09 |
|---|---|
| 프로세스에서 사용중인 파일 디스크립터 찾기 (0) | 2018.07.20 |
| 리눅스 넘버링? (0) | 2018.03.27 |
| vim 화면 스크롤 (0) | 2018.02.15 |
| [명령어] strings (0) | 2016.07.28 |
| 명령 | 기술 |
|---|---|
| Ctrl + E | 한 줄 아래로 스크롤하십시오. |
| Ctrl + D | 화면 절반을 스크롤 다운합니다 ( scroll 옵션을 사용하여 구성 가능). |
| Ctrl + F | 전체 화면을 아래로 스크롤하십시오. |
| z + | 창의 맨 위에있는 창 아래의 첫 번째 선을 그립니다. |
| 명령 | 기술 |
|---|---|
| 지 | 창의 맨 위에있는 현재 행을 다시 그려서 커서를 행의 첫 번째 공백이 아닌 문자에 놓습니다. |
| zt | z와 같지만 커서는 같은 열에 두십시오. |
| 지. | 창의 가운데에있는 현재 행을 다시 그리기하고 행의 첫 번째 비 공백 문자에 커서를 놓습니다. |
| zz | z와 같습니다. 동일한 열에 커서를 두십시오. |
| 지- | 창의 맨 아래에있는 현재 행을 다시 그려서 커서를 행의 첫 번째 비 공백 문자에 놓습니다. |
| zb | z-와 같지만 커서는 같은 열에 두십시오. |
| 명령 | 기술 |
|---|---|
| Ctrl + Y | 한 줄 위로 스크롤하십시오. |
| Ctrl + U | 화면 반 스크롤 ( scroll 옵션을 사용하여 구성 가능). |
| Ctrl + B | 전체 화면을 위로 스크롤하십시오. |
| z ^ | 창의 아래쪽에있는 창 위의 첫 번째 선을 그립니다. |
| /proc/self/cwd (0) | 2019.05.09 |
|---|---|
| 프로세스에서 사용중인 파일 디스크립터 찾기 (0) | 2018.07.20 |
| 리눅스 넘버링? (0) | 2018.03.27 |
| 리눅스 세션 연결 시 history 자동 삭제하기 (0) | 2018.03.20 |
| [명령어] strings (0) | 2016.07.28 |
strings는 바이너리 파일에서 문자열을 추출하기 위한 툴입니다.
grep을 이용하여 원하는 문자열을 빠르게 확인할 수 있습니다.
ex)
SSo@ubuntu: ~ $ stirngs [파일명] | grep [검색할 문자열]
1. 문자열의 위치 출력
-tx, -td, to 옵션을 사용하면 각각 16진수, 10진수, 8진수로 문자열의 위치를 출력함
-t 옵션 예
SSo@ubuntu: ~ $ stirngs -tx [파일명] | head -5
SSo@ubuntu: ~ $ stirngs -td [파일명] | head -5
SSo@ubuntu: ~ $ stirngs -to [파일명] | head -5
$man strings
NAME
strings - find the printable strings in a object, or other binary, file
SYNOPSIS
strings [ - ] [ -a ] [ -o ] [ -t format ] [ -number ] [ -n number ] [--] [file ...]
DESCRIPTION
Strings looks for ASCII strings in a binary file or standard input. Strings is useful for identifying random
object files and many other things. A string is any sequence of 4 (the default) or more printing characters ending
with a newline or a null. Unless the - flag is given, strings looks in all sections of the object files except the
(__TEXT,__text) section. If no files are specified standard input is read.
The file arguments may be of the form libx.a(foo.o), to request information about only that object file and not the
entire library. (Typically this argument must be quoted, ``libx.a(foo.o)'', to get it past the shell.)
The options to strings(1) are:
-a This option causes strings to look for strings in all sections of the object file (including the
(__TEXT,__text) section.
- This option causes strings to look for strings in all bytes of the files (the default for non-object files).
-- This option causes strings to treat all the following arguments as files.
-o Preceded each string by its offset in the file (in decimal).
-t format
Write each string preceded by its byte offset from the start of the file. The format shall be dependent on
the single character used as the format option-argument:
d The offset shall be written in decimal.
o The offset shall be written in octal.
x The offset shall be written in hexadecimal.
-number
The decimal number is used as the minimum string length rather than the default of 4.
-n number
Specify the minimum string length, where the number argument is a positive decimal integer. The default
shall be 4.
-arch arch_type
Specifies the architecture, arch_type, of the file for strings(1) to operate on when the file is a universal
file. (See arch(3) for the currently know arch_types.) The arch_type can be "all" to operate on all archi-
tectures in the file.
SEE ALSO
od(1)
BUGS
The algorithm for identifying strings is extremely primitive.
| /proc/self/cwd (0) | 2019.05.09 |
|---|---|
| 프로세스에서 사용중인 파일 디스크립터 찾기 (0) | 2018.07.20 |
| 리눅스 넘버링? (0) | 2018.03.27 |
| 리눅스 세션 연결 시 history 자동 삭제하기 (0) | 2018.03.20 |
| vim 화면 스크롤 (0) | 2018.02.15 |