joyce8/EMBER2024-capa huggingface dataset:
Function at 0x416676
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
push ebx
push esi
mov esi, dword [ebp + 8]
mov ebx, dword [esi + 8]
test bl, 3
jne 0x4166a4
mov eax, dword fs:[0x18]
mov dword [ebp + 8], eax
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 8]
cmp ebx, ecx
mov dword [ebp - 4], ecx
jb 0x4166ab
cmp ebx, dword [eax + 4]
jae 0x4166ab
xor eax, eax
jmp 0x41689b
push edi
mov edi, dword [esi + 0xc]
cmp edi, 0xffffffff
jne 0x4166bc
xor eax, eax
inc eax
jmp 0x41689a
xor edx, edx
mov dword [ebp + 8], edx
mov eax, ebx
mov ecx, dword [eax]
cmp ecx, 0xffffffff
je 0x4166d2
cmp ecx, edx
jae 0x416817
cmp dword [eax + 4], 0
je 0x4166db
inc dword [ebp + 8]
inc edx
add eax, 0xc
cmp edx, edi
jbe 0x4166c3
cmp dword [ebp + 8], 0
je 0x4166fd
mov eax, dword [esi - 8]
cmp eax, dword [ebp - 4]
jb 0x416817
cmp eax, esi
jae 0x416817
mov eax, dword [0x43ada0]
mov edi, ebx
and edi, 0xfffff000
xor esi, esi
test eax, eax
jle 0x416722
cmp dword [esi*4 + 0x43ada8], edi
je 0x41681b
inc esi
cmp esi, eax
jl 0x416710
push 0x1c
lea eax, [ebp - 0x20]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x416897
cmp dword [ebp - 8], 0x1000000
jne 0x416897
test byte [ebp - 0xc], 0xcc
je 0x4167a0
mov ecx, dword [ebp - 0x1c]
cmp word [ecx], 0x5a4d
jne 0x416897
mov eax, dword [ecx + 0x3c]
add eax, ecx
cmp dword [eax], 0x4550
jne 0x416897
cmp word [eax + 0x18], 0x10b
jne 0x416897
sub ebx, ecx
cmp word [eax + 6], 0
movzx ecx, word [eax + 0x14]
lea ecx, [ecx + eax + 0x18]
jbe 0x416897
mov eax, dword [ecx + 0xc]
cmp ebx, eax
jb 0x4167a0
mov edx, dword [ecx + 8]
add edx, eax
cmp ebx, edx
jae 0x4167a0
test byte [ecx + 0x27], 0x80
jne 0x416817
push 1
push 0x43ade8
call dword [sym.imp.KERNEL32.dll_InterlockedExchange]
test eax, eax
jne 0x4166b4
mov ecx, dword [0x43ada0]
test ecx, ecx
mov edx, ecx
jle 0x4167d4
lea eax, [ecx*4 + 0x43ada4]
cmp dword [eax], edi
je 0x4167d4
dec edx
sub eax, 4
test edx, edx
jg 0x4167c8
test edx, edx
jne 0x416805
push 0xf
pop ebx
cmp ecx, ebx
jg 0x4167e1
mov ebx, ecx
xor edx, edx
test ebx, ebx
jl 0x4167f9
lea eax, [edx*4 + 0x43ada8]
mov esi, dword [eax]
inc edx
cmp edx, ebx
mov dword [eax], edi
mov edi, esi
jle 0x4167e7
cmp ecx, 0x10
jge 0x416805
inc ecx
mov dword [0x43ada0], ecx
push 0
push 0x43ade8
call dword [sym.imp.KERNEL32.dll_InterlockedExchange]
jmp 0x4166b4
xor eax, eax
jmp 0x41689a
test esi, esi
jle 0x4166b4
mov ebx, dword [sym.imp.KERNEL32.dll_InterlockedExchange]
push 1
push 0x43ade8
call ebx
test eax, eax
jne 0x4166b4
cmp dword [esi*4 + 0x43ada8], edi
je 0x416871
mov eax, dword [0x43ada0]
lea esi, [eax - 1]
test esi, esi
jl 0x41685f
cmp dword [esi*4 + 0x43ada8], edi
je 0x41685b
dec esi
jns 0x41684f
test esi, esi
jge 0x41686f
cmp eax, 0x10
jge 0x41686a
inc eax
mov dword [0x43ada0], eax
lea esi, [eax - 1]
jmp 0x416871
je 0x416889
xor ecx, ecx
test esi, esi
jl 0x416889
lea eax, [ecx*4 + 0x43ada8]
mov edx, dword [eax]
inc ecx
cmp ecx, esi
mov dword [eax], edi
mov edi, edx
jle 0x416877
push 0
push 0x43ade8
call ebx
jmp 0x4166b4
or eax, 0xffffffff
pop edi
pop esi
pop ebx
leave
ret
Function at 0x417207
Capabilities:
Link many functions at runtime

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
xor ebx, ebx
cmp dword [0x43adf4], ebx
push esi
push edi
jne 0x417287
push str.user32.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
cmp edi, ebx
je 0x4172c2
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x42f15c
push edi
call esi
test eax, eax
mov dword [0x43adf4], eax
je 0x4172c2
push 0x42f14c
push edi
call esi
push 0x42f138
push edi
mov dword [0x43adf8], eax
call esi
cmp dword [0x43a6c4], 2
mov dword [0x43adfc], eax
jne 0x417287
push str.GetUserObjectInformationA
push edi
call esi
test eax, eax
mov dword [0x43ae04], eax
je 0x417287
push str.GetProcessWindowStation
push edi
call esi
mov dword [0x43ae00], eax
mov eax, dword [0x43ae00]
test eax, eax
je 0x4172cc
call eax
test eax, eax
je 0x4172b3
lea ecx, [ebp - 4]
push ecx
push 0xc
lea ecx, [ebp - 0x10]
push ecx
push 1
push eax
call dword [0x43ae04]
test eax, eax
je 0x4172b3
test byte [ebp - 8], 1
jne 0x4172cc
cmp dword [0x43a6d0], 4
jb 0x4172c6
or byte [ebp + 0x12], 0x20
jmp 0x4172eb
xor eax, eax
jmp 0x4172fb
or byte [ebp + 0x12], 4
jmp 0x4172eb
mov eax, dword [0x43adf8]
test eax, eax
je 0x4172eb
call eax
mov ebx, eax
test ebx, ebx
je 0x4172eb
mov eax, dword [0x43adfc]
test eax, eax
je 0x4172eb
push ebx
call eax
mov ebx, eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
push ebx
call dword [0x43adf4]
pop edi
pop esi
pop ebx
leave
ret
Function at 0x41840c
Capabilities:
Clear file content

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
push esi
push 1
xor esi, esi
push esi
push dword [ebp + 8]
call fcn.00416daa
or ebx, 0xffffffff
add esp, 0xc
cmp eax, ebx
mov dword [ebp - 0xc], eax
je 0x418551
push 2
push esi
push dword [ebp + 8]
call fcn.00416daa
add esp, 0xc
cmp eax, ebx
je 0x418551
push edi
mov edi, dword [ebp + 0xc]
sub edi, eax
test edi, edi
jle 0x4184f4
mov ebx, 0x1000
push ebx
push 8
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
test eax, eax
mov dword [ebp - 4], eax
jne 0x418485
call fcn.0040f308
mov dword [eax], 0xc
or esi, 0xffffffff
jmp 0x41853c
push 0x8000
push dword [ebp + 8]
call fcn.004190e0
pop ecx
pop ecx
mov dword [ebp - 8], eax
cmp edi, ebx
mov eax, ebx
jge 0x41849f
mov eax, edi
push eax
push dword [ebp - 4]
push dword [ebp + 8]
call fcn.00410c33
add esp, 0xc
cmp eax, 0xffffffff
je 0x4184bb
sub edi, eax
test edi, edi
jg 0x418497
jmp 0x4184d3
call fcn.0040f31b
cmp dword [eax], 5
jne 0x4184d0
call fcn.0040f308
mov dword [eax], 0xd
or esi, 0xffffffff
push dword [ebp - 8]
push dword [ebp + 8]
call fcn.004190e0
pop ecx
pop ecx
push dword [ebp - 4]
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
jmp 0x41853c
jge 0x41853c
push 0
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.00416daa
push dword [ebp + 8]
call fcn.004163b8
add esp, 0x10
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
mov esi, eax
neg esi
sbb esi, esi
neg esi
dec esi
cmp esi, ebx
jne 0x41853c
call fcn.0040f308
mov dword [eax], 0xd
call fcn.0040f31b
mov edi, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [edi], eax
push 0
push dword [ebp - 0xc]
push dword [ebp + 8]
call fcn.00416daa
add esp, 0xc
mov eax, esi
pop edi
jmp 0x418553
mov eax, ebx
pop esi
pop ebx
leave
ret
Function at 0x418557
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
and dword [ebp - 8], 0
cmp dword [ebp + 0x10], 0
push ebx
mov ebx, dword [ebp + 0xc]
push esi
push edi
mov edx, ebx
je 0x41872b
mov eax, dword [ebp + 8]
mov ecx, eax
and eax, 0x1f
sar ecx, 5
lea esi, [eax + eax*8]
lea edi, [ecx*4 + 0x43aec0]
mov eax, dword [edi]
shl esi, 2
add eax, esi
mov cl, byte [eax + 4]
test cl, 2
jne 0x41872b
test cl, 0x48
je 0x4185c2
cmp byte [eax + 5], 0xa
je 0x4185c2
mov eax, dword [edi]
mov al, byte [eax + esi + 5]
dec dword [ebp + 0x10]
mov byte [ebx], al
mov eax, dword [edi]
lea edx, [ebx + 1]
mov dword [ebp - 8], 1
mov byte [eax + esi + 5], 0xa
push 0
lea eax, [ebp - 0xc]
push eax
push dword [ebp + 0x10]
mov eax, dword [edi]
push edx
push dword [eax + esi]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x418614
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 5
pop esi
cmp eax, esi
jne 0x4185fc
call fcn.0040f308
mov dword [eax], 9
call fcn.0040f31b
mov dword [eax], esi
jmp 0x41860c
cmp eax, 0x6d
je 0x41872b
push eax
call fcn.0040f32e
pop ecx
or eax, 0xffffffff
jmp 0x41872d
mov eax, dword [ebp - 0xc]
mov ecx, dword [edi]
add dword [ebp - 8], eax
test byte [ecx + esi + 4], 0x80
je 0x418726
test eax, eax
je 0x41863b
cmp byte [ebx], 0xa
jne 0x41863b
mov eax, ecx
lea eax, [eax + esi + 4]
or byte [eax], 4
jmp 0x418644
mov eax, dword [edi]
lea eax, [eax + esi + 4]
and byte [eax], 0xfb
mov eax, dword [ebp + 0xc]
mov ecx, dword [ebp - 8]
add ecx, eax
cmp eax, ecx
mov dword [ebp + 0x10], eax
mov dword [ebp - 8], ecx
jae 0x418720
mov eax, dword [ebp + 0x10]
mov al, byte [eax]
cmp al, 0x1a
je 0x418710
cmp al, 0xd
je 0x418676
mov byte [ebx], al
inc ebx
inc dword [ebp + 0x10]
jmp 0x418702
dec ecx
cmp dword [ebp + 0x10], ecx
jae 0x418690
mov eax, dword [ebp + 0x10]
inc eax
cmp byte [eax], 0xa
jne 0x41868b
add dword [ebp + 0x10], 2
jmp 0x4186e4
mov dword [ebp + 0x10], eax
jmp 0x4186fe
inc dword [ebp + 0x10]
push 0
lea eax, [ebp - 0xc]
push eax
push 1
lea eax, [ebp - 1]
push eax
mov eax, dword [edi]
push dword [eax + esi]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x4186b8
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x4186fe
cmp dword [ebp - 0xc], 0
je 0x4186fe
mov eax, dword [edi]
test byte [eax + esi + 4], 0x48
je 0x4186d9
mov al, byte [ebp - 1]
cmp al, 0xa
je 0x4186e4
mov byte [ebx], 0xd
mov ecx, dword [edi]
mov byte [ecx + esi + 5], al
jmp 0x418701
cmp ebx, dword [ebp + 0xc]
jne 0x4186e9
cmp byte [ebp - 1], 0xa
jne 0x4186e9
mov byte [ebx], 0xa
jmp 0x418701
push 1
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.00416daa
add esp, 0xc
cmp byte [ebp - 1], 0xa
je 0x418702
mov byte [ebx], 0xd
inc ebx
mov ecx, dword [ebp - 8]
cmp dword [ebp + 0x10], ecx
jb 0x41865a
jmp 0x418720
mov eax, dword [edi]
test byte [eax + esi + 4], 0x40
jne 0x418720
lea esi, [eax + esi + 4]
or byte [esi], 2
sub ebx, dword [ebp + 0xc]
mov dword [ebp - 8], ebx
mov eax, dword [ebp - 8]
jmp 0x41872d
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret
Function at 0x419881
Capabilities:
Set environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
push esi
mov esi, dword [ebp + 8]
xor ebx, ebx
cmp esi, ebx
push edi
mov dword [ebp - 0xc], ebx
je 0x4198e9
push 0x3d
push esi
call fcn.0040df43
cmp eax, ebx
pop ecx
pop ecx
mov dword [ebp - 8], eax
je 0x4198e9
cmp esi, eax
je 0x4198e9
xor ecx, ecx
cmp byte [eax + 1], cl
mov eax, dword [0x43a6e4]
sete cl
cmp eax, dword [0x43a6e8]
mov dword [ebp - 4], ecx
jne 0x4198cf
mov edi, eax
call fcn.00419822
mov dword [0x43a6e4], eax
cmp eax, ebx
jne 0x419928
cmp dword [ebp + 0xc], ebx
je 0x4198f1
cmp dword [0x43a6ec], ebx
je 0x4198f1
call fcn.00419075
test eax, eax
je 0x419928
or eax, 0xffffffff
pop edi
pop esi
pop ebx
leave
ret
cmp dword [ebp - 4], ebx
jne 0x419a2c
push 4
pop ecx
call fcn.00411a6c
cmp eax, ebx
mov dword [0x43a6e4], eax
je 0x4198e9
mov dword [eax], ebx
cmp dword [0x43a6ec], ebx
jne 0x419928
push 4
pop ecx
call fcn.00411a6c
cmp eax, ebx
mov dword [0x43a6ec], eax
je 0x4198e9
mov dword [eax], ebx
mov edi, dword [ebp - 8]
mov ebx, dword [0x43a6e4]
sub edi, esi
push esi
call fcn.004197d5
mov edi, eax
test edi, edi
pop ecx
jl 0x419982
cmp dword [ebx], 0
je 0x419982
lea esi, [ebx + edi*4]
push dword [esi]
call fcn.0040ce27
xor eax, eax
cmp dword [ebp - 4], eax
pop ecx
jne 0x419969
mov eax, dword [ebp + 8]
mov dword [esi], eax
mov esi, eax
jmp 0x4199b6
mov ecx, dword [esi + 4]
mov dword [esi], ecx
inc edi
add esi, 4
cmp dword [esi], eax
jne 0x419960
mov edx, edi
shl edx, 2
mov ecx, ebx
call fcn.00411ae2
test eax, eax
mov esi, dword [ebp + 8]
je 0x4199b6
jmp 0x4199b1
cmp dword [ebp - 4], 0
jne 0x419a25
test edi, edi
jge 0x419992
neg edi
lea edx, [edi*4 + 8]
mov ecx, ebx
call fcn.00411ae2
test eax, eax
je 0x4198e9
lea ecx, [eax + edi*4]
and dword [ecx + 4], 0
mov dword [ecx], esi
mov dword [0x43a6e4], eax
cmp dword [ebp + 0xc], 0
je 0x419a10
mov eax, esi
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4199c1
sub eax, edx
lea ecx, [eax + 2]
call fcn.00411a6c
mov edi, eax
test edi, edi
je 0x419a10
mov ecx, esi
sub eax, esi
mov dl, byte [ecx]
mov byte [eax + ecx], dl
inc ecx
test dl, dl
jne 0x4199dc
mov ecx, dword [ebp - 8]
add eax, ecx
mov ecx, dword [ebp - 4]
mov byte [eax], dl
inc eax
neg ecx
sbb ecx, ecx
not ecx
and ecx, eax
push ecx
push edi
call dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableA]
test eax, eax
jne 0x419a09
or dword [ebp - 0xc], 0xffffffff
push edi
call fcn.0040ce27
pop ecx
cmp dword [ebp - 4], 0
je 0x419a1d
push esi
call fcn.0040ce27
pop ecx
mov eax, dword [ebp - 0xc]
jmp 0x4198ec
push esi
call fcn.0040ce27
pop ecx
xor eax, eax
jmp 0x4198ec
Function at 0x41cb60
Capabilities:
Get graphical window text

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push ebx
push esi
push edi
mov esi, dword [ebp + 0x10]
push 0xf00021
mov edx, dword [esi + 4]
mov ecx, dword [esi]
mov eax, dword [esi + 0xc]
sub eax, edx
push eax
mov eax, dword [esi + 8]
sub eax, ecx
push eax
push edx
push ecx
mov ecx, dword [ebp + 0xc]
push ecx
call dword [sym.imp.GDI32.dll_PatBlt]
mov edi, dword [ebp + 8]
push edi
call dword [sym.imp.USER32.dll_GetWindowTextLengthA]
mov ebx, eax
lea eax, [eax + 5]
add eax, 3
and eax, 0xfffffffc
call fcn.0040cf60
mov dword [ebp - 4], esp
cmp dword [ebp - 4], 0
je 0x41cc2b
add ebx, 2
mov eax, dword [ebp - 4]
push ebx
push eax
push edi
call dword [sym.imp.USER32.dll_GetWindowTextA]
test eax, eax
je 0x41cc2b
mov bx, 0x140
mov edi, dword [ebp + 0x14]
mov eax, edi
and al, 0xf
cmp al, 0xc
je 0x41cbde
mov ebx, edi
and bx, 0xf
or bx, 0x150
test edi, 0x80
je 0x41cbe9
or bh, 8
and edi, 0x8000000
je 0x41cc04
mov eax, dword [0x43c2bc]
mov ecx, dword [ebp + 0xc]
push eax
push ecx
call dword [sym.imp.GDI32.dll_SetTextColor]
mov dword [ebp - 8], eax
mov ecx, dword [ebp - 4]
mov edx, dword [ebp + 0xc]
movzx eax, bx
push eax
push esi
push 0xffffffffffffffff
push ecx
push edx
call dword [sym.imp.USER32.dll_DrawTextA]
test edi, edi
je 0x41cc2b
mov eax, dword [ebp - 8]
mov ecx, dword [ebp + 0xc]
push eax
push ecx
call dword [sym.imp.GDI32.dll_SetTextColor]
lea esp, [ebp - 0x14]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x41d000
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov eax, dword [esp + 8]
sub esp, 4
push ebx
push esi
mov esi, dword [esp + 0x10]
push edi
push ebp
push 2
push eax
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
mov edi, eax
test edi, edi
jne 0x41d02b
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret 0x20
push edi
push esi
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov ebx, eax
push edi
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov esi, eax
test esi, esi
jne 0x41d04f
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret 0x20
push ebx
push 0x40
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov ebp, eax
test ebp, ebp
jne 0x41d06a
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret 0x20
mov edi, ebp
mov ecx, ebx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov eax, dword [esp + 0x20]
xor ecx, ecx
mov cl, ah
mov edx, eax
mov dword [esp + 0x10], 0
shl ecx, 8
shr edx, 0x10
mov byte [esp + 0x10], dl
xor edx, edx
or ecx, dword [esp + 0x10]
mov dl, al
shl edx, 0x10
mov eax, dword [esp + 0x28]
or ecx, edx
mov edx, eax
shr edx, 0x10
mov dword [ebp + 0x28], ecx
mov dword [esp + 0x10], 0
xor ecx, ecx
mov byte [esp + 0x10], dl
mov cl, ah
xor edx, edx
shl ecx, 8
mov dl, al
shl edx, 0x10
or ecx, dword [esp + 0x10]
or ecx, edx
mov eax, dword [esp + 0x24]
mov edx, eax
mov dword [ebp + 0x44], ecx
shr edx, 0x10
xor ecx, ecx
mov dword [esp + 0x10], 0
mov cl, ah
mov byte [esp + 0x10], dl
shl ecx, 8
xor edx, edx
or ecx, dword [esp + 0x10]
mov dl, al
shl edx, 0x10
mov eax, dword [esp + 0x2c]
or ecx, edx
xor edx, edx
mov dl, al
mov dword [ebp + 0x48], ecx
shl edx, 0x10
xor ecx, ecx
mov cl, ah
shl ecx, 8
shr eax, 0x10
or ecx, edx
xor edx, edx
mov dl, al
mov eax, dword [esp + 0x30]
or ecx, edx
xor edx, edx
mov dl, al
mov dword [ebp + 0x64], ecx
shl edx, 0x10
xor ecx, ecx
mov cl, ah
shl ecx, 8
shr eax, 0x10
or ecx, edx
xor edx, edx
mov dl, al
mov eax, dword [esp + 0x34]
or ecx, edx
xor edx, edx
mov dl, al
mov dword [ebp + 0x54], ecx
shl edx, 0x10
xor ecx, ecx
mov cl, ah
shl ecx, 8
push 0
shr eax, 0x10
or ecx, edx
xor edx, edx
mov dl, al
or ecx, edx
mov dword [ebp + 0x50], ecx
call dword [sym.imp.USER32.dll_GetDC]
mov edi, eax
push 0
push ebp
lea ecx, [ebp + 0x68]
push ecx
push 4
push ebp
push edi
call dword [sym.imp.GDI32.dll_CreateDIBitmap]
mov esi, eax
push edi
push 0
call dword [sym.imp.USER32.dll_ReleaseDC]
push ebp
call dword [sym.imp.KERNEL32.dll_GlobalFree]
mov eax, esi
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret 0x20
Function at 0x420f9f
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 0x420fe1
call fcn.00426c67
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 0x420fe1
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
cmp eax, edi
jne 0x420fd8
xor eax, eax
jmp 0x420fe9
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov edi, eax
push edi
mov ecx, ebx
call fcn.00420fef
pop edi
pop esi
pop ebx
ret 4

