joyce8/EMBER2024-capa huggingface dataset:
Function at 0x41a380
Capabilities:
Enumerate process modules

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x122c
call fcn.0042e430
mov eax, dword [0x43f0f0]
xor eax, ebp
mov dword [ebp - 4], eax
mov dword [ebp - 0x1214], ecx
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
push eax
mov ecx, dword [ebp - 0x1214]
call fcn.0041a630
mov eax, dword [ebp - 0x1214]
mov ecx, dword [eax]
mov dword [ebp - 0x121c], ecx
lea edx, [ebp - 0x1220]
push edx
push 0x1000
lea eax, [ebp - 0x120c]
push eax
mov ecx, dword [ebp - 0x121c]
push ecx
call sub.KERNEL32.dll_K32EnumProcessModules
test eax, eax
je 0x41a488
mov dword [ebp - 0x1210], 0
jmp 0x41a3ff
mov edx, dword [ebp - 0x1210]
add edx, 1
mov dword [ebp - 0x1210], edx
mov eax, dword [ebp - 0x1220]
shr eax, 2
cmp dword [ebp - 0x1210], eax
jae 0x41a488
mov ecx, dword [ebp - 0x1210]
mov edx, dword [ebp + ecx*4 - 0x120c]
mov dword [ebp - 0x1224], edx
mov eax, dword [ebp - 0x122c]
mov dword [ebp - 0x1218], eax
mov ecx, dword [ebp - 0x1214]
mov edx, dword [ecx]
mov dword [ebp - 0x1218], edx
push 0x208
lea eax, [ebp - 0x20c]
push eax
mov ecx, dword [ebp - 0x1224]
push ecx
mov edx, dword [ebp - 0x1218]
push edx
call sub.KERNEL32.dll_K32GetModuleFileNameExW
test eax, eax
je 0x41a483
mov eax, dword [ebp - 0x1214]
add eax, 0x210
mov dword [ebp - 0x1228], eax
lea ecx, [ebp - 0x20c]
push ecx
mov ecx, dword [ebp - 0x1228]
call fcn.00419e70
jmp 0x41a3f0
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0042e417
mov esp, ebp
pop ebp
ret
Function at 0x41a4a0
Capabilities:
Enumerate process modules

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1030
call fcn.0042e430
mov eax, dword [0x43f0f0]
xor eax, ebp
mov dword [ebp - 4], eax
mov dword [ebp - 0x1008], ecx
mov eax, 1
imul ecx, eax, 0
mov edx, dword [ebp - 0x1008]
mov byte [edx + ecx + 8], 0
mov eax, dword [ebp - 0x1008]
mov ecx, dword [eax]
mov dword [ebp - 0x1018], ecx
lea edx, [ebp - 0x1028]
push edx
push 0x1000
lea eax, [ebp - 0x1004]
push eax
mov ecx, dword [ebp - 0x1018]
push ecx
call sub.KERNEL32.dll_K32EnumProcessModules
test eax, eax
je 0x41a600
mov dword [ebp - 0x100c], 0
jmp 0x41a520
mov edx, dword [ebp - 0x100c]
add edx, 1
mov dword [ebp - 0x100c], edx
cmp dword [ebp - 0x100c], 1
jae 0x41a600
push 0x4766b8
push 0x43f19c
call sub.VCRUNTIME140.dll___std_type_info_name
add esp, 8
mov dword [ebp - 0x101c], eax
push str.char__260_
mov eax, dword [ebp - 0x101c]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpA]
test eax, eax
jne 0x41a5ac
mov ecx, dword [ebp - 0x100c]
mov edx, dword [ebp + ecx*4 - 0x1004]
mov dword [ebp - 0x1020], edx
mov eax, dword [ebp - 0x102c]
mov dword [ebp - 0x1010], eax
mov ecx, dword [ebp - 0x1008]
mov edx, dword [ecx]
mov dword [ebp - 0x1010], edx
push 0x104
mov eax, dword [ebp - 0x1008]
add eax, 8
push eax
mov ecx, dword [ebp - 0x1020]
push ecx
mov edx, dword [ebp - 0x1010]
push edx
call sub.KERNEL32.dll_K32GetModuleBaseNameA
jmp 0x41a5fb
mov eax, dword [ebp - 0x100c]
mov ecx, dword [ebp + eax*4 - 0x1004]
mov dword [ebp - 0x1024], ecx
mov edx, dword [ebp - 0x1030]
mov dword [ebp - 0x1014], edx
mov eax, dword [ebp - 0x1008]
mov ecx, dword [eax]
mov dword [ebp - 0x1014], ecx
push 0x104
mov edx, dword [ebp - 0x1008]
add edx, 8
push edx
mov eax, dword [ebp - 0x1024]
push eax
mov ecx, dword [ebp - 0x1014]
push ecx
call sub.KERNEL32.dll_K32GetModuleBaseNameW
jmp 0x41a511
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0042e417
mov esp, ebp
pop ebp
ret
Function at 0x41c600
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x448
mov eax, dword [0x43f0f0]
xor eax, ebp
mov dword [ebp - 4], eax
mov dword [ebp - 0x420], 0x435668
mov eax, dword [ebp - 0x420]
add eax, 2
mov dword [ebp - 0x42c], eax
mov ecx, dword [ebp - 0x420]
mov dx, word [ecx]
mov word [ebp - 0x426], dx
add dword [ebp - 0x420], 2
cmp word [ebp - 0x426], 0
jne 0x41c62c
mov eax, dword [ebp - 0x420]
sub eax, dword [ebp - 0x42c]
sar eax, 1
mov dword [ebp - 0x430], eax
mov ecx, dword [ebp - 0x430]
mov dword [ebp - 0x434], ecx
mov edx, dword [ebp - 0x434]
mov dword [ebp - 0x438], edx
mov eax, dword [ebp - 0x438]
push eax
push 0x435668
mov ecx, dword [ebp + 8]
call fcn.0041d6a0
mov ecx, 2
imul edx, ecx, 0
lea eax, [ebp + edx - 0x41c]
push eax
push 0x105
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
test eax, eax
jne 0x41c6b3
xor al, al
jmp 0x41c759
lea ecx, [ebp - 0x210]
push ecx
push 0
push 0x43566c
lea edx, [ebp - 0x41c]
push edx
call dword [sym.imp.KERNEL32.dll_GetTempFileNameW]
test eax, eax
jne 0x41c6d9
xor al, al
jmp 0x41c759
lea eax, [ebp - 0x210]
mov dword [ebp - 0x424], eax
mov ecx, dword [ebp - 0x424]
add ecx, 2
mov dword [ebp - 0x43c], ecx
mov edx, dword [ebp - 0x424]
mov ax, word [edx]
mov word [ebp - 0x428], ax
add dword [ebp - 0x424], 2
cmp word [ebp - 0x428], 0
jne 0x41c6f4
mov ecx, dword [ebp - 0x424]
sub ecx, dword [ebp - 0x43c]
sar ecx, 1
mov dword [ebp - 0x440], ecx
mov edx, dword [ebp - 0x440]
mov dword [ebp - 0x444], edx
mov eax, dword [ebp - 0x444]
mov dword [ebp - 0x448], eax
mov ecx, dword [ebp - 0x448]
push ecx
lea edx, [ebp - 0x210]
push edx
mov ecx, dword [ebp + 8]
call fcn.0041d6a0
mov al, 1
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0042e417
mov esp, ebp
pop ebp
ret

