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

Disassembly:
push 0xc
push 0x10054b40
call fcn.100263f0
mov edi, dword [ebp + 8]
push edi
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
xor ebx, ebx
mov dword [ebp - 4], ebx
mov dword [ebp - 0x1c], ebx
mov eax, dword [edi + 0x18]
push ebx
push 0x80
push 4
push ebx
push 1
push 0x1f01ff
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
cmp esi, 0xffffffff
je 0x10016c44
push 2
push ebx
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push ebx
lea eax, [ebp - 0x1c]
push eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push esi
call dword [sym.imp.KERNEL32.dll_FlushFileBuffers]
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
cmp eax, dword [edi + 0x28]
jb 0x10016c38
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
or esi, 0xffffffff
lea ecx, [edi + 0x18]
call fcn.10016b20
mov ecx, edi
call fcn.1001682d
cmp esi, 0xffffffff
je 0x10016c44
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 4], 0xfffffffe
call fcn.10016c5b
call fcn.10026435
ret 0xc

Function at 0x10016d95
Capabilities:
Terminate process

Disassembly:
movzx eax, word [esi + 4]
cmp eax, 1
jne 0x10016dc1
push edi
push 0x2710
push dword [esi + 0x11c]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push 0xffffffffffffffff
push dword [esi + 0x11c]
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
pop edi
jmp 0x10016dd2
cmp eax, 2
jne 0x10016dd2
push dword [esi + 0x11c]
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov eax, dword [esi + 0x10]
test eax, eax
je 0x10016de7
push eax
call fcn.1001d894
push esi
call fcn.1001d894
pop ecx
pop ecx
xor eax, eax
ret
Function at 0x100171ea
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
lea eax, [ebp - 4]
push eax
push str.SYSTEMCurrentControlSetControlWindows
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
mov esi, eax
test esi, esi
jne 0x10017229
push 4
lea eax, [ebp + 8]
push eax
push 4
push esi
push str.ErrorMode
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor eax, eax
test esi, esi
sete al
pop esi
leave
ret
Function at 0x100174ef
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x524
mov eax, dword [0x10058684]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
xor ebx, ebx
push 0x103
lea eax, [ebp - 0x107]
push ebx
push eax
mov byte [ebp - 0x108], bl
call fcn.10024270
xor eax, eax
mov esi, 0x206
push esi
mov word [ebp - 0x518], ax
lea eax, [ebp - 0x516]
push ebx
push eax
call fcn.10024270
xor eax, eax
push esi
mov word [ebp - 0x310], ax
lea eax, [ebp - 0x30e]
push ebx
push eax
call fcn.10024270
add esp, 0x24
lea eax, [ebp - 0x51c]
push eax
push 0x20019
push ebx
push 0x1004f270
push connect
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
je 0x10017585
xor eax, eax
mov ecx, dword [ebp - 4]
pop esi
xor ecx, ebp
pop ebx
call fcn.1001d73b
leave
ret
lea eax, [ebp - 0x524]
push eax
lea eax, [ebp - 0x108]
push eax
lea eax, [ebp - 0x520]
push eax
push ebx
push 0x1004f2dc
push dword [ebp - 0x51c]
mov esi, 0x104
mov dword [ebp - 0x520], 1
mov dword [ebp - 0x524], esi
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
je 0x100175d3
push dword [ebp - 0x51c]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
jmp 0x10017575
push esi
lea eax, [ebp - 0x518]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
push esi
lea eax, [ebp - 0x310]
push eax
lea eax, [ebp - 0x518]
push eax
call dword [sym.imp.KERNEL32.dll_GetShortPathNameW]
lea ecx, [ebp - 0x310]
lea eax, [ebp - 0x108]
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x10017629
cmp dx, bx
je 0x10017625
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x10017629
add eax, 4
add ecx, 4
cmp dx, bx
jne 0x10017603
xor eax, eax
jmp 0x1001762e
sbb eax, eax
sbb eax, 0xffffffff
cmp eax, ebx
je 0x10017645
push dword [ebp - 0x51c]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, ebx
jmp 0x10017577
xor ebx, ebx
inc ebx
jmp 0x10017632
Function at 0x1001764a
Capabilities:
Create process on windows
Delete registry value
Get common file path
Write and execute a file
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x55c
mov eax, dword [0x10058684]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push 0x1004f2e8
push 0x1004f2f0
push connect
call dword [sym.imp.SHLWAPI.dll_SHDeleteValueA]
mov esi, 0x104
push esi
lea eax, [ebp - 0x108]
push eax
xor ebx, ebx
push ebx
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea eax, [ebp - 0x108]
push 0x5c
push eax
call fcn.1001f5e0
pop ecx
pop ecx
cmp eax, ebx
je 0x100176a0
mov byte [eax], bl
lea eax, [ebp - 0x108]
push eax
push eax
push eax
lea eax, [ebp - 0x558]
push str.:re_r_ndel__F__S__Q___s__r_n_rmdir___s__r_nif_exist___s__goto_re_r_ndel___0_r_n
push eax
call fcn.1001794b
add esp, 0x14
mov dword [ebp - 0x55c], eax
lea eax, [ebp - 0x310]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
push str.unins3C.bat
lea eax, [ebp - 0x310]
push eax
call dword [sym.imp.SHLWAPI.dll_PathAppendW]
push ebx
push ebx
push 2
push ebx
push ebx
push 0x40000000
lea eax, [ebp - 0x310]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
cmp esi, 0xffffffff
je 0x1001773b
push ebx
lea eax, [ebp - 0x55c]
push eax
push dword [ebp - 0x55c]
lea eax, [ebp - 0x558]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push ebx
push ebx
push ebx
lea eax, [ebp - 0x310]
push eax
push str.open
push ebx
call dword [sym.imp.SHELL32.dll_ShellExecuteW]
mov ecx, dword [ebp - 4]
pop esi
xor ecx, ebp
pop ebx
call fcn.1001d73b
leave
ret
Function at 0x10017749
Capabilities:
Initialize winsock library
Terminate process
Write file on windows

