joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4058c6
Capabilities:
Get common file path
Get file size
Read file on windows
Write file on windows

Disassembly:
push ebx
push ebp
push esi
push edi
push str.MoveFileExA
push str.KERNEL32.dll
call 0x405e91
test eax, eax
mov esi, dword [esp + 0x18]
je 0x4058f2
push 5
push esi
push dword [esp + 0x1c]
call eax
test eax, eax
jne 0x405a38
mov ebx, dword [sym.imp.KERNEL32.DLL_GetShortPathNameA]
mov dword [0x42ca58], 0x4c554e
test esi, esi
mov edi, 0x400
mov ebp, 0x42ca58
je 0x405936
push 1
push 0
push esi
call fcn.0040584f
push eax
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
push edi
push ebp
push esi
call ebx
test eax, eax
je 0x405a3e
cmp eax, edi
jg 0x405a3e
mov esi, 0x42c4d0
push edi
push esi
push dword [esp + 0x1c]
call ebx
test eax, eax
je 0x405a3e
cmp eax, edi
jg 0x405a3e
push esi
push ebp
push str._s_s_r_n
push 0x42c0d0
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x10
mov ebx, eax
push 0x3f0
push esi
call dword [sym.imp.KERNEL32.DLL_GetWindowsDirectoryA]
push str.wininit.ini
push esi
call sub.KERNEL32.DLL_lstrcatA
xor eax, eax
push eax
push 0x8000080
push 4
push eax
push eax
push 0xc0000000
push esi
call dword [sym.imp.KERNEL32.DLL_CreateFileA]
mov ebp, eax
cmp ebp, 0xffffffff
je 0x405a38
push 0
push ebp
call dword [sym.imp.KERNEL32.DLL_GetFileSize]
mov edi, eax
lea eax, [edi + ebx + 0xa]
push eax
push 0x40
inc eax
call dword [sym.imp.KERNEL32.DLL_GlobalAlloc]
mov esi, eax
test esi, esi
je 0x405a31
lea eax, [esp + 0x18]
push 0
push eax
push edi
push esi
push ebp
call dword [sym.imp.KERNEL32.DLL_ReadFile]
test eax, eax
je 0x405a31
cmp edi, dword [esp + 0x18]
jne 0x405a31
push str._Rename__r_n
push esi
call fcn.004057e3
test eax, eax
jne 0x405a45
lea eax, [esi + edi]
push str._Rename__r_n
push eax
call fcn.00405b7e
add edi, 0xa
mov eax, edi
push ebx
add eax, esi
push 0x42c0d0
push eax
call fcn.0040582f
xor eax, eax
push eax
push eax
push eax
push ebp
call dword [sym.imp.KERNEL32.DLL_SetFilePointer]
lea eax, [esp + 0x18]
push 0
add edi, ebx
push eax
push edi
push esi
push ebp
call dword [sym.imp.KERNEL32.DLL_WriteFile]
push esi
call dword [sym.imp.KERNEL32.DLL_GlobalFree]
push ebp
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
inc dword [0x42f4f0]
pop edi
pop esi
pop ebp
pop ebx
ret 8
add eax, 0xa
push 0x409324
push eax
call fcn.004057e3
test eax, eax
je 0x4059fc
inc eax
lea edx, [esi + edi]
cmp eax, edx
mov ecx, eax
jae 0x405a6e
mov dl, byte [ecx]
mov byte [ecx + ebx], dl
inc ecx
lea edx, [esi + edi]
cmp ecx, edx
jb 0x405a61
sub eax, esi
jmp 0x4059fe
Function at 0x100075f0
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x3c
pushal
call 0x100075ff
pop dword [ebp - 0x2c]
mov eax, 0x100075ff
sub dword [ebp - 0x2c], eax
mov dword [ebp - 0x3c], 0xdf610b59
sub dword [ebp - 0x3c], 0x910ec60e
mov dword [ebp - 0x38], 0x23a0d9f
add dword [ebp - 0x38], 0x2ff93ea6
mov dword [ebp - 0x34], 0xa887f8d9
add dword [ebp - 0x34], 0xa3c44b55
mov dword [ebp - 0x30], 0xb9326e8c
add dword [ebp - 0x30], 0x46cd9174
lea eax, [ebp - 0x3c]
push eax
mov eax, sym.imp.kernel32.dll_GetModuleHandleA
add eax, dword [ebp - 0x2c]
call dword [eax]
mov dword [ebp - 0x3c], 0x9bc6994b
add dword [ebp - 0x3c], 0xd8abd00b
mov dword [ebp - 0x38], 0x4bd55acf
sub dword [ebp - 0x38], 0xa68f95a
mov dword [ebp - 0x34], 0x3e9eeb95
add dword [ebp - 0x34], 0x24d080d7
mov dword [ebp - 0x30], 0x4a769ebb
add dword [ebp - 0x30], 0xb5896145
lea ebx, [ebp - 0x3c]
push ebx
push eax
mov eax, 0x47bd1b95
add eax, 0xc844947f
add eax, dword [ebp - 0x2c]
call dword [eax]
push 0x40
push 0x1000
push 0x3eebf
push 0
call eax
mov ecx, 0x3f993011
sub ecx, 0x3f98e551
mov esi, eax
mov edi, 0x1002b000
add edi, dword [ebp - 0x2c]
mov edx, 0x73a7d785
add dword [ebp - 0x28], edx
mov ebx, dword [edi]
mov dword [ebp - 0x14], 0x22919022
xor ebx, edx
add dword [ebp - 0x1c], eax
mov dword [esi], ebx
mov dword [ebp - 0xc], 0x286fb9c9
add esi, 0x9596c8b7
add esi, 0x6a69374d
add edi, 0x38b683b1
sub edi, 0x38b683ad
loop 0x1000770b
add eax, 0xf3b2aa68
add eax, 0xc4e736b
xor ebx, ebx
add ebx, eax
add eax, 0x5b445b01
sub eax, 0x5b445afc
mov ecx, 0x998a965e
sub ecx, 0x898a965e
add ecx, dword [ebp - 0x2c]
call ebx
leave
ret

