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

Disassembly:
sub esp, 8
mov eax, dword [esp + 0x10]
push edi
push 0
push 0x20
push 2
push 0
push 0
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
xor eax, eax
cmp edi, 0xffffffff
je 0x48e452
mov eax, dword [esp + 0x10]
push ebx
mov ebx, 1
push ebp
cmp eax, ebx
push esi
mov dword [esp + 0x10], ebx
jle 0x48e444
mov ebp, dword [sym.imp.KERNEL32.dll_WriteFile]
lea esi, [esp + 0x2c]
mov eax, dword [esi]
lea edx, [esp + 0x14]
push 0
push edx
lea ecx, [eax + 8]
mov eax, dword [eax + 4]
push eax
push ecx
push edi
call ebp
test eax, eax
je 0x48e43c
mov eax, dword [esp + 0x1c]
inc ebx
add esi, 0xc
cmp ebx, eax
jl 0x48e405
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esp + 0x10]
pop esi
pop ebp
pop ebx
pop edi
add esp, 8
ret
mov dword [esp + 0x10], 0
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esp + 0x10]
pop esi
pop ebp
pop ebx
pop edi
add esp, 8
ret

Function at 0x48e460
Capabilities:
Create process on windows

Disassembly:
sub esp, 0x54
push esi
lea eax, [esp + 0x14]
push edi
push eax
mov dword [esp + 0x1c], 0x44
call dword [sym.imp.KERNEL32.dll_GetStartupInfoA]
mov eax, dword [esp + 0x84]
xor edi, edi
cmp eax, edi
mov dword [esp + 0x54], edi
mov dword [esp + 0x58], edi
mov dword [esp + 0x44], 1
je case.0x48e4a1.2
mov ecx, dword [esp + 0x7c]
lea eax, [ecx - 1]
cmp eax, 5
ja case.0x48e4a1.2
jmp dword [eax*4 + 0x48e52c]
mov word [esp + 0x48], di
jmp 0x48e4da
mov word [esp + 0x48], 2
jmp 0x48e4da
mov word [esp + 0x48], 3
jmp 0x48e4da
mov word [esp + 0x48], 4
jmp 0x48e4da
mov word [esp + 0x48], 7
jmp 0x48e4da
mov word [esp + 0x48], 5
lea edx, [esp + 8]
mov ecx, dword [esp + 0x64]
lea eax, [esp + 0x18]
push edx
push eax
push edi
push edi
push edi
push 1
push edi
push edi
push ecx
push edi
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
mov esi, eax
cmp esi, edi
je 0x48e524
cmp dword [esp + 0x70], edi
je 0x48e510
mov edx, dword [esp + 8]
push 0xffffffffffffffff
push edx
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov eax, dword [esp + 8]
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
push eax
call edi
mov ecx, dword [esp + 0xc]
push ecx
call edi
mov eax, esi
pop edi
pop esi
add esp, 0x54
ret
Function at 0x48e8f0
Capabilities:
Get file size
Read file on windows

