joyce8/EMBER2024-capa huggingface dataset:
Function at 0x40503f
Capabilities:
Persist via run registry key
Query or enumerate registry value

Disassembly:
push 0x428
mov eax, 0x500f1c
call fcn.00496990
mov esi, dword [ebp + 8]
mov ebx, dword [ebp + 0xc]
test esi, esi
jne 0x40505f
xor eax, eax
jmp 0x4051b6
xor edi, edi
test ebx, ebx
je 0x405067
mov dword [ebx], edi
push 0x208
lea eax, [ebp - 0x218]
push edi
push eax
call fcn.004d8620
add esp, 0xc
call fcn.004051bc
push 0x50b8c0
test al, al
lea eax, [ebp - 0x218]
push esi
push eax
je 0x4050d0
call dword [sym.imp.SHLWAPI.dll_PathCombineW]
lea ecx, [ebp - 0x42c]
call fcn.004063c4
push ebx
lea eax, [ebp - 0x218]
mov dword [ebp - 4], edi
push eax
push str.ADBlockMasterTray
lea ecx, [ebp - 0x42c]
call fcn.00407ced
lea ecx, [ebp - 0x42c]
mov edi, eax
call fcn.00406938
jmp 0x4051b4
call dword [sym.imp.SHLWAPI.dll_PathCombineW]
lea eax, [ebp - 0x430]
push eax
push 0x20019
push edi
push str.SoftwareMicrosoftWindowsCurrentVersionRun
push SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x4051b4
lea eax, [ebp - 0x434]
mov dword [ebp - 0x434], 0x104
push eax
lea eax, [ebp - 0x420]
push eax
push edi
push edi
push str.ADBlockMasterTray
push dword [ebp - 0x430]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
push dword [ebp - 0x430]
mov esi, eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test esi, esi
jne 0x4051b4
lea eax, [ebp - 0x420]
push eax
lea ecx, [ebp - 0x428]
call fcn.00404804
inc esi
lea ecx, [ebp - 0x428]
mov dword [ebp - 4], esi
call fcn.00405286
lea eax, [ebp - 0x218]
push eax
lea ecx, [ebp - 0x424]
call fcn.00404804
lea ecx, [ebp - 0x424]
mov byte [ebp - 4], 2
call fcn.00405286
push edi
push dword [ebp - 0x424]
lea ecx, [ebp - 0x428]
call fcn.00404dd3
test eax, eax
js 0x405198
mov edi, esi
test ebx, ebx
je 0x405198
mov dword [ebx], esi
mov ecx, dword [ebp - 0x424]
lea ecx, [ecx - 0x10]
call fcn.00405428
mov ecx, dword [ebp - 0x428]
lea ecx, [ecx - 0x10]
call fcn.00405428
mov eax, edi
call fcn.0049693a
ret
Function at 0x407b85
Capabilities:
Get session user name

Disassembly:
push ebp
mov ebp, esp
push ecx
cmp word [0x550200], 0
push esi
mov esi, 0x550200
jne 0x407bac
lea eax, [ebp - 4]
mov dword [ebp - 4], 0x100
push eax
push esi
push 2
call sub.Secur32.dll_GetUserNameExW
mov ecx, dword [ebp + 8]
push esi
call fcn.00404804
mov eax, dword [ebp + 8]
pop esi
leave
ret 4

Function at 0x40b76b
Capabilities:
Get file version info

