joyce8/EMBER2024-capa huggingface dataset:
Function at 0x457d20
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Connect udp socket
Create tcp socket
Create udp socket
Get local ipv4 addresses
Get socket information
Receive data
Receive data on socket
Send data
Send data on socket
Set socket configuration
Start tcp server

Disassembly:
sub esp, 0x34
mov eax, dword [0x7a9080]
xor eax, esp
mov dword [esp + 0x30], eax
push ebx
mov ebx, dword [esp + 0x48]
push esi
mov esi, dword [sym.imp.WS2_32.dll_socket]
push edi
push 6
push 1
push 2
mov dword [esp + 0x1c], 0x10
mov dword [esp + 0x18], 1
call esi
mov edi, eax
cmp edi, 0xffffffff
je 0x457f06
xorps xmm0, xmm0
mov eax, 2
push 0x7f000001
movlpd qword [esp + 0x20], xmm0
mov word [esp + 0x18], ax
call dword [sym.imp.WS2_32.dll_htonl]
mov dword [esp + 0x18], eax
xor eax, eax
push 4
mov word [esp + 0x1a], ax
lea eax, [esp + 0x10]
push eax
push 4
push 0xffff
push edi
mov dword [ebx + 4], 0xffffffff
mov dword [ebx], 0xffffffff
call dword [sym.imp.WS2_32.dll_setsockopt]
cmp eax, 0xffffffff
je 0x457ef4
push 0x10
lea eax, [esp + 0x18]
push eax
push edi
call dword [sym.imp.WS2_32.dll_bind]
cmp eax, 0xffffffff
je 0x457ef4
lea eax, [esp + 0x10]
push eax
lea eax, [esp + 0x18]
push eax
push edi
call dword [sym.imp.WS2_32.dll_getsockname]
cmp eax, 0xffffffff
je 0x457ef4
push 1
push edi
call dword [sym.imp.WS2_32.dll_listen]
cmp eax, 0xffffffff
je 0x457ef4
push 0
push 1
push 2
call esi
mov dword [ebx], eax
cmp eax, 0xffffffff
je 0x457ef4
push 0x10
lea ecx, [esp + 0x18]
push ecx
push eax
call dword [sym.imp.WS2_32.dll_connect]
cmp eax, 0xffffffff
je 0x457ef4
push 0
push 0
push edi
call dword [sym.imp.WS2_32.dll_accept]
mov dword [ebx + 4], eax
cmp eax, 0xffffffff
je 0x457ef4
push ebx
push 0x49ab08
lea eax, [esp + 0x2c]
push 0xc
push eax
call fcn.0044cf80
lea esi, [esp + 0x34]
add esp, 0x10
lea ecx, [esi + 1]
mov al, byte [esi]
inc esi
test al, al
jne 0x457e52
push 0
sub esi, ecx
lea eax, [esp + 0x28]
push esi
push eax
push dword [ebx]
call dword [sym.imp.WS2_32.dll_send]
cmp eax, esi
jne 0x457ef4
push 0
push 0xc
lea eax, [esp + 0x38]
push eax
push dword [ebx + 4]
call dword [sym.imp.WS2_32.dll_recv]
cmp eax, esi
jne 0x457ef4
lea ecx, [esp + 0x24]
lea edx, [esp + 0x30]
sub esi, 4
jb 0x457ea7
mov eax, dword [ecx]
cmp eax, dword [edx]
jne 0x457eac
add ecx, 4
add edx, 4
sub esi, 4
jae 0x457e96
cmp esi, 0xfffffffc
je 0x457ed9
mov al, byte [ecx]
cmp al, byte [edx]
jne 0x457ef4
cmp esi, 0xfffffffd
je 0x457ed9
mov al, byte [ecx + 1]
cmp al, byte [edx + 1]
jne 0x457ef4
cmp esi, 0xfffffffe
je 0x457ed9
mov al, byte [ecx + 2]
cmp al, byte [edx + 2]
jne 0x457ef4
cmp esi, 0xffffffff
je 0x457ed9
mov al, byte [ecx + 3]
cmp al, byte [edx + 3]
jne 0x457ef4
push edi
call dword [sym.imp.WS2_32.dll_closesocket]
pop edi
pop esi
xor eax, eax
pop ebx
mov ecx, dword [esp + 0x30]
xor ecx, esp
call fcn.00436411
add esp, 0x34
ret
mov esi, dword [sym.imp.WS2_32.dll_closesocket]
push edi
call esi
push dword [ebx]
call esi
push dword [ebx + 4]
call esi
mov ecx, dword [esp + 0x3c]
or eax, 0xffffffff
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.00436411
add esp, 0x34
ret
Function at 0x45bda0
Capabilities:
Resolve dns