Function at 0x42fda3
Capabilities:
Parse pe header

Disassembly:
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
je 0x42fde2
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x42fde2
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x42fde2
mov eax, 0x10b
cmp word [ecx + 0x18], ax
jne 0x42fde2
cmp dword [ecx + 0x74], 0xe
jbe 0x42fde2
cmp dword [ecx + 0xe8], 0
setne al
ret
xor al, al
ret
Function at 0x402da0
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
test ecx, ecx
jne 0x402da7
xor eax, eax
ret
push esi
not eax
cmp edx, 8
jb 0x402e7d
mov esi, edx
shr esi, 3
push edi
lea esp, [esp]
movzx edi, byte [ecx]
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x4196d0]
movzx edi, byte [ecx + 1]
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x4196d0]
movzx edi, byte [ecx + 2]
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x4196d0]
movzx edi, byte [ecx + 3]
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x4196d0]
movzx edi, byte [ecx + 4]
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x4196d0]
movzx edi, byte [ecx + 5]
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x4196d0]
movzx edi, byte [ecx + 6]
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x4196d0]
movzx edi, byte [ecx + 7]
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x4196d0]
add ecx, 8
sub edx, 8
dec esi
jne 0x402dc0
pop edi
test edx, edx
je 0x402e9a
movzx esi, byte [ecx]
xor esi, eax
and esi, 0xff
shr eax, 8
xor eax, dword [esi*4 + 0x4196d0]
inc ecx
dec edx
jne 0x402e81
not eax
pop esi
ret