Disassembly:
push 0x20
mov eax, 0x5018ba
call fcn.0049695c
lea eax, [ebp - 0x14]
xor ebx, ebx
and dword [ebp - 0x14], ebx
push eax
mov eax, dword [ebp + 8]
mov dword [ebp - 0x10], ebx
push dword [eax]
call sub.VERSION.dll_GetFileVersionInfoSizeW
mov esi, eax
test esi, esi
je 0x40b911
push esi
call fcn.00496b0a
mov edi, eax
pop ecx
test edi, edi
je 0x40b911
mov eax, dword [ebp + 8]
push edi
push esi
push dword [ebp - 0x14]
push dword [eax]
call sub.VERSION.dll_GetFileVersionInfoW
test eax, eax
je 0x40b90a
call fcn.0040b9ee
mov ebx, dword [ebp + 0xc]
test al, al
je 0x40b8be
call fcn.0040b96c
test al, al
jne 0x40b8be
and dword [ebp + 8], 0
lea eax, [ebp + 8]
push eax
lea eax, [ebp - 0x28]
push eax
push str.VarFileInfoTranslation
push edi
call sub.VERSION.dll_VerQueryValueW
test eax, eax
je 0x40b8be
xor esi, esi
test dword [ebp + 8], 0xfffffffc
mov dword [ebp - 0x1c], esi
jbe 0x40b8be
and dword [ebp - 4], 0
call fcn.00404f6e
push eax
lea ecx, [ebp - 0x18]
call fcn.004047db
mov ecx, dword [ebp - 0x28]
mov dword [ebp - 4], 1
movzx eax, word [ecx + esi*4 + 2]
push eax
movzx eax, word [ecx + esi*4]
push eax
lea eax, [ebp - 0x18]
push str.StringFileInfo_04x_04xFileVersion
push eax
call fcn.00404e79
mov esi, dword [ebp - 0x18]
lea eax, [ebp - 0x20]
and dword [ebp - 0x24], 0
add esp, 0x10
and dword [ebp - 0x20], 0
push eax
lea eax, [ebp - 0x24]
push eax
push esi
push edi
call sub.VERSION.dll_VerQueryValueW
test eax, eax
jne 0x40b882
or dword [ebp - 4], 0xffffffff
lea ecx, [esi - 0x10]
call fcn.00405428
mov esi, dword [ebp - 0x1c]
mov eax, dword [ebp + 8]
inc esi
shr eax, 2
mov dword [ebp - 0x1c], esi
cmp esi, eax
jb 0x40b80d
jmp 0x40b8be
push dword [ebp - 0x20]
mov ecx, ebx
push dword [ebp - 0x24]
call fcn.00405497
push 0x2e
push 0x2c
mov ecx, ebx
call fcn.0040bad0
push 0x20
mov ecx, ebx
call fcn.0040ba50
or dword [ebp - 4], 0xffffffff
lea ecx, [esi - 0x10]
mov dword [ebp - 0x10], 1
call fcn.00405428
mov eax, dword [ebx]
cmp dword [eax - 0xc], 0
jne 0x40b907
and dword [ebp - 0x1c], 0
lea eax, [ebp - 0x2c]
and dword [ebp - 0x2c], 0
push eax
lea eax, [ebp - 0x1c]
push eax
push 0x50b988
push edi
call sub.VERSION.dll_VerQueryValueW
test eax, eax
je 0x40b907
mov ecx, dword [ebp - 0x1c]
movzx eax, word [ecx + 0xc]
push eax
movzx eax, word [ecx + 0xe]
push eax
movzx eax, word [ecx + 8]
push eax
movzx eax, word [ecx + 0xa]
push eax
push str._d._d._d._d
push ebx
call fcn.00404e79
xor ebx, ebx
add esp, 0x18
inc ebx
jmp 0x40b90a
mov ebx, dword [ebp - 0x10]
push edi
call fcn.00496a8b
pop ecx
mov al, bl
call fcn.00496925
ret
Function at 0x40c245
Capabilities:
Get file version info

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x4010
call fcn.00496b20
mov eax, dword [0x54a708]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov esi, dword [ebp + 8]
lea eax, [ebp - 0x4004]
push edi
mov edi, dword [ebp + 0xc]
xor ebx, ebx
push 0x4000
push ebx
push eax
call fcn.004d8620
add esp, 0xc
mov dword [ebp - 0x4008], ebx
test esi, esi
je 0x40c31f
test edi, edi
je 0x40c31f
lea eax, [ebp - 0x4008]
push eax
push esi
call sub.VERSION.dll_GetFileVersionInfoSizeW
test eax, eax
je 0x40c31f
cmp eax, 0x3fff
ja 0x40c31f
lea ecx, [ebp - 0x4004]
push ecx
push eax
push ebx
push esi
call sub.VERSION.dll_GetFileVersionInfoW
test eax, eax
je 0x40c31f
lea eax, [ebp - 0x4010]
push eax
lea eax, [ebp - 0x400c]
push eax
push 0x50b988
lea eax, [ebp - 0x4004]
push eax
call sub.VERSION.dll_VerQueryValueW
test eax, eax
je 0x40c31f
mov esi, dword [ebp + 0x10]
lea eax, [esi + esi]
push eax
push ebx
push edi
call fcn.004d8620
mov ecx, dword [ebp - 0x400c]
movzx eax, word [ecx + 0xc]
push eax
movzx eax, word [ecx + 0xe]
push eax
movzx eax, word [ecx + 8]
push eax
movzx eax, word [ecx + 0xa]
push eax
push str._d._d._d._d
lea eax, [esi - 1]
push eax
push edi
call fcn.0040c051
xor eax, eax
add esp, 0x28
inc eax
jmp 0x40c321
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00496914
leave
ret

