joyce8/EMBER2024-capa huggingface dataset:
Function at 0x401270
Capabilities:
Create service
Persist via windows service

Disassembly:
push esi
push 2
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov esi, eax
test esi, esi
jne 0x40128a
pop esi
jmp dword [sym.imp.KERNEL32.dll_GetLastError]
mov eax, dword [esp + 0x10]
mov ecx, dword [esp + 0xc]
push edi
push 0
push 0
push 0
push 0
push eax
mov eax, dword [esp + 0x20]
push ecx
push 1
push 2
push 0x10
push 0xf0000
push eax
push eax
push esi
call dword [sym.imp.ADVAPI32.dll_CreateServiceA]
test eax, eax
jne 0x4012cd
call dword [sym.imp.KERNEL32.dll_GetLastError]
push esi
mov edi, eax
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov eax, edi
pop edi
pop esi
ret
mov edi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
push eax
call edi
push esi
call edi
pop edi
xor eax, eax
pop esi
ret

Function at 0x4012e0
Capabilities:
Delete service

Disassembly:
push esi
push 2
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov esi, eax
test esi, esi
jne 0x4012fa
pop esi
jmp dword [sym.imp.KERNEL32.dll_GetLastError]
mov eax, dword [esp + 8]
push edi
push 0xf0000
push eax
push esi
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
mov edi, eax
test edi, edi
jne 0x401326
call dword [sym.imp.KERNEL32.dll_GetLastError]
push esi
mov edi, eax
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov eax, edi
pop edi
pop esi
ret
push edi
call dword [sym.imp.ADVAPI32.dll_DeleteService]
test eax, eax
jne 0x40134c
push ebx
call dword [sym.imp.KERNEL32.dll_GetLastError]
push edi
mov edi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov ebx, eax
call edi
push esi
call edi
mov eax, ebx
pop ebx
pop edi
pop esi
ret
push edi
mov edi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
call edi
push esi
call edi
pop edi
xor eax, eax
pop esi
ret
Function at 0x401550
Capabilities:
Start service

Disassembly:
sub esp, 0x1c
push edi
push 0x80000000
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov edi, eax
test edi, edi
jne 0x401384
call dword [sym.imp.KERNEL32.dll_GetLastError]
pop edi
add esp, 0x1c
ret
mov eax, dword [esp + 0x24]
push esi
push 0xf01ff
push eax
push edi
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
mov esi, eax
test esi, esi
jne 0x4013af
push edi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
call dword [sym.imp.KERNEL32.dll_GetLastError]
pop esi
pop edi
add esp, 0x1c
ret
mov eax, dword [esp + 0x2c]
cmp eax, 0x40
jne 0x4013e5
mov ecx, dword [esp + 0x34]
mov edx, dword [esp + 0x30]
push ecx
push edx
push esi
call dword [sym.imp.ADVAPI32.dll_StartServiceA]
test eax, eax
jne 0x40140e
push esi
mov esi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
call esi
push edi
call esi
call dword [sym.imp.KERNEL32.dll_GetLastError]
pop esi
pop edi
add esp, 0x1c
ret
lea ecx, [esp + 8]
push ecx
push eax
push esi
call dword [sym.imp.ADVAPI32.dll_ControlService]
test eax, eax
jne 0x40140e
push esi
mov esi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
call esi
push edi
call esi
call dword [sym.imp.KERNEL32.dll_GetLastError]
pop esi
pop edi
add esp, 0x1c
ret
push esi
mov esi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
call esi
push edi
call esi
pop esi
xor eax, eax
pop edi
add esp, 0x1c
ret
mov dword [esp + 4], 0x404020
jmp 0x401360
Function at 0x4016d0
Capabilities:
Enumerate process modules

