[Dreamhack] wheat-and-barley
[Dreamhack] wheat-and-barley
문제 링크
https://dreamhack.io/wargame/challenges/2146
문제 설명
You reap what you sow.
문제 분석
stdout
(_IO_2_1_stdout
) 으로부터 최대0x2000
만큼 떨어진 위치에 총 2번의 임의 값 쓰기가 가능하다.stdout
과 가까운 위치에__printf_function_table
과__printf_arginfo_table
이 위치하므로, 이를 조작하여win
함수를 실행하면 셸을 실행할 수 있다.- 해당 방법에 대한 분석은 아래 링크를 참고한다.
새롭게 알게된 점
이 기사는 저작권자의 CC BY 4.0 라이센스를 따릅니다.