joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4eab90
Capabilities:
Packed with generic packer

Disassembly:
pushal
mov esi, section.UPX1
lea edi, [esi - 0x9e000]
push edi
or ebp, 0xffffffff
jmp 0x4eabb2
mov al, byte [esi]
inc esi
mov byte [edi], al
inc edi
add ebx, ebx
jne 0x4eabb9
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x4eaba8
mov eax, 1
add ebx, ebx
jne 0x4eabcb
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc eax, eax
add ebx, ebx
jae 0x4eabdc
jne 0x4eabec
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x4eabec
dec eax
add ebx, ebx
jne 0x4eabe8
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc eax, eax
jmp 0x4eabc0
xor ecx, ecx
sub eax, 3
jb 0x4eac04
shl eax, 8
mov al, byte [esi]
inc esi
xor eax, 0xffffffff
je 0x4eac76
sar eax, 1
mov ebp, eax
jmp 0x4eac0f
add ebx, ebx
jne 0x4eac0f
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
add ebx, ebx
jne 0x4eac1c
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
jne 0x4eac40
inc ecx
add ebx, ebx
jne 0x4eac2c
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
add ebx, ebx
jae 0x4eac21
jne 0x4eac3d
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jae 0x4eac21
add ecx, 2
cmp ebp, 0xfffffb00
adc ecx, 1
lea edx, [edi + ebp]
cmp ebp, 0xfffffffc
jbe 0x4eac60
mov al, byte [edx]
inc edx
mov byte [edi], al
inc edi
dec ecx
jne 0x4eac51
jmp 0x4eabae
mov eax, dword [edx]
add edx, 4
mov dword [edi], eax
add edi, 4
sub ecx, 4
ja 0x4eac60
add edi, ecx
jmp 0x4eabae
pop esi
mov edi, esi
mov ecx, 0x2872
mov al, byte [edi]
inc edi
sub al, 0xe8
cmp al, 1
ja 0x4eac7e
cmp byte [edi], 0x14
jne 0x4eac7e
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 eax, ebx
loop 0x4eac83
lea edi, [esi + 0xe7000]
mov eax, dword [edi]
or eax, eax
je 0x4eacf2
mov ebx, dword [edi + 4]
lea eax, [eax + esi + 0xeb36c]
add ebx, esi
push eax
add edi, 8
call dword [esi + 0xeb40c]
xchg ebp, eax
mov al, byte [edi]
inc edi
or al, al
je 0x4eacb0
mov ecx, edi
push edi
dec eax
repne scasb al, byte es:[edi]
push ebp
call dword [esi + 0xeb410]
or eax, eax
je 0x4eacec
mov dword [ebx], eax
add ebx, 4
jmp 0x4eaccd
call dword [esi + 0xeb414]
popal
jmp 0x450f9c
Function at 0x1002af4
Capabilities:
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x14
and dword [ebp - 0x14], 0
push ebx
push esi
push edi
mov edi, dword [0x1001008]
lea eax, [ebp - 0x10]
push eax
mov ebx, 0x20019
push ebx
push 0
push 0x10018e0
push 0x80000002
mov esi, ecx
call edi
test eax, eax
je 0x1002b64
test byte [0x100a0bc], 8
je 0x1002d50
cmp byte [0x100a0b9], 2
jb 0x1002d50
push eax
push 0x10018e0
push 0x10017b8
push 0x17
push dword [0x100a0b4]
push dword [0x100a0b0]
call fcn.01002932
jmp 0x1002d50
mov eax, dword [esi + 0x30]
lea ecx, [ebp - 0xc]
push ecx
push ebx
push 0
push eax
push dword [ebp - 0x10]
call edi
test eax, eax
je 0x1002bb3
test byte [0x100a0bc], 8
je 0x1002d47
cmp byte [0x100a0b9], 2
jb 0x1002d47
push eax
push dword [esi + 0x30]
push 0x10017b8
push 0x18
push dword [0x100a0b4]
push dword [0x100a0b0]
call fcn.01002932
jmp 0x1002d47
mov edi, dword [entry0]
lea eax, [ebp - 4]
push eax
lea ebx, [esi + 0x68]
push ebx
lea eax, [ebp - 8]
push eax
push 0
push 0x10018a8
push dword [ebp - 0xc]
mov dword [ebp - 4], 4
call edi
test eax, eax
jne 0x1002be2
cmp dword [ebp - 8], 4
je 0x1002c12
test byte [0x100a0bc], 8
je 0x1002c0c
cmp byte [0x100a0b9], 3
jb 0x1002c0c
push 0x10017b8
push 0x19
push dword [0x100a0b4]
push dword [0x100a0b0]
call fcn.010028c1
mov dword [ebx], 0xa
mov ebx, dword [ebx]
mov eax, dword [0x100a158]
cmp ebx, dword [eax + 0x74]
jbe 0x1002c56
test byte [0x100a0bc], 8
je 0x1002d3e
cmp byte [0x100a0b9], 2
jb 0x1002d3e
push ebx
push 0x10017b8
push 0x1a
push dword [0x100a0b4]
push dword [0x100a0b0]
call fcn.0100528f
jmp 0x1002d3e
lea eax, [ebp - 4]
push eax
lea ebx, [esi + 0x6c]
push ebx
lea eax, [ebp - 8]
push eax
push 0
push 0x1001874
push dword [ebp - 0xc]
mov dword [ebp - 4], 4
call edi
test eax, eax
jne 0x1002c7f
cmp dword [ebp - 8], 4
je 0x1002caf
test byte [0x100a0bc], 8
je 0x1002ca9
cmp byte [0x100a0b9], 3
jb 0x1002ca9
push 0x10017b8
push 0x1b
push dword [0x100a0b4]
push dword [0x100a0b0]
call fcn.010028c1
mov dword [ebx], 0xa
mov ebx, dword [ebx]
mov eax, dword [0x100a158]
cmp ebx, dword [eax + 0x78]
jbe 0x1002cda
test byte [0x100a0bc], 8
je 0x1002d3e
cmp byte [0x100a0b9], 2
jb 0x1002d3e
push ebx
push 0x10017b8
push 0x1c
jmp 0x1002c40
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 8]
push eax
mov edi, 0x1001844
push edi
push dword [ebp - 0xc]
call fcn.01005352
mov ebx, eax
test ebx, ebx
jne 0x1002d23
test byte [0x100a0bc], 8
je 0x1002d3e
cmp byte [0x100a0b9], 2
jb 0x1002d3e
push edi
push 0x10017b8
push 0x1d
push dword [0x100a0b4]
push dword [0x100a0b0]
call fcn.010028e7
jmp 0x1002d3e
push ebx
call fcn.010056f0
test eax, eax
mov dword [esi + 0x44], eax
je 0x1002d37
mov dword [ebp - 0x14], 1
push ebx
call fcn.01008052
pop ecx
push dword [ebp - 0xc]
call dword [0x1001004]
push dword [ebp - 0x10]
call dword [0x1001004]
mov eax, dword [ebp - 0x14]
pop edi
pop esi
pop ebx
leave
ret
Function at 0x10033fb
Capabilities:
Terminate process