Function at 0x427496
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 0x4274c4
push dword [esi]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x4274e2
push dword [esp + 0xc]
mov ecx, esi
push eax
call fcn.004273fc
jmp 0x4274e2
mov eax, dword [esi + 0x14]
test eax, eax
je 0x4274e2
push edi
push dword [esp + 0x10]
mov edi, dword [eax + 4]
mov ecx, esi
push eax
call fcn.004273fc
test edi, edi
mov eax, edi
jne 0x4274cc
pop edi
push ebx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop esi
pop ebx
ret 8
Function at 0x4016f0
Capabilities:
Create udp socket
Set socket configuration

Disassembly:
push 0xffffffffffffffff
push 0x4385e8
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x18
push esi
push edi
push 0
push 2
push 2
mov dword [esp + 0x34], 0
call sub.WSOCK32.dll_socket
mov esi, dword [esp + 0x30]
cmp eax, 0xffffffff
mov dword [esi], eax
jne 0x40173d
mov dword [esi], 0
call sub.WSOCK32.dll_WSAGetLastError
mov edi, eax
test edi, edi
jne 0x4017ce
mov eax, dword [esp + 0x34]
mov dword [esp + 0x14], 0
push eax
mov word [esp + 0x14], 2
call sub.WSOCK32.dll_htons
mov edx, dword [esi]
lea ecx, [esp + 0x10]
push 0x10
push ecx
push edx
mov word [esp + 0x1e], ax
call sub.WSOCK32.dll_bind
cmp eax, 0xffffffff
jne 0x401782
call sub.WSOCK32.dll_WSAGetLastError
push 0
push 0
push 0x44a1ac
call fcn.00433bc5
mov ecx, dword [esi]
lea eax, [esp + 0x30]
push 4
push eax
push 0x20
push 0xffff
push ecx
mov dword [esp + 0x44], 1
call sub.WSOCK32.dll_setsockopt
cmp eax, 0xffffffff
jne 0x4017aa
call sub.WSOCK32.dll_WSAGetLastError
mov eax, dword [esi]
lea edx, [esp + 0x30]
push 4
push edx
push 4
push 0xffff
push eax
call sub.WSOCK32.dll_setsockopt
mov edi, eax
cmp edi, 0xffffffff
jne 0x4017ce
call sub.WSOCK32.dll_WSAGetLastError
mov edi, eax
mov eax, dword [esp + 0x38]
test eax, eax
jne 0x401804
mov ecx, dword [esp + 0x3c]
push ecx
call sub.WSOCK32.dll_inet_addr
push 0
mov dword [esp + 0xc], eax
call sub.WSOCK32.dll_htonl
lea edx, [esp + 8]
push 8
mov dword [esp + 0x10], eax
mov eax, dword [esi]
push edx
push 5
push 0
push eax
call sub.WSOCK32.dll_setsockopt
mov edi, eax
lea ecx, [esp + 0x3c]
mov dword [esp + 0x28], 0xffffffff
call fcn.0042f983
mov ecx, dword [esp + 0x20]
mov eax, edi
pop edi
pop esi
mov dword fs:[0], ecx
add esp, 0x24
ret

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