Disassembly:
sub esp, 8
push ebx
mov ebx, dword [esp + 0x14]
push ebp
push esi
test ebx, ebx
push edi
jne 0x48e909
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 8
ret
push ebx
call fcn.00490a90
add esp, 4
test eax, eax
jne 0x48e91e
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
mov edi, dword [esp + 0x34]
test edi, edi
je 0x48e938
mov eax, dword [esp + 0x2c]
test eax, eax
jg 0x48e938
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 8
ret
mov eax, dword [ebx]
xor esi, esi
cmp eax, 1
jne 0x48ea20
mov ebp, dword [ebx + 4]
mov edi, dword [sym.imp.KERNEL32.dll_SetFilePointer]
push eax
push esi
push esi
push ebp
call edi
mov ebx, eax
cmp ebx, 0xffffffff
mov dword [esp + 0x14], ebx
jne 0x48e970
push 2
push esi
push esi
push ebp
call edi
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 8
ret
mov eax, dword [esp + 0x34]
test eax, eax
jne 0x48e987
push 0
push ebp
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
sub esi, ebx
jmp 0x48e98b
mov esi, dword [esp + 0x2c]
push esi
call fcn.004be7a2
add esp, 4
mov ebx, eax
lea eax, [esp + 0x10]
push 0
push eax
push esi
push ebx
push ebp
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x48e9c4
push 2
push eax
push eax
push ebp
call edi
push ebx
call fcn.004be7cb
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
mov edx, dword [esp + 0x10]
xor edi, edi
test edx, edx
mov ecx, ebx
jbe 0x48e9e0
mov al, byte [ecx]
test al, al
je 0x48e9e0
cmp al, 0x1a
je 0x48e9e0
inc edi
inc ecx
cmp edi, edx
jb 0x48e9d0
lea ecx, [edi + 1]
push ecx
call fcn.00489540
mov edx, dword [esp + 0x18]
add esp, 4
mov esi, eax
push 0
lea eax, [edi + edx]
push 0
push eax
push ebp
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push edi
push ebx
push esi
call fcn.004ae650
push ebx
mov byte [edi + esi], 0
call fcn.004be7cb
add esp, 0x10
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
cmp eax, 2
jne 0x48ea9b
mov ebx, dword [ebx + 4]
mov ecx, ebx
mov edx, dword [ebx]
call dword [edx + 0x14]
test edi, edi
mov ebp, eax
jne 0x48ea3a
or eax, 0xffffffff
jmp 0x48ea3e
mov eax, dword [esp + 0x2c]
mov edx, dword [ebx]
lea ecx, [esp + 0x14]
push ecx
lea ecx, [esp + 0x14]
push ecx
push eax
push 0
mov ecx, ebx
call dword [edx + 0x30]
mov edx, dword [esp + 0x10]
xor edi, edi
test eax, eax
jbe 0x48ea6d
mov cl, byte [edx]
test cl, cl
je 0x48ea6d
cmp cl, 0x1a
je 0x48ea6d
inc edi
inc edx
cmp edi, eax
jb 0x48ea5c
lea edx, [edi + 1]
push edx
call fcn.00489540
add esp, 4
lea ecx, [edi + ebp]
mov esi, eax
mov eax, dword [ebx]
push 0
push ecx
mov ecx, ebx
call dword [eax + 0x18]
mov edx, dword [esp + 0x10]
push edi
push edx
push esi
call fcn.004ae650
add esp, 0xc
mov byte [edi + esi], 0
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
Function at 0x48ec10
Capabilities:
Query or enumerate registry value

Disassembly:
sub esp, 0x14
mov eax, dword [esp + 0x1c]
push ebp
push esi
push edi
push eax
call fcn.00490080
mov esi, dword [esp + 0x38]
mov ebp, eax
xor edx, edx
mov edi, esi
or ecx, 0xffffffff
xor eax, eax
add esp, 4
mov dword [esp + 0xc], edx
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp ebp, edx
mov dword [esp + 0x18], edx
je 0x48ecf7
cmp ecx, edx
je 0x48ecf7
inc ecx
push ebx
push ecx
call fcn.004be7a2
mov ebx, eax
mov edi, esi
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push 0x5c
mov edx, ecx
mov esi, edi
mov edi, ebx
push ebx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
call fcn.004ae450
mov esi, eax
add esp, 0xc
test esi, esi
je 0x48ec8d
mov byte [esi], 0
inc esi
lea eax, [esp + 0x18]
push eax
push ebx
push ebp
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
test eax, eax
jne 0x48ece5
lea ecx, [esp + 0x20]
lea edx, [esp + 0x10]
push ecx
mov ecx, dword [esp + 0x1c]
lea eax, [esp + 0x18]
push edx
push eax
push 0
mov edi, 4
push esi
push ecx
mov dword [esp + 0x38], edi
mov dword [esp + 0x2c], edi
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x48ecda
cmp dword [esp + 0x14], edi
jne 0x48ecda
mov dword [esp + 0x1c], 1
mov edx, dword [esp + 0x18]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push ebx
call fcn.004be7cb
mov eax, dword [esp + 0x20]
add esp, 4
test eax, eax
pop ebx
jne 0x48ed03
mov eax, dword [esp + 0x48]
test eax, eax
mov eax, dword [esp + 0x40]
jne 0x48ed07
mov eax, dword [esp + 0xc]
pop edi
pop esi
pop ebp
add esp, 0x14
ret