Function at 0x430000
Capabilities:
Encode data using xor

Disassembly:
pushal
nop
nop
nop
nop
nop
call 0x43000c
nop
nop
pop eax
nop
nop
nop
add eax, 0x403d6f
nop
nop
sub eax, 0x403d15
mov ebx, dword [eax]
nop
nop
nop
nop
nop
nop
nop
mov ecx, dword [eax + 4]
nop
nop
mov edx, dword [eax + 8]
nop
nop
nop
nop
nop
xor dword [ebx], edx
nop
add ebx, 4
nop
nop
nop
nop
nop
cmp ebx, ecx
nop
nop
nop
nop
jl 0x430030
nop
nop
nop
add eax, 0xc
nop
nop
nop
nop
cmp dword [eax], 0
nop
nop
nop
nop
jne 0x43001e
popal
nop
nop
nop
nop
nop
jmp loc.00401219
Function at 0x41cf60
Capabilities:
Packed with generic packer

Disassembly:
pushal
mov esi, 0x419015
lea edi, [esi - 0x18015]
push edi
jmp 0x41cf7a
mov al, byte [esi]
inc esi
mov byte [edi], al
inc edi
add ebx, ebx
jne 0x41cf81
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x41cf70
mov eax, 1
add ebx, ebx
jne 0x41cf93
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc eax, eax
add ebx, ebx
jae 0x41cf88
jne 0x41cfa4
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jae 0x41cf88
xor ecx, ecx
sub eax, 3
jb 0x41cfb8
shl eax, 8
mov al, byte [esi]
inc esi
xor eax, 0xffffffff
je 0x41d02a
mov ebp, eax
add ebx, ebx
jne 0x41cfc3
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
add ebx, ebx
jne 0x41cfd0
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
jne 0x41cff4
inc ecx
add ebx, ebx
jne 0x41cfe0
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
add ebx, ebx
jae 0x41cfd5
jne 0x41cff1
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jae 0x41cfd5
add ecx, 2
cmp ebp, 0xfffff300
adc ecx, 1
lea edx, [edi + ebp]
cmp ebp, 0xfffffffc
jbe 0x41d014
mov al, byte [edx]
inc edx
mov byte [edi], al
inc edi
dec ecx
jne 0x41d005
jmp 0x41cf76
mov eax, dword [edx]
add edx, 4
mov dword [edi], eax
add edi, 4
sub ecx, 4
ja 0x41d014
add edi, ecx
jmp 0x41cf76
pop esi
mov edi, esi
mov ecx, 0x122
mov al, byte [edi]
inc edi
sub al, 0xe8
cmp al, 1
ja 0x41d032
cmp byte [edi], 2
jne 0x41d032
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 al, bl
loop 0x41d037
lea edi, [esi + 0x1a000]
mov eax, dword [edi]
or eax, eax
je 0x41d0a6
mov ebx, dword [edi + 4]
lea eax, [eax + esi + 0x1d058]
add ebx, esi
push eax
add edi, 8
call dword [esi + 0x1d0a8]
xchg ebp, eax
mov al, byte [edi]
inc edi
or al, al
je 0x41d064
mov ecx, edi
push edi
dec eax
repne scasb al, byte es:[edi]
push ebp
call dword [esi + 0x1d0b0]
or eax, eax
je 0x41d0a0
mov dword [ebx], eax
add ebx, 4
jmp 0x41d081
call dword [esi + 0x1d0ac]
mov ebp, dword [esi + 0x1d0b4]
lea edi, [esi - 0x1000]
mov ebx, 0x1000
push eax
push esp
push 4
push ebx
push edi
call ebp
lea eax, [edi + 0x19f]
and byte [eax], 0x7f
and byte [eax + 0x28], 0x7f
pop eax
push eax
push esp
push eax
push ebx
push edi
call ebp
pop eax
lea ebx, [esi - 0x1000]
lea edi, [ebx + 0x1d101]
push edi
xor eax, eax
stosb byte es:[edi], al
pop ecx
dec ecx
push eax
push 1
push ebx
call ecx
popal
lea eax, [esp - 0x80]
push 0
cmp esp, eax
jne 0x41d0f2
sub esp, 0xffffff80
jmp 0x401300
Function at 0x401750
Capabilities:
Resolve function by parsing pe exports

