joyce8/EMBER2024-capa huggingface dataset:
Function at 0x6723aa7
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
mov esi, eax
test esi, esi
je 0x6723b44
push ebx
push esi
call fcn.06723a70
xor ebx, ebx
sub eax, esi
push ebx
push ebx
push ebx
push ebx
sar eax, 1
push eax
push esi
push ebx
push ebx
mov dword [ebp - 8], eax
call fcn.067223ad
add esp, 0x24
mov dword [ebp - 4], eax
test eax, eax
jne 0x6723af1
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x6723b43
push edi
push eax
call fcn.0671c632
mov edi, eax
pop ecx
push ebx
test edi, edi
jne 0x6723b11
call fcn.06719c42
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x6723b42
push ebx
push dword [ebp - 4]
push edi
push dword [ebp - 8]
push esi
push ebx
push ebx
call fcn.067223ad
add esp, 0x20
test eax, eax
jne 0x6723b30
push edi
call fcn.06719c42
jmp 0x6723b38
push ebx
call fcn.06719c42
mov ebx, edi
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov eax, ebx
pop edi
pop ebx
pop esi
leave
ret

Function at 0x6723b47
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push esi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
mov esi, eax
test esi, esi
jne 0x6723b58
pop esi
ret
push ebx
push edi
push esi
call fcn.06723a70
mov ebx, eax
sub ebx, esi
and ebx, 0xfffffffe
push ebx
call fcn.0671c632
mov edi, eax
pop ecx
pop ecx
test edi, edi
je 0x6723b80
push ebx
push esi
push edi
call fcn.06709c30
add esp, 0xc
push 0
call fcn.06719c42
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov eax, edi
pop edi
pop ebx
pop esi
ret

Function at 0x67242da
Capabilities:
Set environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.06723df5