Disassembly:
sub esp, 0x410
mov eax, dword [0x404014]
push ebx
push ebp
push edi
push 0x4e20
mov dword [esp + 0x41c], eax
mov dword [esp + 0x14], 0xffffffff
call sub.MSVCR71.dll_void____cdecl_operator_new_unsigned_int_
push 0x4e20
mov edi, eax
call sub.MSVCR71.dll_void____cdecl_operator_new_unsigned_int_
xor ebp, ebp
add esp, 8
cmp edi, ebp
mov ebx, eax
je 0x401803
cmp ebx, ebp
je 0x401803
lea eax, [esp + 0xc]
push eax
push 0x4e20
push edi
mov dword [esp + 0x18], ebp
call sub.PSAPI.DLL_EnumProcesses
test eax, eax
je 0x401803
mov eax, dword [esp + 0xc]
shr eax, 2
cmp eax, ebp
mov dword [esp + 0x14], eax
jbe 0x4017da
push esi
lea ebx, [ebx]
mov ecx, dword [edi + ebp*4]
push ecx
push 0
push 0x1f0fff
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov esi, eax
test esi, esi
je 0x4017c0
lea edx, [esp + 0x10]
push edx
push 0x4e20
push ebx
push esi
call sub.PSAPI.DLL_EnumProcessModules
test eax, eax
je 0x4017b9
cmp dword [esp + 0x10], 4
jb 0x4017b9
mov ecx, dword [ebx]
push 0x400
lea eax, [esp + 0x20]
push eax
push ecx
push esi
call sub.PSAPI.DLL_GetModuleBaseNameA
test eax, eax
je 0x4017b9
mov edx, dword [esp + 0x424]
mov byte [esp + eax + 0x1c], 0
push edx
lea eax, [esp + 0x20]
push eax
call dword [sym.imp.MSVCR71.dll__stricmp]
add esp, 8
test eax, eax
je 0x4017cb
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esp + 0x18]
inc ebp
cmp ebp, eax
jb 0x401750
jmp 0x4017d9
mov ecx, dword [edi + ebp*4]
push esi
mov dword [esp + 0x18], ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop esi
push ebx
call sub.MSVCR71.dll_void___cdecl_operator_delete_void__
push edi
call sub.MSVCR71.dll_void___cdecl_operator_delete_void__
mov eax, dword [esp + 0x18]
add esp, 8
pop edi
pop ebp
pop ebx
mov ecx, dword [esp + 0x40c]
call fcn.0040216d
add esp, 0x410
ret
push ebx
call sub.MSVCR71.dll_void___cdecl_operator_delete_void__
push edi
call sub.MSVCR71.dll_void___cdecl_operator_delete_void__
mov ecx, dword [esp + 0x420]
add esp, 8
pop edi
pop ebp
or eax, 0xffffffff
pop ebx
call fcn.0040216d
add esp, 0x410
ret
Function at 0x4019e0
Capabilities:
Acquire debug privileges
Create thread
Inject dll
Inject thread

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x444
mov eax, dword [0x404014]
push ebx
push esi
push edi
push 1
push str.SeDebugPrivilege
mov dword [esp + 0x454], eax
call fcn.00401830
add esp, 8
test eax, eax
je 0x401b9f
mov eax, dword [ebp + 0xc]
push eax
push 0
push 0x1f0fff
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov esi, eax
xor eax, eax
test esi, esi
je 0x401be1
mov ecx, 0x10e
lea edi, [esp + 0x10]
push str.LoadLibraryA
rep stosd dword es:[edi], eax
mov edi, dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push str.Kernel32.dll
mov dword [esp + 0x14], eax
call edi
mov ebx, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push eax
call ebx
push 0x4031ac
push str.Kernel32.dll
mov dword [esp + 0x18], eax
call edi
push eax
call ebx
push 0x4031bc
push str.Kernel32.dll
mov dword [esp + 0x1c], eax
call edi
push eax
call ebx
mov edx, dword [ebp + 8]
mov dword [esp + 0x18], eax
mov eax, edx
lea edi, [eax + 1]
jmp 0x401a90
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x401a90
sub eax, edi
mov edi, dword [sym.imp.KERNEL32.dll_lstrcpynA]
inc eax
push eax
push edx
lea ecx, [esp + 0x24]
push ecx
call edi
push 8
push str.DllInit
lea edx, [esp + 0x424]
push edx
call edi
mov al, byte [ebp + 0x14]
test al, al
mov dword [esp + 0x444], 0
je 0x401ae1
mov eax, dword [ebp + 0x18]
mov dword [esp + 0x440], eax
mov dword [esp + 0x444], 1
mov edi, dword [sym.imp.KERNEL32.dll_VirtualAllocEx]
push 4
push 0x1000
push 0x438
push 0
push esi
call edi
mov ebx, eax
test ebx, ebx
je 0x401b98
lea ecx, [esp + 0xc]
push ecx
push 0x438
lea edx, [esp + 0x18]
push edx
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_WriteProcessMemory]
test eax, eax
je 0x401b98
push 4
push 0x1000
push 0xc08
push 0
push esi
call edi
mov edi, eax
test edi, edi
je 0x401b98
lea eax, [esp + 0xc]
push eax
push 0xc08
push 0x4018d0
push edi
push esi
call dword [sym.imp.KERNEL32.dll_WriteProcessMemory]
test eax, eax
je 0x401b98
lea ecx, [esp + 0xc]
push ecx
push 0
push ebx
push edi
push 0
push 0
push esi
call dword [sym.imp.KERNEL32.dll_CreateRemoteThread]
mov edi, eax
push 0xffffffffffffffff
push edi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
test edi, edi
je 0x401b98
lea edx, [esp + 0xc]
push edx
push 0x438
lea eax, [esp + 0x18]
push eax
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_ReadProcessMemory]
test eax, eax
je 0x401b98
mov eax, dword [esp + 0x43c]
test eax, eax
je 0x401bb4
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
mov ecx, dword [esp + 0x44c]
call fcn.0040216d
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp + 0x10]
test eax, eax
jne 0x401bda
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, 1
mov ecx, dword [esp + 0x44c]
call fcn.0040216d
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov dword [eax], esi
mov eax, 1
mov ecx, dword [esp + 0x44c]
call fcn.0040216d
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x402188
Capabilities:
Parse pe header
Terminate process