Disassembly:
push 0x320
mov eax, 0x10042d6c
call fcn.10021f0e
mov esi, 0x103
xor ebx, ebx
push esi
lea eax, [ebp - 0x113]
push ebx
push eax
mov byte [ebp - 0x114], bl
call fcn.10024270
push esi
lea eax, [ebp - 0x217]
push ebx
push eax
mov byte [ebp - 0x218], bl
call fcn.10024270
add esp, 0x18
inc esi
push esi
lea eax, [ebp - 0x218]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
je 0x10017859
call fcn.100174ef
test eax, eax
jne 0x10017812
mov cl, byte [ebp + eax - 0x218]
mov byte [ebp + eax - 0x114], cl
inc eax
cmp cl, bl
jne 0x100177ab
push esi
lea eax, [ebp - 0x218]
push eax
push eax
call dword [sym.imp.KERNEL32.dll_GetShortPathNameA]
call fcn.10017286
lea eax, [ebp - 0x114]
push 0x5c
push eax
call fcn.1001f5e0
pop ecx
pop ecx
cmp eax, ebx
je 0x100177e9
mov byte [eax + 1], bl
call fcn.100174ef
lea edi, [ebp - 0x114]
dec edi
test eax, eax
je 0x10017803
mov al, byte [edi + 1]
inc edi
cmp al, bl
jne 0x100177f9
jmp 0x10017821
mov al, byte [edi + 1]
inc edi
cmp al, bl
jne 0x10017803
mov esi, 0x1004c104
jmp 0x10017826
lea edi, [ebp - 0x114]
dec edi
mov al, byte [edi + 1]
inc edi
cmp al, bl
jne 0x10017819
mov esi, 0x1004ced0
lea eax, [ebp - 0x114]
push 0x1004f398
push eax
movsw word es:[edi], word [esi]
call fcn.10020189
mov esi, eax
pop ecx
pop ecx
cmp esi, ebx
je 0x10017859
push esi
push 1
push 1
push 0x1004d8bc
call fcn.1001e52d
push esi
call fcn.1001e614
add esp, 0x14
push 2
call fcn.100171ea
mov dword [esp], 0x1005b648
push 0x202
call dword [sym.imp.WS2_32.dll_WSAStartup]
cmp eax, ebx
je 0x1001788b
push eax
push str.WSAStartup_error__d
call fcn.10003e3a
pop ecx
pop ecx
or eax, 0xffffffff
jmp 0x10017945
call fcn.100048db
push ebx
call dword [sym.imp.ole32.dll_CoInitialize]
call fcn.10016e8a
push ebx
lea eax, [ebp - 0x32c]
push eax
push 0x1005b7fc
mov dword [ebp - 0x32c], 1
mov dword [ebp - 0x328], ebx
mov dword [ebp - 0x324], ebx
mov dword [ebp - 0x320], ebx
call dword [sym.imp.gdiplus.dll_GdiplusStartup]
lea eax, [ebp - 0x31c]
push eax
call fcn.10012668
mov dword [ebp - 4], ebx
lea ebx, [ebp - 0x31c]
call fcn.100128ad
push dword [0x1005b7fc]
mov esi, eax
call dword [sym.imp.gdiplus.dll_GdiplusShutdown]
call dword [sym.imp.WS2_32.dll_WSACleanup]
xor edi, edi
cmp eax, edi
je 0x10017912
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push str.WSACleanup_error__d
call fcn.10003e3a
pop ecx
pop ecx
call dword [sym.imp.ole32.dll_CoUninitialize]
push edi
call fcn.100171ea
pop ecx
cmp dword [ebp - 0x24c], edi
je 0x10017933
call fcn.1001764a
push edi
call dword [sym.imp.KERNEL32.dll_ExitProcess]
or dword [ebp - 4], 0xffffffff
lea eax, [ebp - 0x31c]
push eax
call fcn.100127f7
mov eax, esi
call fcn.10021f58
ret
Function at 0x10017eb6
Capabilities:
Check if file exists
Create directory
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20c
mov eax, dword [0x10058684]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
xor eax, eax
push 0x206
push eax
mov word [ebp - 0x20c], ax
lea eax, [ebp - 0x20a]
push eax
call fcn.10024270
add esp, 0xc
lea eax, [ebp - 0x20c]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
test eax, eax
jne 0x10017f18
mov esi, str.C:windows_tempData
push esi
call fcn.10002867
pop ecx
push eax
push esi
mov ecx, 0x1005bba4
call fcn.10002599
jmp 0x10017f50
lea eax, [ebp - 0x20c]
push edi
push eax
call fcn.10002867
pop ecx
push eax
lea eax, [ebp - 0x20c]
mov edi, 0x1005bba4
push eax
mov ecx, edi
call fcn.10002599
mov esi, str.Data
push esi
call fcn.10002867
pop ecx
push eax
push esi
mov ecx, edi
call fcn.1000fa64
pop edi
push dword [0x1005bba4]
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
pop esi
test eax, eax
jne 0x10017f6e
push eax
push dword [0x1005bba4]
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1001d73b
leave
ret