Function at 0x40c435
Capabilities:
Allocate or change rwx memory

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
push edi
mov edi, dword [ebp + 8]
test edi, edi
je 0x40c4a0
cmp dword [ebp + 0xc], 0
je 0x40c4a0
mov esi, dword [ebp + 0x10]
test esi, esi
je 0x40c4a0
push esi
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_IsBadReadPtr]
test eax, eax
jne 0x40c4a0
and dword [ebp + 8], eax
lea eax, [ebp + 8]
push eax
push 0x40
push esi
push edi
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
je 0x40c49a
push esi
push dword [ebp + 0xc]
push edi
call fcn.004d7b20
and dword [ebp - 4], 0
lea eax, [ebp - 4]
add esp, 0xc
push eax
push dword [ebp + 8]
push esi
push edi
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
je 0x40c49a
mov al, 1
jmp 0x40c4a2
call dword [sym.imp.KERNEL32.dll_GetLastError]
xor al, al
pop edi
pop esi
leave
ret
Function at 0x40cd7a
Capabilities:
Link many functions at runtime

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
mov edi, ecx
xor ebx, ebx
cmp dword [edi], ebx
jne 0x40cde5
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov dword [edi], eax
test eax, eax
je 0x40cdf9
push esi
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.CurlInit
push eax
call esi
push str.CurlUninit
push dword [edi]
mov dword [edi + 4], eax
call esi
push str.zlib_uncompress
push dword [edi]
mov dword [edi + 8], eax
call esi
push str.zlib_compress
push dword [edi]
mov dword [edi + 0x10], eax
call esi
push str.zlib_compressBound
push dword [edi]
mov dword [edi + 0x14], eax
call esi
mov dword [edi + 0x18], eax
mov eax, dword [edi + 4]
pop esi
test eax, eax
je 0x40cde5
call eax
mov dword [edi + 0xc], eax
cmp dword [edi + 8], ebx
je 0x40cdf7
cmp dword [edi + 4], ebx
je 0x40cdf7
cmp dword [edi + 0xc], ebx
je 0x40cdf7
xor ebx, ebx
inc ebx
mov eax, ebx
pop edi
pop ebx
pop ebp
ret 4

Function at 0x40cdff
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20c
mov eax, dword [0x54a708]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, ecx
cmp dword [esi + 0x1c], 0
je 0x40ce23
xor eax, eax
inc eax
jmp 0x40ceb0
push edi
push 0x208
lea eax, [ebp - 0x20c]
push 0
push eax
call fcn.004d8620
add esp, 0xc
lea eax, [ebp - 0x20c]
push 0x104
push eax
push 0x400000
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
mov edi, dword [ebp + 8]
test edi, edi
je 0x40ce77
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
sub edi, 1
jne 0x40ce65
push 0x50c96c
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathAppendW]
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
pop edi
test eax, eax
je 0x40ceb0
lea eax, [ebp - 0x20c]
mov dword [esi + 0x1c], 1
push eax
mov ecx, esi
call fcn.0040cd7a
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.00496914
leave
ret 4
Function at 0x40dc5c
Capabilities:
Check if file exists