Disassembly:
nop
pushal
jmp 0x40175f
xor edx, edx
nop
mov edx, dword fs:[edx + 0x30]
nop
jmp 0x401771
mov edx, dword [edx + 0xc]
nop
mov edx, dword [edx + 0x14]
jmp 0x401786
mov ebp, esp
nop
jmp 0x401795
nop
jmp 0x4017a4
movzx ecx, word [edx + 0x26]
nop
jmp 0x4017b7
xor edi, edi
nop
mov esi, dword [edx + 0x28]
jmp 0x4017c7
xor eax, eax
jmp 0x4017d3
lodsb al, byte [esi]
nop
cmp al, 0x61
nop
jl 0x4017fb
nop
nop
jmp 0x4017ed
sub al, 0x20
jmp 0x4017fb
nop
jmp 0x40180d
ror edi, 0xd
nop
add edi, eax
nop
dec ecx
nop
jne 0x4017bd
push edx
nop
jmp 0x40182a
push edi
jmp 0x401836
mov edx, dword [edx + 0x10]
jmp 0x401848
mov eax, dword [edx + 0x3c]
jmp 0x401858
add eax, edx
mov eax, dword [eax + 0x78]
nop
jmp 0x40186e
test eax, eax
jmp 0x401881
je 0x401a1f
nop
jmp 0x401897
add eax, edx
jmp 0x4018a8
mov ebx, dword [eax + 0x20]
nop
mov ecx, dword [eax + 0x18]
nop
jmp 0x4018ba
add ebx, edx
jmp 0x4018ca
push eax
nop
test ecx, ecx
nop
jmp 0x4018da
je 0x401a1d
xor edi, edi
nop
jmp 0x4018f2
dec ecx
nop
jmp 0x401905
mov esi, dword [ebx + ecx*4]
add esi, edx
nop
jmp 0x401918
nop
jmp 0x401929
xor eax, eax
lodsb al, byte [esi]
ror edi, 0xd
nop
add edi, eax
nop
jmp 0x401940
cmp al, ah
nop
jne 0x401918
nop
jmp 0x401959
add edi, dword [ebp - 8]
nop
jmp 0x401971
cmp edi, dword [ebp + 0x24]
jne 0x4018cc
nop
jmp 0x40198c
pop eax
mov ebx, dword [eax + 0x24]
nop
jmp 0x4019a3
add ebx, edx
mov cx, word [ebx + ecx*2]
nop
jmp 0x4019b7
mov ebx, dword [eax + 0x1c]
nop
jmp 0x4019c9
add ebx, edx
nop
mov eax, dword [ebx + ecx*4]
add eax, edx
mov dword [esp + 0x24], eax
jmp 0x4019e6
pop ebx
pop ebx
jmp 0x4019f6
popal
nop
jmp 0x401a06
pop ecx
jmp 0x401a16
pop edx
nop
push ecx
nop
jmp eax
pop eax
nop
jmp 0x401a31
pop edi
jmp 0x401a43
pop edx
nop
mov edx, dword [edx]
jmp 0x401a56
jmp 0x401795