Disassembly:
sub esp, 0xc
mov eax, dword [esp + 0x1c]
push esi
xor esi, esi
mov dword [esp + 4], esi
mov dword [eax], esi
lea eax, [esp + 8]
push eax
push dword [esp + 0x20]
push dword [esp + 0x20]
push dword [esp + 0x20]
call dword [sym.imp.WS2_32.dll_getaddrinfo]
mov dword [esp + 0xc], eax
test eax, eax
jne 0x45bf52
push ebx
mov ebx, dword [esp + 0xc]
push edi
test ebx, ebx
je 0x45bf3c
push ebp
mov eax, dword [ebx + 4]
cmp eax, 2
jne 0x45bdef
lea ebp, [eax + 0xe]
jmp 0x45bdfb
cmp eax, 0x17
jne 0x45bea9
lea ebp, [eax + 5]
cmp dword [ebx + 0x18], 0
je 0x45bea9
mov eax, dword [ebx + 0x10]
test eax, eax
je 0x45bea9
cmp eax, ebp
jb 0x45bea9
push 0x20
call dword [0x7a90d4]
mov edi, eax
add esp, 4
test edi, edi
je 0x45bf31
mov ecx, dword [ebx]
mov dword [edi], ecx
mov ecx, dword [ebx + 4]
mov dword [edi + 4], ecx
mov ecx, dword [ebx + 8]
mov dword [edi + 8], ecx
mov eax, dword [ebx + 0xc]
push ebp
mov dword [edi + 0xc], eax
mov dword [edi + 0x10], ebp
mov dword [edi + 0x18], 0
mov dword [edi + 0x14], 0
mov dword [edi + 0x1c], 0
call dword [0x7a90d4]
add esp, 4
mov dword [edi + 0x18], eax
test eax, eax
je 0x45bf20
push ebp
push dword [ebx + 0x18]
push eax
call sub.VCRUNTIME140.dll_memcpy
mov eax, dword [ebx + 0x14]
add esp, 0xc
test eax, eax
je 0x45be95
push eax
call dword [0x7a90e0]
add esp, 4
mov dword [edi + 0x14], eax
test eax, eax
je 0x45bf06
mov eax, dword [esp + 0x10]
test esi, esi
cmove esi, edi
test eax, eax
je 0x45bea5
mov dword [eax + 0x1c], edi
mov dword [esp + 0x10], edi
mov ebx, dword [ebx + 0x1c]
test ebx, ebx
jne 0x45bde2
mov ebx, dword [esp + 0x18]
mov eax, dword [esp + 0x14]
pop ebp
test eax, eax
je 0x45bec8
push eax
call dword [sym.imp.WS2_32.dll_freeaddrinfo]
test ebx, ebx
je 0x45bf38
test esi, esi
je 0x45bef5
push dword [esi + 0x18]
call dword [0x7a90d8]
push dword [esi + 0x14]
call dword [0x7a90d8]
mov edi, dword [esi + 0x1c]
push esi
call dword [0x7a90d8]
add esp, 0xc
mov esi, edi
test edi, edi
jne 0x45bed0
mov eax, dword [esp + 0x28]
xor esi, esi
pop edi
mov dword [eax], esi
mov eax, ebx
pop ebx
pop esi
add esp, 0xc
ret
push dword [edi + 0x18]
mov ebx, 8
call dword [0x7a90d8]
push edi
call dword [0x7a90d8]
add esp, 8
jmp 0x45beb8
push edi
mov ebx, 8
call dword [0x7a90d8]
add esp, 4
jmp 0x45beb8
mov ebx, 8
jmp 0x45beb8
test esi, esi
jne 0x45bf48
mov ebx, 0x2af9
push ebx
call dword [sym.imp.WS2_32.dll_WSASetLastError]
mov eax, dword [esp + 0x28]
pop edi
mov dword [eax], esi
mov eax, ebx
pop ebx
pop esi
add esp, 0xc
ret