Function at 0x4035f0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, ebx
imul esi, dword [ebp + 0xc]
cmp byte [edi], 0
je 0x403626
mov ecx, dword [ebp + 8]
mov edx, dword [edi + 4]
push 0
lea eax, [ebp + 0xc]
push eax
push esi
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x40361c
mov byte [edi + 8], 1
mov eax, dword [ebp + 0xc]
xor edx, edx
div ebx
pop esi
pop ebp
ret
mov ecx, dword [edi + 0x18]
mov eax, dword [edi + 0x14]
lea edx, [ecx + esi]
cmp edx, eax
jbe 0x403637
sub eax, ecx
mov esi, eax
mov eax, dword [edi + 0x10]
add eax, ecx
mov ecx, dword [ebp + 8]
push esi
push eax
push ecx
call fcn.0040a7a0
add dword [edi + 0x18], esi
add esp, 0xc
mov eax, esi
xor edx, edx
div ebx
pop esi
pop ebp
ret

Function at 0x403660
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
cmp byte [esi], 0
push edi
mov edi, 1
je 0x403693
mov edx, dword [esi + 4]
push 0
lea eax, [ebp - 8]
push eax
push edi
lea ecx, [ebp - 1]
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x40368e
mov byte [esi + 8], 1
mov edi, dword [ebp - 8]
jmp 0x4036be
mov eax, dword [esi + 0x14]
push ebx
mov ebx, dword [esi + 0x18]
lea ecx, [ebx + 1]
cmp ecx, eax
jbe 0x4036a5
sub eax, ebx
mov edi, eax
mov edx, dword [esi + 0x10]
push edi
add edx, ebx
push edx
lea eax, [ebp - 1]
push eax
call fcn.0040a7a0
add esp, 0xc
add ebx, edi
mov dword [esi + 0x18], ebx
pop ebx
cmp edi, 1
pop edi
jne 0x4036d3
movzx ecx, byte [ebp - 1]
mov edx, dword [ebp + 8]
mov dword [edx], ecx
xor eax, eax
mov esp, ebp
pop ebp
ret
cmp byte [esi], 0
je 0x4036cd
cmp byte [esi + 8], 0
je 0x4036cd
or eax, 0xffffffff
mov esp, ebp
pop ebp
ret
Function at 0x403770
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
cmp byte [esi], 0
je 0x4037b7
cmp byte [esi + 1], 0
je 0x4037bf
mov eax, dword [esi + 4]
push 2
push 0
push 0
push eax
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp byte [esi], 0
push ebx
je 0x4037d1
cmp byte [esi + 1], 0
je 0x4037c5
mov edx, dword [esi + 4]
push 1
push 0
push 0
push edx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov ebx, eax
sub ebx, dword [esi + 0xc]
mov dword [ebp - 4], ebx
jmp 0x4037d9
mov ecx, dword [esi + 0x14]
mov dword [esi + 0x18], ecx
jmp 0x403791
xor eax, eax
mov esp, ebp
pop ebp
ret
mov dword [ebp - 4], 0
mov ebx, dword [ebp - 4]
jmp 0x4037d9
mov eax, dword [esi + 0x18]
mov dword [ebp - 4], eax
mov ebx, eax
push edi
mov edi, 0xffff
mov dword [ebp - 8], edi
cmp ebx, edi
jae 0x4037eb
mov dword [ebp - 8], ebx
mov edi, ebx
push 0x404
call fcn.004088b1
add esp, 4
mov dword [ebp - 0x10], eax
test eax, eax
jne 0x403805
pop edi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, 4
mov dword [ebp - 0x14], 0
cmp edi, eax
jbe 0x403919
jmp 0x403829
mov edi, dword [ebp - 8]
mov eax, dword [ebp - 0xc]
mov ebx, dword [ebp - 4]
add eax, 0x400
mov dword [ebp - 0xc], edi
cmp eax, edi
ja 0x403838
mov dword [ebp - 0xc], eax
mov eax, ebx
sub eax, dword [ebp - 0xc]
sub ebx, eax
mov dword [ebp - 0x1c], eax
cmp ebx, 0x404
jbe 0x40384f
mov ebx, 0x404
cmp byte [esi], 0
je 0x403874
cmp byte [esi + 1], 0
je 0x403919
mov ecx, dword [esi + 0xc]
mov edx, dword [esi + 4]
push 0
push 0
add ecx, eax
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
jmp 0x403877
mov dword [esi + 0x18], eax
cmp byte [esi], 0
mov edi, ebx
je 0x4038a0
mov ecx, dword [ebp - 0x10]
mov edx, dword [esi + 4]
push 0
lea eax, [ebp - 0x18]
push eax
push ebx
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x40389b
mov byte [esi + 8], 1
mov eax, dword [ebp - 0x18]
jmp 0x4038c9
mov eax, dword [esi + 0x18]
mov ecx, dword [esi + 0x14]
lea edx, [eax + ebx]
cmp edx, ecx
jbe 0x4038b1
sub ecx, eax
mov edi, ecx
mov ecx, dword [esi + 0x10]
mov edx, dword [ebp - 0x10]
push edi
add ecx, eax
push ecx
push edx
call fcn.0040a7a0
add esp, 0xc
add dword [esi + 0x18], edi
mov eax, edi
xor edx, edx
div ebx
cmp eax, 1
jne 0x403919
lea eax, [ebx - 3]
test eax, eax
jle 0x40390d
lea esp, [esp]
mov ecx, dword [ebp - 0x10]
dec eax
cmp byte [eax + ecx], 0x50
jne 0x4038ff
cmp byte [eax + ecx + 1], 0x4b
jne 0x4038ff
cmp byte [eax + ecx + 2], 5
jne 0x4038ff
cmp byte [eax + ecx + 3], 6
je 0x403905
test eax, eax
jg 0x4038e0
jmp 0x40390d
add eax, dword [ebp - 0x1c]
mov dword [ebp - 0x14], eax
jne 0x403919
mov edx, dword [ebp - 8]
cmp dword [ebp - 0xc], edx
jb 0x403820
mov eax, dword [ebp - 0x10]
push eax
call fcn.00408837
mov eax, dword [ebp - 0x14]
add esp, 4
pop edi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x404c50
Capabilities:
Create directory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x414
mov eax, dword [0x41c054]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
push edi
mov edi, dword [ebp + 0xc]
test edi, edi
je 0x404d3c
movzx eax, word [edi]
test ax, ax
je 0x404d3c
push esi
mov esi, edi
mov ecx, edi
cmp ax, 0x2f
je 0x404c90
cmp ax, 0x5c
jne 0x404c92
mov esi, ecx
movzx eax, word [ecx + 2]
add ecx, 2
test ax, ax
jne 0x404c84
cmp esi, edi
je 0x404cce
sub esi, edi
sar esi, 1
push esi
lea eax, [ebp - 0x20c]
push edi
push eax
call fcn.00408945
lea edx, [ebp - 0x20c]
push edx
xor ecx, ecx
push ebx
mov word [ebp + esi*2 - 0x20c], cx
call fcn.00404c50
add esp, 0x14
lea edx, [ebp - 0x414]
mov eax, ebx
sub edx, ebx
jmp 0x404ce0
movzx ecx, word [eax]
mov word [edx + eax], cx
add eax, 2
test cx, cx
jne 0x404ce0
mov eax, edi
mov edx, edi
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x404cf3
lea edi, [ebp - 0x414]
sub eax, edx
add edi, 0xfffffffe
lea esp, [esp]
mov cx, word [edi + 2]
add edi, 2
test cx, cx
jne 0x404d10
mov ecx, eax
shr ecx, 2
mov esi, edx
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
push 0
lea eax, [ebp - 0x414]
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
pop esi
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop ebx
call fcn.00408828
mov esp, ebp
pop ebp
ret
Function at 0x405070
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
push edi
push 0x340
call fcn.00408b7e
add esp, 4
or ecx, 0xffffffff
test eax, eax
je 0x40509d
mov dword [eax], 0
mov dword [eax + 4], ecx
mov dword [eax + 0x134], ecx
mov esi, eax
jmp 0x40509f
xor esi, esi
cmp dword [esi], 0
jne 0x4050f5
cmp dword [esi + 4], ecx
jne 0x4050f5
lea edi, [esi + 0x138]
push edi
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
add edi, 0xfffffffe
mov edi, edi
mov ax, word [edi + 2]
add edi, 2
test ax, ax
jne 0x4050c0
mov eax, dword [0x419cc8]
mov dword [edi], eax
mov eax, dword [ebp + 8]
lea edi, [ebp - 4]
call fcn.00403550
test eax, eax
jne 0x4050e7
mov eax, dword [ebp - 4]
jmp 0x4050fa
call fcn.00403930
mov dword [esi], eax
mov eax, dword [0x41e1d4]
jmp 0x4050fa
mov eax, 0x1000000
mov dword [0x41e1d8], eax
test eax, eax
je 0x405114
push esi
call fcn.00408b24
add esp, 4
xor eax, eax
pop edi
pop esi
mov esp, ebp
pop ebp
ret
push 8
call fcn.00408b7e
add esp, 4
pop edi
mov dword [eax + 4], esi
mov dword [eax], 1
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x405530
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x804
mov eax, dword [0x41c054]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
xor eax, eax
push 0x7fe
mov ebx, ecx
push eax
lea ecx, [ebp - 0x802]
push ecx
mov word [ebp - 0x804], ax
call fcn.0040a030
add esp, 0xc
lea edx, [ebp - 0x804]
push edx
push 0x41a38c
push 0
push 0
push 0x1c
push 0
call dword [sym.imp.SHELL32.dll_SHGetFolderPathAndSubDirW]
mov esi, eax
test esi, esi
js 0x4055b1
lea eax, [ebp - 0x804]
lea edx, [eax + 2]
mov edi, edi
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x405590
sub eax, edx
push edi
sar eax, 1
lea ecx, [ebp - 0x804]
push ecx
mov edi, eax
call fcn.00407960
mov eax, esi
pop edi
mov ecx, dword [ebp - 4]
pop esi
xor ecx, ebp
pop ebx
call fcn.00408828
mov esp, ebp
pop ebp
ret
Function at 0x405830
Capabilities:
Check if file exists
Delete file
Move file
Print debug messages

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x415a9b
mov eax, dword fs:[0]
push eax
sub esp, 0x3f0
mov eax, dword [0x41c054]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [esi + 0xc]
xor edi, edi
mov dword [esi + 0x10], edi
mov dword [esi + 0x14], edi
mov dword [esi + 0x1c], edi
mov dword [esi + 0x20], edi
cmp eax, edi
je 0x4058a9
push eax
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
test eax, eax
jne 0x4058a6
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0x3f8]
push str._nfreelibrary_ocdll_failed:__d
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0xc
lea ecx, [ebp - 0x3f8]
push ecx
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
mov dword [esi + 0xc], edi
mov eax, dword [esi + 8]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x405954
mov eax, dword [esi + 8]
mov ebx, dword [sym.imp.KERNEL32.dll_DeleteFileW]
push eax
call ebx
test eax, eax
jne 0x405954
mov eax, dword [esi + 8]
sub eax, 0x10
call fcn.00407b00
add eax, 0x10
mov dword [ebp - 0x3fc], eax
push str.OCDLL.bak
push str.OCDLL.dll
lea edx, [ebp - 0x3fc]
push edx
mov dword [ebp - 4], edi
call fcn.00407320
mov edi, dword [ebp - 0x3fc]
push edi
call ebx
mov eax, dword [esi + 8]
push edi
push eax
call dword [sym.imp.KERNEL32.dll_MoveFileW]
test eax, eax
jne 0x40591e
mov eax, dword [esi + 8]
push 4
push 0
push eax
jmp 0x405929
push edi
call ebx
test eax, eax
jne 0x40592f
push 4
push eax
push edi
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
add edi, 0xfffffff0
mov dword [ebp - 4], 0xffffffff
lea eax, [edi + 0xc]
or ecx, 0xffffffff
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x405952
mov ecx, dword [edi]
mov edx, dword [ecx]
mov eax, dword [edx + 4]
push edi
call eax
xor edi, edi
mov ecx, dword [esi + 8]
mov ebx, dword [ecx - 0x10]
cmp dword [ecx - 0xc], edi
lea eax, [ecx - 0x10]
je 0x4059ab
cmp dword [eax + 0xc], edi
lea edx, [eax + 0xc]
jge 0x405986
cmp dword [ecx - 8], edi
jge 0x405979
push 0x80070057
call fcn.00408810
mov dword [ecx - 0xc], edi
mov ecx, dword [esi + 8]
xor edx, edx
mov word [ecx], dx
jmp 0x4059ab
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40599c
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov edx, dword [ebx]
mov eax, dword [edx + 0xc]
mov ecx, ebx
call eax
add eax, 0x10
mov dword [esi + 8], eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00408828
mov esp, ebp
pop ebp
ret
Function at 0x405a40
Capabilities:
Check if file exists
Create directory
Delete file
Extract resource via kernel32 functions
Get common file path
Set file attributes
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x608
mov eax, dword [0x41c054]
xor eax, ebp
mov dword [ebp - 8], eax
mov eax, dword [ebp + 8]
push ebx
push esi
mov esi, edx
push edi
mov dword [ebp - 0x600], ecx
test esi, esi
je 0x405bb7
push 0x419e68
push eax
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov edi, eax
test edi, edi
je 0x405bb7
push edi
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov ebx, eax
test ebx, ebx
je 0x405bb7
push edi
push esi
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov esi, eax
test esi, esi
je 0x405bb7
lea edx, [ebp - 0x5fc]
push edx
push 0x1f4
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
lea eax, [ebp - 0x214]
push eax
push 0
push 0x419e70
lea ecx, [ebp - 0x5fc]
push ecx
call dword [sym.imp.KERNEL32.dll_GetTempFileNameW]
test eax, eax
je 0x405bb7
push 0
push 0x80
push 2
push 0
push 0
push 0xc0000000
lea edx, [ebp - 0x214]
push edx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
cmp edi, 0xffffffff
je 0x405baf
push 0
lea eax, [ebp - 0x604]
push eax
push esi
push ebx
push edi
mov dword [ebp - 0x604], 0
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x405b29
call dword [sym.imp.KERNEL32.dll_GetLastError]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 0x20
lea ecx, [ebp - 0x214]
push ecx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
mov esi, dword [ebp - 0x600]
mov eax, dword [esi]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x405b7a
lea edx, [ebp - 0x214]
mov eax, esi
call fcn.004071f0
push 0x41a38c
push str..tmp
push esi
call fcn.00407320
mov edx, dword [esi]
push 0
push edx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
mov eax, dword [esi]
push eax
lea ecx, [ebp - 0x214]
push ecx
call fcn.00405280
add esp, 8
lea edx, [ebp - 0x214]
push edx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov eax, 1
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.00408828
mov esp, ebp
pop ebp
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x405b3f
mov ecx, dword [ebp - 8]
pop edi
pop esi
xor ecx, ebp
xor eax, eax
pop ebx
call fcn.00408828
mov esp, ebp
pop ebp
ret
Function at 0x408610
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push esi
push edi
xor esi, esi
push esi
mov ecx, 0x41e004
call fcn.004115b7
mov ebx, eax
mov dword [ebp - 4], 1
test ebx, ebx
je 0x4086c4
test esi, esi
jne 0x4086c4
mov eax, dword [ebp + 8]
shr eax, 4
inc eax
push esi
movzx ecx, ax
push ecx
push 6
push ebx
call dword [sym.imp.KERNEL32.dll_FindResourceExW]
mov edi, eax
test edi, edi
je 0x4086a8
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
je 0x4086a2
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov esi, eax
test esi, esi
je 0x4086a2
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov ecx, dword [ebp + 8]
add eax, esi
and ecx, 0xf
jbe 0x408691
cmp esi, eax
jae 0x408695
dec ecx
movzx edx, word [esi]
lea esi, [esi + edx*2 + 2]
jne 0x408683
cmp esi, eax
jb 0x408699
xor eax, eax
jmp 0x4086a2
movzx eax, word [esi]
neg eax
sbb eax, eax
and eax, esi
mov esi, eax
test eax, eax
jne 0x4086cd
mov edi, dword [ebp - 4]
push edi
mov ecx, 0x41e004
call fcn.004115b7
mov ebx, eax
inc edi
mov dword [ebp - 4], edi
test ebx, ebx
jne 0x408635
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
pop edi
pop esi
mov eax, ebx
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x4087b0
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
push edi
mov edi, eax
mov eax, dword [ebp + 8]
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
jne 0x4087c8
pop edi
pop ebp
ret
push esi
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov esi, eax
test esi, esi
je 0x4087fa
mov ecx, dword [ebp + 8]
push ebx
push ecx
call dword [sym.imp.KERNEL32.dll_SizeofResource]
add eax, esi
and edi, 0xf
jbe 0x4087f6
cmp esi, eax
jae 0x4087fa
dec edi
movzx edx, word [esi]
lea esi, [esi + edx*2 + 2]
jne 0x4087e8
cmp esi, eax
jb 0x408800
pop esi
xor eax, eax
pop edi
pop ebp
ret
movzx eax, word [esi]
neg eax
sbb eax, eax
and eax, esi
pop esi
pop edi
pop ebp
ret