Disassembly:
push 0x10
push 0x1001aa0
call fcn.01008060
mov esi, ecx
mov dword [ebp - 0x20], esi
mov dword [esi], fcn.01002a53
xor ebx, ebx
cmp dword [esi + 0x74], ebx
je 0x1003422
push esi
mov ecx, dword [esi + 0x70]
call fcn.01002d5d
push dword [esi + 0x44]
call fcn.01008052
pop ecx
lea eax, [esi + 0x4c]
cmp dword [eax], ebx
je 0x1003439
push eax
call dword [0x1001144]
lea eax, [esi + 0x48]
cmp dword [eax], ebx
je 0x1003447
push eax
call dword [0x1001144]
mov eax, dword [esi + 0x54]
cmp eax, ebx
je 0x1003455
push eax
call dword [fcn.010010c0]
cmp dword [esi + 0x50], ebx
je 0x10034b5
mov dword [ebp - 4], ebx
push dword [esi + 0x60]
call fcn.0100286c
or dword [ebp - 4], 0xffffffff
jmp 0x10034b5
mov eax, dword [esi + 0x60]
cmp eax, ebx
je 0x10034c2
push eax
call fcn.01008640
mov eax, dword [esi + 0x50]
cmp eax, ebx
je 0x100352d
mov ecx, dword [esi + 0x6c]
imul ecx, ecx, 0x3e8
push ecx
push eax
mov edi, dword [fcn.010010c4]
call edi
cmp eax, ebx
je 0x1003524
test byte [0x100a0bc], 8
je 0x100350b
cmp byte [0x100a0b9], 2
jb 0x100350b
push eax
push 0x10017b8
push 0x16
push dword [0x100a0b4]
push dword [0x100a0b0]
call fcn.0100528f
push ebx
push dword [esi + 0x50]
call dword [0x10010c8]
mov eax, dword [esi + 0x6c]
imul eax, eax, 0x3e8
push eax
push dword [esi + 0x50]
call edi
push dword [esi + 0x50]
call dword [fcn.010010c0]
mov ecx, esi
call fcn.01002a79
call fcn.0100809b
ret
Function at 0x1005352
Capabilities:
Query environment variable
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ecx
push ebx
push esi
push edi
xor edi, edi
xor ebx, ebx
mov dword [ebp - 4], 4
mov dword [ebp - 8], edi
xor esi, esi
lea eax, [ebp - 8]
push eax
push ebx
lea eax, [ebp - 4]
push eax
push edi
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [entry0]
cmp eax, edi
jne 0x100540c
cmp dword [ebp - 4], 7
je 0x100539c
cmp dword [ebp - 4], 1
je 0x100539c
cmp dword [ebp - 4], 2
jne 0x100540c
mov eax, dword [ebp - 8]
shr eax, 1
cmp ebx, edi
jne 0x10053be
lea eax, [eax + eax + 2]
push eax
call fcn.01008046
mov ebx, eax
cmp ebx, edi
pop ecx
je 0x100540c
inc esi
cmp esi, 2
jb 0x100536c
jmp 0x10053c3
mov word [ebx + eax*2 - 2], di
cmp dword [ebp - 4], 2
jne 0x1005432
xor esi, esi
and dword [ebp + 0xc], esi
mov dword [ebp + 8], 0x1f
mov eax, edi
shr eax, 1
push eax
push esi
push ebx
call dword [0x10010b8]
shl eax, 1
cmp eax, edi
jbe 0x1005417
test esi, esi
jne 0x100540c
mov edi, eax
shr eax, 1
shl eax, 1
push eax
call fcn.01008046
mov esi, eax
test esi, esi
pop ecx
jne 0x1005427
mov dword [ebp + 8], 8
cmp dword [ebp + 8], 0
je 0x1005432
push ebx
call fcn.01008052
pop ecx
xor ebx, ebx
jmp 0x1005442
push ebx
call fcn.01008052
and dword [ebp + 8], 0
pop ecx
mov ebx, esi
mov dword [ebp - 8], edi
inc dword [ebp + 0xc]
cmp dword [ebp + 0xc], 2
jb 0x10053d5
jmp 0x1005406
mov eax, dword [ebp + 0x14]
mov ecx, dword [ebp - 8]
mov dword [eax], ecx
mov eax, dword [ebp + 0x10]
mov ecx, dword [ebp - 4]
mov dword [eax], ecx
pop edi
pop esi
mov eax, ebx
pop ebx
leave
ret 0x10
Function at 0x10056f0
Capabilities:
Get common file path

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x21c
mov eax, dword [0x100a140]
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
mov dword [ebp - 4], eax
push 0x105
lea eax, [ebp - 0x210]
push eax
mov dword [ebp - 0x218], esi
call dword [0x10010a8]
test eax, eax
jne 0x1005763
test byte [0x100a0bc], 1
je 0x100585f
cmp byte [0x100a0b9], 2
jb 0x100585f
call dword [fcn.010010d0]
push eax
push 0x10020fc
push 0x3b
push dword [0x100a0b4]
push dword [0x100a0b0]
call fcn.0100528f
jmp 0x100585f
mov edi, dword [0x10010ac]
xor ebx, ebx
push ebx
push ebx
push ebx
push ebx
push esi
lea eax, [ebp - 0x210]
push eax
call edi
cmp eax, ebx
jne 0x10057a7
test byte [0x100a0bc], 1
je 0x100585f
cmp byte [0x100a0b9], 2
jb 0x100585f
call dword [fcn.010010d0]
push eax
push 0x10020fc
push 0x3c
jmp 0x100574d
lea esi, [eax + 1]
lea eax, [esi + esi]
push eax
call fcn.01008046
cmp eax, ebx
pop ecx
mov dword [ebp - 0x214], eax
jne 0x10057f8
test byte [0x100a0bc], 1
je 0x100585f
cmp byte [0x100a0b9], 2
jb 0x100585f
push dword [ebp - 0x218]
push 0x10020fc
push 0x3d
push dword [0x100a0b4]
push dword [0x100a0b0]
call fcn.010028e7
jmp 0x100585f
lea ecx, [ebp - 0x21c]
push ecx
push eax
push esi
push ebx
push dword [ebp - 0x218]
lea eax, [ebp - 0x210]
push eax
call edi
cmp eax, ebx
je 0x1005822
dec esi
cmp eax, esi
ja 0x1005822
mov eax, dword [ebp - 0x214]
jmp 0x1005861
test byte [0x100a0bc], 1
je 0x1005853
cmp byte [0x100a0b9], 2
jb 0x1005853
call dword [fcn.010010d0]
push eax
push 0x10020fc
push 0x3e
push dword [0x100a0b4]
push dword [0x100a0b0]
call fcn.0100528f
push dword [ebp - 0x214]
call fcn.01008052
pop ecx
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
pop ebx
call fcn.01007d97
leave
ret 4
Function at 0x1008690
Capabilities:
Get session user name

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push esi
lea eax, [ebp - 4]
push eax
xor esi, esi
push esi
push 2
mov dword [ebp - 4], esi
call fcn.010090ac
test al, al
je 0x10086ea
test byte [0x100a07c], 8
je 0x10087af
cmp byte [0x100a079], 2
jb 0x10087af
call dword [fcn.010010d0]
push eax
push 0x100263c
push 0x2d
push dword [0x100a074]
push dword [0x100a070]
call fcn.0100528f
jmp 0x10087af
push edi
mov edi, dword [fcn.010010d0]
call edi
cmp eax, 0xea
je 0x1008736
cmp eax, 0x7a
je 0x1008736
test byte [0x100a07c], 8
je 0x10087ae
cmp byte [0x100a079], 2
jb 0x10087ae
call edi
push eax
push 0x100263c
push 0x2e
push dword [0x100a074]
push dword [0x100a070]
call fcn.0100528f
jmp 0x10087ae
mov eax, dword [ebp - 4]
add eax, eax
push eax
call dword [fcn.0100119c]
mov esi, eax
test esi, esi
pop ecx
jne 0x1008767
test byte [0x100a07c], 8
je 0x10087ae
cmp byte [0x100a079], 3
jb 0x10087ae
push dword [ebp - 4]
push 0x100263c
push 0x2f
jmp 0x1008723
lea eax, [ebp - 4]
push eax
push esi
push 2
call fcn.010090ac
test al, al
jne 0x10087ae
test byte [0x100a07c], 8
je 0x10087a4
cmp byte [0x100a079], 2
jb 0x10087a4
call edi
push eax
push 0x100263c
push 0x30
push dword [0x100a074]
push dword [0x100a070]
call fcn.0100528f
push esi
call dword [fcn.010011ac]
pop ecx
xor esi, esi
pop edi
mov eax, esi
pop esi
leave
ret
Function at 0x1008ce5
Capabilities:
Listen for remote procedure calls

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
test byte [0x100a07c], 2
push ebx
push esi
push edi
mov edi, 0x100263c
je 0x1008d18
cmp byte [0x100a079], 4
jb 0x1008d18
push edi
push 0x1a
push dword [0x100a074]
push dword [0x100a070]
call fcn.010028c1
mov eax, dword [ebp + 0x10]
test eax, eax
jne 0x1008d26
mov ebx, fcn.0100833e
jmp 0x1008d4a
cmp eax, 1
jne 0x1008d32
mov ebx, 0x10088a4
jmp 0x1008d4a
cmp eax, 2
jne 0x1008d3e
mov ebx, 0x1008a19
jmp 0x1008d4a
cmp eax, 3
jne 0x1008ec2
mov ebx, dword [ebp + 0x14]
test byte [0x100a07c], 2
je 0x1008d79
cmp byte [0x100a079], 5
jb 0x1008d79
push dword [0x100a148]
push dword [ebp + 0xc]
push edi
push 0x1b
push dword [0x100a074]
push dword [0x100a070]
call fcn.0100828d
push 0
push dword [ebp + 0xc]
push 0xa
push dword [0x100a148]
call dword [0x1001108]
mov esi, eax
xor eax, eax
cmp esi, eax
je 0x1008db4
test byte [0x100a07c], 2
je 0x1008ec5
cmp byte [0x100a079], 2
jb 0x1008ec5
push esi
push edi
push 0x1c
jmp 0x1008de7
push ebx
push eax
push 8
push eax
push eax
push dword [ebp + 8]
call dword [0x100110c]
mov esi, eax
test esi, esi
je 0x1008dfd
test byte [0x100a07c], 2
je 0x1008ec5
cmp byte [0x100a079], 2
jb 0x1008ec5
push esi
push edi
push 0x1d
push dword [0x100a074]
push dword [0x100a070]
call fcn.0100528f
jmp 0x1008ec5
mov ebx, 0x100a18c
push ebx
call dword [0x10010d8]
test byte [0x100a07c], 2
mov dword [ebp + 0x10], eax
je 0x1008e5e
cmp byte [0x100a079], 5
jb 0x1008e35
push dword [ebp + 0xc]
push edi
push 0x1e
push dword [0x100a074]
push dword [0x100a070]
call fcn.010028e7
test byte [0x100a07c], 2
je 0x1008e5e
cmp byte [0x100a079], 5
jb 0x1008e5e
push dword [ebp + 0x10]
push edi
push 0x1f
push dword [0x100a074]
push dword [0x100a070]
call fcn.0100528f
cmp dword [ebp + 0x10], 1
jne 0x1008ed5
push 1
push 0x4d2
push 1
call dword [0x1001110]
mov esi, eax
cmp esi, 0x6b1
jne 0x1008e7f
xor esi, esi
test esi, esi
je 0x1008ed5
test byte [0x100a07c], 2
je 0x1008eaa
cmp byte [0x100a079], 2
jb 0x1008eaa
push esi
push edi
push 0x20
push dword [0x100a074]
push dword [0x100a070]
call fcn.0100528f
push 1
push 0
push dword [ebp + 8]
call dword [0x1001120]
push ebx
mov esi, eax
call dword [0x10010bc]
jmp 0x1008ec5
push 0x57
pop esi
test esi, esi
jle 0x1008ed5
and esi, 0xffff
or esi, 0x80070000
pop edi
mov eax, esi
pop esi
pop ebx
pop ebp
ret 0x10
Function at 0x401180
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
push esi
mov esi, dword [esp + 0x10]
xor ecx, ecx
test esi, esi
jbe 0x4011bc
mov edx, dword [esp + 8]
push ebx
push ebp
push edi
mov edi, dword [esp + 0x18]
mov eax, dword [edx]
movzx ebx, byte [ecx + edi]
mov ebp, eax
and ebp, 0xff
xor ebx, ebp
mov ebp, dword [ebx*4 + 0x4210c8]
shr eax, 8
xor eax, ebp
inc ecx
cmp ecx, esi
mov dword [edx], eax
jb 0x401196
pop edi
pop ebp
pop ebx
pop esi
ret