Function at 0x672655f
Capabilities:
Get geographical location

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push esi
push edi
call fcn.06719fe6
mov esi, dword [ebp + 8]
mov edi, eax
push 2
lea eax, [ebp - 4]
mov ecx, esi
push eax
and ecx, 0x3ff
push 0x20000001
or ecx, 0x400
push ecx
call dword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
test eax, eax
je 0x67265ce
cmp esi, dword [ebp - 4]
je 0x67265c9
cmp dword [ebp + 0xc], 0
je 0x67265c9
mov esi, dword [edi + 0x50]
lea ecx, [esi + 2]
mov ax, word [esi]
add esi, 2
test ax, ax
jne 0x67265a6
push dword [edi + 0x50]
sub esi, ecx
sar esi, 1
call fcn.067260b1
pop ecx
xor ecx, ecx
cmp eax, esi
setne cl
mov eax, ecx
jmp 0x67265d0
xor eax, eax
inc eax
jmp 0x67265d0
xor eax, eax
pop edi
pop esi
leave
ret
Function at 0x6726635
Capabilities:
Get geographical location

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword [0x6740080]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
push ebx
mov ebx, dword [ebp + 0x10]
push esi
mov esi, dword [ebp + 8]
push edi
mov dword [ebp - 0x18], eax
call fcn.06719fe6
add eax, 0x50
lea edi, [ebp - 0x10]
mov dword [ebp - 0x14], eax
xor eax, eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
call fcn.06719fe6
lea ecx, [ebp - 0x10]
xor edx, edx
mov dword [eax + 0x34c], ecx
lea ecx, [esi + 0x80]
mov eax, dword [ebp - 0x14]
mov dword [eax], esi
lea edi, [eax + 4]
mov dword [edi], ecx
test ecx, ecx
je 0x67266ac
cmp word [ecx], dx
je 0x67266ac
mov eax, dword [0x673539c]
push edi
dec eax
push eax
push 0x6735288
call fcn.067265d4
mov eax, dword [ebp - 0x14]
add esp, 0xc
xor edx, edx
mov dword [ebp - 0x10], edx
mov eax, dword [eax]
test eax, eax
je 0x672671f
cmp word [eax], dx
je 0x672671f
mov eax, dword [edi]
test eax, eax
je 0x67266d0
cmp word [eax], dx
je 0x67266d0
lea eax, [ebp - 0x10]
push eax
call fcn.06725fb7
jmp 0x67266d9
lea eax, [ebp - 0x10]
push eax
call fcn.06726052
cmp dword [ebp - 0x10], 0
pop ecx
jne 0x6726749
mov eax, dword [0x6735284]
push dword [ebp - 0x14]
dec eax
push eax
push 0x6734f78
call fcn.067265d4
add esp, 0xc
test al, al
je 0x6726749
mov eax, dword [edi]
xor edi, edi
test eax, eax
je 0x6726714
cmp word [eax], di
je 0x6726714
lea eax, [ebp - 0x10]
push eax
call fcn.06725fb7
pop ecx
jmp 0x672674b
lea eax, [ebp - 0x10]
push eax
call fcn.06726052
jmp 0x6726711
mov eax, dword [edi]
test eax, eax
je 0x6726736
cmp word [eax], dx
je 0x6726736
lea eax, [ebp - 0x10]
push eax
call fcn.06725f6c
pop ecx
jmp 0x6726749
mov dword [ebp - 0x10], 0x104
call dword [sym.imp.KERNEL32.dll_GetUserDefaultLCID]
mov dword [ebp - 8], eax
mov dword [ebp - 0xc], eax
xor edi, edi
cmp dword [ebp - 0x10], 0
je 0x6726814
lea eax, [ebp - 0x10]
push eax
lea eax, [esi + 0x100]
neg esi
sbb esi, esi
and esi, eax
push esi
call fcn.06726459
mov esi, eax
pop ecx
pop ecx
test esi, esi
je 0x6726814
movzx ecx, si
push ecx
call dword [sym.imp.KERNEL32.dll_IsValidCodePage]
test eax, eax
je 0x6726814
push 1
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_IsValidLocale]
test eax, eax
je 0x6726814
mov eax, dword [ebp - 0x18]
test eax, eax
je 0x67267a1
mov dword [eax], esi
mov eax, dword [ebp - 0x14]
push edi
push 0x55
add eax, 0x250
push eax
push dword [ebp - 0xc]
call fcn.0671ed58
test ebx, ebx
je 0x672680f
push edi
push 0x55
lea eax, [ebx + 0x120]
push eax
push dword [ebp - 0xc]
call fcn.0671ed58
push 0x40
push ebx
push 0x1001
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
test eax, eax
je 0x6726814
push 0x40
lea eax, [ebx + 0x80]
push eax
push 0x1002
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
test eax, eax
je 0x6726814
push 0xa
push 0x10
lea ecx, [ebx + 0x100]
push ecx
push esi
call fcn.0672a6e9
add esp, 0x10
xor eax, eax
inc eax
jmp 0x6726816
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.06708594
leave
ret
Function at 0x672af9d
Capabilities:
Clear file content

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x2c
push ebx
mov ebx, dword [ebp + 8]
lea ecx, [ebp - 0x2c]
push esi
push edi
push dword [ebp + 0x10]
mov edi, dword [ebp + 0x14]
push dword [ebp + 0xc]
push ebx
call fcn.0672af19
mov eax, dword [ebp - 0x2c]
and eax, dword [ebp - 0x28]
cmp eax, 0xffffffff
je 0x672b10c
mov eax, dword [ebp - 0x24]
and eax, dword [ebp - 0x20]
cmp eax, 0xffffffff
je 0x672b10c
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 8], ecx
mov dword [ebp - 4], eax
test ecx, ecx
jl 0x672b0c1
jg 0x672aff9
test eax, eax
je 0x672b0b7
push 1
push 0x1000
call fcn.0671d2a5
mov esi, eax
pop ecx
pop ecx
test esi, esi
jne 0x672b01c
push 0xc
pop ebx
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], ebx
jmp 0x672b0ae
push 0x8000
push ebx
call fcn.0672ae4a
pop ecx
pop ecx
mov ecx, dword [ebp - 0x1c]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0x18]
test eax, eax
jl 0x672b045
jg 0x672b040
cmp ecx, 0x1000
jb 0x672b045
mov ecx, 0x1000
push edi
push ecx
push esi
push ebx
call fcn.0671d089
add esp, 0x10
cmp eax, 0xffffffff
je 0x672b08a
mov ecx, dword [ebp - 4]
cdq
sub ecx, eax
mov eax, dword [ebp - 8]
mov dword [ebp - 4], ecx
sbb eax, edx
mov dword [ebp - 8], eax
test eax, eax
jg 0x672b040
jl 0x672b071
test ecx, ecx
jne 0x672b032
push dword [ebp - 0xc]
push ebx
call fcn.0672ae4a
push esi
call fcn.06719c42
add esp, 0xc
xor ebx, ebx
jmp 0x672b11a
cmp byte [edi + 0x24], 0
je 0x672b0a1
cmp dword [edi + 0x20], 5
jne 0x672b0a1
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], 0xd
cmp byte [edi + 0x1c], 0
je 0x672b0ac
mov ebx, dword [edi + 0x18]
jmp 0x672b0ae
xor ebx, ebx
push esi
call fcn.06719c42
pop ecx
jmp 0x672b11a
test ecx, ecx
jg 0x672b083
jl 0x672b0c1
test eax, eax
jae 0x672b083
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.0671d548
and eax, edx
add esp, 0x10
cmp eax, 0xffffffff
jne 0x672b0e1
cmp byte [edi + 0x1c], 0
je 0x672b083
jmp 0x672b112
push ebx
call fcn.06726bef
pop ecx
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x672b083
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 0xd
mov byte [edi + 0x24], 1
mov dword [edi + 0x20], eax
pop ebx
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], ebx
jmp 0x672b11a
cmp byte [edi + 0x1c], 0
je 0x672b117
mov ebx, dword [edi + 0x18]
jmp 0x672b11a
push 0x16
pop ebx
push 0
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
push dword [ebp - 0x14]
call fcn.0671d548
add esp, 0x10
mov eax, ebx
pop edi
pop esi
pop ebx
leave
ret