Disassembly:
push 0x5c
mov eax, 0x501bf7
call fcn.00496990
mov ebx, ecx
mov dword [ebp - 0x68], ebx
push ecx
push ecx
mov eax, esp
mov dword [eax], 0x50c568
mov dword [eax + 4], 6
lea eax, [ebp - 0x28]
push eax
call fcn.0041c4cb
add esp, 0xc
mov dword [ebp - 4], 1
call fcn.00404f6e
push eax
lea ecx, [ebp - 0x60]
call fcn.004047db
cmp dword [ebp - 0x14], 8
lea eax, [ebp - 0x28]
push str.ADBlockMaster_tray.log
cmovae eax, dword [ebp - 0x28]
push eax
lea eax, [ebp - 0x60]
mov byte [ebp - 4], 2
push str._s_s
push eax
call fcn.00404e79
add esp, 0x10
mov byte [ebp - 4], 3
call fcn.00404f6e
push eax
lea ecx, [ebp - 0x64]
call fcn.004047db
mov esi, dword [ebp - 0x60]
lea eax, [ebp - 0x64]
push esi
push str._s.on
push eax
mov byte [ebp - 4], 4
call fcn.00404e79
mov edi, dword [ebp - 0x64]
add esp, 0xc
push edi
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x40dd03
mov byte [ebx + 4], al
jmp 0x40dd76
push 0x28
mov byte [ebx + 4], 1
call fcn.00496a5b
pop ecx
mov dword [ebp - 0x5c], eax
mov byte [ebp - 4], 5
test eax, eax
je 0x40dd24
push esi
mov ecx, eax
call fcn.0040d55e
jmp 0x40dd26
xor eax, eax
mov ecx, dword [ebp - 0x68]
mov dword [ebx + 0x20], eax
mov dword [ebp - 0x5c], eax
mov eax, dword [eax]
mov byte [ebp - 4], 4
mov ebx, dword [eax]
lea eax, [ebp - 0x58]
push eax
call fcn.0040db90
push str._____________________log_start_____________________________r_n
mov ecx, eax
mov byte [ebp - 4], 6
call fcn.0040d9e6
push eax
lea ecx, [ebp - 0x40]
call fcn.0040d52b
mov ecx, dword [ebp - 0x5c]
lea eax, [ebp - 0x40]
push eax
mov byte [ebp - 4], 7
call ebx
lea ecx, [ebp - 0x40]
call fcn.004094aa
lea ecx, [ebp - 0x58]
call fcn.004094aa
lea ecx, [edi - 0x10]
call fcn.00405428
lea ecx, [esi - 0x10]
call fcn.00405428
lea ecx, [ebp - 0x28]
call fcn.004094aa
call fcn.0049693a
ret

Function at 0x40de81
Capabilities:
Print debug messages

