私はこのキーロガーにオンラインで出くわし、次のコードが実際に何をするのか疑問に思いました。連続して2つのlodsdコマンドがあり、それは私を混乱させます。また、orコマンドの目的は何ですか?完全なコードは次の場所にあります:http: //www.rohitab.com/discuss/topic/21205-asm-keylogger-in-4k-d/
コードの抜粋(295行目以降)は次のとおりです。
get_name_of_key: ; no need for large table of pointers to get asciiz
mov esi, [lParam]
lodsd ; skip virtual key code
lodsd ; eax = scancode
shl eax, 16
xchg eax, ecx
lodsd ; extended key info
shl eax, 24
or ecx, eax
push 32
lea edi, [lpCharBuf]
push edi
push ecx
call GetKeyNameTextA ; get the key text