Function at 0x45c3b0
Capabilities:
Create thread

Disassembly:
push 0
push 0
push dword [esp + 0x10]
push dword [esp + 0x10]
push 0
push 0
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__beginthreadex]
add esp, 0x18
test eax, eax
je 0x45c3d2
cmp eax, 0xffffffff
jne 0x45c3d4
xor eax, eax
ret
Function at 0x45fbf0
Capabilities:
Query environment variable

Disassembly:
push ebx
push ebp
xor ebp, ebp
push esi
push edi
lea esi, [ebp + 1]
push esi
push ebp
call dword [0x7a90dc]
mov edi, eax
add esp, 8
test edi, edi
je 0x45fc47
nop word [eax + eax]
push esi
push edi
push dword [esp + 0x1c]
mov ebp, edi
mov ebx, esi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableA]
mov esi, eax
test esi, esi
je 0x45fc5f
cmp esi, ebx
je 0x45fc5f
cmp esi, 0x8000
ja 0x45fc5f
cmp esi, ebx
jb 0x45fc58
push esi
push edi
call dword [0x7a90dc]
mov edi, eax
add esp, 8
test edi, edi
jne 0x45fc10
push ebp
call dword [0x7a90d8]
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
ret
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
ret
push edi
call dword [0x7a90d8]
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
ret

Function at 0x4656c0
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
sub esp, 0x88
mov eax, dword [0x7a9080]
xor eax, esp
mov dword [esp + 0x84], eax
push ebx
push ebp
push esi
push edi
mov edi, dword [esp + 0x9c]
lea eax, [esp + 0x10]
push eax
lea eax, [esp + 0x18]
mov dword [esp + 0x14], 0x80
push eax
mov ebp, dword [edi + 0x424]
or esi, 0xffffffff
mov ebx, dword [edi]
push ebp
call dword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
jne 0x465722
lea eax, [esp + 0x10]
mov dword [esp + 0x10], 0x80
push eax
lea eax, [esp + 0x18]
push eax
push ebp
call dword [sym.imp.WS2_32.dll_accept]
mov esi, eax
push ebp
push edi
call fcn.0044aa40
add esp, 8
cmp esi, 0xffffffff
jne 0x465746
push str.Error_accept__ing_server_connect
push ebx
call fcn.00449e60
add esp, 8
mov eax, 0x1e
jmp 0x4657b5
push str.Connection_accepted_from_server_n
push ebx
call fcn.00449f40
push 1
push esi
mov byte [edi + 0x514], 0
mov dword [edi + 0x424], esi
call fcn.00457f20
add esp, 0x10
mov byte [edi + 0x7f0], 1
cmp dword [ebx + 0x610], 0
je 0x4657b3
push 1
push ebx
call fcn.0043bc60
mov eax, dword [ebx + 0x610]
push 1
push esi
push dword [ebx + 0x614]
call eax
push 0
push ebx
mov esi, eax
call fcn.0043bc60
add esp, 0x1c
test esi, esi
je 0x4657b3
push edi
call fcn.00465c50
add esp, 4
mov eax, 0x2a
jmp 0x4657b5
xor eax, eax
mov ecx, dword [esp + 0x94]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.00436411
add esp, 0x88
ret
Function at 0x46cbd0
Capabilities:
Send data
Send data on socket

Disassembly:
mov eax, dword [esp + 0xc]
push ebx
mov ebx, dword [esp + 0xc]
push esi
mov esi, dword [esp + 0xc]
push edi
push 0
mov byte [esp + 0x16], al
lea eax, [esp + 0x14]
mov edi, dword [esi]
push 3
push eax
push dword [esi + 0x420]
mov byte [esp + 0x20], 0xff
mov byte [esp + 0x21], bl
call dword [sym.imp.WS2_32.dll_send]
test eax, eax
jns 0x46cc1c
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push str.Sending_data_failed___d_
push edi
call fcn.00449e60
add esp, 0xc
push dword [esp + 0x18]
push ebx
push str.SENT
push dword [esi]
call fcn.0046c7e0
add esp, 0x10
pop edi
pop esi
pop ebx
ret

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

