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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x88
mov dword [ebp - 0x34], esp
mov eax, dword [ebp + 8]
lea ecx, [ebp - 0x18]
mov dword [ebp - 0xc], ebx
mov dword [ebp - 8], esi
mov dword [ebp - 0x60], eax
lea eax, [ebp - 0x5c]
mov dword [esp], eax
mov dword [ebp - 4], edi
mov dword [ebp - 0x44], sym.___gxx_personality_sj0
mov dword [ebp - 0x40], 0x40e410
mov dword [ebp - 0x3c], ecx
mov dword [ebp - 0x38], 0x4096c8
call sym.__Unwind_SjLj_Register
mov dword [ebp - 0x64], 0
mov eax, dword [ebp + 0xc]
test eax, eax
je 0x4095df
mov eax, dword [0x40f0f8]
test eax, eax
je 0x409600
cmp dword [ebp + 0xc], 0x80
ja 0x4095ca
cmp dword [0x40f0f8], 1
jne 0x409632
mov dword [ebp - 0x58], 0xffffffff
mov eax, dword [ebp + 0xc]
mov dword [esp], eax
call sym.operator_new_unsigned_int_
mov dword [ebp - 0x64], eax
lea eax, [ebp - 0x5c]
mov dword [esp], eax
call sym.__Unwind_SjLj_Unregister
mov eax, dword [ebp - 0x64]
mov ebx, dword [ebp - 0xc]
mov esi, dword [ebp - 8]
mov edi, dword [ebp - 4]
mov esp, ebp
pop ebp
ret
mov dword [esp], str.GLIBCXX_FORCE_NEW
call sym._getenv
test eax, eax
jne 0x4096b0
mov edi, 0xffffffff
mov dword [esp + 4], edi
mov dword [esp], 0x40f0f8
mov dword [ebp - 0x58], 0xffffffff
call method.__gnu_cxx.__atomic_add_int_volatile__int_
jmp 0x4095b8
mov dword [ebp - 0x58], 0xffffffff
mov ecx, dword [ebp + 0xc]
mov eax, dword [ebp - 0x60]
mov dword [esp + 4], ecx
mov dword [esp], eax
call method.__gnu_cxx::__pool_alloc_base._M_get_free_list_unsigned_int_
mov dword [ebp - 0x68], eax
mov ecx, dword [ebp - 0x60]
mov dword [esp], ecx
call method.__gnu_cxx::__pool_alloc_base._M_get_mutex__
mov dword [ebp - 0x28], eax
mov esi, dword [0x416370]
test esi, esi
jne 0x4096be
mov eax, dword [ebp - 0x68]
mov edx, dword [eax]
test edx, edx
je 0x4096ff
mov eax, dword [edx]
mov dword [ebp - 0x64], edx
mov ecx, dword [ebp - 0x68]
mov dword [ecx], eax
mov ebx, dword [ebp - 0x64]
test ebx, ebx
je 0x409726
mov edx, dword [0x416370]
mov eax, dword [ebp - 0x28]
test edx, edx
je 0x4095df
mov dword [esp], eax
mov dword [ebp - 0x58], 1
call sym.___gthr_win32_mutex_unlock
jmp 0x4095df
mov eax, 1
mov dword [esp + 4], eax
jmp 0x40961d
mov dword [esp], eax
call sym.___gthr_win32_mutex_lock
jmp 0x409666
mov dword [ebp - 0x58], 3
mov eax, dword [ebp + 0xc]
mov ecx, dword [ebp - 0x60]
add eax, 7
and eax, 0xfffffff8
mov dword [esp + 4], eax
mov dword [esp], ecx
call method.__gnu_cxx::__pool_alloc_base._M_refill_unsigned_int_
mov dword [ebp - 0x64], eax
jmp 0x40967d
mov dword [ebp - 0x58], 3
call method.std.__throw_bad_alloc__
jmp 0x409688
Function at 0x409930
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x88
mov dword [ebp - 0x34], esp
mov eax, dword [ebp + 8]
lea ecx, [ebp - 0x18]
mov dword [ebp - 0xc], ebx
mov dword [ebp - 8], esi
mov dword [ebp - 0x60], eax
lea eax, [ebp - 0x5c]
mov dword [ebp - 4], edi
mov dword [ebp - 0x44], sym.___gxx_personality_sj0
mov dword [ebp - 0x40], 0x40e438
mov dword [ebp - 0x3c], ecx
mov dword [ebp - 0x38], 0x409ad9
mov dword [esp], eax
call sym.__Unwind_SjLj_Register
mov dword [ebp - 0x64], 0
mov eax, dword [ebp + 0xc]
test eax, eax
je 0x409a40
mov edi, dword [ebp + 0xc]
test edi, edi
js 0x409a34
mov esi, dword [0x40f0fc]
test esi, esi
je 0x409a90
mov eax, dword [ebp + 0xc]
add eax, eax
cmp eax, 0x80
mov dword [ebp - 0x68], eax
ja 0x409a60
cmp dword [0x40f0fc], 1
je 0x409a60
mov eax, dword [ebp - 0x68]
mov ecx, dword [ebp - 0x60]
mov dword [esp + 4], eax
mov dword [esp], ecx
mov dword [ebp - 0x58], 0xffffffff
call method.__gnu_cxx::__pool_alloc_base._M_get_free_list_unsigned_int_
mov dword [ebp - 0x6c], eax
mov eax, dword [ebp - 0x60]
mov dword [esp], eax
call method.__gnu_cxx::__pool_alloc_base._M_get_mutex__
mov dword [ebp - 0x28], eax
mov edx, dword [0x416370]
test edx, edx
jne 0x409acc
mov ecx, dword [ebp - 0x6c]
mov edx, dword [ecx]
test edx, edx
je 0x409b10
mov eax, dword [edx]
mov dword [ebp - 0x64], edx
mov ecx, dword [ebp - 0x6c]
mov dword [ecx], eax
mov eax, dword [ebp - 0x64]
test eax, eax
je 0x409b37
mov esi, dword [0x416370]
mov eax, dword [ebp - 0x28]
test esi, esi
je 0x409a40
mov dword [esp], eax
mov dword [ebp - 0x58], 1
call sym.___gthr_win32_mutex_unlock
jmp 0x409a40
mov dword [ebp - 0x58], 0xffffffff
call method.std.__throw_bad_alloc__
lea eax, [ebp - 0x5c]
mov dword [esp], eax
call sym.__Unwind_SjLj_Unregister
mov eax, dword [ebp - 0x64]
mov ebx, dword [ebp - 0xc]
mov esi, dword [ebp - 8]
mov edi, dword [ebp - 4]
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 0x68]
mov dword [esp], ecx
mov dword [ebp - 0x58], 0xffffffff
call sym.operator_new_unsigned_int_
mov dword [ebp - 0x64], eax
lea eax, [ebp - 0x5c]
mov dword [esp], eax
call sym.__Unwind_SjLj_Unregister
mov eax, dword [ebp - 0x64]
mov ebx, dword [ebp - 0xc]
mov esi, dword [ebp - 8]
mov edi, dword [ebp - 4]
mov esp, ebp
pop ebp
ret
mov dword [esp], str.GLIBCXX_FORCE_NEW
call sym._getenv
test eax, eax
je 0x409ac1
mov ebx, 1
mov dword [esp + 4], ebx
mov dword [esp], 0x40f0fc
mov dword [ebp - 0x58], 0xffffffff
call method.__gnu_cxx.__atomic_add_int_volatile__int_
jmp 0x40999c
mov ecx, 0xffffffff
mov dword [esp + 4], ecx
jmp 0x409aa9
mov dword [esp], eax
call sym.___gthr_win32_mutex_lock
jmp 0x4099f4
mov eax, dword [ebp - 0x68]
add eax, 7
and eax, 0xfffffff8
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x60]
mov dword [esp], eax
mov dword [ebp - 0x58], 3
call method.__gnu_cxx::__pool_alloc_base._M_refill_unsigned_int_
mov dword [ebp - 0x64], eax
jmp 0x409a0b
mov dword [ebp - 0x58], 3
call method.std.__throw_bad_alloc__
jmp 0x409a16
Function at 0x403553
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1000
call fcn.00413ac0
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
cmp word [esi], 0
je 0x4036d4
push esi
call fcn.004036dd
push esi
call fcn.00418793
pop ecx
push esi
mov edi, eax
call fcn.00403708
test al, al
je 0x403608
push esi
call fcn.004036dd
test al, al
je 0x4035c2
lea eax, [edi + 4]
cmp dword [ebp + 0x10], eax
jbe 0x4036d4
push dword [ebp + 0x10]
push str.__
push dword [ebp + 0xc]
call fcn.004068cd
push dword [ebp + 0x10]
push esi
push dword [ebp + 0xc]
call fcn.004068a5
mov al, 1
jmp 0x4036d6
push 0x5c
pop eax
cmp word [esi], ax
jne 0x4036d4
lea ebx, [esi + 2]
cmp word [ebx], ax
jne 0x4036d4
mov esi, dword [ebp + 0x10]
lea eax, [edi + 6]
cmp esi, eax
jbe 0x4036d4
push esi
push str.__
push dword [ebp + 0xc]
call fcn.004068cd
push esi
push 0x4285e4
push dword [ebp + 0xc]
call fcn.004068a5
push esi
push ebx
jmp 0x4035b3
lea eax, [ebp - 0x1000]
mov ebx, 0x7ff
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
test eax, eax
je 0x4036d4
cmp eax, ebx
ja 0x4036d4
movzx eax, word [esi]
push eax
call fcn.0040373d
test al, al
je 0x403673
lea eax, [edi + 6]
mov edi, dword [ebp + 0x10]
cmp edi, eax
jbe 0x4036d4
push edi
push str.__
push dword [ebp + 0xc]
call fcn.004068cd
xor eax, eax
mov word [ebp - 0xffc], ax
lea eax, [ebp - 0x1000]
push edi
push eax
push dword [ebp + 0xc]
call fcn.004068a5
push edi
jmp 0x4035b2
push 0x800
lea eax, [ebp - 0x1000]
push eax
call fcn.0040316f
lea eax, [ebp - 0x1000]
push eax
call fcn.00418793
add edi, 4
add eax, edi
mov edi, dword [ebp + 0x10]
pop ecx
cmp edi, eax
jbe 0x4036d4
push edi
push str.__
push dword [ebp + 0xc]
call fcn.004068cd
push edi
lea eax, [ebp - 0x1000]
push eax
push dword [ebp + 0xc]
call fcn.004068a5
cmp word [esi], 0x2e
jne 0x40366d
movzx eax, word [esi + 2]
push eax
call fcn.0040373d
test al, al
je 0x40366d
add esi, 4
jmp 0x40366d
xor al, al
pop edi
pop esi
pop ebx
leave
ret 0xc
Function at 0x401077
Capabilities:
Get common file path