Disassembly:
push 0x74
push 0x403278
call fcn.004023f4
xor ebx, ebx
mov dword [ebp - 0x20], ebx
push ebx
mov edi, dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
call edi
cmp word [eax], 0x5a4d
jne 0x4021c8
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x4021c8
movzx eax, word [ecx + 0x18]
cmp eax, 0x10b
je 0x4021e0
cmp eax, 0x20b
je 0x4021cd
mov dword [ebp - 0x1c], ebx
jmp 0x4021f4
cmp dword [ecx + 0x84], 0xe
jbe 0x4021c8
xor eax, eax
cmp dword [ecx + 0xf8], ebx
jmp 0x4021ee
cmp dword [ecx + 0x74], 0xe
jbe 0x4021c8
xor eax, eax
cmp dword [ecx + 0xe8], ebx
setne al
mov dword [ebp - 0x1c], eax
mov dword [ebp - 4], ebx
push 2
call dword [sym.imp.MSVCR71.dll___set_app_type]
pop ecx
or dword [0x4040ec], 0xffffffff
or dword [0x4040f0], 0xffffffff
call dword [sym.imp.MSVCR71.dll___p__fmode]
mov ecx, dword [0x4040e4]
mov dword [eax], ecx
call dword [sym.imp.MSVCR71.dll___p__commode]
mov ecx, dword [0x4040e0]
mov dword [eax], ecx
mov eax, dword [sym.imp.MSVCR71.dll__adjust_fdiv]
mov eax, dword [eax]
mov dword [0x4040e8], eax
call fcn.0040248a
call fcn.0040252a
cmp dword [0x404018], ebx
jne 0x402254
push fcn.0040252a
call dword [sym.imp.MSVCR71.dll___setusermatherr]
pop ecx
call fcn.00402518
push 0x404010
push 0x40400c
call sub.MSVCR71.dll__initterm
push 0x4024ce
call fcn.00402478
mov eax, dword [0x4040dc]
mov dword [ebp - 0x28], eax
lea eax, [ebp - 0x28]
push eax
push dword [0x4040d8]
lea eax, [ebp - 0x30]
push eax
lea eax, [ebp - 0x34]
push eax
lea eax, [ebp - 0x38]
push eax
call dword [sym.imp.MSVCR71.dll___getmainargs]
add esp, 0x20
mov dword [ebp - 0x3c], eax
cmp eax, ebx
jge 0x4022a8
push 8
call sub.MSVCR71.dll__amsg_exit
pop ecx
push 0x404008
push section..data
call sub.MSVCR71.dll__initterm
pop ecx
pop ecx
mov eax, dword [sym.imp.MSVCR71.dll__acmdln]
mov esi, dword [eax]
mov dword [ebp - 0x24], esi
mov al, byte [esi]
cmp al, 0x20
ja 0x402326
cmp al, bl
je 0x4022d2
cmp dword [ebp - 0x20], ebx
jne 0x402326
mov al, byte [esi]
cmp al, bl
je 0x4022e2
cmp al, 0x20
ja 0x4022e2
inc esi
mov dword [ebp - 0x24], esi
jmp 0x4022d2
mov dword [ebp - 0x58], ebx
lea eax, [ebp - 0x84]
push eax
call dword [sym.imp.KERNEL32.dll_GetStartupInfoA]
test byte [ebp - 0x58], 1
je 0x4022fe
movzx eax, word [ebp - 0x54]
jmp 0x402301
push 0xa
pop eax
push eax
push esi
push ebx
push ebx
call edi
push eax
call fcn.00401c00
mov esi, eax
mov dword [ebp - 0x40], esi
cmp dword [ebp - 0x1c], ebx
jne 0x40231e
push esi
call dword [sym.imp.MSVCR71.dll_exit]
call dword [sym.imp.MSVCR71.dll__cexit]
jmp 0x40237b
cmp al, 0x22
jne 0x402335
xor ecx, ecx
cmp dword [ebp - 0x20], ebx
sete cl
mov dword [ebp - 0x20], ecx
movzx eax, al
push eax
call dword [sym.imp.MSVCR71.dll__ismbblead]
pop ecx
test eax, eax
je 0x402348
inc esi
mov dword [ebp - 0x24], esi
inc esi
jmp 0x4022c0
or dword [ebp - 4], 0xffffffff
mov eax, esi
call fcn.0040242f
ret
Function at 0x737660
Capabilities:
Packed with generic packer

