joyce8/EMBER2024-capa huggingface dataset:
Function at 0x1003e4e6
Capabilities:
Connect pipe

Disassembly:
push ebp
mov ebp, esp
push ecx
and dword [ebp - 4], 0
push edi
mov edi, ecx
cmp byte [edi + 0x1040], 0
je 0x1003e501
mov byte [edi + 0x1040], 0
mov ecx, dword [edi + 0x1060]
cmp ecx, 0xffffffff
je 0x1003e566
push esi
lea eax, [edi + 0x1028]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_ConnectNamedPipe]
or dword [edi + 0x1080], 2
mov esi, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
test esi, esi
pop esi
jne 0x1003e566
cmp eax, 0xe8
je 0x1003e566
cmp eax, 0x217
je 0x1003e554
cmp eax, 0x3e5
jne 0x1003e566
or dword [edi + 0x1080], 4
mov byte [edi + 0x1040], 1
jmp 0x1003e562
or dword [edi + 0x1080], 0x10
mov byte [edi + 0x107c], 0
mov al, 1
jmp 0x1003e568
xor al, al
pop edi
mov esp, ebp
pop ebp
ret

Function at 0x1003e56d
Capabilities:
Check if file exists
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xb4
push ebx
push esi
mov esi, ecx
xor ebx, ebx
push edi
mov dword [ebp - 4], ebx
cmp byte [esi + 0x105c], bl
je 0x1003e5d3
mov byte [esi + 0x105c], bl
cmp dword [ebp + 8], ebx
je 0x1003e69b
cmp dword [ebp + 0xc], ebx
je 0x1003e69b
cmp dword [esi + 0x1078], ebx
jne 0x1003e5ad
call fcn.10008f00
lea edi, [esi + 0x1068]
mov ecx, edi
call fcn.1003ea82
mov ecx, dword [eax]
dec dword [edi + 0x10]
jne 0x1003e5c6
mov dword [edi + 0xc], ebx
jmp 0x1003e5c9
inc dword [edi + 0xc]
test ecx, ecx
je 0x1003e5d3
mov eax, dword [ecx]
push 1
call dword [eax]
cmp dword [esi + 0x1078], ebx
je 0x1003e6f9
cmp dword [esi + 0x1060], 0xffffffff
je 0x1003e6ee
lea ecx, [esi + 0x1068]
call fcn.1003ea82
mov edi, dword [eax]
or dword [esi + 0x1080], 0x20
cmp byte [esi + 0x107f], bl
je 0x1003e60d
call fcn.10008f00
mov byte [esi + 0x107f], 1
lea eax, [esi + 0x1044]
mov edx, dword [edi + 4]
mov ecx, dword [edi + 8]
push eax
lea eax, [ebp + 0xc]
add ecx, dword [edx]
push eax
push ecx
push edx
push dword [esi + 0x1060]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x1003e6f2
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
cmp edi, 0x3e5
je 0x1003e6f2
mov byte [esi + 0x107f], bl
call fcn.10009750
mov esi, 0x100
cmp eax, 2
jg 0x1003e697
push 2
push 0x1ca
push str.b:core_srcipcipc_channel_win.cc
lea ecx, [ebp - 0xb4]
mov ebx, esi
call fcn.100097c0
push edi
add eax, 8
push str.pipe_error:
push eax
call fcn.100038f0
pop ecx
pop ecx
mov ecx, eax
call fcn.1000a1b0
test esi, ebx
jmp 0x1003e6e1
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
call fcn.10009750
cmp eax, 2
jg 0x1003e6de
push 8
pop ebx
push 2
push 0x1a4
push str.b:core_srcipcipc_channel_win.cc
lea ecx, [ebp - 0xb4]
call fcn.100097c0
push esi
add eax, ebx
push str.pipe_error:
push eax
call fcn.100038f0
pop ecx
pop ecx
mov ecx, eax
call fcn.1000a1b0
test bl, 8
je 0x1003e6ee
lea ecx, [ebp - 0xb4]
call fcn.10009810
xor al, al
jmp 0x1003e6fb
mov byte [esi + 0x105c], 1
mov al, 1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
Function at 0xefb6b8
Capabilities:
Encode data using xor