Disassembly:
push ebx
mov ebx, 0x111
cmp dword [esp + 0xc], ebx
push esi
push edi
jne 0x4010d6
movzx eax, word [esp + 0x18]
dec eax
jne 0x4010d6
mov esi, dword [sym.imp.USER32.dll_GetFocus]
call esi
mov edi, dword [sym.imp.USER32.dll_GetDlgCtrlID]
push eax
call edi
cmp eax, 0x461
je 0x4010d6
call esi
push eax
call edi
cmp eax, 0x471
je 0x4010d6
mov eax, dword [0x4063e4]
add eax, 0x13b34
push eax
push 0x100
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
push 1
push 3
push ebx
push dword [esp + 0x1c]
call dword [sym.imp.USER32.dll_PostMessageA]
pop edi
pop esi
xor eax, eax
pop ebx
ret 0x10
Function at 0x401fb9
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x108
push ebx
push esi
push edi
push 6
push str._WORK_
xor ebx, ebx
push dword [ebp + 8]
mov byte [ebp - 0x108], bl
xor edi, edi
call fcn.004021d5
test eax, eax
jne 0x401ffa
lea eax, [ebp - 0x108]
push eax
push 0x100
call fcn.0040220f
push 6
jmp 0x4020da
push 8
pop esi
push esi
push str._WinDir_
push dword [ebp + 8]
call fcn.004021d5
test eax, eax
jne 0x402028
lea eax, [ebp - 0x108]
push 0x100
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
mov edi, esi
jmp 0x40212c
push 9
push str._WinRoot_
push dword [ebp + 8]
call fcn.004021d5
test eax, eax
jne 0x40205a
lea eax, [ebp - 0x108]
push 0x100
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
mov byte [ebp - 0x106], bl
push 9
jmp 0x4020da
push 0xb
push str._SystemDir_
push dword [ebp + 8]
call fcn.004021d5
test eax, eax
jne 0x40207a
push 0xb
pop edi
push 0x100
jmp 0x40211f
push 0xe
push str._ProgramFiles_
push dword [ebp + 8]
call fcn.004021d5
test eax, eax
jne 0x4020dd
cmp dword [0x4063d8], ebx
mov byte [ebp - 0x108], bl
mov esi, 0x100
jne 0x4020bc
lea eax, [ebp - 0x108]
push esi
push eax
push 0x4063cc
push str.ProgramFilesDir
push str.SOFTWAREMicrosoftWindowsCurrentVersion
call fcn.0040215c
cmp byte [ebp - 0x108], bl
jne 0x4020d8
lea eax, [ebp - 0x108]
push esi
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
mov byte [ebp - 0x106], bl
push 0xe
pop edi
jmp 0x40212c
push esi
push str._Search_
push dword [ebp + 8]
call fcn.004021d5
test eax, eax
jne 0x40212c
mov eax, dword [ebp + 0xc]
cmp byte [eax], bl
je 0x40212c
lea ecx, [ebp - 4]
mov edi, esi
push ecx
lea ecx, [ebp - 0x108]
mov esi, 0x100
push ecx
push esi
push ebx
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_SearchPathA]
test eax, eax
jbe 0x40211e
mov eax, dword [ebp - 4]
mov byte [eax - 1], bl
jmp 0x40212c
push esi
lea eax, [ebp - 0x108]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
mov esi, dword [ebp + 8]
lea eax, [ebp - 0x108]
add edi, esi
push edi
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatA]
lea eax, [ebp - 0x108]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
push 0x5c
push esi
call fcn.00401e2c
pop edi
pop esi
pop ebx
leave
ret 8