Disassembly:
pushal
mov esi, section.UPX1
lea edi, [esi - 0x1c0000]
mov dword [edi + 0x23fe90], 0x96ce3667
push edi
or ebp, 0xffffffff
jmp 0x73768a
mov al, byte [esi]
inc esi
mov byte [edi], al
inc edi
add ebx, ebx
jne 0x737691
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x737680
mov eax, 1
add ebx, ebx
jne 0x7376a3
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc eax, eax
add ebx, ebx
jae 0x7376b4
jne 0x7376d3
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x7376d3
dec eax
add ebx, ebx
jne 0x7376c0
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc eax, eax
jmp 0x737698
add ebx, ebx
jne 0x7376cf
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
jmp 0x737725
xor ecx, ecx
sub eax, 3
jb 0x7376eb
shl eax, 8
mov al, byte [esi]
inc esi
xor eax, 0xffffffff
je 0x73775a
sar eax, 1
mov ebp, eax
jmp 0x7376f6
add ebx, ebx
jne 0x7376f6
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x7376c4
inc ecx
add ebx, ebx
jne 0x737704
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x7376c4
add ebx, ebx
jne 0x737711
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
add ebx, ebx
jae 0x737706
jne 0x737722
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jae 0x737706
add ecx, 2
cmp ebp, 0xfffffb00
adc ecx, 2
lea edx, [edi + ebp]
cmp ebp, 0xfffffffc
jbe 0x737744
mov al, byte [edx]
inc edx
mov byte [edi], al
inc edi
dec ecx
jne 0x737736
jmp 0x737686
mov eax, dword [edx]
add edx, 4
mov dword [edi], eax
add edi, 4
sub ecx, 4
ja 0x737744
add edi, ecx
jmp 0x737686
pop esi
mov edi, esi
mov ecx, 0xe015
mov al, byte [edi]
inc edi
sub al, 0xe8
cmp al, 1
ja 0x737762
cmp byte [edi], 0x28
jne 0x737762
mov eax, dword [edi]
mov bl, byte [edi + 4]
shr ax, 8
rol eax, 0x10
xchg ah, al
sub eax, edi
sub bl, 0xe8
add eax, esi
mov dword [edi], eax
add edi, 5
mov al, bl
loop 0x737767
lea edi, [esi + 0x326000]
mov eax, dword [edi]
or eax, eax
je 0x7377df
mov ebx, dword [edi + 4]
lea eax, [eax + esi + 0x3589e4]
add ebx, esi
push eax
add edi, 8
call dword [esi + 0x358bf0]
xchg ebp, eax
mov al, byte [edi]
inc edi
or al, al
je 0x737794
mov ecx, edi
jns 0x7377c3
movzx eax, word [edi]
inc edi
push eax
inc edi
mov ecx, 0xaef24857
push edi
dec eax
repne scasb al, byte es:[edi]
push ebp
call dword [esi + 0x358bf8]
or eax, eax
je 0x7377d9
mov dword [ebx], eax
add ebx, 4
jmp 0x7377b1
call dword [esi + 0x358bf4]
add edi, 4
lea ebx, [esi - 4]
xor eax, eax
mov al, byte [edi]
inc edi
or eax, eax
je 0x737810
cmp al, 0xef
ja 0x737803
add ebx, eax
mov eax, dword [ebx]
xchg ah, al
rol eax, 0x10
xchg ah, al
add eax, esi
mov dword [ebx], eax
jmp 0x7377e5
and al, 0xf
shl eax, 0x10
mov ax, word [edi]
add edi, 2
jmp 0x7377f2
mov ebp, dword [esi + 0x358bfc]
lea edi, [esi - 0x1000]
mov ebx, 0x1000
push eax
push esp
push 4
push ebx
push edi
call ebp
lea eax, [edi + 0x24f]
and byte [eax], 0x7f
and byte [eax + 0x28], 0x7f
pop eax
push eax
push esp
push eax
push ebx
push edi
call ebp
pop eax
popal
lea eax, [esp - 0x80]
push 0
cmp esp, eax
jne 0x737844
sub esp, 0xffffff80
jmp 0x4a423c
Function at 0x4071c8
Capabilities:
Accept command line arguments