Function at 0x672c5f0
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x672c61d
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x672c61d
mov edx, 0x10b
xor eax, eax
cmp word [ecx + 0x18], dx
sete al
pop ebp
ret
xor eax, eax
pop ebp
ret
Function at 0x30041869
Capabilities:
Terminate process

Disassembly:
push 0x5c
push 0x30043668
call fcn.300419d0
xor ebx, ebx
mov dword [ebp - 0x1c], ebx
mov dword [ebp - 4], ebx
lea eax, [ebp - 0x6c]
push eax
call dword [sym.imp.KERNEL32.dll_GetStartupInfoW]
mov dword [ebp - 4], 0xfffffffe
mov dword [ebp - 4], 1
mov eax, dword fs:[0x18]
mov esi, dword [eax + 4]
mov dword [ebp - 0x20], ebx
mov edi, 0x3007d2b4
push ebx
push esi
push edi
call dword [sym.imp.KERNEL32.dll_InterlockedCompareExchange]
cmp eax, ebx
je 0x3004160c
cmp eax, esi
jne 0x300415ff
xor esi, esi
inc esi
mov dword [ebp - 0x20], esi
jmp 0x3004160f
push 0x3e8
call dword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x300415e6
xor esi, esi
inc esi
mov eax, dword [0x3007d2b0]
cmp eax, esi
jne 0x30041622
push 0x1f
call sub.MSVCR80.dll__amsg_exit
pop ecx
jmp 0x30041651
mov eax, dword [0x3007d2b0]
test eax, eax
jne 0x3004164b
mov dword [0x3007d2b0], esi
push 0x3000146c
push 0x30001460
call fcn.301ee000
pop ecx
pop ecx
test eax, eax
je 0x30041651
jmp 0x30041775
mov dword [0x3007cf60], esi
mov eax, dword [0x3007d2b0]
cmp eax, esi
jne 0x30041675
push 0x3000145c
push 0x30001444
call sub.MSVCR80.dll__initterm
pop ecx
pop ecx
mov dword [0x3007d2b0], 2
cmp dword [ebp - 0x20], ebx
jne 0x30041682
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_InterlockedExchange]
cmp dword [0x3007d2c0], ebx
je 0x300416a3
push 0x3007d2c0
call fcn.30041e9d
pop ecx
test eax, eax
je 0x300416a3
push ebx
push 2
push ebx
call dword [0x3007d2c0]
mov eax, dword [sym.imp.MSVCR80.dll__wcmdln]
cmp dword [eax], ebx
je 0x30041775
mov eax, dword [eax]
mov dword [ebp - 0x24], eax
movzx ecx, word [eax]
cmp cx, 0x20
ja 0x3004170d
cmp cx, bx
je 0x300416c8
cmp dword [ebp - 0x1c], ebx
jne 0x3004170d
movzx ecx, word [eax]
cmp cx, bx
je 0x300416dd
cmp cx, 0x20
ja 0x300416dd
inc eax
inc eax
mov dword [ebp - 0x24], eax
jmp 0x300416c8
test byte [ebp - 0x40], 1
je 0x300416e9
movzx ecx, word [ebp - 0x3c]
jmp 0x300416ec
push 0xa
pop ecx
push ecx
push eax
push ebx
push 0x30000000
call main
mov dword [0x3007cf5c], eax
cmp dword [0x3007cf50], ebx
jne 0x30041752
push eax
call dword [sym.imp.MSVCR80.dll_exit]
cmp cx, 0x22
jne 0x3004171e
xor ecx, ecx
cmp dword [ebp - 0x1c], ebx
sete cl
mov dword [ebp - 0x1c], ecx
inc eax
inc eax
jmp 0x300416b2
cmp dword [0x3007cf60], ebx
jne 0x30041760
call dword [sym.imp.MSVCR80.dll__cexit]
mov dword [ebp - 4], 0xfffffffe
mov eax, dword [0x3007cf5c]
jmp 0x30041781
mov dword [ebp - 4], 0xfffffffe
mov eax, 0xff
call fcn.30041a15
ret
call fcn.30040f0c
jmp 0x300415a9
Function at 0x487ebf
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff0
mov eax, section.sect_0
call 0x487ebf
lcall 0x5de5, 0x8b10c483
jmp loc.0310f518
Function at 0x100112c
Capabilities:
Query or enumerate registry value
Set registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
mov dword [ebp - 0x10], 4
call dword [sym.imp.KERNEL32.dll_GetTickCount]
shr eax, 3
mov ebx, 0x3e8
xor edx, edx
mov ecx, ebx
div ecx
lea eax, [ebp - 8]
push eax
push 0x10010e8
push 0x80000002
mov dword [ebp - 0xc], edx
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyA]
test eax, eax
je 0x100116e
mov eax, dword [ebp - 0xc]
jmp 0x10011c8
push esi
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0x14]
push eax
push 0
mov esi, 0x10010dc
push esi
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
je 0x1001194
and dword [ebp - 4], 0
inc dword [ebp - 4]
push 4
lea eax, [ebp - 4]
push eax
push 4
push 0
push esi
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
pop esi
je 0x10011b6
mov eax, dword [ebp - 0xc]
mov dword [ebp - 4], eax
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, dword [ebp - 4]
xor edx, edx
div ebx
mov eax, edx
pop ebx
leave
ret