Function at 0x40215c
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x54
and dword [ebp - 4], 0
push esi
push dword [ebp + 8]
mov esi, dword [sym.imp.KERNEL32.dll_lstrcpyA]
lea eax, [ebp - 0x54]
push eax
call esi
lea eax, [ebp - 4]
push eax
push 1
lea eax, [ebp - 0x54]
push 0
push eax
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
je 0x40219b
push dword [ebp + 0x10]
push dword [ebp + 0x14]
call esi
jmp 0x4021d0
lea eax, [ebp + 0x18]
mov dword [ebp + 8], 1
push eax
lea eax, [ebp + 8]
push dword [ebp + 0x14]
push eax
push 0
push dword [ebp + 0xc]
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
je 0x4021c7
push dword [ebp + 0x10]
push dword [ebp + 0x14]
call esi
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop esi
leave
ret 0x14
Function at 0x40240d
Capabilities:
Encode data using xor

Disassembly:
mov eax, dword [esp + 8]
mov ecx, eax
dec eax
test ecx, ecx
jle 0x402455
push edi
push esi
mov esi, dword [esp + 0xc]
push ebx
lea edi, [eax + 1]
mov eax, dword [0x4063e4]
movzx ebx, byte [esi]
mov cx, word [eax + 0x250]
mov edx, ecx
and edx, 0xff
xor edx, ebx
xor ebx, ebx
mov bl, ch
mov cx, word [eax + edx*2 + 0x48]
xor cx, bx
inc esi
dec edi
mov word [eax + 0x250], cx
jne 0x402422
pop ebx
pop esi
pop edi
mov eax, dword [0x4063e4]
mov ax, word [eax + 0x250]
ret 8