Function at 0x4912e0
Capabilities:
Check for time delay via gettickcount

Disassembly:
sub esp, 0xa0
push ebx
push ebp
mov ebp, dword [esp + 0xac]
push esi
push edi
push ebp
call sub.RASAPI32.dll_RasHangUpA
mov esi, dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ecx, 0x28
xor eax, eax
lea edi, [esp + 0x10]
rep stosd dword es:[edi], eax
mov dword [esp + 0x10], 0xa0
call esi
mov edi, eax
call esi
sub eax, edi
cmp eax, 0xbb8
jae 0x491346
mov ebx, dword [sym.imp.KERNEL32.dll_Sleep]
lea eax, [esp + 0x10]
push eax
push ebp
call sub.RASAPI32.dll_RasGetConnectStatusA
cmp eax, 6
je 0x491346
push 0
call ebx
call esi
sub eax, edi
cmp eax, 0xbb8
jb 0x491327
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xa0
ret

Function at 0x4916d0
Capabilities:
Create http request

Disassembly:
push esi
mov esi, ecx
cmp dword [esi], 0
jne 0x491708
mov edx, dword [esi + 4]
xor eax, eax
push 0
push 0
mov ecx, dword [edx - 8]
test ecx, ecx
setne al
mov ecx, eax
neg ecx
sbb ecx, ecx
and ecx, edx
neg eax
sbb eax, eax
push ecx
and eax, 2
inc eax
push eax
push str.Mozilla_4.0__compatible__MSIE_6.0__Windows_NT_5.0_
call dword [sym.imp.WININET.dll_InternetOpenA]
mov dword [esi], eax
mov ecx, dword [esi]
xor eax, eax
test ecx, ecx
setne al
pop esi
ret
Function at 0x4923f0
Capabilities:
Get socket status

Disassembly:
sub esp, 0x10c
mov eax, dword [ecx]
lea ecx, [esp]
push ecx
push 0
lea edx, [esp + 0x10]
push 0
push edx
push 0
mov dword [esp + 0x14], 0
mov dword [esp + 0x18], 0
mov dword [esp + 0x20], eax
mov dword [esp + 0x1c], 1
call sub.WSOCK32.dll_select
cmp eax, 0xffffffff
jne 0x492439
xor eax, eax
add esp, 0x10c
ret 4
mov edx, dword [esp + 0x110]
xor ecx, ecx
test eax, eax
setne cl
mov dword [edx], ecx
mov eax, 1
add esp, 0x10c
ret 4

Function at 0x4928b0
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x4c6ae0
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 8
push esi
mov esi, ecx
lea ecx, [esp + 4]
call fcn.00492460
lea eax, [esp + 4]
lea ecx, [esi + 4]
push eax
mov dword [esp + 0x18], 0
call fcn.004924e0
lea ecx, [esp + 4]
push ecx
lea ecx, [esi + 0x14]
call fcn.004924e0
lea ecx, [esi + 0xc]
call fcn.004be9ec
lea ecx, [esi + 0x10]
call fcn.004be9ec
push 0xffffffffffffffff
push 0
lea ecx, [esi + 0x1c]
call fcn.00493a70
push 0xffffffffffffffff
push 0
lea ecx, [esi + 0x30]
call fcn.00493a70
push 0xffffffffffffffff
push 0
lea ecx, [esi + 0x44]
call fcn.00493a70
lea ecx, [esp + 8]
mov dword [esp + 0x14], 1
call fcn.004bea61
lea ecx, [esp + 4]
mov dword [esp + 0x14], 0xffffffff
call fcn.004bea61
mov ecx, dword [esp + 0xc]
pop esi
mov dword fs:[0], ecx
add esp, 0x14
ret
Function at 0x494320
Capabilities:
Get file size
Parse pe header
Read file on windows