Function at 0x10011cb
Capabilities:
Get file size
Get hostname
Get session user name

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x38
and dword [ebp - 8], 0
push ebx
push 0
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x10011fd
push 0x2712
push 1
call fcn.01001760
pop ecx
pop ecx
xor eax, eax
jmp 0x10012f1
push esi
push edi
lea eax, [ebp - 4]
push eax
mov edi, 0x1002040
mov esi, 0x101
push edi
mov dword [ebp - 4], esi
call dword [sym.imp.KERNEL32.dll_GetComputerNameA]
lea eax, [ebp - 4]
mov dword [ebp - 4], esi
push eax
mov esi, 0x1003160
push esi
call dword [sym.imp.ADVAPI32.dll_GetUserNameA]
mov al, byte [ebp + 0x1c]
mov dword [ebp - 0x38], edi
mov dword [ebp - 0x34], esi
mov byte [ebp - 0x30], al
call fcn.0100112c
mov edi, dword [ebp + 8]
mov dword [ebp - 0x28], eax
mov eax, dword [ebp + 0x14]
mov dword [ebp - 0x24], eax
mov eax, dword [ebp + 0x18]
mov dword [ebp - 0x20], eax
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp + 0x20]
mov dword [ebp - 0x18], eax
mov eax, dword [ebp + 0x24]
push edi
mov dword [ebp - 0x2c], ebx
mov dword [ebp - 0x14], eax
call sub.LPRHELP.dll_InitiateConnection
test eax, eax
je 0x100127e
push 0x2713
push 1
call fcn.01001760
pop ecx
pop ecx
xor eax, eax
jmp 0x10012ef
lea eax, [ebp - 0x38]
push eax
push edi
call sub.LPRHELP.dll_StartJob
test eax, eax
je 0x1001293
push 0x2714
jmp 0x1001271
test ebx, ebx
jbe 0x10012cd
mov esi, 0x1002160
push 0x1000
push esi
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll__lread]
cmp eax, 0xffffffff
je 0x10012de
lea ecx, [ebp - 0xc]
push ecx
push eax
push esi
push edi
call sub.LPRHELP.dll_WriteJobData
test eax, eax
jne 0x10012e5
mov eax, dword [ebp - 8]
add eax, dword [ebp - 0xc]
cmp eax, ebx
mov dword [ebp - 8], eax
jb 0x100129c
push edi
call sub.LPRHELP.dll_EndJob
test eax, eax
je 0x10012ec
push 0x2717
jmp 0x1001271
push 0x2715
jmp 0x1001271
push 0x2716
jmp 0x1001271
xor eax, eax
inc eax
pop edi
pop esi
pop ebx
leave
ret 0x20
Function at 0x1001542
Capabilities:
Parse pe header
Terminate process