Disassembly:
push ecx
cmp dword [esp + 0xc], 0x1f
mov eax, dword [esp + 8]
push ebx
mov eax, dword [eax]
mov dword [esp + 4], eax
mov ebx, dword [eax + 0x14c]
jne 0x46ceae
push ebp
push edi
lea ebp, [ebx + 0x1cb0]
lea edi, [ebx + 0x1eb0]
mov dword [edi], ebp
cmp ebp, edi
jae 0x46cdae
lea eax, [ebp + 1]
mov byte [ebp], 0xff
mov dword [edi], eax
cmp eax, edi
jae 0x46cdae
mov byte [eax], 0xfa
inc dword [edi]
mov eax, dword [edi]
cmp eax, edi
jae 0x46cdae
mov byte [eax], 0x1f
inc dword [edi]
movzx eax, word [ebx + 0x1ca8]
push esi
mov esi, dword [sym.imp.WS2_32.dll_htons]
push eax
call esi
movzx eax, ax
mov dword [esp + 0x1c], eax
movzx eax, word [ebx + 0x1caa]
push eax
call esi
mov edx, dword [esp + 0x1c]
movzx ecx, ax
mov eax, dword [edi]
cmp eax, edi
jae 0x46ce19
mov byte [eax], dl
inc dword [edi]
mov eax, dword [edi]
cmp eax, edi
jae 0x46ce19
mov byte [eax], dh
inc dword [edi]
mov eax, dword [edi]
cmp eax, edi
jae 0x46ce19
mov byte [eax], cl
inc dword [edi]
mov eax, dword [edi]
cmp eax, edi
jae 0x46ce19
shr ecx, 8
mov byte [eax], cl
inc dword [edi]
mov eax, dword [edi]
cmp eax, edi
jae 0x46ce19
mov byte [eax], 0xff
inc dword [edi]
mov eax, dword [edi]
cmp eax, edi
jae 0x46ce19
mov byte [eax], 0xf0
mov eax, dword [edi]
inc eax
mov esi, dword [esp + 0x10]
mov dword [ebx + 0x1eb4], eax
sub eax, ebp
sub eax, 2
mov dword [edi], ebp
push eax
lea eax, [ebx + 0x1cb2]
push eax
push 0x3e
push esi
call fcn.0046c8e0
mov edi, dword [esp + 0x28]
add esp, 0x10
push 0
push 3
push ebp
push dword [edi + 0x420]
call dword [sym.imp.WS2_32.dll_send]
mov ebp, dword [sym.imp.WS2_32.dll_WSAGetLastError]
test eax, eax
jns 0x46ce6d
call ebp
push eax
push str.Sending_data_failed___d_
push esi
call fcn.00449e60
add esp, 0xc
push 4
lea eax, [ebx + 0x1cb3]
push eax
push edi
call fcn.0046cc40
add esp, 0xc
lea eax, [ebx + 0x1cb7]
push 0
push 2
push eax
push dword [edi + 0x420]
call dword [sym.imp.WS2_32.dll_send]
test eax, eax
jns 0x46ceab
call ebp
push eax
push str.Sending_data_failed___d_
push esi
call fcn.00449e60
add esp, 0xc
pop esi
pop edi
pop ebp
pop ebx
pop ecx
ret
Function at 0x47fae0
Capabilities:
Authenticate hmac
Encode data using xor