Function at 0x10018553
Capabilities:
Check if file exists

Disassembly:
push ebx
push esi
mov esi, eax
lea eax, [esi + 4]
push eax
mov ecx, 0x1005bb9c
call fcn.100023d5
mov eax, dword [esi + 8]
add esi, 0xc
mov ebx, 0x1005bba0
push esi
mov ecx, ebx
mov dword [0x10059a04], eax
call fcn.100023d5
mov eax, dword [0x1005bb9c]
cmp dword [eax - 0xc], 0
je 0x100185c1
cmp dword [0x10059a04], 0xffffffff
je 0x100185c1
mov eax, dword [0x1005bba0]
cmp dword [eax - 0xc], 0
je 0x100185c1
push 0x1004f91c
call fcn.100163f4
push dword [0x1005bba0]
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x100185bd
push ebx
call fcn.1001a0b5
pop ecx
mov al, 1
jmp 0x100185c3
xor al, al
pop esi
pop ebx
ret
Function at 0x100185c6
Capabilities:
Enumerate files on windows

Disassembly:
push 0x26c
mov eax, 0x1004098c
call fcn.10021f0e
push 0x1004f924
mov edi, 0x1005bba0
lea eax, [ebp - 0x270]
push edi
push eax
call fcn.1000436d
mov eax, dword [eax]
add esp, 0xc
lea ecx, [ebp - 0x260]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov ecx, dword [ebp - 0x270]
add ecx, 0xfffffff0
mov dword [ebp - 0x264], eax
call fcn.10002c37
cmp dword [ebp - 0x264], 0xffffffff
mov ebx, dword [sym.imp.KERNEL32.dll_FindNextFileW]
je 0x100186fc
push 0x1004b5ac
lea eax, [ebp - 0x268]
push edi
push eax
call fcn.1000436d
and dword [ebp - 4], 0
lea ecx, [ebp - 0x234]
push ecx
push eax
lea eax, [ebp - 0x26c]
push eax
call fcn.1000436d
add esp, 0x18
mov byte [ebp - 4], 1
mov esi, dword [0x1005bac8]
push eax
call fcn.10018821
mov ecx, dword [ebp - 0x26c]
add ecx, 0xfffffff0
call fcn.10002c37
or dword [ebp - 4], 0xffffffff
mov ecx, dword [ebp - 0x268]
jmp 0x100186d5
push 0x1004b5ac
lea eax, [ebp - 0x26c]
push edi
push eax
call fcn.1000436d
lea ecx, [ebp - 0x234]
push ecx
push eax
lea eax, [ebp - 0x268]
push eax
mov dword [ebp - 4], 2
call fcn.1000436d
add esp, 0x18
mov byte [ebp - 4], 3
mov esi, dword [0x1005bac8]
push eax
call fcn.10018821
mov ecx, dword [ebp - 0x268]
add ecx, 0xfffffff0
call fcn.10002c37
or dword [ebp - 4], 0xffffffff
mov ecx, dword [ebp - 0x26c]
add ecx, 0xfffffff0
call fcn.10002c37
lea eax, [ebp - 0x260]
push eax
push dword [ebp - 0x264]
call ebx
test eax, eax
jne 0x1001867d
push dword [ebp - 0x264]
call dword [sym.imp.KERNEL32.dll_FindClose]
push str..mp3
lea eax, [ebp - 0x268]
push edi
push eax
call fcn.1000436d
mov eax, dword [eax]
add esp, 0xc
lea ecx, [ebp - 0x260]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov ecx, dword [ebp - 0x268]
add ecx, 0xfffffff0
mov dword [ebp - 0x264], eax
call fcn.10002c37
cmp dword [ebp - 0x264], 0xffffffff
je 0x1001881b
push 0x1004b5ac
lea eax, [ebp - 0x270]
push edi
push eax
call fcn.1000436d
lea ecx, [ebp - 0x234]
push ecx
push eax
lea eax, [ebp - 0x26c]
push eax
mov dword [ebp - 4], 4
call fcn.1000436d
add esp, 0x18
mov byte [ebp - 4], 5
mov esi, dword [0x1005bac8]
push eax
call fcn.10018821
mov ecx, dword [ebp - 0x26c]
add ecx, 0xfffffff0
call fcn.10002c37
or dword [ebp - 4], 0xffffffff
mov ecx, dword [ebp - 0x270]
jmp 0x100187f4
push 0x1004b5ac
lea eax, [ebp - 0x278]
push edi
push eax
call fcn.1000436d
lea ecx, [ebp - 0x234]
push ecx
push eax
lea eax, [ebp - 0x274]
push eax
mov dword [ebp - 4], 6
call fcn.1000436d
add esp, 0x18
mov byte [ebp - 4], 7
mov esi, dword [0x1005bac8]
push eax
call fcn.10018821
mov ecx, dword [ebp - 0x274]
add ecx, 0xfffffff0
call fcn.10002c37
or dword [ebp - 4], 0xffffffff
mov ecx, dword [ebp - 0x278]
add ecx, 0xfffffff0
call fcn.10002c37
lea eax, [ebp - 0x260]
push eax
push dword [ebp - 0x264]
call ebx
test eax, eax
jne 0x1001879c
push dword [ebp - 0x264]
call dword [sym.imp.KERNEL32.dll_FindClose]
call fcn.10021f58
ret
Function at 0x100189df
Capabilities:
Create thread