Disassembly:
push ebx
push esi
push edi
add esp, 0xfffffdf4
mov ebx, edx
mov esi, eax
mov eax, ebx
call fcn.0040a574
test esi, esi
jne 0x4071fe
push 0x105
lea eax, [esp + 4]
push eax
push 0
call sub.kernel32.dll_GetModuleFileNameW
mov ecx, eax
mov edx, esp
mov eax, ebx
call fcn.0040a6fc
jmp 0x40721c
call sub.kernel32.dll_GetCommandLineW
mov edi, eax
mov edx, ebx
mov eax, edi
call fcn.0040710c
mov edi, eax
test esi, esi
je 0x40721c
cmp dword [ebx], 0
je 0x40721c
dec esi
jmp 0x407205
add esp, 0x20c
pop edi
pop esi
pop ebx
ret

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

Disassembly:
push ebx
push esi
push edi
push ebp
add esp, 0xfffffff0
mov edi, edx
mov esi, eax
mov ebp, dword [esi + 0x10]
mov eax, esi
call fcn.00409618
mov byte [esp], al
cmp byte [esp], 0
jne 0x409315
test edi, edi
je 0x409315
mov byte [esp + 1], 0
test ebp, ebp
jle 0x409255
call sub.kernel32.dll_GetTickCount
mov dword [esp + 4], eax
xor eax, eax
mov dword [esp + 0xc], eax
test ebp, ebp
jle 0x409230
cmp edi, 0xffffffff
je 0x4091f1
call sub.kernel32.dll_GetTickCount
sub eax, dword [esp + 4]
cmp edi, eax
ja 0x4091f1
mov byte [esp], 0
jmp 0x409315
cmp dword [esi], 1
jg 0x409230
cmp dword [esi], 0
jne 0x409222
xor eax, eax
mov edx, 1
lock cmpxchg dword [esi], edx
test eax, eax
jne 0x409222
call sub.kernel32.dll_GetCurrentThreadId
mov dword [esi + 8], eax
mov dword [esi + 4], 1
mov byte [esp], 1
jmp 0x409315
lea eax, [esp + 0xc]
call fcn.00408e48
dec ebp
test ebp, ebp
jg 0x4091d6
cmp edi, 0xffffffff
je 0x409255
call sub.kernel32.dll_GetTickCount
mov dword [esp + 8], eax
mov eax, dword [esp + 8]
sub eax, dword [esp + 4]
cmp edi, eax
ja 0x409253
mov byte [esp], 0
jmp 0x409315
sub edi, eax
mov ebx, dword [esi]
test ebx, ebx
je 0x40919a
lea edx, [ebx + 2]
mov eax, ebx
lock cmpxchg dword [esi], edx
cmp ebx, eax
jne 0x409255
call sub.kernel32.dll_GetTickCount
mov dword [esp + 4], eax
mov eax, esi
call fcn.00409384
mov edx, eax
mov ebx, dword [0x57b8f8]
mov ecx, edi
xor eax, eax
call dword [ebx + 0x10]
test eax, eax
sete byte [esp]
cmp edi, 0xffffffff
je 0x4092b9
call sub.kernel32.dll_GetTickCount
mov dword [esp + 8], eax
mov eax, dword [esp + 8]
sub eax, dword [esp + 4]
cmp edi, eax
jbe 0x4092b7
mov eax, dword [esp + 8]
sub eax, dword [esp + 4]
sub edi, eax
jmp 0x4092b9
xor edi, edi
cmp byte [esp], 0
je 0x4092df
mov ebx, dword [esi]
test bl, 1
jne 0x4092f5
mov edx, ebx
sub edx, 2
or edx, 1
mov eax, ebx
lock cmpxchg dword [esi], edx
cmp ebx, eax
jne 0x4092bf
mov byte [esp + 1], 1
jmp 0x4092f5
mov ebx, dword [esi]
mov edx, ebx
sub edx, 2
mov eax, ebx
lock cmpxchg dword [esi], edx
cmp ebx, eax
jne 0x4092df
mov byte [esp + 1], 1
cmp byte [esp + 1], 0
je 0x40926c
cmp byte [esp], 0
je 0x409315
call sub.kernel32.dll_GetCurrentThreadId
mov dword [esi + 8], eax
mov dword [esi + 4], 1
movzx eax, byte [esp]
add esp, 0x10
pop ebp
pop edi
pop esi
pop ebx
ret
Function at 0x409f58
Capabilities:
Terminate process