Disassembly:
jmp 0xefb6c2
pushal
call 0xefb6c8
pop ebp
sub ebp, 0x10
sub ebp, 0xafb6b8
jmp 0xefb6de
mov eax, 0xafb6b8
add eax, ebp
add eax, 0x4c
mov ecx, 0x5d1
mov edx, 0x66e2f831
xor byte [eax], dl
inc eax
dec ecx
jne 0xefb6f5
jmp 0xefb708
mov edx, 0xdb8bafc
xor dword [ecx], esi
xor dword [eax + 0x3131c9f0], esi
xor dword [edx], esi
cld
mov dword [edi], esi
xor dword [ecx], esi
xor dword [ebx + 0x31313119], ecx
invalid
Function at 0x403809
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
push esi
mov ecx, 0x47e216
call fcn.004411c7
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
je 0x40386d
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov esi, eax
test esi, esi
je 0x40386d
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov edx, dword [ebp + 0x10]
lea ecx, [esi + eax]
and edx, 0xf
jbe 0x40385d
cmp esi, ecx
jae 0x40386d
movzx eax, word [esi]
lea esi, [esi + eax*2]
add esi, 2
sub edx, 1
jne 0x40384b
cmp esi, ecx
jae 0x40386d
xor eax, eax
cmp word [esi], ax
cmove esi, eax
mov eax, esi
jmp 0x40386f
xor eax, eax
pop esi
pop ebp
ret

Function at 0x40426f
Capabilities:
Check if file exists
Create directory
Delete directory

Disassembly:
mov eax, 0x462c57
call fcn.004414ac
sub esp, 0xc
mov ecx, 0x47e838
push ebx
call fcn.004411c7
sub esp, 0x18
mov ecx, esp
push 0x46375c
call fcn.00401510
call fcn.004036b4
add esp, 0x18
test al, al
je 0x4042ad
mov eax, dword [ebp + 8]
mov byte [eax], 0
jmp 0x404348
push 0x463760
lea ecx, [ebp - 0x14]
call fcn.00401e79
xor ebx, ebx
lea ecx, [ebp - 0x10]
push str.D:Program_Filesgptchrometmp
mov dword [ebp - 4], ebx
call fcn.00401e79
push dword [ebp - 0x14]
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x4042ef
push ebx
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
mov eax, dword [ebp + 8]
je 0x404330
push dword [ebp - 0x14]
jmp 0x404325
push dword [ebp - 0x10]
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x404311
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
test eax, eax
mov eax, dword [ebp + 8]
setne cl
mov byte [eax], cl
jmp 0x404332
push ebx
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
mov eax, dword [ebp + 8]
je 0x404330
push dword [ebp - 0x10]
mov byte [eax], 1
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
jmp 0x404332
mov byte [eax], bl
mov ecx, dword [ebp - 0x10]
lea ecx, [ecx - 0x10]
call fcn.00402e8f
mov ecx, dword [ebp - 0x14]
lea ecx, [ecx - 0x10]
call fcn.00402e8f
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ebx
leave
ret
Function at 0x404355
Capabilities:
Create process on windows