Disassembly:
push ebx
mov ebx, dword [0x1005bacc]
cmp dword [ebx + 0xc], 0
je 0x100189f0
mov al, 1
pop ebx
ret
push esi
push edi
xor eax, eax
lea edi, [ebx + 4]
stosd dword es:[edi], eax
stosw word es:[edi], ax
push dword [ebx]
mov esi, 0x1005bad8
lea edi, [ebx + 4]
movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
call dword [sym.imp.KERNEL32.dll_ResetEvent]
xor esi, esi
push esi
push esi
push ebx
push 0x10018e92
push esi
push esi
call fcn.10020d0d
add esp, 0x18
mov dword [ebx + 0xc], eax
cmp eax, esi
je 0x10018a31
push 0xfffffffffffffff1
push eax
call dword [sym.imp.KERNEL32.dll_SetThreadPriority]
xor eax, eax
cmp dword [ebx + 0xc], esi
pop edi
pop esi
setne al
pop ebx
ret

Function at 0x10018a66
Capabilities:
Encode data using xor
Get file size

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
xor ecx, ecx
push ecx
push 0x80
push 3
push ecx
mov ebx, eax
mov eax, dword [ebp + 0xc]
mov eax, dword [eax]
push ecx
push connect
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 4], eax
cmp eax, 0xffffffff
jne 0x10018a99
xor al, al
jmp 0x10018b5f
push esi
mov esi, dword [ebp + 8]
push edi
mov byte [ebx], 0xfe
add esi, 4
lea edi, [ebx + 2]
movsd dword es:[edi], dword [esi]
push 7
movsw word es:[edi], word [esi]
call dword [sym.imp.WS2_32.dll_htons]
xor edi, edi
push edi
push dword [ebp - 4]
mov word [ebx + 8], ax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
push eax
call dword [sym.imp.WS2_32.dll_htonl]
push 0x10
lea esi, [ebx + 0x31a]
push 0x1005bb0c
push esi
mov dword [ebx + 0xa], eax
call fcn.10020ee0
push 0x10
lea eax, [ebx + 0x32a]
push 0x1005bb1c
push eax
call fcn.10020ee0
push 8
lea eax, [ebx + 0x33a]
push 0x1005bb2c
push eax
call fcn.10020ee0
add esp, 0x24
xor eax, eax
xor byte [esi + eax], 0x78
inc eax
cmp eax, 0x28
jl 0x10018b0a
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp + 0xc]
push 0x5c
call fcn.10002215
mov ecx, dword [ebp + 0xc]
lea edx, [eax + 1]
lea eax, [ebp + 0xc]
push eax
call fcn.100042f8
mov esi, dword [ebp + 0xc]
push edi
push edi
push 0x104
add ebx, 0xe
push ebx
push 0xffffffffffffffff
push esi
push edi
push 0xfde9
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
lea ecx, [esi - 0x10]
call fcn.10002c37
pop edi
mov al, 1
pop esi
pop ebx
leave
ret 8
Function at 0x10019d41
Capabilities:
Check if file exists