Disassembly:
push ecx
push esi
mov esi, dword [esp + 0xc]
push edi
mov ecx, dword [esi + 0xc]
mov eax, dword [esi + 0x14]
lea eax, [eax + ecx*2]
add eax, 0xc
push eax
call dword [0x7a90d4]
mov edi, eax
add esp, 4
test edi, edi
jne 0x47fb07
pop edi
pop esi
pop ecx
ret
lea ecx, [edi + 0xc]
mov dword [edi], esi
mov dword [edi + 4], ecx
mov eax, dword [esi + 0xc]
add eax, ecx
push ebx
mov ebx, dword [esp + 0x1c]
mov dword [edi + 8], eax
push ebp
cmp ebx, dword [esi + 0x10]
jbe 0x47fb52
mov eax, dword [esi]
push ecx
call eax
mov eax, dword [esi + 4]
push ebx
push dword [esp + 0x24]
push dword [edi + 4]
call eax
mov ebp, dword [edi + 8]
push dword [edi + 4]
add ebp, dword [esi + 0xc]
mov eax, dword [esi + 8]
push ebp
call eax
mov ebx, dword [esi + 0x14]
add esp, 0x18
mov ecx, dword [edi + 4]
mov dword [esp + 0x20], ebx
jmp 0x47fb56
mov ebp, dword [esp + 0x1c]
mov eax, dword [esi]
push ecx
call eax
push dword [edi + 8]
mov eax, dword [esi]
call eax
mov eax, dword [esp + 0x28]
add esp, 8
xor ebx, ebx
test eax, eax
je 0x47fbb6
mov dword [esp + 0x10], eax
mov ebx, eax
movzx eax, byte [ebp]
xor al, 0x36
mov byte [esp + 0x18], al
lea eax, [esp + 0x18]
push 1
push eax
push dword [edi + 4]
mov eax, dword [esi + 4]
call eax
movzx eax, byte [ebp]
lea ebp, [ebp + 1]
xor al, 0x5c
mov byte [esp + 0x24], al
lea eax, [esp + 0x24]
push 1
push eax
push dword [edi + 8]
mov eax, dword [esi + 4]
call eax
add esp, 0x18
sub ebx, 1
jne 0x47fb75
mov ebx, dword [esp + 0x10]
cmp ebx, dword [esi + 0x10]
jae 0x47fbe7
nop dword [eax + eax]
mov eax, dword [esi + 4]
push 1
push str.6Unknown_exception
push dword [edi + 4]
call eax
mov eax, dword [esi + 4]
push 1
push 0x4a18d7
push dword [edi + 8]
call eax
inc ebx
add esp, 0x18
cmp ebx, dword [esi + 0x10]
jb 0x47fbc0
pop ebp
pop ebx
mov eax, edi
pop edi
pop esi
pop ecx
ret
Function at 0x404724
Capabilities:
Accept command line arguments

Disassembly:
push ebx
push esi
push edi
add esp, 0xfffffdf4
mov ebx, edx
mov esi, eax
mov eax, ebx
xor edx, edx
call fcn.00407594
test esi, esi
jne 0x40475c
push 0x105
lea eax, [esp + 4]
push eax
push 0
call sub.kernel32.dll_GetModuleFileNameW
mov ecx, eax
mov edx, esp
mov eax, ebx
call fcn.004076d0
jmp 0x40477a
call sub.kernel32.dll_GetCommandLineW
mov edi, eax
mov edx, ebx
mov eax, edi
call fcn.00404668
mov edi, eax
test esi, esi
je 0x40477a
cmp dword [ebx], 0
je 0x40477a
dec esi
jmp 0x404763
add esp, 0x20c
pop edi
pop esi
pop ebx
ret

Function at 0x4047ac
Capabilities:
Generate random numbers using the delphi lcg

Disassembly:
push ebx
xor ebx, ebx
imul edx, dword [ebx + 0x61a008], 0x8088405
inc edx
mov dword [ebx + 0x61a008], edx
mul edx
mov eax, edx
pop ebx
ret

Function at 0x406550
Capabilities:
Write file on windows

Disassembly:
push ecx
cmp byte [0x626054], 0
je 0x4065b1
cmp word [0x626330], 0xd7b2
jne 0x406579
cmp dword [0x626338], 0
jbe 0x406579
mov eax, 0x62632c
call dword [0x626348]
push 0
lea eax, [esp + 4]
push eax
push 0x1d
push str.Runtime_error_____at_00000000
push 0xfffffffffffffff5
call sub.kernel32.dll_GetStdHandle
push eax
call sub.kernel32.dll_WriteFile
push 0
lea eax, [esp + 4]
push eax
push 2
push 0x4065dc
push 0xfffffffffffffff5
call sub.kernel32.dll_GetStdHandle
push eax
call sub.kernel32.dll_WriteFile
pop edx
ret
cmp byte [0x61a034], 0
jne 0x4065cd
push 0
push str.Error
push str.Runtime_error_____at_00000000
push 0
call sub.user32.dll_MessageBoxA
pop edx
ret