Function at 0x4090b0
Capabilities:
Set socket configuration

Disassembly:
or al, 0x8d
push ebp
adc byte [edx - 0x43], ch
push edx
xor ebp, dword [0x10c7687d]
add byte [eax], al
push 0xbd00ffff
push ecx
call dword [sym.imp.WSOCK32.dll_setsockopt]
cmp eax, 0xffffffff
xlatb
test dword [ebp - 3], ebx
invalid
Function at 0x4011a0
Capabilities:
Create udp socket

Disassembly:
push 0xffffffffffffffff
push 0x4118da
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
push ecx
mov eax, dword [esp + 0x14]
push esi
push 0
push eax
mov esi, ecx
push 2
call sub.WSOCK32.dll_socket
mov dword [esi + 4], eax
cmp eax, 0xffffffff
pop esi
jne 0x401215
push 0x10
call sub.MFC42.DLL_operatornew
add esp, 4
mov dword [esp], eax
test eax, eax
mov dword [esp + 0xc], 0
je 0x4011f8
push 0x4140f4
mov ecx, eax
call fcn.00401020
jmp 0x4011fa
xor eax, eax
lea ecx, [esp + 0x14]
push 0x412930
push ecx
mov dword [esp + 0x14], 0xffffffff
mov dword [esp + 0x1c], eax
call sub.MSVCRT.dll__CxxThrowException
mov ecx, dword [esp + 4]
mov dword fs:[0], ecx
add esp, 0x10
ret 4

Function at 0x4014d0
Capabilities:
Get socket status
Send data
Send data on socket

Disassembly:
push 0xffffffffffffffff
push 0x41198a
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x114
push esi
mov esi, ecx
push edi
mov ecx, 0x3f
mov eax, dword [esi + 4]
lea edi, [esp + 0x20]
mov dword [esp + 0x1c], eax
xor eax, eax
mov dword [esp + 0x18], 1
lea edx, [esp + 0x10]
rep stosd dword es:[edi], eax
mov ecx, dword [esp + 0x134]
xor edi, edi
push edx
lea eax, [esp + 0x1c]
push edi
push eax
push edi
push edi
mov dword [esp + 0x24], ecx
mov dword [esp + 0x28], edi
call sub.WSOCK32.dll_select
test eax, eax
jne 0x401579
push 0x10
call sub.MFC42.DLL_operatornew
add esp, 4
mov dword [esp + 8], eax
cmp eax, edi
mov dword [esp + 0x124], edi
je 0x401559
push 0x414164
mov ecx, eax
call fcn.00401020
jmp 0x40155b
xor eax, eax
lea ecx, [esp + 0xc]
push 0x412930
push ecx
mov dword [esp + 0x12c], 0xffffffff
mov dword [esp + 0x14], eax
call sub.MSVCRT.dll__CxxThrowException
mov edx, dword [esp + 0x130]
mov eax, dword [esp + 0x12c]
mov ecx, dword [esi + 4]
push edi
push edx
push eax
push ecx
call sub.WSOCK32.dll_send
cmp eax, 0xffffffff
jne 0x4015e3
push 0x10
call sub.MFC42.DLL_operatornew
add esp, 4
mov dword [esp + 0xc], eax
cmp eax, edi
mov dword [esp + 0x124], 1
je 0x4015c3
push 0x414154
mov ecx, eax
call fcn.00401020
jmp 0x4015c5
xor eax, eax
lea edx, [esp + 8]
push 0x412930
push edx
mov dword [esp + 0x12c], 0xffffffff
mov dword [esp + 0x10], eax
call sub.MSVCRT.dll__CxxThrowException
mov ecx, dword [esp + 0x11c]
pop edi
pop esi
mov dword fs:[0], ecx
add esp, 0x120
ret 0xc
Function at 0x401600
Capabilities:
Get socket status
Receive data
Receive data on socket