Function at 0x40265b
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
cmp dword [ebp + 0x10], 0xffffffff
push esi
je 0x4026ab
mov esi, dword [ebp + 0xc]
lea eax, [ebp + 0xc]
push 0
push eax
push esi
push dword [ebp + 8]
push dword [ebp + 0x10]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x402684
cmp esi, dword [ebp + 0xc]
je 0x4026a0
mov eax, dword [0x4063e4]
add eax, 0x13b34
push eax
push str.Write_ERROR
call fcn.00402380
push 1
call fcn.004026fe
push esi
push dword [ebp + 8]
call fcn.0040240d
jmp 0x4026f9
mov eax, dword [0x4063e4]
mov cl, byte [eax + 0x344e]
cmp cl, 1
jne 0x4026d5
mov edx, dword [ebp + 0xc]
mov ecx, 0x400
cmp edx, ecx
ja 0x4026ca
lea ecx, [edx + 1]
push ecx
add eax, 0x17e38
push dword [ebp + 8]
jmp 0x4026f2
cmp cl, 2
jne 0x4026f9
mov edx, dword [ebp + 0xc]
mov ecx, 0x1000
cmp edx, ecx
ja 0x4026e9
lea ecx, [edx + 1]
push ecx
add eax, 0x18238
push dword [ebp + 8]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpynA]
pop esi
pop ebp
ret 0xc

