0x02 Reverse Engineer(124)
-
[파일 자동 삭제]
#define _CRT_SECURE_NO_WARNINGS#include #include void Kill(char *thisFile){FILE *fp = NULL;// batch파일명char* killer = "killfile.bat";// 실행파일명char* thisFileReal = thisFile;char szBatFile[256]; // batch파일을 생성합니다.fp = fopen(killer, "wt");if (fp == NULL){puts("파일생성 실패");return;} // batch파일에 실행할 내용 작성wsprintfA(szBatFile,":Repeat \r\n""del /f /s /q %s \r\n""if exist \"%s\" goto Repeat \r\n""del /s /q %..
2017.09.19 -
[H4C CTF] Let's Bingo !
보호되어 있는 글입니다.
2017.09.09 -
[Basic] Tutorial Reversing - Controlled to printf
많은 사람들이 C언어를 처음 접했을 때 'hello world' 부터 경험하면서 우와 이거 정말 신기하다. 라고 느꼈을 것이다. ( 전 정말로 너무 신기했었습니다. 까만 창에 글이 적히는 행위가)그때를 회상하며, 오늘은 리버스엔지니어링에서 'hello world'를 조작하는 방법에 대해 포스팅을 해볼까합니다. 카카오톡 오픈채팅에서 어떤 분이 부탁하셔서 작성하게 되었는데, 은근히 글 쓰는게 재밌을 것 같아서 흔쾌히 동의하고 포스팅을 시작해봅니다. 우선, 프로그램을 만들어야겠죠? VS IDE를 이용하도록 하겠습니다. IDE(Integrated development environment) 라고 하는데요. 코딩, 디버그, 컴파일, 배포 등 프로그램 개발에 관련된 모든 작업을 하나의 프로그램 안에서 처리하는 환경..
2017.08.25 -
[CodeEngn Basic 15] obj. KNOW BOLRAND & Routine
문제 : Find the Serial when the name is CodeEngn 바이너리 실행 : [그림 1] 바이너리 실행 [그림 2] Borland Delphi 바이너리 컴파일 한 언어는 볼랜드였다. 볼랜드도 C기반이라고 들었던 것 같은데.. 검색을 해보고, 링크를 걸어두었다. https://en.wikipedia.org/wiki/Borland_C%2B%2B 올리디버거로 까보자. 볼랜드도 엔트리포인트는 4번대 주소였다. 그럼 c언어를 모토로 삼는 언어는 다들 유저 메모리 영역이 4번대인가보다.(exe) [그림 3] 처음 보는 Borland 구조 구경중~ win32api와 다른건 없다. 똑같이 모듈을 얻어오는 GetModuleHandle, 윈도우 창을 세팅해주는 SetWindow, GetDC, Re..
2017.08.23 -
[CodeEngn Basic 13] Find the Answer feat. C#
문제 : Find the Answer 바이너리 실행 : [그림 1] 비밀번호를 입력하는 프로그램 틀리면 계속 반복하는 프로그램 (부르트포싱이 가능한가?) [그림 2] 틀린 비밀번호 바이너리를 뜯어보아요. C# 프로그램이다..!! C#은 디컴파일러가 따로 존재한다. [STAThread]private static void Main(string[] args){ string plainText = ""; string cipherText = "BnCxGiN4aJDE+qUe2yIm8Q=="; string passPhrase = "^F79ejk56$\x00a3"; string saltValue = "DHj47&*)$h"; string hashAlgorithm = "MD5"; int passwordIterations =..
2017.08.20 -
[CodeEngn Basic 12] Can you replace?
문제 : You will see a success message after finding the key. If you would want the Key itself to replace the success message in the MessageBox, open up a Hex Editor and overwrite the key value in the offset range 0x???? ~ 0x????. Q : find the key value and the offset range and write the solution in this format : key???????? (first ???? for the start and the next 4 ?s for the end). 바이너리 실행 : [그림 1]..
2017.08.20