Disassembly:
push 0x28
push 0x1001108
call fcn.010016e0
xor edi, edi
push edi
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
cmp word [eax], 0x5a4d
jne 0x100157d
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x100157d
movzx eax, word [ecx + 0x18]
cmp eax, 0x10b
je 0x1001595
cmp eax, 0x20b
je 0x1001582
mov dword [ebp - 0x1c], edi
jmp 0x10015a9
cmp dword [ecx + 0x84], 0xe
jbe 0x100157d
xor eax, eax
cmp dword [ecx + 0xf8], edi
jmp 0x10015a3
cmp dword [ecx + 0x74], 0xe
jbe 0x100157d
xor eax, eax
cmp dword [ecx + 0xe8], edi
setne al
mov dword [ebp - 0x1c], eax
mov dword [ebp - 4], edi
push 1
call dword [sym.imp.msvcrt.dll___set_app_type]
pop ecx
or dword [0x1003264], 0xffffffff
or dword [0x1003268], 0xffffffff
call dword [sym.imp.msvcrt.dll___p__fmode]
mov ecx, dword [0x100202c]
mov dword [eax], ecx
call dword [sym.imp.msvcrt.dll___p__commode]
mov ecx, dword [0x1002028]
mov dword [eax], ecx
mov eax, dword [sym.imp.msvcrt.dll__adjust_fdiv]
mov eax, dword [eax]
mov dword [0x100326c], eax
call fcn.010016da
cmp dword [section..data], edi
jne 0x1001604
push fcn.010016da
call dword [sym.imp.msvcrt.dll___setusermatherr]
pop ecx
call fcn.010016c8
push 0x10010b8
push 0x10010b4
call sub.msvcrt.dll__initterm
mov eax, dword [0x1002024]
mov dword [ebp - 0x20], eax
lea eax, [ebp - 0x20]
push eax
push dword [0x1002020]
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x28]
push eax
lea eax, [ebp - 0x2c]
push eax
call dword [sym.imp.msvcrt.dll___getmainargs]
mov dword [ebp - 0x30], eax
push 0x10010b0
push 0x10010ac
call sub.msvcrt.dll__initterm
mov eax, dword [ebp - 0x24]
mov ecx, dword [sym.imp.msvcrt.dll___initenv]
mov dword [ecx], eax
push dword [ebp - 0x24]
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
call fcn.01001383
add esp, 0x30
mov esi, eax
mov dword [ebp - 0x34], esi
cmp dword [ebp - 0x1c], edi
jne 0x100167b
push esi
call dword [sym.imp.msvcrt.dll_exit]
call dword [sym.imp.msvcrt.dll__cexit]
jmp 0x10016b0
or dword [ebp - 4], 0xffffffff
mov eax, esi
call fcn.01001719
ret
Function at 0x401310
Capabilities:
Delete file
Extract resource via kernel32 functions
Get common file path
Write file on windows