Function at 0x4026fe
Capabilities:
Delete file
Terminate process

Disassembly:
mov eax, dword [0x4063e4]
mov eax, dword [eax + 0x38]
test eax, eax
je 0x402727
cmp eax, 0xffffffff
je 0x402727
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [0x4063e4]
add eax, 0x13b34
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov eax, dword [0x4063e4]
mov eax, dword [eax + 0x34]
test eax, eax
je 0x40273f
cmp eax, 0xffffffff
je 0x40273f
push eax
call dword [sym.imp.KERNEL32.dll__lclose]
mov eax, dword [0x4063e4]
push dword [esp + 4]
or dword [eax + 0x38], 0xffffffff
mov eax, dword [0x4063e4]
or dword [eax + 0x34], 0xffffffff
call sub.CRTDLL.dll_exit
pop ecx
ret 4
Function at 0x403114
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x68
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
mov edi, dword [eax]
push 1
pop ebx
lea eax, [ebp - 0x68]
push 0x64
push eax
push 0x4062dc
xor esi, esi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableA]
test eax, eax
je 0x403189
mov cl, byte [ebp - 0x68]
lea eax, [ebp - 0x68]
test cl, cl
je 0x403160
cmp cl, 0x2b
je 0x403160
cmp cl, 0x2d
je 0x403160
cmp cl, 0x30
jb 0x40315a
cmp cl, 0x39
jbe 0x403160
mov cl, byte [eax + 1]
inc eax
jmp 0x403142
mov cl, byte [eax]
cmp cl, 0x2d
jne 0x40316b
xor ebx, ebx
jmp 0x403170
cmp cl, 0x2b
jne 0x403171
inc eax
mov cl, byte [eax]
cmp cl, 0x30
jb 0x403189
cmp cl, 0x39
ja 0x403189
movzx ecx, cl
lea edx, [esi + esi*4]
lea esi, [ecx + edx*2 - 0x30]
jmp 0x403170
imul esi, esi, 0xe10
test ebx, ebx
je 0x403197
sub edi, esi
jmp 0x403199
add edi, esi
mov eax, dword [ebp + 8]
mov dword [eax], edi
pop edi
pop esi
pop ebx
leave
ret 4