Disassembly:
sub esp, 0x44
lea eax, [esp + 0x10]
push esi
mov esi, dword [esp + 0x4c]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetFileInformationByHandle]
test eax, eax
jne 0x494342
mov eax, 0x200
pop esi
add esp, 0x44
ret
mov eax, dword [esp + 0x14]
push ebp
mov edx, eax
xor ebp, ebp
and edx, 1
je 0x494355
mov ebp, 1
test al, 2
je 0x49435c
or ebp, 2
test al, 4
je 0x494363
or ebp, 4
mov ecx, eax
and ecx, 0x10
je 0x49436d
or ebp, 0x10
test al, 0x20
je 0x494374
or ebp, 0x20
test ecx, ecx
je 0x494380
or ebp, 0x40000000
jmp 0x494386
or ebp, 0x80000000
or ebp, 0x1000000
test edx, edx
jne 0x494396
or ebp, 0x800000
push ebx
push edi
push 0
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
cmp eax, 0x28
mov dword [esp + 0x14], eax
jbe 0x494445
mov edi, dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 0
push 0
push 0
push esi
call edi
mov ebx, dword [sym.imp.KERNEL32.dll_ReadFile]
lea ecx, [esp + 0x10]
push 0
push ecx
lea edx, [esp + 0x60]
push 2
push edx
push esi
call ebx
push 0
push 0
push 0x24
push esi
call edi
lea eax, [esp + 0x10]
push 0
push eax
lea ecx, [esp + 0x20]
push 4
push ecx
push esi
call ebx
cmp word [esp + 0x58], 0x54ad
jne 0x494445
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x14]
lea edx, [eax + 0x34]
cmp ecx, edx
jbe 0x494445
push 0
push 0
push eax
push esi
call edi
lea eax, [esp + 0x10]
push 0
push eax
lea ecx, [esp + 0x24]
push 4
push ecx
push esi
call ebx
mov eax, dword [esp + 0x1c]
cmp eax, 0x5a4d
je 0x49443f
cmp eax, 0x454e
je 0x49443f
cmp eax, 0x454c
je 0x49443f
cmp eax, 0x4550
jne 0x494445
or ebp, 0x400000
mov eax, dword [esp + 0x5c]
pop edi
test eax, eax
pop ebx
je 0x494451
mov dword [eax], ebp
mov eax, dword [esp + 0x58]
pop ebp
test eax, eax
je 0x494460
mov edx, dword [esp + 8]
mov dword [eax], edx
mov esi, dword [esp + 0x58]
test esi, esi
je 0x4944a0
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x20]
push eax
push ecx
call fcn.00494280
mov edx, dword [esp + 0x34]
mov dword [esi], eax
mov eax, dword [esp + 0x30]
push edx
push eax
call fcn.00494280
mov ecx, dword [esp + 0x2c]
mov edx, dword [esp + 0x28]
push ecx
push edx
mov dword [esi + 4], eax
call fcn.00494280
add esp, 0x18
mov dword [esi + 8], eax
mov esi, dword [esp + 0x5c]
test esi, esi
je 0x4944df
mov edx, dword [esp + 0x2c]
lea eax, [esp + 0x50]
lea ecx, [esp + 0x4c]
push eax
mov eax, dword [esp + 0x2c]
push ecx
push edx
push eax
call fcn.00494210
mov ecx, dword [esp + 0x5c]
mov edx, dword [esp + 0x60]
and ecx, 0xffff
and edx, 0xffff
shl ecx, 0x10
add esp, 0x10
or ecx, edx
mov dword [esi], ecx
xor eax, eax
pop esi
add esp, 0x44
ret
Function at 0x495c80
Capabilities:
Encode data using xor