Function at 0x40675c
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push esi
push edi
mov ebx, ecx
mov dword [ebp - 4], edx
mov edi, eax
mov esi, dword [ebp + 0x10]
cmp dword [0x61a03c], 0
je 0x406782
mov edx, esi
mov eax, ebx
call dword [0x61a03c]
jmp 0x406791
mov eax, 8
call fcn.004043b0
mov dword [eax], ebx
mov dword [eax + 4], esi
mov byte [0x626055], 1
mov edx, dword [ebp + 8]
push edx
mov edx, dword [ebp + 0xc]
push edx
push eax
mov eax, 0x406724
push eax
mov eax, dword [ebp - 4]
push eax
push edi
call sub.kernel32.dll_CreateThread
pop edi
pop esi
pop ebx
pop ecx
pop ebp
ret 0xc
Function at 0x409900
Capabilities:
Get geographical location

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffe94
push ebx
push esi
push edi
xor ecx, ecx
mov dword [ebp - 0x164], ecx
mov dword [ebp - 0x168], ecx
mov dword [ebp - 0x16c], ecx
mov dword [ebp - 8], edx
mov esi, eax
xor eax, eax
push ebp
push 0x409a67
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, dword [ebp - 8]
xor edx, edx
call fcn.00407594
cmp si, word [0x61a7e4]
jb 0x40999a
cmp si, word [0x61a9e4]
ja 0x40999a
mov edi, 0x40
xor eax, eax
mov dword [ebp - 0xc], eax
cmp edi, dword [ebp - 0xc]
jb 0x40999a
mov ebx, dword [ebp - 0xc]
add ebx, edi
shr ebx, 1
cmp si, word [ebx*8 + 0x61a7e4]
jae 0x409974
mov edi, ebx
dec edi
jmp 0x409995
cmp si, word [ebx*8 + 0x61a7e4]
jbe 0x409984
inc ebx
mov dword [ebp - 0xc], ebx
jmp 0x409995
mov edx, dword [ebp - 8]
mov eax, dword [ebx*8 + 0x61a7e8]
call fcn.00409810
jmp 0x40999a
cmp edi, dword [ebp - 0xc]
jae 0x40995e
mov eax, dword [ebp - 8]
cmp dword [eax], 0
jne 0x409a49
push 2
movzx eax, si
push eax
call sub.kernel32.dll_IsValidLocale
test eax, eax
je 0x409a49
push 0x55
lea eax, [ebp - 0xb6]
push eax
push 0x59
movzx ebx, si
push ebx
call sub.kernel32.dll_GetLocaleInfoW
push 0x55
lea eax, [ebp - 0x160]
push eax
push 0x5a
push ebx
call sub.kernel32.dll_GetLocaleInfoW
lea eax, [ebp - 0x164]
lea edx, [ebp - 0xb6]
mov ecx, 0x55
call fcn.004077a4
push dword [ebp - 0x164]
push 0x409a84
lea eax, [ebp - 0x168]
lea edx, [ebp - 0x160]
mov ecx, 0x55
call fcn.004077a4
push dword [ebp - 0x168]
push 0x409a94
lea eax, [ebp - 0x16c]
lea edx, [ebp - 0xb6]
mov ecx, 0x55
call fcn.004077a4
push dword [ebp - 0x16c]
mov eax, dword [ebp - 8]
mov edx, 5
call fcn.00407b5c
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x409a6e
lea eax, [ebp - 0x16c]
mov edx, 3
call fcn.0040758c
ret
Function at 0x409c20
Capabilities:
Identify system language via api

