iT邦幫忙

2025 iThome 鐵人賽

DAY 29
0
Security

逆向系列 第 29

逆向題目練習 - blade(4)

  • 分享至 

  • xImage
  •  

承接上文,

  • 查看完 verify 後,我們觀察即可能與 verify 相關的 prompt 程式碼,並搜尋 verify
    https://ithelp.ithome.com.tw/upload/images/20250831/20168374wnBL0o3obd.png

    https://ithelp.ithome.com.tw/upload/images/20250831/20168374xswMou33w6.png

    • 我們在 13A6D 查看到該程式碼(按下 Tab 可進行反編譯)

      cmp dword ptr [r15], 67616C66h
      
      或
      
      case 0x67616C66:
      

      67616C66 為 16 進位 → 0x67 0x61 0x6C 0x66,轉換成 ASCII = glaf(按右鍵,點擊 Char 轉換即可),由於檔案為 Little Endian,因此需要倒過來看,即為 flag ,因此若輸入的指令開頭為 flag ,則會觸發 verify
      https://ithelp.ithome.com.tw/upload/images/20250831/20168374kuf2n69j3G.png
      https://ithelp.ithome.com.tw/upload/images/20250831/201683746tgLaIOBtl.png

      其他在 flag 附近的 case 分別為:

      • 65707974 = "type"
      • 67616C66 = "flag"
      • 74697865 = "exit"
      • 74697571 = "quit"

      因此我們回到終端機,輸入「開頭為 flag」的任意字串,得到了 Incorrect 的結果,與輸入一般指令(此處輸入 a)得到的回覆不同,證實輸入開頭為 flag 的任意字串可進入隱藏的 flag checker

      https://ithelp.ithome.com.tw/upload/images/20250831/20168374kjtYY3ulZ4.png
      https://ithelp.ithome.com.tw/upload/images/20250831/201683741Dvr6vaBOV.png


上一篇
逆向題目練習 - blade(3)
下一篇
逆向題目練習 - blade(5)
系列文
逆向30
圖片
  熱門推薦
圖片
{{ item.channelVendor }} | {{ item.webinarstarted }} |
{{ formatDate(item.duration) }}
直播中

尚未有邦友留言

立即登入留言