Disassembly:
push ebx
mov ebx, dword [esp + 0xc]
push ebp
xor ebp, ebp
push esi
cmp ebx, 1
push edi
jl 0x495c9b
cmp ebx, 8
jg 0x495c9b
mov eax, 1
jmp 0x495c9d
xor eax, eax
mov esi, dword [esp + 0x14]
push str.bad_pack_level
push eax
push esi
call fcn.004944f0
mov eax, dword [esi + 0x6af70]
add esp, 0xc
cmp eax, ebp
mov dword [esi + 0x6af78], ebp
jne 0x495cd4
mov dword [esi + 0x6af78], 1
mov dword [esi + 0x6af70], 0x10000
mov ecx, 0x7fff
xor eax, eax
lea edi, [esi + 0x4af70]
mov dword [esi + 0x6af6c], ebp
rep stosd dword es:[edi], eax
mov ax, word [ebx*8 + 0x4ca2ba]
xor ecx, ecx
mov dword [esi + 0x6af98], eax
mov cx, word [ebx*8 + 0x4ca2b8]
xor edx, edx
mov dword [esi + 0x6af9c], ecx
mov dx, word [ebx*8 + 0x4ca2bc]
xor eax, eax
mov dword [esi + 0x6afa0], edx
mov ax, word [ebx*8 + 0x4ca2be]
cmp ebx, 2
mov dword [esi + 0x6af94], eax
jg 0x495d35
mov eax, dword [esp + 0x1c]
or byte [eax], 4
jmp 0x495d41
cmp ebx, 8
jl 0x495d41
mov eax, dword [esp + 0x1c]
or byte [eax], 2
lea edi, [esi + 0x1af70]
push 0x10000
push edi
push esi
mov dword [esi + 0x6af84], ebp
mov dword [esi + 0x6af74], ebp
call dword [esi + 0xc]
add esp, 0xc
cmp eax, ebp
mov dword [esi + 0x6af90], eax
je 0x495dba
cmp eax, 0xffffffff
je 0x495dba
cmp eax, 0x106
mov dword [esi + 0x6af8c], ebp
jae 0x495d85
push esi
call fcn.00495fd0
add esp, 4
mov dword [esi + 0x6af7c], ebp
xor eax, eax
mov edx, dword [esi + 0x6af7c]
xor ecx, ecx
mov cl, byte [edi + eax]
and edx, 0x3ff
and ecx, 0x7fff
shl edx, 5
xor ecx, edx
inc eax
cmp eax, 2
mov dword [esi + 0x6af7c], ecx
jb 0x495d8d
pop edi
pop esi
pop ebp
pop ebx
ret
mov dword [esi + 0x6af8c], 1
mov dword [esi + 0x6af90], ebp
pop edi
pop esi
pop ebp
pop ebx
ret
Function at 0x497050
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
mov ecx, dword [esp + 8]
test ecx, ecx
jne 0x49705b
xor eax, eax
ret
mov eax, dword [esp + 4]
push ebx
push esi
mov esi, dword [esp + 0x14]
cmp esi, 8
not eax
jb 0x49715e
push edi
mov edi, esi
shr edi, 3
mov edx, eax
xor ebx, ebx
mov bl, byte [ecx]
and edx, 0xff
xor edx, ebx
mov ebx, eax
shr ebx, 8
mov eax, dword [edx*4 + 0x4ca308]
sub esi, 8
xor eax, ebx
inc ecx
mov edx, eax
xor ebx, ebx
mov bl, byte [ecx]
and edx, 0xff
xor edx, ebx
xor ebx, ebx
mov bl, byte [ecx + 1]
mov edx, dword [edx*4 + 0x4ca308]
shr eax, 8
xor edx, eax
inc ecx
mov eax, edx
and eax, 0xff
xor eax, ebx
xor ebx, ebx
mov bl, byte [ecx + 1]
mov eax, dword [eax*4 + 0x4ca308]
shr edx, 8
xor eax, edx
inc ecx
mov edx, eax
and edx, 0xff
xor edx, ebx
xor ebx, ebx
mov bl, byte [ecx + 1]
mov edx, dword [edx*4 + 0x4ca308]
shr eax, 8
xor edx, eax
inc ecx
mov eax, edx
and eax, 0xff
xor eax, ebx
xor ebx, ebx
mov bl, byte [ecx + 1]
mov eax, dword [eax*4 + 0x4ca308]
shr edx, 8
xor eax, edx
inc ecx
mov edx, eax
and edx, 0xff
xor edx, ebx
xor ebx, ebx
mov bl, byte [ecx + 1]
mov edx, dword [edx*4 + 0x4ca308]
shr eax, 8
xor edx, eax
inc ecx
mov eax, edx
and eax, 0xff
xor eax, ebx
xor ebx, ebx
mov bl, byte [ecx + 1]
mov eax, dword [eax*4 + 0x4ca308]
shr edx, 8
xor eax, edx
inc ecx
mov edx, eax
and edx, 0xff
xor edx, ebx
shr eax, 8
mov edx, dword [edx*4 + 0x4ca308]
xor eax, edx
inc ecx
dec edi
jne 0x497076
pop edi
test esi, esi
je 0x497180
mov edx, eax
xor ebx, ebx
mov bl, byte [ecx]
and edx, 0xff
xor edx, ebx
shr eax, 8
mov edx, dword [edx*4 + 0x4ca308]
xor eax, edx
inc ecx
dec esi
jne 0x497162
pop esi
pop ebx
not eax
ret