Disassembly:
push 0x44
mov eax, 0x10042461
call fcn.10021f0e
mov eax, dword [ebp + 0xc]
mov esi, dword [ebp + 8]
mov ebx, dword [0x1005bac4]
push esi
push eax
mov dword [ebp - 0x50], eax
call fcn.10019faa
test al, al
je 0x10019d6e
mov eax, esi
jmp 0x10019f02
mov eax, dword [ebx + 0x94]
cmp esi, eax
jbe 0x10019e59
lea edx, [ebp - 0x2c]
mov ecx, ebx
call fcn.10019af2
and dword [ebp - 4], 0
cmp dword [ebp - 0x1c], 0
je 0x10019e3b
cmp dword [ebp - 0x18], 8
mov eax, dword [ebp - 0x2c]
jae 0x10019da0
lea eax, [ebp - 0x2c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x10019e3b
cmp dword [ebp - 0x18], 8
mov eax, dword [ebp - 0x2c]
jae 0x10019dbb
lea eax, [ebp - 0x2c]
push eax
lea ecx, [ebp - 0x4c]
call fcn.100021a3
lea eax, [ebp - 0x4c]
mov byte [ebp - 4], 1
mov esi, dword [0x1005bac8]
push eax
call fcn.10018821
mov byte [ebp - 4], 0
mov ecx, dword [ebp - 0x4c]
add ecx, 0xfffffff0
call fcn.10002c37
lea esi, [ebx + 0x94]
call fcn.10019750
mov esi, dword [ebp + 8]
add esi, esi
push esi
call fcn.1001c971
pop ecx
mov dword [ebx + 0x9c], eax
test eax, eax
je 0x10019e14
and dword [ebx + 0x98], 0
mov dword [ebx + 0x94], esi
mov esi, dword [ebp + 8]
push esi
push dword [ebp - 0x50]
push eax
call fcn.10021760
add esp, 0xc
mov dword [ebx + 0x98], esi
push 1
xor edi, edi
lea esi, [ebp - 0x2c]
call fcn.10003078
jmp 0x10019eff
push str.Write_data_to_file_failed.
call fcn.10003e3a
lea esi, [ebp - 0x2c]
pop ecx
xor edi, edi
push 1
call fcn.10003078
xor eax, eax
jmp 0x10019f02
mov ecx, dword [ebx + 0x98]
add ecx, esi
cmp ecx, eax
jbe 0x10019edd
lea edx, [ebp - 0x48]
mov ecx, ebx
call fcn.10019af2
mov dword [ebp - 4], 2
cmp dword [ebp - 0x38], 0
je 0x10019f0a
cmp dword [ebp - 0x34], 8
mov eax, dword [ebp - 0x48]
jae 0x10019e8c
lea eax, [ebp - 0x48]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x10019f0a
cmp dword [ebp - 0x34], 8
mov eax, dword [ebp - 0x48]
jae 0x10019ea3
lea eax, [ebp - 0x48]
push eax
lea ecx, [ebp - 0x4c]
call fcn.100021a3
lea eax, [ebp - 0x4c]
mov byte [ebp - 4], 3
mov esi, dword [0x1005bac8]
push eax
call fcn.10018821
mov ecx, dword [ebp - 0x4c]
add ecx, 0xfffffff0
call fcn.10002c37
and dword [ebx + 0x98], 0
push 1
xor edi, edi
lea esi, [ebp - 0x48]
call fcn.10003078
mov esi, dword [ebp + 8]
mov eax, dword [ebx + 0x9c]
add eax, dword [ebx + 0x98]
push esi
push dword [ebp - 0x50]
push eax
call fcn.10021760
add esp, 0xc
add dword [ebx + 0x98], esi
mov eax, dword [ebp + 8]
call fcn.10021f58
ret 8
push str.Write_data_to_file_failed.
call fcn.10003e3a
lea esi, [ebp - 0x48]
jmp 0x10019e48
Function at 0x1001a0b5
Capabilities:
Check if file exists
Create directory

Disassembly:
push 4
mov eax, 0x100408dd
call fcn.10021ea5
mov esi, dword [ebp + 8]
push dword [esi]
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x1001a13b
mov eax, dword [esi]
sub eax, 0x10
push eax
call fcn.10002687
add eax, 0x10
pop ecx
mov dword [ebp + 8], eax
and dword [ebp - 4], 0
lea edi, [ebp + 8]
call fcn.1001a143
mov esi, dword [ebp + 8]
push 0x5c
push esi
call fcn.1001ef2c
pop ecx
pop ecx
test eax, eax
je 0x1001a12a
sub eax, esi
sar eax, 1
cmp eax, 0xffffffff
je 0x1001a12a
push eax
lea eax, [ebp - 0x10]
push eax
mov ecx, edi
call fcn.10002289
push eax
mov byte [ebp - 4], 1
call fcn.1001a0b5
pop ecx
mov ecx, dword [ebp - 0x10]
add ecx, 0xfffffff0
call fcn.10002c37
push 0
push esi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
lea ecx, [esi - 0x10]
call fcn.10002c37
mov al, 1
call fcn.10021f44
ret

Function at 0x1001a6b5
Capabilities:
Create thread

Disassembly:
push 4
mov eax, 0x1004164c
call fcn.10021ea5
mov dword [ebp - 0x10], ecx
and dword [ebp - 4], 0
push 0x14
call fcn.1001ec97
mov ebx, eax
pop ecx
test ebx, ebx
je 0x1001a6ee
mov esi, 0x100581b4
push esi
mov ecx, ebx
call fcn.100023ad
push esi
lea ecx, [ebx + 8]
call fcn.100023ad
jmp 0x1001a6f0
xor ebx, ebx
push dword [ebp + 8]
mov ecx, ebx
call fcn.100023d5
lea eax, [ebp + 0x10]
push eax
lea ecx, [ebx + 8]
mov byte [ebx + 4], 0
call fcn.100023d5
mov ax, word [ebp + 0x14]
push 0x342
mov word [ebx + 0xc], ax
call fcn.1001ec97
mov esi, dword [ebp + 0xc]
pop ecx
mov dword [ebx + 0x10], eax
mov edi, eax
mov ecx, 0xd0
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
mov eax, dword [ebx + 0x10]
cmp dword [eax + 0xa], 0x100000
push ebx
jbe 0x1001a749
mov esi, dword [ebp - 0x10]
lea eax, [esi + 0x58]
push eax
call fcn.1001ae62
jmp 0x1001a758
mov eax, dword [ebp - 0x10]
add eax, 0x24
push eax
call fcn.1001ae62
mov esi, dword [ebp - 0x10]
xor edi, edi
cmp dword [esi + 0x20], edi
jne 0x1001a774
push edi
push edi
push esi
push 0x1001a9a3
push edi
push edi
call fcn.10020d0d
add esp, 0x18
mov dword [esi + 0x20], eax
cmp dword [esi + 0x54], edi
jne 0x1001a78e
push edi
push edi
push esi
push 0x1001aa62
push edi
push edi
call fcn.10020d0d
add esp, 0x18
mov dword [esi + 0x54], eax
mov ecx, dword [ebp + 0x10]
add ecx, 0xfffffff0
call fcn.10002c37
call fcn.10021f44
ret 0x10
Function at 0x1001a7a1
Capabilities:
Encode data using xor
Get file size

Disassembly:
push 0x35c
mov eax, 0x1004295e
call fcn.10021f0e
mov eax, dword [ebp + 8]
mov edi, dword [ebp + 0xc]
mov dword [ebp - 0x360], ecx
mov dword [ebp - 0x35c], eax
xor esi, esi
push esi
push 0x80
push 3
push esi
push esi
mov dword [ebp - 4], esi
mov eax, dword [eax]
push connect
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x358], eax
cmp eax, 0xffffffff
je 0x1001a990
push 0x341
lea eax, [ebp - 0x353]
push esi
push eax
call fcn.10024270
lea eax, [ebp - 0x352]
add esp, 0xc
push eax
mov word [ebp - 0x354], 0x2fe
call fcn.1000783c
mov ebx, eax
call fcn.1000787a
push dword [ebp + 0x10]
call dword [sym.imp.WS2_32.dll_htons]
push esi
push dword [ebp - 0x358]
mov word [ebp - 0x34c], ax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
push eax
call dword [sym.imp.WS2_32.dll_htonl]
mov ebx, 0x104
push ebx
mov dword [ebp - 0x34a], eax
lea eax, [ebp - 0x346]
push esi
push eax
call fcn.10024270
mov eax, dword [edi]
mov edi, dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
add esp, 0xc
cmp dword [eax - 0xc], esi
je 0x1001a885
push esi
push esi
push 0x208
lea ecx, [ebp - 0x242]
push ecx
push 0xffffffffffffffff
push eax
push esi
push 0xfde9
call edi
push 0x10
lea eax, [ebp - 0x3a]
push 0x1005bb0c
push eax
call fcn.10020ee0
push 0x10
lea eax, [ebp - 0x2a]
push 0x1005bb1c
push eax
call fcn.10020ee0
push 8
lea eax, [ebp - 0x1a]
push 0x1005bb2c
push eax
call fcn.10020ee0
add esp, 0x24
xor eax, eax
xor byte [ebp + eax - 0x3a], 0x78
inc eax
cmp eax, 0x28
jl 0x1001a8ba
push dword [ebp - 0x358]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 0x35c]
push 0x5c
call fcn.10002215
mov ecx, dword [ebp - 0x35c]
lea edx, [eax + 1]
lea eax, [ebp - 0x364]
push eax
call fcn.100042f8
push esi
push esi
push ebx
lea eax, [ebp - 0x346]
push eax
push 0xffffffffffffffff
mov byte [ebp - 4], 1
mov ebx, dword [ebp - 0x364]
push ebx
push esi
push 0xfde9
call edi
mov eax, dword [ebp + 0x14]
add eax, 0xfffffff0
push eax
call fcn.10002687
add eax, 0x10
pop ecx
mov dword [ebp - 0x358], eax
mov byte [ebp - 4], 2
cmp dword [eax - 0xc], esi
jne 0x1001a94f
mov ecx, dword [ebp - 0x360]
mov eax, dword [ecx]
call dword [eax + 8]
push eax
lea eax, [ebp - 0x358]
push eax
call fcn.1000fa0b
mov eax, dword [ebp - 0x358]
push dword [ebp + 0x18]
lea esi, [eax - 0x10]
push ecx
mov dword [ebp - 0x368], esp
mov edi, esp
push esi
call fcn.10002687
pop ecx
mov ecx, dword [ebp - 0x360]
lea edx, [ebp - 0x354]
add eax, 0x10
push edx
push dword [ebp - 0x35c]
mov dword [edi], eax
mov eax, dword [ecx]
call dword [eax]
mov ecx, esi
call fcn.10002c37
lea ecx, [ebx - 0x10]
call fcn.10002c37
mov ecx, dword [ebp + 0x14]
add ecx, 0xfffffff0
call fcn.10002c37
call fcn.10021f58
ret 0x14