Disassembly:
sub esp, 0x208
mov eax, dword [0x44f7f4]
xor eax, esp
mov dword [esp + 0x204], eax
cmp dword [0x450fa8], 0
je 0x401347
mov eax, 1
mov ecx, dword [esp + 0x204]
xor ecx, esp
call fcn.004221b5
add esp, 0x208
ret
push ebx
push ebp
push esi
push edi
push 0x43f800
push 0x6d
push 0
call dword [sym.imp.KERNEL32.dll_FindResourceA]
mov ebx, dword [sym.imp.KERNEL32.dll_LoadResource]
mov ebp, dword [sym.imp.KERNEL32.dll_LockResource]
mov esi, eax
test esi, esi
je 0x4013aa
push esi
push 0
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov edi, eax
cmp edi, 0x64
ja 0x401435
push esi
push 0
call ebx
push eax
call ebp
mov esi, eax
push edi
push esi
call fcn.004012d0
add esp, 8
test eax, eax
je 0x401435
push esi
call fcn.00422b26
add esp, 4
mov dword [0x451060], eax
push 0x43f7fc
push 0x6f
push 0
call dword [sym.imp.KERNEL32.dll_FindResourceA]
mov esi, eax
test esi, esi
je 0x4013f9
push esi
push 0
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov edi, eax
cmp edi, 0x64
ja 0x401435
push esi
push 0
call ebx
push eax
call ebp
mov esi, eax
push edi
push esi
call fcn.004012d0
add esp, 8
test eax, eax
je 0x401435
push 0x64
push esi
push 0x64
push 0x450fb8
call fcn.00422a62
add esp, 0x10
push 0x43f7f8
push 0x70
push 0
call dword [sym.imp.KERNEL32.dll_FindResourceA]
mov esi, eax
test esi, esi
je 0x401536
push esi
push 0
call dword [sym.imp.KERNEL32.dll_SizeofResource]
push esi
push 0
mov edi, eax
call ebx
push eax
call ebp
mov esi, eax
push edi
push esi
call fcn.004012d0
add esp, 8
test eax, eax
jne 0x40143c
xor eax, eax
jmp 0x40153b
lea eax, [esp + 0x114]
push eax
push 0xff
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
lea ecx, [esp + 0x14]
push ecx
push 0
push 0x43f7f4
lea edx, [esp + 0x120]
push edx
call dword [sym.imp.KERNEL32.dll_GetTempFileNameA]
push 0x43f7f0
lea eax, [esp + 0x18]
push eax
lea ecx, [esp + 0x18]
push ecx
mov dword [esp + 0x1c], 0
call fcn.00422a12
mov eax, dword [esp + 0x1c]
add esp, 0xc
test eax, eax
je 0x401536
push eax
push 1
push edi
push esi
call fcn.004228c1
mov edx, dword [esp + 0x20]
mov esi, eax
sub esi, 1
neg esi
sbb esi, esi
push edx
add esi, 1
call fcn.0042272b
add esp, 0x14
test esi, esi
je 0x401522
lea eax, [esp + 0x14]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov esi, eax
test esi, esi
je 0x401522
mov edi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x43f7f8
push esi
call edi
push 0x43f7fc
push esi
mov dword [0x451184], eax
call edi
push 0x43f800
push esi
mov dword [0x451188], eax
call edi
cmp dword [0x451184], 0
mov dword [0x45118c], eax
je 0x40151b
cmp dword [0x451188], 0
je 0x40151b
test eax, eax
je 0x40151b
mov dword [0x450fa8], 1
jmp 0x401536
push esi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
cmp dword [0x450fa8], 0
jne 0x401536
lea ecx, [esp + 0x14]
push ecx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov eax, dword [0x450fa8]
mov ecx, dword [esp + 0x214]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.004221b5
add esp, 0x208
ret
Function at 0x4015e0
Capabilities:
Contain obfuscated stackstrings
Resolve function by parsing pe exports