Disassembly:
sub esp, 0x10
xor eax, eax
mov ecx, dword [esp + 0x1c]
mov dword [esp], eax
push esi
mov dword [esp + 8], eax
push edi
mov edi, dword [esp + 0x20]
mov dx, word [esp + 0x28]
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], ecx
mov ecx, dword [esp + 0x2c]
mov dword [esp + 0x14], eax
mov ax, word [edi + 5]
mov word [esp + 8], 2
mov esi, eax
mov word [esp + 0xa], dx
and esi, 0xffff
test ecx, ecx
je 0x401cb7
push edi
call fcn.00401830
add esp, 4
test al, al
je 0x401cac
mov ecx, dword [esp + 0x1c]
lea eax, [esp + 8]
push 0x10
push eax
mov edx, dword [ecx]
push 0
push esi
push edi
push edx
call sub.WSOCK32.dll_sendto
cmp eax, 0xffffffff
jne 0x401ced
call sub.WSOCK32.dll_WSAGetLastError
pop edi
pop esi
add esp, 0x10
ret
pop edi
mov eax, 0xfffffffe
pop esi
add esp, 0x10
ret
push eax
call sub.WSOCK32.dll_htons
mov ecx, dword [esp + 0x1c]
mov si, ax
lea eax, [esp + 8]
push 0x10
mov edx, dword [ecx]
and esi, 0xffff
push eax
push 0
push esi
push edi
push edx
call sub.WSOCK32.dll_sendto
cmp eax, 0xffffffff
jne 0x401ced
call sub.WSOCK32.dll_WSAGetLastError
pop edi
pop esi
add esp, 0x10
ret
sub eax, esi
pop edi
neg eax
sbb eax, eax
pop esi
add esp, 0x10
ret
Function at 0x401d00
Capabilities:
Set socket configuration