Disassembly:
push 0xffffffffffffffff
push 0x4119ba
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x114
push esi
mov esi, ecx
push edi
mov ecx, 0x3f
mov eax, dword [esi + 4]
lea edi, [esp + 0x20]
mov dword [esp + 0x1c], eax
xor eax, eax
mov dword [esp + 0x18], 1
lea edx, [esp + 0x10]
rep stosd dword es:[edi], eax
mov ecx, dword [esp + 0x134]
xor edi, edi
push edx
push edi
lea eax, [esp + 0x20]
push edi
push eax
push edi
mov dword [esp + 0x24], ecx
mov dword [esp + 0x28], edi
call sub.WSOCK32.dll_select
test eax, eax
jne 0x4016a9
push 0x10
call sub.MFC42.DLL_operatornew
add esp, 4
mov dword [esp + 8], eax
cmp eax, edi
mov dword [esp + 0x124], edi
je 0x401689
push 0x414190
mov ecx, eax
call fcn.00401020
jmp 0x40168b
xor eax, eax
lea ecx, [esp + 0xc]
push 0x412930
push ecx
mov dword [esp + 0x12c], 0xffffffff
mov dword [esp + 0x14], eax
call sub.MSVCRT.dll__CxxThrowException
mov edx, dword [esp + 0x130]
mov eax, dword [esp + 0x12c]
mov ecx, dword [esi + 4]
push edi
push edx
push eax
push ecx
call sub.WSOCK32.dll_recv
cmp eax, 0xffffffff
jne 0x401713
push 0x10
call sub.MFC42.DLL_operatornew
add esp, 4
mov dword [esp + 0xc], eax
cmp eax, edi
mov dword [esp + 0x124], 1
je 0x4016f3
push 0x41417c
mov ecx, eax
call fcn.00401020
jmp 0x4016f5
xor eax, eax
lea edx, [esp + 8]
push 0x412930
push edx
mov dword [esp + 0x12c], 0xffffffff
mov dword [esp + 0x10], eax
call sub.MSVCRT.dll__CxxThrowException
mov ecx, dword [esp + 0x11c]
pop edi
pop esi
mov dword fs:[0], ecx
add esp, 0x120
ret 0xc
Function at 0x40161b
Capabilities:
Get socket status
Receive data
Receive data on socket