Disassembly:
push ebp
mov ebp, esp
push 0
push ebx
push esi
mov esi, edx
mov ebx, eax
xor eax, eax
push ebp
push 0x409d25
push dword fs:[eax]
mov dword fs:[eax], esp
push 0x628b5c
call sub.kernel32.dll_EnterCriticalSection
cmp bx, word [0x628b74]
jne 0x409c6c
mov eax, esi
mov edx, 0x628b78
mov ecx, 0x55
call fcn.004077a4
push 0x628b5c
call sub.kernel32.dll_LeaveCriticalSection
jmp 0x409d0f
push 0x628b5c
call sub.kernel32.dll_LeaveCriticalSection
mov eax, esi
xor edx, edx
call fcn.00407594
push 2
movzx eax, bx
push eax
call sub.kernel32.dll_IsValidLocale
test eax, eax
je 0x409cdd
cmp byte [0x628b58], 0
je 0x409ca2
mov edx, esi
mov eax, ebx
call fcn.00409b00
jmp 0x409cdd
mov edx, esi
mov eax, ebx
call fcn.00409900
call sub.kernel32.dll_GetSystemDefaultUILanguage
cmp bx, ax
je 0x409cdd
cmp dword [esi], 0
je 0x409cc6
mov eax, esi
mov edx, 0x409d40
call fcn.004079b8
call sub.kernel32.dll_GetSystemDefaultUILanguage
lea edx, [ebp - 4]
call fcn.00409900
mov edx, dword [ebp - 4]
mov eax, esi
call fcn.004079b8
push 0x628b5c
call sub.kernel32.dll_EnterCriticalSection
mov word [0x628b74], bx
push 0xaa
mov eax, dword [esi]
call fcn.00407620
push eax
push 0x628b78
call sub.kernel32.dll_lstrcpynW
push 0x628b5c
call sub.kernel32.dll_LeaveCriticalSection
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x409d2c
lea eax, [ebp - 4]
call fcn.00407584
ret
Function at 0x409f64
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffde4
push ebx
mov ebx, edx
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
call fcn.0040757c
xor eax, eax
push ebp
push 0x40a149
push dword fs:[eax]
mov dword fs:[eax], esp
cmp dword [ebp - 4], 0
jne 0x409fa4
push 0x105
lea eax, [ebp - 0x21a]
push eax
push 0
call sub.kernel32.dll_GetModuleFileNameW
jmp 0x409fbe
push 0x105
mov eax, dword [ebp - 4]
call fcn.00407620
push eax
lea eax, [ebp - 0x21a]
push eax
call sub.kernel32.dll_lstrcpynW
cmp word [ebp - 0x21a], 0
je 0x40a133
xor eax, eax
mov dword [ebp - 8], eax
lea eax, [ebp - 0xc]
push eax
push 0xf0019
push 0
push 0x40a158
push 0x80000001
call sub.advapi32.dll_RegOpenKeyExW
test eax, eax
je 0x40a04d
lea eax, [ebp - 0xc]
push eax
push 0xf0019
push 0
push 0x40a158
push 0x80000002
call sub.advapi32.dll_RegOpenKeyExW
test eax, eax
je 0x40a04d
lea eax, [ebp - 0xc]
push eax
push 0xf0019
push 0
push 0x40a18c
push 0x80000001
call sub.advapi32.dll_RegOpenKeyExW
test eax, eax
je 0x40a04d
lea eax, [ebp - 0xc]
push eax
push 0xf0019
push 0
push 0x40a1c0
push 0x80000001
call sub.advapi32.dll_RegOpenKeyExW
test eax, eax
jne 0x40a133
xor eax, eax
push ebp
push 0x40a12c
push dword fs:[eax]
mov dword fs:[eax], esp
lea eax, [ebp - 0x21a]
mov edx, 0x105
call fcn.00409d68
lea eax, [ebp - 0x10]
push eax
push 0
push 0
push 0
lea eax, [ebp - 0x21a]
push eax
mov eax, dword [ebp - 0xc]
push eax
call sub.advapi32.dll_RegQueryValueExW
test eax, eax
jne 0x40a0bc
mov eax, dword [ebp - 0x10]
call fcn.004043b0
mov dword [ebp - 8], eax
lea eax, [ebp - 0x10]
push eax
mov eax, dword [ebp - 8]
push eax
push 0
push 0
lea eax, [ebp - 0x21a]
push eax
mov eax, dword [ebp - 0xc]
push eax
call sub.advapi32.dll_RegQueryValueExW
mov eax, ebx
mov edx, dword [ebp - 8]
call fcn.00407750
jmp 0x40a107
lea eax, [ebp - 0x10]
push eax
push 0
push 0
push 0
push 0x40a200
mov eax, dword [ebp - 0xc]
push eax
call sub.advapi32.dll_RegQueryValueExW
test eax, eax
jne 0x40a107
mov eax, dword [ebp - 0x10]
call fcn.004043b0
mov dword [ebp - 8], eax
lea eax, [ebp - 0x10]
push eax
mov eax, dword [ebp - 8]
push eax
push 0
push 0
push 0x40a200
mov eax, dword [ebp - 0xc]
push eax
call sub.advapi32.dll_RegQueryValueExW
mov eax, ebx
mov edx, dword [ebp - 8]
call fcn.00407750
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x40a133
cmp dword [ebp - 8], 0
je 0x40a122
mov eax, dword [ebp - 8]
call fcn.004043cc
mov eax, dword [ebp - 0xc]
push eax
call sub.advapi32.dll_RegCloseKey
ret
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x40a150
lea eax, [ebp - 4]
call fcn.00407584
ret
Function at 0x40a414
Capabilities:
Identify system language via api

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffdd8
push ebx
push esi
push edi
xor ebx, ebx
mov dword [ebp - 0x228], ebx
mov dword [ebp - 0x224], ebx
mov dword [ebp - 0x220], ebx
mov esi, ecx
mov dword [ebp - 0x21c], edx
mov dword [ebp - 0x218], eax
mov eax, dword [ebp - 0x218]
call fcn.0040757c
mov eax, dword [ebp - 0x21c]
call fcn.0040757c
lea edi, [ebp - 0x210]
xor eax, eax
push ebp
push 0x40a5b3
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, esi
xor edx, edx
call fcn.00407594
xor ebx, ebx
push 0x105
mov eax, dword [ebp - 0x21c]
call fcn.00407620
push eax
lea eax, [ebp - 0x20a]
push eax
call sub.kernel32.dll_lstrcpynW
lea eax, [ebp - 0x20a]
push eax
call sub.kernel32.dll_lstrlenW
add eax, eax
lea edx, [ebp - 0x20a]
add eax, edx
sub eax, 2
mov dword [edi], eax
jmp 0x40a4b4
sub dword [edi], 2
mov eax, dword [edi]
cmp word [eax], 0x2e
je 0x40a4c6
lea eax, [ebp - 0x20a]
cmp eax, dword [edi]
jne 0x40a4b1
lea eax, [ebp - 0x20a]
cmp eax, dword [edi]
je 0x40a57f
add dword [edi], 2
mov eax, dword [edi]
mov word [eax], 0
lea eax, [ebp - 0x20a]
mov edx, dword [edi]
sub edx, eax
sar edx, 1
jns 0x40a4ef
adc edx, 0
mov eax, 0x105
sub eax, edx
mov dword [ebp - 0x214], eax
lea edx, [ebp - 0x220]
mov eax, dword [ebp - 0x218]
call fcn.00409f64
cmp dword [ebp - 0x220], 0
je 0x40a527
push ebp
mov eax, dword [ebp - 0x220]
call fcn.0040a308
pop ecx
mov ebx, eax
jmp 0x40a57f
push ebp
call sub.kernel32.dll_GetUserDefaultUILanguage
lea edx, [ebp - 0x224]
call fcn.00409c20
mov eax, dword [ebp - 0x224]
call fcn.0040a308
pop ecx
mov ebx, eax
test bl, bl
jne 0x40a572
cmp byte [0x628b58], 0
jne 0x40a572
push ebp
call sub.kernel32.dll_GetSystemDefaultUILanguage
lea edx, [ebp - 0x228]
call fcn.00409c20
mov eax, dword [ebp - 0x228]
call fcn.0040a308
pop ecx
mov ebx, eax
test bl, bl
jne 0x40a57f
push ebp
call fcn.0040a3b8
pop ecx
mov ebx, eax
test bl, bl
je 0x40a595
mov eax, esi
lea edx, [ebp - 0x20a]
mov ecx, 0x105
call fcn.004077a4
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x40a5ba
lea eax, [ebp - 0x228]
mov edx, 5
call fcn.0040758c
ret

Function at 0x40ae44
Capabilities:
Get system information on windows

Disassembly:
add esp, 0xffffffdc
push esp
call sub.kernel32.dll_GetSystemInfo
mov eax, dword [esp + 0x14]
add esp, 0x24
ret