Function at 0x4014d0
Capabilities:
Get file size

Disassembly:
mov eax, dword [esp + 4]
mov ecx, dword [eax + 8]
push ebx
push edi
mov edi, dword [eax + 4]
xor ebx, ebx
cmp edi, ecx
je 0x401566
push ebp
mov ebp, dword [sym.imp.KERNEL32.dll_CreateFileA]
push esi
mov edi, edi
mov eax, dword [edi]
cmp eax, 1
jne 0x401503
mov ecx, dword [edi + 4]
test ecx, ecx
je 0x401503
add ebx, dword [edi + 8]
jmp 0x401556
cmp eax, 2
jne 0x401511
mov eax, dword [edi + 8]
lea ebx, [ebx + eax + 4]
jmp 0x401556
cmp eax, 3
jne 0x401556
mov eax, dword [edi + 4]
test eax, eax
je 0x401556
push 0
push 0x80
push 3
push 0
push 1
push 0x80000000
push eax
call ebp
mov esi, eax
test esi, esi
je 0x401556
cmp esi, 0xffffffff
je 0x401556
push 0
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
cmp eax, 0x3200000
jae 0x40154f
add ebx, eax
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [esp + 0x14]
mov eax, dword [ecx + 8]
add edi, 0xc
cmp edi, eax
jne 0x4014f0
pop esi
pop ebp
pop edi
mov eax, ebx
pop ebx
ret 4
Function at 0x401570
Capabilities:
Get file size
Read file on windows