Function at 0x497190
Capabilities:
Generate random numbers using the delphi lcg
Hash data with crc32

Disassembly:
mov ecx, dword [esp + 4]
push esi
mov esi, dword [esp + 0xc]
mov edx, dword [ecx]
and esi, 0xff
mov eax, edx
and eax, 0xff
xor eax, esi
shr edx, 8
mov eax, dword [eax*4 + 0x4ca308]
xor eax, edx
mov edx, dword [ecx + 4]
mov dword [ecx], eax
and eax, 0xff
add eax, edx
mov edx, dword [ecx + 8]
imul eax, eax, 0x8088405
inc eax
mov esi, edx
mov dword [ecx + 4], eax
and esi, 0xff
shr eax, 0x18
xor eax, esi
pop esi
shr edx, 8
mov eax, dword [eax*4 + 0x4ca308]
xor eax, edx
mov dword [ecx + 8], eax
ret
Function at 0x497530
Capabilities:
Write file on windows

Disassembly:
push ebx
mov ebx, ecx
push ebp
mov ebp, dword [esp + 0x10]
mov al, byte [ebx + 0x2d]
push esi
mov esi, dword [esp + 0x10]
push edi
test al, al
je 0x4975b5
mov eax, dword [ebx + 0x3c]
test eax, eax
je 0x497561
cmp dword [ebx + 0x40], ebp
jae 0x497561
push eax
call fcn.004be7cb
add esp, 4
mov dword [ebx + 0x3c], 0
mov eax, dword [ebx + 0x3c]
test eax, eax
jne 0x49757b
lea eax, [ebp + ebp]
push eax
call fcn.004be7a2
add esp, 4
mov dword [ebx + 0x3c], eax
mov dword [ebx + 0x40], ebp
mov edi, dword [ebx + 0x3c]
mov ecx, ebp
mov edx, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
xor esi, esi
test ebp, ebp
jbe 0x4975b2
lea edi, [ebx + 0x30]
mov eax, dword [ebx + 0x3c]
mov cl, byte [esi + eax]
push ecx
push edi
call fcn.00497210
mov edx, dword [ebx + 0x3c]
add esp, 8
mov byte [esi + edx], al
inc esi
cmp esi, ebp
jb 0x497597
mov esi, dword [ebx + 0x3c]
mov edx, dword [ebx + 0x20]
test edx, edx
je 0x4975fd
mov eax, dword [ebx + 0x24]
mov edi, dword [ebx + 0x28]
lea ecx, [eax + ebp]
cmp ecx, edi
jb 0x4975d9
pop edi
pop esi
mov dword [ebx + 0x14], 0x30000
pop ebp
xor eax, eax
pop ebx
ret 8
mov ecx, ebp
lea edi, [eax + edx]
mov edx, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov eax, dword [ebx + 0x24]
pop edi
add eax, ebp
pop esi
mov dword [ebx + 0x24], eax
mov eax, ebp
pop ebp
pop ebx
ret 8
mov eax, dword [ebx + 4]
test eax, eax
je 0x49761f
lea ecx, [esp + 0x14]
push 0
push ecx
push ebp
push esi
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [esp + 0x14]
pop edi
pop esi
pop ebp
pop ebx
ret 8
pop edi
pop esi
mov dword [ebx + 0x14], 0x1000000
pop ebp
xor eax, eax
pop ebx
ret 8
Function at 0x4979b0
Capabilities:
Read file on windows