Function at 0x408828
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x41c054]
jne 0x408832
repz ret
jmp fcn.00409608
Function at 0x40e4db
Capabilities:
Link many functions at runtime

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [0x41c054]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
mov dword [ebp - 0x20], eax
mov eax, dword [ebp + 0xc]
push esi
push edi
mov dword [ebp - 0x1c], eax
call fcn.0040a323
and dword [ebp - 0x14], 0
cmp dword [0x41df90], 0
mov dword [ebp - 0x18], eax
jne 0x40e58e
push str.USER32.DLL
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov ebx, eax
test ebx, ebx
je 0x40e636
mov edi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x417208
push ebx
call edi
test eax, eax
je 0x40e636
mov esi, dword [sym.imp.KERNEL32.dll_EncodePointer]
push eax
call esi
push str.GetActiveWindow
push ebx
mov dword [0x41df90], eax
call edi
push eax
call esi
push str.GetLastActivePopup
push ebx
mov dword [0x41df94], eax
call edi
push eax
call esi
push str.GetUserObjectInformationW
push ebx
mov dword [0x41df98], eax
call edi
push eax
call esi
mov dword [0x41dfa0], eax
test eax, eax
je 0x40e58e
push str.GetProcessWindowStation
push ebx
call edi
push eax
call esi
mov dword [0x41df9c], eax
mov eax, dword [0x41df9c]
mov ecx, dword [ebp - 0x18]
mov esi, dword [sym.imp.KERNEL32.dll_DecodePointer]
cmp eax, ecx
je 0x40e5e7
cmp dword [0x41dfa0], ecx
je 0x40e5e7
push eax
call esi
push dword [0x41dfa0]
mov edi, eax
call esi
mov ebx, eax
test edi, edi
je 0x40e5e7
test ebx, ebx
je 0x40e5e7
call edi
test eax, eax
je 0x40e5de
lea ecx, [ebp - 0x24]
push ecx
push 0xc
lea ecx, [ebp - 0x10]
push ecx
push 1
push eax
call ebx
test eax, eax
je 0x40e5de
test byte [ebp - 8], 1
jne 0x40e5e7
or dword [ebp + 0x10], 0x200000
jmp 0x40e61a
mov eax, dword [0x41df94]
cmp eax, dword [ebp - 0x18]
je 0x40e61a
push eax
call esi
test eax, eax
je 0x40e61a
call eax
mov dword [ebp - 0x14], eax
test eax, eax
je 0x40e61a
mov eax, dword [0x41df98]
cmp eax, dword [ebp - 0x18]
je 0x40e61a
push eax
call esi
test eax, eax
je 0x40e61a
push dword [ebp - 0x14]
call eax
mov dword [ebp - 0x14], eax
push dword [0x41df90]
call esi
test eax, eax
je 0x40e636
push dword [ebp + 0x10]
push dword [ebp - 0x1c]
push dword [ebp - 0x20]
push dword [ebp - 0x14]
call eax
jmp 0x40e638
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00408828
leave
ret