Disassembly:
mov eax, 0x462c78
call fcn.004414ac
sub esp, 0x24c
mov ecx, 0x47e838
call fcn.004411c7
call dword [sym.imp.SHELL32.dll_IsUserAnAdmin]
test eax, eax
je 0x404380
mov al, 1
jmp 0x404469
push ebx
push esi
push 0x208
xor ebx, ebx
lea eax, [ebp - 0x258]
push ebx
push eax
call fcn.00443780
add esp, 0xc
lea eax, [ebp - 0x258]
push 0x104
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
push 0x38
lea eax, [ebp - 0x4c]
mov dword [ebp - 0x50], 0x3c
push ebx
push eax
call fcn.00443780
add esp, 0xc
mov dword [ebp - 0x44], str.runas
lea eax, [ebp - 0x258]
mov dword [ebp - 0x34], 1
lea ecx, [ebp - 0x14]
mov dword [ebp - 0x40], eax
call fcn.00401ece
mov eax, dword [ebp + 8]
mov edx, str._upprivi__can_ins_d
mov ecx, str._upprivi
mov dword [ebp - 4], ebx
cmp byte [eax], bl
cmovne ecx, edx
push ecx
lea ecx, [ebp - 0x14]
call fcn.00403139
mov esi, dword [ebp - 0x14]
lea eax, [ebp - 0x50]
push eax
mov dword [ebp - 0x3c], esi
call dword [sym.imp.SHELL32.dll_ShellExecuteExW]
test eax, eax
jne 0x40445d
push edi
mov edi, 0x4634c8
lea ecx, [ebp - 0x10]
push edi
call fcn.00401e79
push 0x4637f4
lea ecx, [ebp - 0x10]
mov byte [ebp - 4], 1
call fcn.0040246e
push 4
push edi
push dword [ebp - 0x10]
push ebx
call dword [sym.imp.USER32.dll_MessageBoxW]
pop edi
cmp eax, 6
jne 0x404475
mov ecx, dword [ebp - 0x10]
add ecx, 0xfffffff0
call fcn.00402e8f
lea ecx, [esi - 0x10]
call fcn.00402e8f
mov al, 1
jmp 0x404467
lea ecx, [esi - 0x10]
call fcn.00402e8f
xor al, al
pop esi
pop ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
leave
ret
push ebx
call fcn.004491b8
int3
Function at 0x404a17
Capabilities:
Check mutex on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
push ebx
push esi
push edi
mov ecx, 0x47ee55
call fcn.004411c7
push dword [ebp + 0x10]
lea ecx, [ebp - 8]
call fcn.00401e79
lea ecx, [ebp - 0x18]
call fcn.004049fd
call fcn.004035bd
push dword [ebp + 0x10]
lea ecx, [ebp + 0x10]
call fcn.00401e79
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp + 0x10]
push eax
call fcn.00404040
pop ecx
pop ecx
mov ecx, dword [ebp + 0x10]
lea ecx, [ecx - 0x10]
call fcn.00402e8f
push str.GCMainWnd
lea ecx, [ebp - 4]
call fcn.00401e79
cmp byte [ebp - 0x17], 0
jne 0x404b40
cmp byte [ebp - 0x11], 0
jne 0x404b09
lea eax, [ebp - 4]
push eax
lea eax, [ebp + 0x10]
push str.Global_
push eax
call fcn.004022d9
add esp, 0xc
xor edi, edi
push dword [eax]
push edi
push edi
call dword [sym.imp.KERNEL32.dll_CreateMutexW]
mov ecx, dword [ebp + 0x10]
mov esi, eax
add ecx, 0xfffffff0
call fcn.00402e8f
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
je 0x404ac7
test esi, esi
jne 0x404b40
push dword [ebp - 4]
push edi
call dword [sym.imp.USER32.dll_FindWindowW]
mov ebx, eax
test ebx, ebx
je 0x404b72
cmp byte [ebp - 0x16], 0
jne 0x404b72
mov esi, dword [sym.imp.USER32.dll_SendMessageW]
push edi
push 0xf020
push 0x112
push ebx
call esi
push edi
push 0xf120
push 0x112
push ebx
call esi
jmp 0x404b72
push 0x1f4
call dword [sym.imp.KERNEL32.dll_Sleep]
lea eax, [ebp - 4]
push eax
lea eax, [ebp + 0x10]
push str.Global_
push eax
call fcn.004022d9
add esp, 0xc
xor edi, edi
push dword [eax]
push edi
push edi
call dword [sym.imp.KERNEL32.dll_CreateMutexW]
mov ecx, dword [ebp + 0x10]
lea ecx, [ecx - 0x10]
call fcn.00402e8f
cmp byte [ebp - 0x18], 0
jne 0x404b56
cmp byte [ebp - 0x11], 0
jne 0x404b56
lea eax, [ebp - 0x18]
push eax
call fcn.0040426f
pop ecx
cmp byte [ebp - 0x17], 0
jne 0x404b72
cmp byte [ebp - 0x16], 0
jne 0x404b72
cmp byte [ebp - 0x11], 0
jne 0x404b72
lea eax, [ebp - 0x18]
push eax
call fcn.00404355
pop ecx
mov ecx, dword [ebp - 4]
lea ecx, [ecx - 0x10]
call fcn.00402e8f
lea ecx, [ebp - 0xc]
call fcn.004020bf
mov ecx, dword [ebp - 8]
lea ecx, [ecx - 0x10]
call fcn.00402e8f
pop edi
pop esi
xor eax, eax
pop ebx
leave
ret 0x10
Function at 0x40a7a0
Capabilities:
Encode data using xor
Hash data using djb2

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 0xc]
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
mov edi, 0x1505
lea ebx, [esi + eax]
cmp esi, ebx
jae 0x40a7d6
mov al, byte [esi]
push eax
call fcn.00412670
movsx ecx, al
inc esi
mov eax, edi
add esp, 4
shl eax, 5
add eax, edi
xor ecx, eax
mov edi, ecx
cmp esi, ebx
jb 0x40a7b8
mov eax, 0x4104105
mov esi, edi
mul edi
sub esi, edx
shr esi, 1
add esi, edx
shr esi, 5
mov ecx, esi
shl ecx, 6
sub ecx, esi
sub edi, ecx
mov eax, edi
pop edi
pop esi
pop ebx
pop ebp
ret
Function at 0x4131c0
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 8]
test esi, esi
je 0x4131eb
cmp dword [esi + 0x84], 0
je 0x4131eb
push 2
push 3
push esi
call fcn.004129f0
push dword [ebp + 0xc]
call fcn.00412ce0
add esp, 0x10
jmp 0x4131fa
push dword [ebp + 0xc]
call fcn.00412ce0
add esp, 4
test esi, esi
je 0x41320e
cmp dword [esi + 0x84], 0
je 0x41320e
push 3
push esi
call fcn.00412a30
add esp, 8
pop esi
pop ebp
ret