Disassembly:
push 0xffffffffffffffff
push 0x4119ba
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x114
push esi
mov esi, ecx
push edi
mov ecx, 0x3f
mov eax, dword [esi + 4]
lea edi, [esp + 0x20]
mov dword [esp + 0x1c], eax
xor eax, eax
mov dword [esp + 0x18], 1
lea edx, [esp + 0x10]
rep stosd dword es:[edi], eax
mov ecx, dword [esp + 0x134]
xor edi, edi
push edx
push edi
lea eax, [esp + 0x20]
push edi
push eax
push edi
mov dword [esp + 0x24], ecx
mov dword [esp + 0x28], edi
call sub.WSOCK32.dll_select
test eax, eax
jne 0x4016a9
push 0x10
call sub.MFC42.DLL_operatornew
add esp, 4
mov dword [esp + 8], eax
cmp eax, edi
mov dword [esp + 0x124], edi
je 0x401689
push 0x414190
mov ecx, eax
call fcn.00401020
jmp 0x40168b
xor eax, eax
lea ecx, [esp + 0xc]
push 0x412930
push ecx
mov dword [esp + 0x12c], 0xffffffff
mov dword [esp + 0x14], eax
call sub.MSVCRT.dll__CxxThrowException
mov edx, dword [esp + 0x130]
mov eax, dword [esp + 0x12c]
mov ecx, dword [esi + 4]
push edi
push edx
push eax
push ecx
call sub.WSOCK32.dll_recv
cmp eax, 0xffffffff
jne 0x401713
push 0x10
call sub.MFC42.DLL_operatornew
add esp, 4
mov dword [esp + 0xc], eax
cmp eax, edi
mov dword [esp + 0x124], 1
je 0x4016f3
push 0x41417c
mov ecx, eax
call fcn.00401020
jmp 0x4016f5
xor eax, eax
lea edx, [esp + 8]
push 0x412930
push edx
mov dword [esp + 0x12c], 0xffffffff
mov dword [esp + 0x10], eax
call sub.MSVCRT.dll__CxxThrowException
mov ecx, dword [esp + 0x11c]
pop edi
pop esi
mov dword fs:[0], ecx
add esp, 0x120
ret 0xc
Function at 0x402250
Capabilities:
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x411af0
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x28
push ebx
push esi
mov esi, dword [0x417bcc]
mov ebx, ecx
push edi
xor edi, edi
mov ecx, 2
mov word [ebp - 0x22], di
mov word [ebp - 0x24], cx
mov dword [ebp - 0x20], edi
mov eax, dword [esi - 8]
mov dword [ebp - 0x10], esp
mov dword [ebp - 4], edi
cmp eax, edi
mov ax, word [0x41424c]
jne 0x4022c3
push eax
mov word [ebp - 0x34], cx
call sub.WSOCK32.dll_htons
push edi
mov word [ebp - 0x32], ax
call sub.WSOCK32.dll_htonl
mov ecx, dword [ebp - 0x34]
mov edx, dword [ebp - 0x2c]
mov dword [ebp - 0x20], eax
mov eax, dword [ebp - 0x28]
mov dword [ebp - 0x24], ecx
mov dword [ebp - 0x1c], edx
jmp 0x4022e9
push eax
mov word [ebp - 0x34], cx
call sub.WSOCK32.dll_htons
push esi
mov word [ebp - 0x32], ax
call sub.WSOCK32.dll_inet_addr
mov ecx, dword [ebp - 0x34]
mov edx, dword [ebp - 0x2c]
mov dword [ebp - 0x20], eax
mov eax, dword [ebp - 0x28]
mov dword [ebp - 0x24], ecx
mov dword [ebp - 0x1c], edx
push 1
mov ecx, 0x417bc0
mov dword [ebp - 0x18], eax
call fcn.004011a0
lea ecx, [ebp - 0x24]
push ecx
mov ecx, 0x417bc0
call fcn.00401230
mov ecx, 0x417bc0
call fcn.004012c0
mov dword [0x417bd8], 1
mov dword [0x417bd4], edi
push edi
push edi
push edi
push edi
push ebx
push 0x403140
call sub.MFC42.DLL_AfxBeginThread
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x402750
Capabilities:
Get hostname
Resolve dns

