我試圖「破解」一個控制檯程序,迫使它顯示一些東西。問題是我無法打印換行符(\r\n
)。 隨着disassebler我找到了那個地方和編輯二進制:call printf()編輯可執行文件
push 4ad0eb46 ; the string (let's pretend "Hi guys")
push 4ad0eb80 ; and the format ("%s")
call near ds:[<&msvcrt.printf>] ; call printf
jmp 4ad0eb4f ; skip data
; now here I coded the strings
mov ds:[4ad289ec],eax ; and here the program resumes
正如我所說的,我無法打印一個換行符。我嘗試在格式字符串中編碼"\r\n"
(因此它變成"%s\r\n"
,就像我在C中所做的那樣)並獲得打印"Hi guys\r\n"
,並將其編碼爲 字符串本身(使其爲"Hi guys\x13\x10"
)並獲得"Hi guys"
和兩個奇怪字符,可能是ASCII表示0x13和0x10。
你得到了什麼「奇怪的人物」?對你而言,似乎很陌生的東西可能是對別人有用的信息。 – 2011-01-10 18:02:30
一種'!!'和一個三角形,類似'|>' – BlackBear 2011-01-10 18:05:39