Function at 0x4038be
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x54
push ebx
push esi
xor esi, esi
push edi
push esi
push str.Progman
call dword [sym.imp.USER32.dll_FindWindowA]
push 1
test eax, eax
pop edi
jne 0x403932
lea eax, [ebp - 0x10]
mov dword [ebp - 0x54], 0x44
push eax
lea eax, [ebp - 0x54]
push eax
push esi
push esi
push 0x220
push edi
push esi
push esi
push str.PROGMAN.EXE
push esi
mov dword [ebp - 0x50], esi
mov dword [ebp - 0x4c], esi
mov dword [ebp - 0x48], esi
mov dword [ebp - 0x28], esi
mov word [ebp - 0x22], si
mov dword [ebp - 0x20], esi
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
push 0xbb8
push dword [ebp - 0x10]
call dword [sym.imp.USER32.dll_WaitForInputIdle]
push dword [ebp - 0x10]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
push dword [ebp - 0xc]
call esi
mov esi, dword [sym.imp.KERNEL32.dll_GlobalAddAtomA]
mov dword [0x4063f8], edi
mov edi, str.PROGMAN
push edi
call esi
push edi
mov ebx, eax
call esi
mov esi, eax
movzx eax, si
movzx ecx, bx
shl eax, 0x10
or eax, ecx
push eax
push dword [ebp + 8]
push 0x3e0
push 0xffffffffffffffff
call dword [sym.imp.USER32.dll_SendMessageA]
push esi
mov esi, dword [sym.imp.KERNEL32.dll_GlobalDeleteAtom]
call esi
push ebx
call esi
pop edi
pop esi
pop ebx
leave
ret 4

Function at 0x403b34
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x54
push esi
lea eax, [ebp - 0x54]
push dword [ebp + 8]
xor esi, esi
mov dword [ebp - 4], esi
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
lea eax, [ebp + 8]
push eax
lea eax, [ebp - 4]
push eax
push esi
push 0x20006
push esi
push str._standard_
lea eax, [ebp - 0x54]
push esi
push eax
push 0x80000000
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
test eax, eax
jne 0x403b92
push dword [ebp + 0x10]
call dword [sym.imp.KERNEL32.dll_lstrlenA]
inc eax
push eax
push dword [ebp + 0x10]
push 1
push esi
push dword [ebp + 0xc]
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
cmp dword [ebp - 4], esi
je 0x403ba0
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop esi
leave
ret 0xc
Function at 0x404266
Capabilities:
Terminate process