Disassembly:
push 0xffffffffffffffff
push 0x411b4b
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x104
push ebx
push ebp
push esi
push edi
lea ecx, [esp + 0x10]
call sub.MFC42.DLL_CString::CString_1
mov ecx, 0x3f
xor eax, eax
lea edi, [esp + 0x15]
mov byte [esp + 0x14], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov ecx, 0x3f
xor eax, eax
lea edi, [esp + 0x14]
push 0xff
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea eax, [esp + 0x18]
push eax
call sub.WSOCK32.dll_gethostname
or esi, 0xffffffff
cmp eax, esi
je 0x4027c3
lea ecx, [esp + 0x14]
push ecx
call sub.WSOCK32.dll_gethostbyname
mov ebp, eax
test ebp, ebp
jne 0x4027d7
lea ecx, [esp + 0x10]
mov dword [esp + 0x11c], esi
call sub.MFC42.DLL_CString::CString
mov eax, esi
jmp 0x402826
mov ebx, dword [esp + 0x128]
mov eax, dword [esp + 0x124]
xor edi, edi
xor esi, esi
mov edx, dword [ebp + 0xc]
mov ecx, dword [esi + edx]
test ecx, ecx
je 0x40280f
mov dl, byte [ecx]
cmp dl, 0x7f
je 0x402807
test dl, dl
je 0x402807
mov ecx, dword [ecx]
inc edi
cmp edi, ebx
mov dword [eax], ecx
je 0x402841
add esi, 4
cmp esi, 0x40
jl 0x4027e9
lea ecx, [esp + 0x10]
mov dword [esp + 0x11c], 0xffffffff
call sub.MFC42.DLL_CString::CString
or eax, 0xffffffff
mov ecx, dword [esp + 0x114]
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x110
ret 8
lea ecx, [esp + 0x10]
mov dword [esp + 0x11c], 0xffffffff
call sub.MFC42.DLL_CString::CString
xor eax, eax
jmp 0x402826
Function at 0x402f10
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x411bf2
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x1c
push esi
push edi
lea ecx, [esp + 0x10]
call sub.MFC42.DLL_CException::CException
lea ecx, [esp + 0x20]
mov dword [esp + 0x2c], 0
call sub.MFC42.DLL_CString::CString_1
push 0
lea ecx, [esp + 0x24]
mov byte [esp + 0x30], 1
mov dword [esp + 0x14], 0x4127bc
mov dword [esp + 0x1c], 0
mov dword [esp + 0x20], 0xffffffff
call sub.MFC42.DLL_CString::operator_1
push 0x10
mov dword [esp + 0x30], 2
call sub.MFC42.DLL_operatornew
add esp, 4
mov dword [esp + 0xc], eax
test eax, eax
mov byte [esp + 0x2c], 3
je 0x402f96
mov ecx, eax
call sub.MFC42.DLL_CFile::CFile
mov esi, eax
jmp 0x402f98
xor esi, esi
mov eax, dword [esp + 0x34]
mov byte [esp + 0x2c], 2
cmp byte [eax], 0x2f
jne 0x402fa7
inc eax
push eax
lea ecx, [esp + 0xc]
call fcn.00411524
push 0x5c
push 0x2f
lea ecx, [esp + 0x10]
mov byte [esp + 0x34], 4
call sub.MFC42.DLL_CString::Replace
lea eax, [esp + 8]
lea ecx, [esp + 0x34]
push eax
push 0x417bd0
push ecx
call sub.MFC42.DLL_operator_1
mov eax, dword [eax]
mov edx, dword [esi]
lea ecx, [esp + 0x10]
mov byte [esp + 0x2c], 5
push ecx
push 0
push eax
mov ecx, esi
call dword [edx + 0x28]
lea ecx, [esp + 0x34]
mov edi, eax
mov byte [esp + 0x2c], 4
call sub.MFC42.DLL_CString::CString
test edi, edi
je 0x40303b
lea ecx, [esp + 8]
mov byte [esp + 0x2c], 2
call sub.MFC42.DLL_CString::CString
mov dword [esp + 0x10], 0x4127bc
lea ecx, [esp + 0x20]
mov dword [esp + 0x2c], 6
call sub.MFC42.DLL_CString::CString
mov eax, esi
pop edi
pop esi
mov ecx, dword [esp + 0x1c]
mov dword fs:[0], ecx
add esp, 0x28
ret
mov eax, dword [esp + 0x18]
cmp eax, 5
je 0x40304d
cmp eax, 3
jne 0x4030f1
mov ecx, dword [esp + 8]
mov eax, dword [ecx - 8]
cmp eax, 1
jle 0x40306b
cmp byte [eax + ecx - 1], 0x5c
je 0x40306b
push 0x5c
lea ecx, [esp + 0xc]
call fcn.004115a2
push 0x417bc8
lea ecx, [esp + 0xc]
call sub.MFC42.DLL_CString::operator
lea edx, [esp + 8]
lea eax, [esp + 0x34]
push edx
push 0x417bd0
push eax
call sub.MFC42.DLL_operator_1
mov eax, dword [eax]
mov edx, dword [esi]
lea ecx, [esp + 0x10]
mov byte [esp + 0x2c], 7
push ecx
push 0
push eax
mov ecx, esi
call dword [edx + 0x28]
lea ecx, [esp + 0x34]
mov edi, eax
mov byte [esp + 0x2c], 4
call sub.MFC42.DLL_CString::CString
test edi, edi
je 0x4030f1
lea ecx, [esp + 8]
mov byte [esp + 0x2c], 2
call sub.MFC42.DLL_CString::CString
mov dword [esp + 0x10], 0x4127bc
lea ecx, [esp + 0x20]
mov dword [esp + 0x2c], 8
call sub.MFC42.DLL_CString::CString
mov eax, esi
pop edi
pop esi
mov ecx, dword [esp + 0x1c]
mov dword fs:[0], ecx
add esp, 0x28
ret
test esi, esi
je 0x4030fe
mov edx, dword [esi]
push 1
mov ecx, esi
call dword [edx + 4]
lea ecx, [esp + 8]
mov byte [esp + 0x2c], 2
call sub.MFC42.DLL_CString::CString
mov dword [esp + 0x10], 0x4127bc
lea ecx, [esp + 0x20]
mov dword [esp + 0x2c], 9
call sub.MFC42.DLL_CString::CString
mov ecx, dword [esp + 0x24]
pop edi
xor eax, eax
pop esi
mov dword fs:[0], ecx
add esp, 0x28
ret
Function at 0x403900
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Connect udp socket
Create tcp socket
Create udp socket
Set socket configuration