Disassembly:
push ecx
push ebx
push esi
push edi
mov ebx, 0x57db98
cmp dword [ebp + 0xc], 2
jl 0x409f6c
mov ebx, 0x57dbc8
mov esi, ebx
lea edi, [ebp - 0x40]
mov ecx, 0xc
rep movsd dword es:[edi], dword [esi]
pop dword [ebx + 0x20]
pop dword [ebx + 0x1c]
pop dword [ebx + 0x18]
mov dword [ebx + 0x14], ebp
mov dword [ebx + 8], eax
mov dword [ebx + 0x10], edx
lea ecx, [ebp - 0x40]
mov dword [ebx], ecx
call sub.kernel32.dll_GetCurrentThreadId
mov dword [ebx + 0x2c], eax
mov eax, dword [ebx + 8]
xor ecx, ecx
cmp dword [ebp + 0xc], 0
jne 0x409fa4
mov ecx, dword [eax]
mov dword [ebx + 0xc], ecx
mov eax, 0x4050fc
mov dword [0x57b01c], eax
mov eax, 0x405104
mov dword [0x57b020], eax
mov eax, ebx
call fcn.00409e3c
mov eax, dword [ebp + 0xc]
inc eax
mov byte [ebx + 0x28], al
dec eax
pop ecx
mov edx, dword [ecx]
mov dword [ebx + 0x24], edx
je 0x409fd9
cmp al, 3
jge 0x409fd9
call dword [ecx + eax*4]
push ecx
mov ecx, dword [esp + 8]
test ecx, ecx
je 0x409fea
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
call ecx
pop ecx
mov eax, dword [ebp + 0xc]
cmp al, 3
jl 0x409ff5
call dword [ecx + eax*4]
cmp dword [0x57b040], 0
jne 0x40a00b
mov byte [0x57b048], 1
fnstcw word [0x573024]
mov eax, dword [ebp + 0xc]
dec eax
jne fcn.0040a2a4
call fcn.00409eec
ret 4