Disassembly:
push 0xb4
mov eax, 0x501c27
call fcn.00496990
mov esi, ecx
mov edi, dword [ebp + 8]
push 0x180
push 0x40
push 0x8101
push edi
push esi
call fcn.004dfeba
mov ebx, eax
add esp, 0x14
test ebx, ebx
je 0x40df3a
push 1
push 2
lea ecx, [ebp - 0xc0]
call fcn.0040620f
and dword [ebp - 4], 0
lea eax, [ebp - 0xc0]
push str._error.__
push edi
push str.open
push eax
call fcn.00405645
pop ecx
pop ecx
push eax
call fcn.00405645
pop ecx
pop ecx
push eax
call fcn.00405645
pop ecx
pop ecx
push 0x50c9f4
push ebx
mov ecx, eax
call fcn.0040d6fe
push eax
call fcn.00405645
pop ecx
pop ecx
lea eax, [ebp - 0x28]
push eax
lea ecx, [ebp - 0xbc]
call fcn.0040dfcd
cmp dword [ebp - 0x14], 8
lea eax, [ebp - 0x28]
cmovae eax, dword [ebp - 0x28]
push eax
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
lea ecx, [ebp - 0x28]
call fcn.004094aa
lea ecx, [ebp - 0xc0]
call fcn.00406e45
or eax, 0xffffffff
cmp dword [esi], eax
je 0x40df4f
push 2
push 0
push dword [esi]
call fcn.004e055d
add esp, 0xc
call fcn.0049693a
ret 4
Function at 0x40e0eb
Capabilities:
Print debug messages

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
mov eax, dword [0x54a708]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov esi, ecx
push edi
mov edi, dword [ebp + 8]
cmp byte [esi + 8], 0
je 0x40e112
call fcn.0040df57
mov byte [esi + 8], 0
cmp dword [esi + 4], 0x40000000
jle 0x40e122
mov ecx, esi
call fcn.0040dab6
push 0xfde9
lea eax, [ebp - 0x1c]
push edi
push eax
call fcn.0040e052
add esp, 0xc
lea ecx, [esi + 0x24]
push eax
call fcn.0040d50f
lea ecx, [ebp - 0x1c]
mov ebx, eax
call fcn.00409484
test ebx, ebx
jle 0x40e150
add dword [esi + 4], ebx
jmp 0x40e15f
cmp dword [edi + 0x14], 8
jb 0x40e158
mov edi, dword [edi]
push edi
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00496914
leave
ret 4
Function at 0x41008a
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push 0x424
mov eax, 0x501e71
call fcn.004969fe
mov eax, dword [ebp + 0xc]
xor ebx, ebx
mov esi, dword [ebp + 8]
mov dword [ebp - 0x420], eax
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x41c], eax
mov dword [ebp - 0x430], ebx
mov dword [ebp - 4], ebx
mov dword [ebp - 0x428], ecx
mov dword [ebp - 0x42c], ebx
mov dword [ebp - 0x418], ebx
push 0x60
push ebx
push esi
mov byte [ebp - 4], 1
call dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
mov edi, eax
mov dword [ebp - 0x424], edi
test edi, edi
jne 0x410107
push 2
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
mov edi, eax
mov dword [ebp - 0x424], eax
test edi, edi
jne 0x410107
call fcn.0040eeee
mov esi, eax
jmp 0x4101de
push dword [ebp - 0x41c]
push dword [ebp - 0x420]
push edi
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov esi, eax
test esi, esi
jne 0x41012a
call fcn.0040eeee
jmp 0x4101d1
push esi
push edi
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov dword [ebp - 0x41c], eax
test eax, eax
je 0x410120
push esi
push edi
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov esi, eax
mov dword [ebp - 0x420], esi
lea eax, [esi + 1]
cmp eax, esi
jae 0x41015a
mov esi, 0x8007000e
jmp 0x4101d3
push eax
lea ecx, [ebp - 0x418]
mov byte [ebp - 4], 2
call fcn.0040ed6b
jmp 0x410180
cmp dword [ebp - 0x418], 0
mov dword [ebp - 4], 1
je 0x410153
push esi
push dword [ebp - 0x418]
push esi
push dword [ebp - 0x41c]
push ebx
push 3
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
mov ecx, eax
test ecx, ecx
je 0x410120
mov eax, dword [ebp - 0x418]
xor edx, edx
push dword [ebp + 0x14]
mov word [eax + ecx*2], dx
lea ecx, [ebp - 0x42c]
push dword [ebp - 0x418]
call fcn.0040ff51
mov esi, eax
test edi, edi
je 0x4101de
push edi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
lea eax, [ebp - 0x414]
cmp dword [ebp - 0x418], eax
je 0x4101f7
lea ecx, [ebp - 0x418]
call fcn.0040f39b
mov eax, esi
call fcn.0049694b
ret 0x10
Function at 0x410b45
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
push ecx
mov edx, dword [ebp + 0xc]
push ebx
mov ebx, ecx
test edx, edx
jne 0x410b58
push 0xd
pop eax
jmp 0x410b9c
push esi
xor eax, eax
push edi
mov dword [ebp + 0xc], eax
mov esi, eax
mov edi, edx
mov ecx, edi
lea eax, [ecx + 2]
mov dword [ebp - 4], eax
mov ax, word [ecx]
add ecx, 2
cmp ax, word [ebp + 0xc]
jne 0x410b6b
sub ecx, dword [ebp - 4]
sar ecx, 1
inc ecx
lea edi, [edi + ecx*2]
lea esi, [esi + ecx*2]
cmp ecx, 1
jne 0x410b63
push esi
push edx
push 7
xor eax, eax
push eax
push dword [ebp + 8]
push dword [ebx]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
pop edi
pop esi
pop ebx
leave
ret 8

Function at 0x410ba1
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
mov edx, dword [ebp + 0xc]
push esi
mov esi, ecx
test edx, edx
jne 0x410bb3
push 0xd
pop eax
jmp 0x410be5
mov ecx, edx
push ebx
push edi
xor ebx, ebx
lea edi, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
cmp ax, bx
jne 0x410bbc
sub ecx, edi
sar ecx, 1
lea eax, [ecx*2 + 2]
push eax
push edx
push dword [ebp + 0x10]
push ebx
push dword [ebp + 8]
push dword [esi]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
pop edi
pop ebx
pop esi
pop ebp
ret 0xc
Function at 0x412041
Capabilities:
Connect pipe