Disassembly:
sub esp, 0x84
mov eax, dword [0x44f7f4]
xor eax, esp
mov dword [esp + 0x80], eax
xor eax, eax
push esi
push edi
mov edi, dword [esp + 0x94]
mov dword [esp + 0x28], eax
mov word [esp + 0x2c], ax
mov dword [esp + 0x32], eax
mov word [esp + 0x36], ax
mov dword [esp + 0x3c], eax
mov word [esp + 0x40], ax
mov dword [esp + 0x46], eax
mov word [esp + 0x4a], ax
mov dword [esp + 0x50], eax
mov word [esp + 0x54], ax
mov dword [esp + 0x5a], eax
mov word [esp + 0x5e], ax
mov dword [esp + 0x64], eax
mov word [esp + 0x68], ax
mov dword [esp + 0x6e], eax
mov word [esp + 0x72], ax
mov dword [esp + 0x78], eax
mov word [esp + 0x7c], ax
mov dword [esp + 0x82], eax
mov word [esp + 0x86], ax
mov eax, dword [esp + 0x90]
mov dword [esp + 0x10], edi
mov byte [esp + 0x18], 0x2b
mov byte [esp + 0x19], 0x2f
mov byte [esp + 0x1a], 0x3f
mov byte [esp + 0x1b], 0x25
mov byte [esp + 0x1c], 0x23
mov byte [esp + 0x1d], 0x26
mov byte [esp + 0x1e], 0x3d
mov byte [esp + 0x1f], 0x5c
mov byte [esp + 0x20], 0x2e
mov byte [esp + 0x21], 0x3a
mov dword [esp + 0x24], 0x423225
mov dword [esp + 0x2e], 0x463225
mov dword [esp + 0x38], 0x463325
mov dword [esp + 0x42], 0x353225
mov dword [esp + 0x4c], 0x333225
mov dword [esp + 0x56], 0x363225
mov dword [esp + 0x60], 0x443325
mov dword [esp + 0x6a], 0x433525
mov dword [esp + 0x74], 0x453225
mov dword [esp + 0x7e], 0x413325
lea ecx, [eax + 1]
nop
mov dl, byte [eax]
add eax, 1
test dl, dl
jne 0x4016f0
sub eax, ecx
mov esi, 0
mov dword [esp + 0x14], eax
mov dword [esp + 0xc], esi
je 0x4017b2
push ebx
push ebp
xor ebx, ebx
mov dword [esp + 0x10], ebx
lea ebp, [esp + 0x2c]
lea ebx, [ebx]
mov eax, dword [esp + 0x98]
mov cl, byte [esi + eax]
cmp cl, byte [esp + ebx + 0x20]
jne 0x401770
mov eax, ebp
mov dword [esp + 0x10], 1
mov ecx, eax
lea esp, [esp]
mov dl, byte [eax]
add eax, 1
test dl, dl
jne 0x401740
sub eax, ecx
mov esi, ecx
add edi, 0xffffffff
mov cl, byte [edi + 1]
add edi, 1
test cl, cl
jne 0x401750
mov ecx, eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, dword [esp + 0x18]
mov esi, dword [esp + 0x14]
add ebx, 1
add ebp, 0xa
cmp ebx, 0xa
jb 0x401720
cmp dword [esp + 0x10], 0
jne 0x40179f
mov eax, edi
lea edx, [eax + 1]
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x401787
sub eax, edx
mov edx, dword [esp + 0x98]
mov cl, byte [esi + edx]
mov byte [eax + edi], cl
add esi, 1
cmp esi, dword [esp + 0x1c]
mov dword [esp + 0x14], esi
jb 0x401710
pop ebp
pop ebx
mov ecx, dword [esp + 0x88]
pop edi
pop esi
xor ecx, esp
call fcn.004221b5
add esp, 0x84
ret 8