Disassembly:
mov eax, dword fs:[0]
push ebp
mov ebp, esp
push 0xffffffffffffffff
push section..rdata
push 0x4043b4
push eax
mov eax, dword [0x4063c4]
mov dword fs:[0], esp
mov ecx, dword [sym.imp.CRTDLL.dll__fmode_dll]
sub esp, 0x6c
mov dword [ecx], eax
mov edx, dword [0x4063c0]
mov eax, dword [sym.imp.CRTDLL.dll__commode_dll]
push ebx
push esi
push edi
mov dword [ebp - 0x18], esp
mov dword [eax], edx
call fcn.004043aa
lea edx, [ebp - 0x28]
lea eax, [ebp - 0x2c]
push dword [0x4063bc]
push edx
push eax
lea ecx, [ebp - 0x30]
push ecx
call sub.CRTDLL.dll___GetMainArgs
add esp, 0x10
push 0x408004
push section..CRT
call sub.CRTDLL.dll__initterm
add esp, 8
mov dword [ebp - 4], 0
mov eax, dword [sym.imp.CRTDLL.dll__acmdln_dll]
mov esi, dword [eax]
mov al, byte [esi]
cmp al, 0x22
jne 0x404301
mov al, byte [ebp - 0x34]
inc esi
mov al, byte [esi]
test al, al
je 0x4042f9
cmp al, 0x22
jne 0x4042ee
cmp byte [esi], 0x22
jne 0x40430b
inc esi
jmp 0x40430b
cmp al, 0x20
jbe 0x40430b
inc esi
cmp byte [esi], 0x20
ja 0x404305
cmp byte [esi], 0
je 0x40431b
cmp byte [esi], 0x20
ja 0x40431b
inc esi
cmp byte [esi], 0
jne 0x404310
mov dword [ebp - 0x50], 0
lea eax, [ebp - 0x7c]
push eax
call dword [sym.imp.KERNEL32.dll_GetStartupInfoA]
test byte [ebp - 0x50], 1
mov eax, 0xa
je 0x40433b
movzx eax, word [ebp - 0x4c]
push eax
push esi
push 0
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call main
push eax
call sub.CRTDLL.dll_exit
jmp 0x404377
add esp, 4
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x10]
pop edi
mov dword fs:[0], eax
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x402480
Capabilities:
Set current directory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x224
mov eax, dword [0x507a74]
xor eax, ebp
mov dword [ebp - 4], eax
push 0x104
lea eax, [ebp - 0x210]
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push eax
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
test eax, eax
je 0x4024ea
push 0x5c
lea ecx, [ebp - 0x210]
push ecx
call fcn.00402560
add esp, 8
mov dword [ebp - 0x218], eax
cmp dword [ebp - 0x218], 0
je 0x4024ea
xor edx, edx
mov eax, dword [ebp - 0x218]
mov word [eax], dx
lea ecx, [ebp - 0x210]
push ecx
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
push 0xc
call fcn.004a8268
add esp, 4
mov dword [ebp - 0x220], eax
cmp dword [ebp - 0x220], 0
je 0x402516
mov ecx, dword [ebp - 0x220]
call fcn.00401750
mov dword [ebp - 0x224], eax
jmp 0x402520
mov dword [ebp - 0x224], 0
mov edx, dword [ebp - 0x224]
mov dword [ebp - 0x21c], edx
mov eax, dword [ebp - 0x21c]
mov dword [ebp - 0x214], eax
mov ecx, dword [ebp - 0x214]
call fcn.004013b0
xor eax, eax
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004a81b0
mov esp, ebp
pop ebp
ret 0x10

Function at 0x402f10
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4be797
mov eax, dword fs:[0]
push eax
sub esp, 0x38
mov eax, dword [0x507a74]
xor eax, ebp
mov dword [ebp - 0x24], eax
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x44], 0
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
mov dword [ebp - 0x1c], eax
cmp dword [ebp - 0x1c], 0
jne 0x402f70
mov ecx, dword [ebp + 8]
call fcn.00402cf0
mov dword [ebp - 4], 0
mov eax, dword [ebp - 0x44]
or eax, 1
mov dword [ebp - 0x44], eax
mov eax, dword [ebp + 8]
jmp 0x403031
push 0xa
push 0x67
mov ecx, dword [ebp - 0x1c]
push ecx
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov dword [ebp - 0x18], eax
cmp dword [ebp - 0x18], 0
jne 0x402fa7
mov ecx, dword [ebp + 8]
call fcn.00402cf0
mov dword [ebp - 4], 0
mov edx, dword [ebp - 0x44]
or edx, 1
mov dword [ebp - 0x44], edx
mov eax, dword [ebp + 8]
jmp 0x403031
mov eax, dword [ebp - 0x18]
push eax
mov ecx, dword [ebp - 0x1c]
push ecx
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov dword [ebp - 0x14], eax
mov edx, dword [ebp - 0x14]
push edx
call dword [sym.imp.KERNEL32.dll_LockResource]
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x18]
push eax
mov ecx, dword [ebp - 0x1c]
push ecx
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov dword [ebp - 0x20], eax
lea ecx, [ebp - 0x40]
call fcn.00402cf0
mov dword [ebp - 4], 1
mov edx, dword [ebp - 0x20]
add edx, 1
push edx
lea ecx, [ebp - 0x40]
call fcn.00403190
mov eax, dword [ebp - 0x20]
push eax
mov ecx, dword [ebp - 0x10]
push ecx
lea ecx, [ebp - 0x40]
call fcn.00403170
push eax
call fcn.004a8f60
add esp, 0xc
lea edx, [ebp - 0x40]
push edx
mov ecx, dword [ebp + 8]
call fcn.00403130
mov eax, dword [ebp - 0x44]
or eax, 1
mov dword [ebp - 0x44], eax
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x40]
call fcn.00401840
mov eax, dword [ebp + 8]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov ecx, dword [ebp - 0x24]
xor ecx, ebp
call fcn.004a81b0
mov esp, ebp
pop ebp
ret
Function at 0x403cc0
Capabilities:
Initialize winsock library

