/bin/sh 문자열 주소 찾는 방법.
·
Tips & theory
사실 /bin/sh 문자열만 찾는 것은 아니며 이를 활용해서 여러 함수의 주소를 찾을 수 있다. gdb에서 찾기. 보통 system 함수와 함께 쓰이므로 아래와 같이 찾을 수 있다. gef➤ find &system,+999999999,"/bin/sh" 0xb7f8ad4c warning: Unable to access 16000 bytes of target memory at 0xb7fd8f54, halting search. 1 pattern found. gef➤ x/s 0xb7f8ad4c 0xb7f8ad4c: "/bin/sh" 또는 gef 같은 경우 grep 명령어로 찾을 수 있다. gef➤ grep /bin/sh [+] Searching '/bin/sh' in memory [+] In '/usr/lib/..