Disassembly:
push esi
push 0xe
call fcn.0041b20f
mov esi, eax
add esp, 4
mov byte [esi + 2], 1
mov word [esi], 0x100
mov word [esi + 5], 0xe
mov ax, word [0x44a234]
mov word [esi + 3], ax
mov ax, word [0x44a234]
inc ax
cmp ax, 0x8000
mov word [0x44a234], ax
jne 0x401d43
mov word [0x44a234], 1
push str.255.255.255.255
call sub.WSOCK32.dll_inet_addr
push 1
push 0x1587
mov dword [esi + 7], eax
mov word [esi + 0xb], 0xffff
mov byte [esi + 0xd], 0
call sub.WSOCK32.dll_htons
push eax
push str.255.255.255.255
call sub.WSOCK32.dll_inet_addr
push eax
lea ecx, [esp + 0x14]
push esi
push ecx
call fcn.00401c30
push esi
call fcn.0041b1c7
add esp, 0x18
xor eax, eax
pop esi
ret

Function at 0x401e20
Capabilities:
Get hostname
Initialize winsock library
Resolve dns
Set socket configuration

Disassembly:
push 0xffffffffffffffff
push 0x438616
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x200
mov eax, dword [0x44abb4]
push esi
push edi
mov dword [esp + 0xc], eax
mov ecx, 0x19
xor eax, eax
lea edi, [esp + 0x14]
mov dword [esp + 0x210], 0
rep stosd dword es:[edi], eax
lea ecx, [esp + 0x78]
push ecx
push 0x202
call sub.WSOCK32.dll_WSAStartup
mov esi, eax
test esi, esi
je 0x401ea0
lea ecx, [esp + 0xc]
mov dword [esp + 0x210], 0xffffffff
call fcn.0042f983
mov eax, esi
pop edi
pop esi
mov ecx, dword [esp + 0x200]
mov dword fs:[0], ecx
add esp, 0x20c
ret
mov ax, word [esp + 0x78]
cmp al, 2
jne 0x401f97
xor edx, edx
mov dl, ah
cmp dl, al
jne 0x401f97
push ebp
lea eax, [esp + 0x18]
push 0x64
push eax
call sub.WSOCK32.dll_gethostname
test eax, eax
mov dword [esp + 0x14], eax
jne 0x401f5e
lea ecx, [esp + 0x18]
push ecx
call sub.WSOCK32.dll_gethostbyname
mov ebp, eax
test ebp, ebp
je 0x401f5e
mov edx, dword [0x44abb4]
xor esi, esi
mov dword [esp + 0xc], edx
mov eax, dword [ebp + 0xc]
mov byte [esp + 0x214], 1
cmp dword [eax], 0
je 0x401f4b
xor ecx, ecx
mov eax, dword [eax + ecx]
mov eax, dword [eax]
push eax
call sub.WSOCK32.dll_inet_ntoa
push eax
lea ecx, [esp + 0x10]
call fcn.0042fb0c
mov ecx, dword [esp + 0xc]
push ecx
call sub.WSOCK32.dll_inet_addr
test esi, esi
mov edi, eax
jne 0x401f39
lea edx, [esp + 0xc]
lea ecx, [esp + 0x10]
push edx
call fcn.0042fabc
mov dword [0x44cfdc], edi
mov eax, dword [ebp + 0xc]
inc esi
mov edx, dword [eax + esi*4]
lea ecx, [esi*4]
test edx, edx
jne 0x401f00
lea ecx, [esp + 0xc]
mov byte [esp + 0x214], 0
call fcn.0042f983
jmp 0x401f67
call sub.WSOCK32.dll_WSAGetLastError
mov dword [esp + 0x14], eax
lea ecx, [esp + 0x10]
mov dword [esp + 0x214], 0xffffffff
call fcn.0042f983
mov eax, dword [esp + 0x14]
pop ebp
pop edi
pop esi
mov ecx, dword [esp + 0x200]
mov dword fs:[0], ecx
add esp, 0x20c
ret
call sub.WSOCK32.dll_WSACleanup
lea ecx, [esp + 0xc]
mov dword [esp + 0x210], 0xffffffff
call fcn.0042f983
mov ecx, dword [esp + 0x208]
pop edi
or eax, 0xffffffff
pop esi
mov dword fs:[0], ecx
add esp, 0x20c
ret