Disassembly:
sub esp, 0x194
mov eax, dword [0x507a74]
xor eax, esp
mov dword [esp + 0x190], eax
lea eax, [esp]
push eax
push 0x202
call dword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
jne 0x403d12
mov eax, dword [esp]
cmp al, 2
jne 0x403d0c
shr eax, 8
cmp al, 2
jne 0x403d0c
xor eax, eax
mov ecx, dword [esp + 0x190]
xor ecx, esp
call fcn.004a81b0
add esp, 0x194
ret
call dword [sym.imp.WS2_32.dll_WSACleanup]
mov ecx, dword [esp + 0x190]
xor ecx, esp
mov eax, 2
call fcn.004a81b0
add esp, 0x194
ret
Function at 0x40d490
Capabilities:
Receive data
Receive data on socket

Disassembly:
mov eax, dword [esp + 0xc]
mov ecx, dword [esp + 8]
mov edx, dword [esp + 4]
push 0
push eax
push ecx
push edx
call dword [sym.imp.WS2_32.dll_recv]
cmp eax, 0xffffffff
jne 0x40d4c0
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
sub eax, 0x2733
neg eax
sbb eax, eax
and eax, 0x39
dec eax
ret
mov ecx, dword [esp + 0x10]
mov dword [ecx], eax
xor eax, eax
ret

Function at 0x40d640
Capabilities:
Write file on windows

Disassembly:
mov ecx, dword [esi + 0x140]
test ecx, ecx
je 0x40d65b
mov edx, dword [esi + 0xe4]
push edx
push edi
push ebx
push eax
push esi
call ecx
add esp, 0x14
ret
test eax, eax
jl 0x40d68f
cmp eax, 2
jg 0x40d68f
mov ecx, dword [esi + 0xe0]
push ecx
push 1
lea edx, [eax + eax*2 + 0x4c043c]
push 2
push edx
call fcn.004a9e4d
mov eax, dword [esi + 0xe0]
push eax
push 1
push edi
push ebx
call fcn.004a9e4d
add esp, 0x20
xor eax, eax
ret

Function at 0x40d8c0
Capabilities:
Send data
Send data on socket

Disassembly:
mov eax, dword [edi + eax*4 + 0xd4]
push esi
push 0
push ecx
push edx
push eax
call dword [sym.imp.WS2_32.dll_send]
mov esi, eax
cmp esi, 0xffffffff
jne 0x40d905
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
jne 0x40d8eb
xor eax, eax
pop esi
ret
push eax
push edi
call fcn.00422d30
push eax
mov eax, dword [edi]
push str.Send_failure:__s
push eax
call fcn.0040d820
add esp, 0x14
mov eax, esi
pop esi
ret