Function at 0x40a20c
Capabilities:
Write file on windows

Disassembly:
push ecx
cmp byte [0x57b058], 0
je 0x40a273
cmp word [0x57b344], 0xd7b2
jne 0x40a235
cmp dword [0x57b34c], 0
jbe 0x40a235
mov eax, 0x57b340
call dword [0x57b35c]
push 0
lea eax, [esp + 4]
push eax
push 0x1d
push str.Runtime_error_____at_00000000
push 0xfffffffffffffff5
call sub.kernel32.dll_GetStdHandle
push eax
call sub.kernel32.dll_WriteFile
push 0
lea eax, [esp + 4]
push eax
push 2
mov eax, 0x40a2a0
call fcn.0040ad58
push eax
push 0xfffffffffffffff5
call sub.kernel32.dll_GetStdHandle
push eax
call sub.kernel32.dll_WriteFile
pop edx
ret
cmp byte [0x57302e], 0
jne 0x40a28f
push 0
push str.Error
push str.Runtime_error_____at_00000000
push 0
call sub.user32.dll_MessageBoxA
pop edx
ret

Function at 0x40a434
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff8
push ebx
push esi
push edi
mov esi, ecx
mov dword [ebp - 8], edx
mov dword [ebp - 4], eax
mov edi, dword [ebp + 0x10]
cmp dword [0x573030], 0
je 0x40a45f
mov edx, edi
mov eax, esi
call dword [0x573030]
mov ebx, eax
jmp 0x40a470
mov eax, 8
call fcn.00406e68
mov ebx, eax
mov dword [ebx], esi
mov dword [ebx + 4], edi
mov byte [0x57b059], 1
mov eax, dword [ebp + 8]
push eax
mov eax, dword [ebp + 0xc]
push eax
push ebx
mov eax, 0x40a3fc
push eax
mov eax, dword [ebp - 8]
push eax
mov eax, dword [ebp - 4]
push eax
call sub.kernel32.dll_CreateThread
mov esi, eax
test esi, esi
jne 0x40a4a0
mov eax, ebx
call fcn.00406e84
mov eax, esi
pop edi
pop esi
pop ebx
pop ecx
pop ecx
pop ebp
ret 0xc
Function at 0x40d1a8
Capabilities:
Get geographical location

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffe98
push ebx
push esi
push edi
xor ecx, ecx
mov dword [ebp - 0x160], ecx
mov dword [ebp - 0x164], ecx
mov dword [ebp - 0x168], ecx
mov dword [ebp - 4], edx
mov esi, eax
xor eax, eax
push ebp
push 0x40d30d
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, dword [ebp - 4]
call fcn.0040a574
cmp si, word [0x573a00]
jb 0x40d240
cmp si, word [0x573c00]
ja 0x40d240
mov edi, 0x40
xor eax, eax
mov dword [ebp - 8], eax
cmp edi, dword [ebp - 8]
jb 0x40d240
mov ebx, edi
add ebx, dword [ebp - 8]
shr ebx, 1
cmp si, word [ebx*8 + 0x573a00]
jae 0x40d21a
mov edi, ebx
dec edi
jmp 0x40d23b
cmp si, word [ebx*8 + 0x573a00]
jbe 0x40d22a
inc ebx
mov dword [ebp - 8], ebx
jmp 0x40d23b
mov edx, dword [ebp - 4]
mov eax, dword [ebx*8 + 0x573a04]
call fcn.0040d0c8
jmp 0x40d240
cmp edi, dword [ebp - 8]
jae 0x40d204
mov eax, dword [ebp - 4]
cmp dword [eax], 0
jne 0x40d2ef
push 2
movzx eax, si
push eax
call sub.kernel32.dll_IsValidLocale
test eax, eax
je 0x40d2ef
push 0x55
lea eax, [ebp - 0xb2]
push eax
push 0x59
movzx ebx, si
push ebx
call sub.kernel32.dll_GetLocaleInfoW
push 0x55
lea eax, [ebp - 0x15c]
push eax
push 0x5a
push ebx
call sub.kernel32.dll_GetLocaleInfoW
lea eax, [ebp - 0x160]
lea edx, [ebp - 0xb2]
mov ecx, 0x55
call fcn.0040b110
push dword [ebp - 0x160]
push 0x40d328
lea eax, [ebp - 0x164]
lea edx, [ebp - 0x15c]
mov ecx, 0x55
call fcn.0040b110
push dword [ebp - 0x164]
push 0x40d338
lea eax, [ebp - 0x168]
lea edx, [ebp - 0xb2]
mov ecx, 0x55
call fcn.0040b110
push dword [ebp - 0x168]
mov eax, dword [ebp - 4]
mov edx, 5
call fcn.0040b348
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x40d314
lea eax, [ebp - 0x168]
mov edx, 3
call fcn.0040a5d4
ret
Function at 0x40d4c0
Capabilities:
Identify system language via api