Disassembly:
push ebp
mov ebp, esp
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
imul esi, ebx, 0x4058
mov edi, ecx
add esi, edi
push esi
push dword [esi + 0x28]
and dword [esi + 0x4038], 0
call dword [sym.imp.KERNEL32.dll_ConnectNamedPipe]
test eax, eax
je 0x412089
mov byte [esi + 0x2c], 0
mov dword [esi + 0x4038], 1
mov ecx, dword [edi + 0x80ec]
test ecx, ecx
je 0x412089
mov eax, dword [ecx]
push 0
push ebx
push edi
call dword [eax]
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x217
je 0x4120a7
cmp eax, 0x3e5
je 0x4120a1
xor al, al
jmp 0x4120b6
mov byte [esi + 0x2c], 1
jmp 0x4120b0
push dword [esi + 0x10]
call dword [sym.imp.KERNEL32.dll_SetEvent]
mov byte [esi + 0x2d], 0
mov al, 1
pop edi
pop esi
pop ebx
pop ebp
ret 4

Function at 0x4120bd
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push esi
push edi
mov esi, ecx
call fcn.00412293
xor edi, edi
push edi
push 0x40000000
push 3
push edi
push edi
push 0xc0000000
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [esi + 4], eax
cmp eax, 0xffffffff
jne 0x4120f7
call dword [sym.imp.KERNEL32.dll_GetLastError]
xor al, al
jmp 0x41216b
push dword [ebp + 8]
lea ecx, [esi + 0x10]
call fcn.004096d1
push edi
push edi
lea eax, [ebp - 4]
mov dword [ebp - 4], 2
push eax
push dword [esi + 4]
call dword [sym.imp.KERNEL32.dll_SetNamedPipeHandleState]
mov ecx, dword [esi + 0xc]
test ecx, ecx
je 0x412125
mov eax, dword [ecx]
push edi
push esi
call dword [eax]
push edi
push edi
push 1
push edi
call dword [sym.imp.KERNEL32.dll_CreateEventW]
cmp byte [esi + 0x28], 0
mov dword [esi + 8], eax
jne 0x412169
lea eax, [ebp - 8]
push eax
push edi
push esi
push 0x41273e
push edi
push edi
call fcn.004e1152
add esp, 0x18
mov dword [esi], eax
test eax, eax
jne 0x412169
cmp dword [esi + 4], 0xffffffff
je 0x4120f3
push dword [esi + 4]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
or dword [esi + 4], 0xffffffff
jmp 0x4120f3
mov al, 1
pop edi
pop esi
leave
ret 4
Function at 0x412171
Capabilities:
Create pipe
Create thread

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2c
push esi
mov esi, ecx
cmp dword [esi + 0x80c8], 0xffffffff
je 0x41218a
xor al, al
jmp 0x41228e
push ebx
push edi
push 1
lea eax, [ebp - 0x2c]
xor ebx, ebx
push eax
mov dword [ebp - 4], ebx
call dword [sym.imp.ADVAPI32.dll_InitializeSecurityDescriptor]
push ebx
xor edi, edi
lea eax, [ebp - 0x2c]
push ebx
inc edi
push edi
push eax
call dword [sym.imp.ADVAPI32.dll_SetSecurityDescriptorDacl]
lea eax, [ebp - 0x2c]
mov dword [ebp - 0x10], edi
mov dword [ebp - 8], ebx
lea edi, [esi + 0x10]
mov dword [ebp - 0x18], 0xc
lea ebx, [esi + 0x80b4]
mov dword [ebp - 0x14], eax
lea eax, [ebp - 0x18]
push eax
push 0x3e8
push 0x6000
push 0x6000
push 2
push 6
push 0x40000003
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateNamedPipeW]
mov dword [edi + 0x18], eax
cmp eax, 0xffffffff
je 0x41227d
push 0
push 1
push 1
push 0
call dword [sym.imp.KERNEL32.dll_CreateEventW]
mov dword [ebx - 4], eax
xor eax, eax
push eax
push eax
push 1
push eax
call dword [sym.imp.KERNEL32.dll_CreateEventW]
add dword [ebp - 4], 2
mov dword [ebx], eax
mov eax, dword [ebx - 4]
mov dword [edi], eax
mov eax, dword [ebx]
add ebx, 8
mov dword [edi + 0x14], eax
add edi, 0x4058
mov eax, dword [ebp - 8]
inc eax
mov dword [ebp - 8], eax
cmp eax, 2
jb 0x4121c9
xor ebx, ebx
push ebx
push ebx
push 1
push ebx
call dword [sym.imp.KERNEL32.dll_CreateEventW]
mov ecx, dword [ebp - 4]
mov dword [esi + ecx*4 + 0x80b0], eax
mov dword [esi + 0x80c4], eax
lea eax, [ebp - 0xc]
push eax
push ebx
push esi
push 0x4126d7
push ebx
push ebx
call fcn.004e1152
add esp, 0x18
mov dword [esi + 0x80c8], eax
test eax, eax
je 0x41227d
mov al, 1
jmp 0x41228c
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, esi
call fcn.004122e0
xor al, al
pop edi
pop ebx
pop esi
leave
ret 4