Function at 0x4132c0
Capabilities:
Create udp socket

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 8]
test esi, esi
je 0x413301
mov eax, dword [esi + 0x7c]
cmp byte [eax + 0x100], 0
jne 0x4132f1
push 0
call fcn.004132c0
add esp, 4
test al, al
mov eax, dword [esi + 0x7c]
setne cl
inc cl
mov byte [eax + 0x100], cl
mov eax, dword [esi + 0x7c]
pop esi
cmp byte [eax + 0x100], 2
sete al
pop ebp
ret
push 0
push 2
push 0x17
call dword [sym.imp.WS2_32.dll_socket]
cmp eax, 0xffffffff
jne 0x413317
xor al, al
pop esi
pop ebp
ret
push eax
call dword [sym.imp.WS2_32.dll_closesocket]
mov al, 1
pop esi
pop ebp
ret

Function at 0x41a590
Capabilities:
Get socket status

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push ebx
mov ebx, dword [ebp + 0x14]
push esi
mov esi, dword [ebp + 0x10]
push edi
mov edi, dword [ebp + 0xc]
test edi, edi
je 0x41a5ab
cmp dword [edi], 0
jne 0x41a5bd
test esi, esi
je 0x41a5b4
cmp dword [esi], 0
jne 0x41a5bd
test ebx, ebx
je 0x41a606
cmp dword [ebx], 0
je 0x41a606
push dword [ebp + 0x1c]
lea eax, [ebp - 8]
push dword [ebp + 0x18]
push eax
call fcn.0043e2d0
add esp, 0xc
test ebx, ebx
je 0x41a5d8
cmp dword [ebx], 0
jne 0x41a5da
xor ebx, ebx
test esi, esi
je 0x41a5e3
cmp dword [esi], 0
jne 0x41a5e5
xor esi, esi
test edi, edi
je 0x41a5ee
cmp dword [edi], 0
jne 0x41a5f0
xor edi, edi
push eax
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
inc eax
push eax
call dword [sym.imp.WS2_32.dll_select]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push dword [ebp + 0x1c]
push dword [ebp + 0x18]
call fcn.0041a540
add esp, 8
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x41d2c0
Capabilities:
Move file

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
push ebx
push esi
lea eax, [ebp - 0x10]
push edi
push eax
call fcn.0040b0d0
push dword [ebp + 8]
movups xmm0, xmmword [eax]
movups xmmword [ebp - 0x10], xmm0
call fcn.0041bdb0
push dword [ebp + 0xc]
mov edi, eax
call fcn.0041bdb0
mov ebx, dword [sym.imp.KERNEL32.dll_MoveFileExW]
add esp, 0xc
mov esi, eax
push 1
push esi
push edi
call ebx
test eax, eax
jne 0x41d347
lea eax, [ebp - 0x20]
push eax
call fcn.0040b0d0
movups xmm0, xmmword [ebp - 0x10]
sub esp, 0xc
mov ecx, esp
sub esp, 0x10
movups xmmword [ecx], xmm0
mov ecx, esp
movups xmm0, xmmword [eax]
movups xmmword [ecx], xmm0
call fcn.0040b180
add esp, 0x20
test edx, edx
ja 0x41d36a
jb 0x41d335
cmp eax, 0x3e8
ja 0x41d36a
push 1
call dword [sym.imp.KERNEL32.dll_Sleep]
push 1
push esi
push edi
call ebx
test eax, eax
je 0x41d300
test edi, edi
je 0x41d354
push edi
call fcn.00445d54
add esp, 4
test esi, esi
je 0x41d361
push esi
call fcn.00445d54
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
test edi, edi
je 0x41d377
push edi
call fcn.00445d54
add esp, 4
test esi, esi
je 0x41d384
push esi
call fcn.00445d54
add esp, 4
pop edi
pop esi
mov eax, 1
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x41d780
Capabilities:
Resolve dns

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
mov eax, dword [ebp + 0x14]
push ebx
xor ebx, ebx
mov dword [ebp - 0xc], ebx
mov dword [eax], ebx
lea eax, [ebp - 0x10]
push eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.WS2_32.dll_getaddrinfo]
mov dword [ebp - 0x14], eax
test eax, eax
jne 0x41d8fd
push esi
mov esi, dword [ebp - 0x10]
test esi, esi
je 0x41d8e9
push edi
nop dword [eax]
mov eax, dword [esi + 0x14]
test eax, eax
je 0x41d7de
lea edx, [eax + 1]
nop word [eax + eax]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x41d7d0
sub eax, edx
lea ecx, [eax + 1]
jmp 0x41d7e0
xor ecx, ecx
mov eax, dword [esi + 4]
mov dword [ebp - 8], ecx
cmp eax, 2
jne 0x41d7f2
mov eax, 0x10
jmp 0x41d800
cmp eax, 0x17
jne 0x41d8a5
mov eax, 0x1c
cmp dword [esi + 0x18], 0
mov dword [ebp - 4], eax
je 0x41d8a5
mov edx, dword [esi + 0x10]
test edx, edx
je 0x41d8a5
cmp edx, eax
jb 0x41d8a5
add ecx, 0x20
add eax, ecx
push eax
call dword [0x47b010]
mov edi, eax
add esp, 4
test edi, edi
je 0x41d8de
mov ecx, dword [esi]
mov dword [edi], ecx
mov ecx, dword [esi + 4]
mov dword [edi + 4], ecx
mov ecx, dword [esi + 8]
mov dword [edi + 8], ecx
mov eax, dword [esi + 0xc]
mov ecx, dword [ebp - 4]
mov dword [edi + 0xc], eax
lea eax, [edi + 0x20]
push ecx
mov dword [edi + 0x10], ecx
mov dword [edi + 0x14], 0
mov dword [edi + 0x1c], 0
mov dword [edi + 0x18], eax
push dword [esi + 0x18]
push eax
call fcn.00443200
mov edx, dword [ebp - 8]
add esp, 0xc
test edx, edx
je 0x41d893
mov eax, dword [edi + 0x18]
add eax, dword [ebp - 4]
push edx
mov dword [edi + 0x14], eax
push dword [esi + 0x14]
push eax
call fcn.00443200
add esp, 0xc
mov eax, dword [ebp - 0xc]
test ebx, ebx
cmove ebx, edi
test eax, eax
je 0x41d8a2
mov dword [eax + 0x1c], edi
mov dword [ebp - 0xc], edi
mov esi, dword [esi + 0x1c]
test esi, esi
jne 0x41d7c0
mov esi, dword [ebp - 0x14]
mov eax, dword [ebp - 0x10]
pop edi
test eax, eax
je 0x41d8c2
push eax
call dword [sym.imp.WS2_32.dll_freeaddrinfo]
test esi, esi
je 0x41d8e5
push ebx
call fcn.0041d750
mov eax, dword [ebp + 0x14]
add esp, 4
xor ebx, ebx
mov dword [eax], ebx
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov esi, 8
jmp 0x41d8b3
test ebx, ebx
jne 0x41d8f5
mov esi, 0x2af9
push esi
call dword [sym.imp.WS2_32.dll_WSASetLastError]
mov eax, dword [ebp + 0x14]
mov dword [eax], ebx
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x41dbc0
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push 0
push 0
push dword [ebp + 0xc]
push dword [ebp + 8]
push 0
push 0
call fcn.00449f5a
mov ecx, eax
add esp, 0x18
xor eax, eax
test ecx, ecx
je 0x41dbe7
cmp ecx, 0xffffffff
cmovne eax, ecx
pop ebp
ret