Disassembly:
push ebx
mov ebx, ecx
push ebp
push esi
mov edx, dword [ebx + 0x78]
test edx, edx
je 0x497a23
mov eax, dword [ebx + 0x80]
mov ebp, dword [ebx + 0x7c]
cmp eax, ebp
jae 0x497a74
mov ecx, dword [esp + 0x14]
sub ebp, eax
cmp ebp, ecx
jbe 0x4979d9
mov ebp, ecx
mov ecx, ebp
lea esi, [eax + edx]
mov eax, dword [esp + 0x10]
mov edx, ecx
push edi
mov edi, eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
push ebp
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
mov edx, dword [ebx + 0x80]
mov ecx, dword [ebx + 0x68]
mov eax, dword [ebx + 0x6c]
add edx, ebp
add ecx, ebp
push eax
mov dword [ebx + 0x80], edx
mov dword [ebx + 0x68], ecx
call fcn.00497050
add esp, 0xc
mov dword [ebx + 0x6c], eax
mov eax, ebp
pop edi
pop esi
pop ebp
pop ebx
ret 8
mov eax, dword [ebx + 0x70]
test eax, eax
je 0x497a6d
mov edx, dword [esp + 0x14]
mov esi, dword [esp + 0x10]
lea ecx, [esp + 0x14]
push 0
push ecx
push edx
push esi
push eax
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x497a74
mov eax, dword [esp + 0x14]
mov ecx, dword [ebx + 0x68]
add ecx, eax
push eax
mov eax, dword [ebx + 0x6c]
push esi
push eax
mov dword [ebx + 0x68], ecx
call fcn.00497050
add esp, 0xc
mov dword [ebx + 0x6c], eax
mov eax, dword [esp + 0x14]
pop esi
pop ebp
pop ebx
ret 8
mov dword [ebx + 0x14], 0x1000000
pop esi
pop ebp
xor eax, eax
pop ebx
ret 8
Function at 0x49c260
Capabilities:
Terminate process

Disassembly:
push ecx
push ebx
push ebp
push esi
push 0x800
call fcn.004aef75
mov esi, dword [esp + 0x18]
add esp, 4
mov edx, eax
xor ebp, ebp
test esi, esi
mov dword [esp + 0xc], edx
jne 0x49c288
pop esi
pop ebp
xor eax, eax
pop ebx
pop ecx
ret
push edi
mov edi, esi
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
pop edi
cmp ecx, 0x800
jbe 0x49c2a3
pop esi
pop ebp
pop ebx
pop ecx
ret
mov al, byte [esi]
inc esi
test al, al
je 0x49c379
cmp ebp, 0x400
je 0x49c364
cmp al, 0x25
jne 0x49c343
mov al, byte [esi]
inc esi
test al, al
je 0x49c35c
mov cl, byte [esi]
inc esi
test cl, cl
mov byte [esp + 0x14], cl
je 0x49c35c
movsx eax, al
push eax
call fcn.004ae2c9
movsx ecx, byte [esp + 0x18]
push ecx
mov bl, al
call fcn.004ae2c9
movsx edx, bl
push edx
mov byte [esp + 0x20], al
call fcn.004afc4d
add esp, 0xc
test eax, eax
je 0x49c372
movsx eax, byte [esp + 0x14]
push eax
call fcn.004afc4d
add esp, 4
test eax, eax
je 0x49c372
cmp bl, 0x39
jg 0x49c322
add bl, 0xd0
jmp 0x49c325
add bl, 0xa9
mov al, byte [esp + 0x14]
cmp al, 0x39
jg 0x49c331
add al, 0xd0
jmp 0x49c333
add al, 0xa9
mov ecx, dword [esp + 0xc]
shl bl, 4
add bl, al
mov edx, ecx
mov byte [ecx + ebp], bl
jmp 0x49c350
cmp al, 0x2b
jne 0x49c34d
mov byte [edx + ebp], 0x20
jmp 0x49c350
mov byte [edx + ebp], al
mov al, byte [esi]
inc ebp
inc esi
test al, al
jne 0x49c2ae
cmp ebp, 0x400
jne 0x49c379
pop esi
pop ebp
mov byte [edx + 0x3ff], 0
mov eax, edx
pop ebx
pop ecx
ret
push 0
call fcn.004b081a
mov byte [edx + ebp], 0
pop esi
pop ebp
mov eax, edx
pop ebx
pop ecx
ret

Function at 0x49ffb0
Capabilities:
Create tcp socket
Initialize winsock library