Disassembly:
push ebp
mov ebp, esp
push 0
push ebx
push esi
mov esi, edx
mov ebx, eax
xor eax, eax
push ebp
push 0x40d5c4
push dword fs:[eax]
mov dword fs:[eax], esp
push 0x57dc10
call sub.kernel32.dll_EnterCriticalSection
cmp bx, word [0x57dc28]
jne 0x40d50c
mov eax, esi
mov edx, 0x57dc2a
mov ecx, 0x55
call fcn.0040b110
push 0x57dc10
call sub.kernel32.dll_LeaveCriticalSection
jmp 0x40d5ae
push 0x57dc10
call sub.kernel32.dll_LeaveCriticalSection
mov eax, esi
call fcn.0040a574
push 2
movzx eax, bx
push eax
call sub.kernel32.dll_IsValidLocale
test eax, eax
je 0x40d57b
cmp byte [0x57dc0c], 0
je 0x40d540
mov edx, esi
mov eax, ebx
call fcn.0040d3a4
jmp 0x40d57b
mov edx, esi
mov eax, ebx
call fcn.0040d1a8
call sub.kernel32.dll_GetSystemDefaultUILanguage
cmp bx, ax
je 0x40d57b
cmp dword [esi], 0
je 0x40d564
mov eax, esi
mov edx, 0x40d5dc
call fcn.0040b268
call sub.kernel32.dll_GetSystemDefaultUILanguage
lea edx, [ebp - 4]
call fcn.0040d1a8
mov edx, dword [ebp - 4]
mov eax, esi
call fcn.0040b268
push 0x57dc10
call sub.kernel32.dll_EnterCriticalSection
mov word [0x57dc28], bx
mov eax, dword [esi]
call fcn.0040b054
mov ecx, eax
mov eax, 0x57dc2a
mov edx, 0xaa
call fcn.0040d028
push 0x57dc10
call sub.kernel32.dll_LeaveCriticalSection
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x40d5cb
lea eax, [ebp - 4]
call fcn.0040a574
ret