Function at 0x41dd70
Capabilities:
Generate random numbers via winapi

Disassembly:
push ebp
mov ebp, esp
push dword [ebp + 0xc]
push 0
push dword [ebp + 8]
call fcn.00443780
add esp, 0xc
push 2
push dword [ebp + 0xc]
push dword [ebp + 8]
push 0
call sub.bcrypt.dll_BCryptGenRandom
neg eax
sbb eax, eax
and eax, 2
pop ebp
ret
Function at 0x423620
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x8c
mov eax, dword [0x47b380]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
lea eax, [ebp - 0x8c]
push eax
lea eax, [ebp - 0x84]
push eax
mov ebx, dword [edi + 0x18]
mov esi, dword [ebx + 0x12c]
push esi
mov dword [ebp - 0x88], 0xffffffff
mov dword [ebp - 0x8c], 0x80
call dword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
jne 0x423696
lea eax, [ebp - 0x8c]
mov dword [ebp - 0x8c], 0x80
push eax
lea eax, [ebp - 0x84]
push eax
push esi
call dword [sym.imp.WS2_32.dll_accept]
mov dword [ebp - 0x88], eax
jmp 0x42369c
mov eax, dword [ebp - 0x88]
cmp eax, 0xffffffff
jne 0x4236c5
push str.Error_accept__ing_server_connect
push edi
call fcn.0040fac0
add esp, 8
mov eax, 0x1e
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00441cc6
mov esp, ebp
pop ebp
ret
push str.Connection_accepted_from_server
push edi
call fcn.0040fb80
mov byte [ebx + 0x1d5], 0
push 1
push dword [ebp - 0x88]
call fcn.0043e3e0
lea eax, [ebp - 0x88]
push eax
push 1
push ebx
push edi
call fcn.004330c0
add esp, 0x20
test eax, eax
jne 0x423754
cmp dword [edi + 0x1ac], eax
je 0x423752
push 1
push edi
call fcn.004080b0
mov eax, dword [edi + 0x1ac]
push 1
push dword [ebp - 0x88]
push dword [edi + 0x1b0]
call eax
push 0
push edi
mov esi, eax
call fcn.004080b0
add esp, 0x1c
test esi, esi
je 0x423752
push ebx
push edi
call fcn.00423bf0
add esp, 8
mov eax, 0x2a
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00441cc6
mov esp, ebp
pop ebp
ret
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00441cc6
mov esp, ebp
pop ebp
ret