Disassembly:
sub esp, 0x190
lea eax, [esp]
push eax
push 1
call sub.WSOCK32.dll_WSAStartup
test eax, eax
je 0x49ffd0
or eax, 0xffffffff
add esp, 0x190
ret
push 6
push 1
push 2
call sub.WSOCK32.dll_socket
add esp, 0x190
ret
Function at 0x4a0000
Capabilities:
Connect socket
Get socket status
Set socket configuration

Disassembly:
sub esp, 0x228
push esi
mov esi, dword [esp + 0x234]
test esi, esi
je 0x4a01ee
mov ecx, dword [esp + 0x23c]
mov eax, 0x66666667
imul ecx
sar edx, 2
mov eax, edx
push ebx
shr eax, 0x1f
add edx, eax
push edi
test edx, edx
mov edi, 1
mov dword [esp + 0xc], edx
jg 0x4a0041
mov dword [esp + 0xc], edi
xor ecx, ecx
push esi
mov dword [esp + 0x18], ecx
mov word [esp + 0x18], 2
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x20], ecx
mov dword [esp + 0x24], ecx
call sub.WSOCK32.dll_inet_addr
mov edx, dword [esp + 0x240]
mov dword [esp + 0x18], eax
push edx
call sub.WSOCK32.dll_htons
mov esi, dword [esp + 0x238]
mov word [esp + 0x16], ax
push esi
call fcn.0049ff80
add esp, 4
call dword [sym.imp.KERNEL32.dll_GetTickCount]
lea eax, [esp + 0x14]
push 0x10
push eax
push esi
call sub.WSOCK32.dll_connect
test eax, eax
jge 0x4a01d7
call fcn.0049fbf0
push eax
call fcn.004a0200
add esp, 4
cmp eax, 0xffffd8cd
je 0x4a00d4
cmp eax, 0xffffd8cc
je 0x4a00d4
push esi
mov edi, eax
call fcn.0049ff50
add esp, 4
mov eax, edi
pop edi
pop ebx
pop esi
add esp, 0x228
ret
mov eax, dword [esp + 0xc]
mov dword [esp + 0x10], 0
test eax, eax
jle 0x4a0189
lea ebx, [esi + 1]
lea ecx, [esp + 0x24]
lea edx, [esp + 0x2c]
push ecx
push 0
lea eax, [esp + 0x138]
push edx
push eax
push ebx
mov dword [esp + 0x44], esi
mov dword [esp + 0x40], edi
mov dword [esp + 0x148], esi
mov dword [esp + 0x144], edi
mov dword [esp + 0x38], 0
mov dword [esp + 0x3c], 0x2710
call sub.WSOCK32.dll_select
cmp eax, 0xffffffff
je 0x4a01bd
lea ecx, [esp + 0x2c]
push ecx
push esi
call sub.WSOCK32.dll___WSAFDIsSet
test eax, eax
jne 0x4a01d7
lea edx, [esp + 0x130]
push edx
push esi
call sub.WSOCK32.dll___WSAFDIsSet
test eax, eax
jne 0x4a01d7
mov ecx, dword [esp + 0x248]
mov eax, dword [esp + 0x24c]
cmp dword [ecx], eax
je 0x4a01a3
call fcn.0049fbf0
test eax, eax
jne 0x4a01bd
mov eax, dword [esp + 0x10]
mov ecx, dword [esp + 0xc]
inc eax
cmp eax, ecx
mov dword [esp + 0x10], eax
jl 0x4a00eb
push esi
mov edi, 0xfffffff5
call fcn.0049ff50
add esp, 4
mov eax, edi
pop edi
pop ebx
pop esi
add esp, 0x228
ret
push esi
mov edi, 0xffffffec
call fcn.0049ff50
add esp, 4
mov eax, edi
pop edi
pop ebx
pop esi
add esp, 0x228
ret
push esi
mov edi, 0xfffffffb
call fcn.0049ff50
add esp, 4
mov eax, edi
pop edi
pop ebx
pop esi
add esp, 0x228
ret
push esi
xor edi, edi
call fcn.0049ff50
add esp, 4
mov eax, edi
pop edi
pop ebx
pop esi
add esp, 0x228
ret
xor eax, eax
pop esi
add esp, 0x228
ret