Disassembly:
mov eax, dword [esp + 8]
push esi
test eax, eax
mov esi, ecx
jne 0x40390f
pop esi
ret 0x10
mov ecx, dword [esp + 8]
mov edx, dword [esp + 0x14]
push ebx
lea ebx, [esi + 0x28]
mov dword [esi + 0x18], eax
mov dword [esi + 0x1c], ecx
mov ecx, dword [edx]
mov eax, ebx
push edi
mov dword [eax], ecx
mov ecx, dword [edx + 4]
mov dword [eax + 4], ecx
mov ecx, dword [edx + 8]
mov dword [eax + 8], ecx
mov edx, dword [edx + 0xc]
mov dword [eax + 0xc], edx
mov eax, dword [esi + 4]
test eax, eax
je 0x40394e
push eax
call sub.WSOCK32.dll_closesocket
mov dword [esi + 4], 0
mov eax, dword [esi + 4]
test eax, eax
jne 0x403963
push 0
push 1
push 2
call sub.WSOCK32.dll_socket
mov dword [esi + 4], eax
lea edi, [esi + 8]
push ebx
mov word [edi], 2
call sub.WSOCK32.dll_inet_addr
mov dword [esi + 0xc], eax
mov ax, word [esi + 0x18]
push eax
call sub.WSOCK32.dll_htons
mov ecx, dword [esi + 4]
push 0x10
push edi
push ecx
mov word [esi + 0xa], ax
call sub.WSOCK32.dll_connect
pop edi
cmp eax, 0xffffffff
pop ebx
jne 0x4039a2
mov dword [esi + 0x20], 0
xor eax, eax
pop esi
ret 0x10
mov eax, 1
mov dword [esi + 0x20], eax
pop esi
ret 0x10

Function at 0x4039b0
Capabilities:
Receive data
Receive data on socket

Disassembly:
push ebx
mov ebx, dword [esp + 0xc]
push ebp
push esi
test ebx, ebx
push edi
mov ebp, ecx
jg 0x4039c7
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
ret 8
mov eax, dword [esp + 0x14]
test eax, eax
jne 0x4039d8
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
ret 8
mov eax, dword [ebp + 0x20]
test eax, eax
jne 0x4039e8
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
ret 8
xor esi, esi
mov edi, ebx
mov ecx, dword [esp + 0x14]
mov eax, ebx
sub eax, esi
push 0
push eax
mov eax, dword [ebp + 4]
lea edx, [esi + ecx]
push edx
push eax
call sub.WSOCK32.dll_recv
test eax, eax
jle 0x403a19
sub edi, eax
add esi, eax
test edi, edi
jg 0x4039ec
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
ret 8
pop edi
pop esi
pop ebp
or eax, 0xffffffff
pop ebx
ret 8

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

Disassembly:
push ecx
push ebx
mov ebx, dword [esp + 0x10]
push ebp
push esi
test ebx, ebx
push edi
mov dword [esp + 0x10], ecx
jg 0x403a4b
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
pop ecx
ret 8
mov ebp, dword [esp + 0x18]
test ebp, ebp
jne 0x403a5d
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
pop ecx
ret 8
xor esi, esi
mov edi, ebx
mov edx, dword [esp + 0x10]
mov eax, ebx
sub eax, esi
push 0
push eax
mov eax, dword [edx + 4]
lea ecx, [esi + ebp]
push ecx
push eax
call sub.WSOCK32.dll_send
test eax, eax
jle 0x403a8f
sub edi, eax
add esi, eax
test edi, edi
jg 0x403a61
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
pop ecx
ret 8
pop edi
pop esi
pop ebp
or eax, 0xffffffff
pop ebx
pop ecx
ret 8