Function at 0x425ca0
Capabilities:
Check http status code

Disassembly:
push ebp
mov ebp, esp
mov ecx, dword [ebp + 0xc]
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
lea eax, [ecx - 0xc8]
xor edi, edi
mov ebx, dword [esi + 0x18]
cmp eax, 0x64
jb 0x425cd2
push str.Couldnt_set_desired_mode
push esi
call fcn.0040fac0
add esp, 8
lea eax, [edi + 0x11]
pop edi
pop esi
pop ebx
pop ebp
ret
cmp ecx, 0xc8
je 0x425ce9
push ecx
push str.Got_a__03d_response_code_instead_of_the_assumed_200
push esi
call fcn.0040fb80
add esp, 0xc
mov al, byte [ebp + 0x10]
cmp al, 0x13
jne 0x425d01
push ebx
push esi
call fcn.00425970
add esp, 8
mov edi, eax
pop edi
pop esi
pop ebx
pop ebp
ret
cmp al, 0x14
jne 0x425d15
push esi
call fcn.004249c0
add esp, 4
mov edi, eax
pop edi
pop esi
pop ebx
pop ebp
ret
cmp al, 0x15
jne 0x425d29
push esi
call fcn.00425950
add esp, 4
mov edi, eax
pop edi
pop esi
pop ebx
pop ebp
ret
cmp al, 0x16
jne 0x425d38
push esi
call fcn.00425b80
add esp, 4
mov edi, eax
mov eax, edi
pop edi
pop esi
pop ebx
pop ebp
ret
Function at 0x42c3b0
Capabilities:
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
mov ecx, dword [ebp + 0x10]
push ebx
mov ebx, dword [ebp + 0xc]
push esi
mov esi, dword [ebp + 8]
push 0
mov byte [ebp + 0xa], cl
lea ecx, [ebp + 8]
push 3
mov eax, dword [esi + 0x18]
push ecx
mov byte [ebp + 8], 0xff
mov byte [ebp + 9], bl
push dword [eax + 0x128]
call dword [sym.imp.WS2_32.dll_send]
test eax, eax
jns 0x42c3f8
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push str.Sending_data_failed___d_
push esi
call fcn.0040fac0
add esp, 0xc
push dword [ebp + 0x10]
push ebx
push str.SENT
push esi
call fcn.0042bc60
add esp, 0x10
pop esi
pop ebx
pop ebp
ret

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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
cmp dword [ebp + 0xc], 0x1f
push ebx
mov ebx, dword [ebp + 8]
mov edx, dword [ebx + 0x124]
mov eax, dword [ebx + 0x18]
mov dword [ebp + 8], edx
mov dword [ebp - 4], eax
jne 0x42c698
lea ecx, [edx + 0x1cb4]
push edi
lea edi, [edx + 0x1eb4]
mov eax, ecx
mov dword [edi], ecx
cmp ecx, edi
jae 0x42c570
lea eax, [ecx + 1]
mov byte [ecx], 0xff
mov dword [edi], eax
cmp eax, edi
jae 0x42c584
mov byte [eax], 0xfa
inc dword [edi]
mov eax, dword [edi]
cmp eax, edi
jae 0x42c584
mov byte [eax], 0x1f
inc dword [edi]
movzx eax, word [edx + 0x1ca8]
push esi
mov esi, dword [sym.imp.WS2_32.dll_htons]
push eax
call esi
mov ecx, dword [ebp + 8]
mov dword [ebp + 0xc], eax
shr eax, 8
mov dword [ebp - 8], eax
movzx ecx, word [ecx + 0x1caa]
push ecx
call esi
mov ecx, dword [edi]
mov edx, eax
shr edx, 8
mov dword [ebp - 0xc], eax
cmp ecx, edi
jae 0x42c5fb
mov eax, dword [ebp + 0xc]
mov byte [ecx], al
inc dword [edi]
mov ecx, dword [edi]
cmp ecx, edi
jae 0x42c5fb
mov eax, dword [ebp - 8]
mov byte [ecx], al
inc dword [edi]
mov ecx, dword [edi]
cmp ecx, edi
jae 0x42c5fb
mov eax, dword [ebp - 0xc]
mov byte [ecx], al
inc dword [edi]
mov ecx, dword [edi]
cmp ecx, edi
jae 0x42c5fb
mov byte [ecx], dl
inc dword [edi]
mov ecx, dword [edi]
cmp ecx, edi
jae 0x42c5fb
mov byte [ecx], 0xff
inc dword [edi]
mov ecx, dword [edi]
cmp ecx, edi
jae 0x42c5fb
mov byte [ecx], 0xf0
mov ecx, dword [edi]
inc ecx
mov eax, dword [ebp + 8]
lea esi, [eax + 0x1cb4]
mov dword [eax + 0x1eb8], ecx
sub ecx, esi
mov dword [edi], esi
sub ecx, 2
add eax, 0x1cb6
push ecx
push eax
push 0x3e
push ebx
call fcn.0042bd60
mov eax, dword [ebp - 4]
add esp, 0x10
push 0
push 3
push esi
push dword [eax + 0x128]
call dword [sym.imp.WS2_32.dll_send]
mov edi, dword [sym.imp.WS2_32.dll_WSAGetLastError]
test eax, eax
jns 0x42c652
call edi
push eax
push str.Sending_data_failed___d_
push ebx
call fcn.0040fac0
add esp, 0xc
mov esi, dword [ebp + 8]
push 4
lea eax, [esi + 0x1cb7]
push eax
push ebx
call fcn.0042c410
add esp, 0xc
lea eax, [esi + 0x1cbb]
push 0
push 2
push eax
mov eax, dword [ebp - 4]
push dword [eax + 0x128]
call dword [sym.imp.WS2_32.dll_send]
pop esi
test eax, eax
jns 0x42c697
call edi
push eax
push str.Sending_data_failed___d_
push ebx
call fcn.0040fac0
add esp, 0xc
pop edi
pop ebx
mov esp, ebp
pop ebp
ret