Function at 0x41289d
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push ebx
push esi
push edi
imul edi, dword [ebp + 8], 0x4058
mov ebx, 0x2000
push ebx
push 0
add edi, ecx
lea esi, [edi + 0x38]
push esi
call fcn.004d8620
add esp, 0xc
lea eax, [edi + 0x30]
push edi
push eax
push ebx
push esi
push dword [edi + 0x28]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x4128dc
mov byte [edi + 0x2c], 0
mov al, 1
jmp 0x4128f1
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x3e5
jne 0x4128ef
mov byte [edi + 0x2c], 1
jmp 0x4128d8
xor al, al
pop edi
pop esi
pop ebx
pop ebp
ret 4

Function at 0x4128f8
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
and dword [ebp - 4], 0
lea eax, [ebp - 4]
push esi
push 0
push eax
push dword [ebp + 0xc]
mov esi, ecx
push dword [ebp + 8]
push dword [esi + 4]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x412920
xor al, al
jmp 0x412931
mov ecx, dword [esi + 0xc]
test ecx, ecx
je 0x41292f
mov eax, dword [ecx]
push 0
push esi
call dword [eax + 0xc]
mov al, 1
pop esi
leave
ret 8
Function at 0x4129ad
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
push edi
imul edi, dword [ebp + 8], 0x4058
mov esi, ecx
and dword [ebp - 4], 0
lea eax, [edi + 0x14]
add eax, esi
push eax
lea eax, [ebp - 4]
push eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [edi + esi + 0x28]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x4129e7
mov byte [edi + esi + 0x2d], 0
mov al, 1
jmp 0x4129fd
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x3e5
jne 0x4129fb
mov byte [edi + esi + 0x2d], 1
jmp 0x4129e3
xor al, al
pop edi
pop esi
leave
ret 0xc

Function at 0x414127
Capabilities:
Create thread

Disassembly:
push 0x18
mov eax, 0x5021a2
call fcn.0049695c
mov edi, ecx
mov dword [ebp - 0x10], edi
test edi, edi
je 0x414143
push edi
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov ecx, dword [ebp + 8]
xor ebx, ebx
mov dword [ebp - 4], ebx
mov eax, dword [ecx]
mov dword [ebp - 0x1c], eax
mov eax, dword [ecx + 4]
mov dword [ebp - 0x18], eax
lea eax, [ebp - 0x1c]
push eax
lea eax, [ebp - 0x24]
push eax
call fcn.0041435a
pop ecx
pop ecx
lea eax, [ebp - 0x24]
mov dword [ebp - 0x18], ebx
push eax
lea ecx, [ebp - 0x18]
mov dword [ebp - 0x14], ebx
call fcn.0040d304
lea eax, [ebp - 0x18]
mov byte [ebp - 4], 2
push eax
lea ecx, [edi + 0x20]
call fcn.004142f1
mov ecx, dword [ebp - 0x14]
test ecx, ecx
je 0x414193
call fcn.00408755
cmp dword [edi + 0x18], ebx
jne 0x4141b2
lea eax, [edi + 0x1c]
push eax
push ebx
push edi
push 0x414e26
push ebx
push ebx
call fcn.004e1152
add esp, 0x18
mov dword [edi + 0x18], eax
mov bl, 1
mov ecx, dword [ebp - 0x20]
test ecx, ecx
je 0x4141be
call fcn.00408755
push edi
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov al, bl
call fcn.00496925
ret 4