Disassembly:
mov edx, dword [esp + 8]
sub esp, 8
test edx, edx
push edi
je 0x401729
mov edi, dword [esp + 0x18]
test edi, edi
je 0x401729
mov eax, dword [esp + 0x10]
mov ecx, dword [eax + 8]
push ebx
push ebp
mov ebp, dword [eax + 4]
xor ebx, ebx
cmp ebp, ecx
mov dword [esp + 0x10], ebp
je 0x40171e
push esi
jmp 0x4015b0
mov edi, dword [esp + 0x24]
lea ecx, [ecx]
mov eax, dword [ebp]
cmp eax, 1
jne 0x4015e6
mov esi, dword [ebp + 4]
test esi, esi
je 0x4015e6
mov ecx, dword [ebp + 8]
lea eax, [ecx + ebx]
cmp eax, edi
ja 0x40171d
mov eax, ecx
shr ecx, 2
lea edi, [ebx + edx]
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
add ebx, dword [ebp + 8]
jmp 0x4016f4
cmp eax, 2
jne 0x401629
mov eax, dword [ebp + 8]
lea ecx, [eax + ebx + 4]
cmp ecx, edi
ja 0x40171d
mov dword [ebx + edx], eax
mov esi, dword [ebp + 4]
test esi, esi
je 0x40161d
mov ecx, dword [ebp + 8]
test ecx, ecx
je 0x40161d
mov eax, ecx
shr ecx, 2
lea edi, [ebx + edx + 4]
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [ebp + 8]
lea ebx, [ebx + ecx + 4]
jmp 0x4016f4
cmp eax, 3
jne 0x4016f4
mov eax, dword [ebp + 4]
test eax, eax
je 0x4016f4
push 0
push 0x80
push 3
push 0
push 1
push 0x80000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
test edi, edi
je 0x4016f0
cmp edi, 0xffffffff
je 0x4016f0
mov esi, dword [esp + 0x24]
mov ebp, dword [sym.imp.KERNEL32.dll_GetFileSize]
push 0
push edi
sub esi, ebx
call ebp
cmp esi, eax
jae 0x401682
mov ebp, esi
jmp 0x401689
push 0
push edi
call ebp
mov ebp, eax
cmp ebp, 0x3200000
jae 0x401716
mov eax, dword [esp + 0x24]
lea edx, [ebx + ebp]
cmp edx, eax
ja 0x401716
xor esi, esi
mov dword [esp + 0x10], esi
mov eax, ebp
sub eax, esi
cmp eax, 0x400
jbe 0x4016b6
mov eax, 0x400
mov edx, dword [esp + 0x20]
push 0
lea ecx, [esp + 0x14]
push ecx
push eax
lea eax, [ebx + edx]
add eax, esi
push eax
push edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x4016e3
mov eax, dword [esp + 0x10]
test eax, eax
jbe 0x4016e3
cmp esi, ebp
ja 0x4016e3
add esi, eax
jmp 0x4016a6
push edi
add ebx, esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ebp, dword [esp + 0x14]
mov edx, dword [esp + 0x20]
mov eax, dword [esp + 0x1c]
mov ecx, dword [eax + 8]
add ebp, 0xc
cmp ebp, ecx
mov dword [esp + 0x14], ebp
jne 0x4015a9
pop esi
pop ebp
mov eax, ebx
pop ebx
pop edi
add esp, 8
ret 0xc
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop esi
pop ebp
mov eax, ebx
pop ebx
pop edi
add esp, 8
ret 0xc
xor eax, eax
pop edi
add esp, 8
ret 0xc
Function at 0x402ea0
Capabilities:
Get file version info

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x124
mov eax, dword [str._u]
xor eax, ebp
push ebx
mov dword [esp + 0x124], eax
mov eax, dword [ebp + 8]
push esi
push edi
mov dword [esp + 0x1c], eax
xor eax, eax
xor ebx, ebx
mov byte [esp + 0x20], bl
mov ecx, 0x40
lea edi, [esp + 0x21]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
push str.WININET.DLL
stosb byte es:[edi], al
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
cmp eax, ebx
mov dword [esp + 0x10], ebx
je 0x402f61
push 0x104
lea ecx, [esp + 0x24]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jbe 0x402f61
lea edx, [esp + 0x10]
push edx
lea eax, [esp + 0x24]
push eax
call sub.VERSION.dll_GetFileVersionInfoSizeA
mov edi, eax
cmp edi, ebx
jbe 0x402f61
push edi
call fcn.00412749
mov ecx, dword [esp + 0x14]
add esp, 4
mov esi, eax
push esi
push edi
push ecx
lea edx, [esp + 0x2c]
push edx
call sub.VERSION.dll_GetFileVersionInfoA
test eax, eax
je 0x402f58
lea eax, [esp + 0x18]
push eax
lea ecx, [esp + 0x18]
push ecx
push 0x41d38c
push esi
mov dword [esp + 0x24], ebx
mov dword [esp + 0x28], ebx
call sub.VERSION.dll_VerQueryValueA
test eax, eax
jne 0x402f78
push esi
call fcn.0041221d
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x120]
xor ecx, ebp
call fcn.0041277f
mov esp, ebp
pop ebp
ret
mov eax, dword [esp + 0x14]
movzx edx, word [eax + 8]
movzx eax, word [eax + 0xa]
mov ecx, dword [esp + 0x1c]
push edx
push eax
push str.MSIE__d._d
push ecx
call dword [sym.imp.USER32.dll_wsprintfA]
push esi
call fcn.0041221d
mov ecx, dword [esp + 0x140]
add esp, 0x14
pop edi
pop esi
xor ecx, ebp
mov eax, 1
pop ebx
call fcn.0041277f
mov esp, ebp
pop ebp
ret
Function at 0x402fc0
Capabilities:
Check os version

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0xa8
mov eax, dword [str._u]
xor eax, ebp
push esi
mov esi, dword [ebp + 8]
push edi
mov dword [esp + 0xac], eax
xor eax, eax
mov ecx, 0x27
lea edi, [esp + 8]
rep stosd dword es:[edi], eax
mov edi, dword [sym.imp.KERNEL32.dll_GetVersionExA]
lea eax, [esp + 8]
push eax
mov dword [esp + 0xc], 0x9c
call edi
test eax, eax
jne 0x40302e
lea ecx, [esp + 8]
push ecx
mov dword [esp + 0xc], 0x94
call edi
test eax, eax
jne 0x40302e
mov byte [esi], al
pop edi
pop esi
mov ecx, dword [esp + 0xa4]
xor ecx, ebp
call fcn.0041277f
mov esp, ebp
pop ebp
ret
mov eax, dword [esp + 0x18]
sub eax, 0
je 0x4030ad
dec eax
je 0x403058
dec eax
jne 0x4030bc
mov edx, dword [esp + 0x10]
mov eax, dword [esp + 0xc]
push edx
push eax
push str.Windows_NT__d._d
push esi
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x10
jmp 0x4030bc
cmp dword [esp + 0xc], 4
jne 0x4030bc
mov eax, dword [esp + 0x10]
test eax, eax
mov edi, dword [sym.imp.USER32.dll_wsprintfA]
jne 0x403081
push str.Windows_95
push esi
call edi
mov eax, dword [esp + 0x14]
add esp, 8
cmp eax, 4
jne 0x4030bc
cmp dword [esp + 0x10], 0xa
jne 0x40309c
push str.Windows_98
push esi
call edi
mov eax, dword [esp + 0x14]
add esp, 8
cmp eax, 4
jne 0x4030bc
cmp dword [esp + 0x10], 0x5a
jne 0x4030bc
push str.Windows_Me
push esi
call edi
jmp 0x4030b9
push str.Windows
push esi
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 8
mov ecx, dword [esp + 0xac]
pop edi
xor ecx, ebp
mov eax, 1
pop esi
call fcn.0041277f
mov esp, ebp
pop ebp
ret
Function at 0x4030e0
Capabilities:
Create directory

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x114
mov eax, dword [str._u]
xor eax, ebp
mov dword [esp + 0x110], eax
mov eax, dword [ebp + 0xc]
push ebx
push esi
push edi
mov esi, ecx
mov dword [esp + 0xc], eax
xor eax, eax
test esi, esi
mov byte [esp + 0x10], 0
mov ecx, 0x40
lea edi, [esp + 0x11]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov ebx, 1
stosb byte es:[edi], al
je 0x403143
mov edi, dword [sym.imp.KERNEL32.dll_lstrlenA]
push esi
call edi
test eax, eax
jle 0x403143
push esi
call edi
cmp eax, 0x104
jbe 0x40315a
push 0x6f
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x110]
xor ecx, ebp
call fcn.0041277f
mov esp, ebp
pop ebp
ret
push 0x103
push esi
lea ecx, [esp + 0x18]
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcpynA]
mov eax, dword [ebp + 8]
test eax, eax
je 0x40317d
lea edx, [esp + 0x10]
push edx
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecA]
lea eax, [esp + 0x10]
push eax
call dword [sym.imp.SHLWAPI.dll_PathSkipRootA]
mov esi, eax
push esi
call edi
test eax, eax
jne 0x4031ab
mov eax, 1
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x110]
xor ecx, ebp
call fcn.0041277f
mov esp, ebp
pop ebp
ret
push 0x5c
push esi
call fcn.00412d4c
mov edi, dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
mov esi, eax
add esp, 8
test esi, esi
je 0x4031fc
mov ecx, dword [esp + 0xc]
push ecx
lea edx, [esp + 0x14]
push edx
mov byte [esi], 0
call edi
and ebx, eax
jne 0x4031e7
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
jne 0x4031e7
mov ebx, 1
mov byte [esi], 0x5c
push 0x5c
inc esi
push esi
call fcn.00412d4c
mov esi, eax
add esp, 8
test esi, esi
jne 0x4031c2
mov eax, dword [esp + 0xc]
push eax
lea ecx, [esp + 0x14]
push ecx
call edi
and ebx, eax
jne 0x40321e
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
jne 0x40321e
mov ebx, 1
mov ecx, dword [esp + 0x11c]
pop edi
pop esi
mov eax, ebx
xor ecx, ebp
pop ebx
call fcn.0041277f
mov esp, ebp
pop ebp
ret

Function at 0x403370
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebx
mov ebx, dword [esp + 8]
push edi
mov edi, dword [esp + 0x10]
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
jne 0x403389
pop edi
pop ebx
ret
push esi
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov esi, eax
test esi, esi
jne 0x40339d
pop esi
pop edi
xor eax, eax
pop ebx
ret
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov ecx, dword [esp + 0x18]
add eax, esi
and ecx, 0xf
jbe 0x4033be
cmp esi, eax
jae 0x403397
dec ecx
movzx edx, word [esi]
lea esi, [esi + edx*2 + 2]
jne 0x4033b0
cmp esi, eax
jae 0x403397
mov ax, word [esi]
neg ax
sbb eax, eax
and eax, esi
pop esi
pop edi
pop ebx
ret