joyce8/EMBER2024-capa huggingface dataset:
Function at 0x10025260
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
mov eax, dword [0x10063040]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
push esi
push edi
mov edi, dword [ebp + 8]
cmp eax, 1
jne 0x10025438
push str.ntdll.dll
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push str.RtlImageNtHeader
push eax
mov dword [0x10067e90], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [0x10066690], eax
lea eax, [ebp - 8]
push eax
push 0
push 2
mov dword [0x10066aa8], edi
mov dword [ebp - 8], 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleExW]
test eax, eax
jne 0x100252e6
push 0x10
push str.GreenLuma_2024
push str.Unable_to_get_exe_path___1_
push eax
call dword [sym.imp.USER32.dll_MessageBoxW]
push 0
call dword [sym.imp.KERNEL32.dll_ExitProcess]
push 0x104
push 0x10067968
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
test eax, eax
jne 0x10025318
push 0x10
push str.GreenLuma_2024
push str.Unable_to_get_exe_path___2_
push eax
call dword [sym.imp.USER32.dll_MessageBoxW]
push 0
call dword [sym.imp.KERNEL32.dll_ExitProcess]
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
nop
call esi
cmp eax, 0x7a
jne 0x10025346
push 0x10
push str.GreenLuma_2024
push str.Unable_to_get_exe_path___3_
push 0
call dword [sym.imp.USER32.dll_MessageBoxW]
push 0
call dword [sym.imp.KERNEL32.dll_ExitProcess]
push 0x104
push 0x10066278
push edi
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
test eax, eax
jne 0x10025376
push 0x10
push str.GreenLuma_2024
push str.Unable_to_get_dll_path___1_
push eax
call dword [sym.imp.USER32.dll_MessageBoxW]
push 0
call dword [sym.imp.KERNEL32.dll_ExitProcess]
call esi
cmp eax, 0x7a
jne 0x10025399
push 0x10
push str.GreenLuma_2024
push str.Unable_to_get_dll_path___2_
push 0
call dword [sym.imp.USER32.dll_MessageBoxW]
push 0
call dword [sym.imp.KERNEL32.dll_ExitProcess]
push 0x10067968
push 0x104
push 0x100682b8
call fcn.1003695d
push 0x10066278
push 0x104
push 0x10072958
call fcn.1003695d
add esp, 0x18
mov edx, str.user32.dll
mov ecx, 0x10072958
call fcn.10001d80
cmp al, 1
jne 0x1002542f
push str.steamclient.dll
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
mov esi, eax
test esi, esi
je 0x10025428
push esi
call dword [0x10066690]
push str.xxx____x____x____
push 0x1005bb84
mov ecx, esi
mov edx, dword [eax + 0x50]
call fcn.10001fc0
add esp, 8
mov dword [0x10072b74], eax
test eax, eax
je 0x10025428
push ecx
lea edx, [ebp - 0xc]
mov word [ebp - 0xc], 0x18eb
call fcn.10002040
add esp, 4
mov byte [0x10065e56], 1
xor ecx, ecx
call fcn.10023500
jmp 0x10025485
test eax, eax
jne 0x10025485
nop dword [eax]
cmp byte [0x10065e55], al
jne 0x10025485
xor edx, edx
xor ecx, ecx
call fcn.10027aa0
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.NtCreateUserProcess
push dword [0x10067e90]
call esi
mov ecx, eax
call fcn.10027960
push str.NtResumeThread
push dword [0x10067e90]
call esi
mov ecx, eax
call fcn.10027960
nop
call fcn.10027560
mov ecx, dword [ebp - 4]
mov eax, 1
pop edi
xor ecx, ebp
pop esi
call fcn.1002c6a1
mov esp, ebp
pop ebp
ret 0xc
Function at 0x10027060
Capabilities:
Enumerate threads

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [0x10063040]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
xor ebx, ebx
mov esi, ecx
push ebx
push 4
call dword [sym.imp.KERNEL32.dll_CreateToolhelp32Snapshot]
mov edi, eax
mov dword [ebp - 0x24], edi
cmp edi, 0xffffffff
je 0x100271d8
lea eax, [ebp - 0x20]
mov dword [ebp - 0x20], 0x1c
xorps xmm0, xmm0
push eax
push edi
movlpd qword [ebp - 0x1c], xmm0
movlpd qword [ebp - 0x14], xmm0
movlpd qword [ebp - 0xc], xmm0
call dword [sym.imp.KERNEL32.dll_Thread32First]
nop dword [eax + eax]
test eax, eax
je 0x100271d1
mov ebx, 1
nop dword [eax]
cmp dword [ebp - 0x20], 0x10
jb 0x1002715f
nop word [eax + eax]
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
cmp dword [ebp - 0x14], eax
jne 0x1002715f
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
cmp dword [ebp - 0x18], eax
je 0x1002715f
mov edx, dword [esi]
test edx, edx
jne 0x10027123
push 0x200
push 8
push dword [0x10072fa0]
mov dword [esi + 4], 0x80
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov edx, eax
mov dword [esi], edx
test edx, edx
je 0x10027185
lea edi, [esi + 8]
jmp 0x10027152
mov eax, dword [esi + 4]
lea edi, [esi + 8]
cmp dword [edi], eax
jb 0x10027152
add eax, eax
mov dword [esi + 4], eax
shl eax, 2
push eax
push edx
push 8
push dword [0x10072fa0]
call dword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov edx, eax
test edx, edx
je 0x100271eb
mov dword [esi], edx
mov ecx, dword [edi]
mov eax, dword [ebp - 0x18]
mov dword [edx + ecx*4], eax
inc dword [edi]
mov edi, dword [ebp - 0x24]
lea eax, [ebp - 0x20]
mov dword [ebp - 0x20], 0x1c
push eax
push edi
call dword [sym.imp.KERNEL32.dll_Thread32Next]
test eax, eax
jne 0x100270d0
call dword [sym.imp.KERNEL32.dll_GetLastError]
nop
cmp eax, 0x12
je 0x100271d1
mov eax, dword [esi]
xor ebx, ebx
test eax, eax
je 0x100271d1
push eax
push ebx
push dword [0x10072fa0]
call dword [sym.imp.KERNEL32.dll_HeapSize]
mov ecx, eax
cmp ecx, 0xffffffff
je 0x100271bb
test ecx, ecx
je 0x100271bb
mov eax, dword [esi]
nop dword [eax + eax]
mov byte [eax], 0
lea eax, [eax + 1]
sub ecx, 1
jne 0x100271b0
push dword [esi]
push 0
push dword [0x10072fa0]
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov dword [esi], 0
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 4]
mov eax, ebx
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.1002c6a1
mov esp, ebp
pop ebp
ret
mov edi, dword [ebp - 0x24]
jmp 0x10027185
Function at 0x10027200
Capabilities:
Suspend thread

Disassembly:
push ebp
mov ebp, esp
push ecx
push edi
mov edi, ecx
mov dword [ebp - 4], edx
mov dword [edi], 0
mov dword [edi + 4], 0
mov dword [edi + 8], 0
call fcn.10027060
test eax, eax
jne 0x10027233
mov eax, 9
pop edi
mov esp, ebp
pop ebp
ret
cmp dword [edi], 0
je 0x1002728e
push esi
xor esi, esi
cmp dword [edi + 8], esi
jbe 0x10027286
push ebx
mov eax, dword [edi]
push dword [eax + esi*4]
push 0
push 0x5a
call dword [sym.imp.KERNEL32.dll_OpenThread]
mov ebx, eax
test ebx, ebx
je 0x1002727d
push ebx
call dword [sym.imp.KERNEL32.dll_SuspendThread]
push dword [ebp + 8]
mov edx, dword [ebp - 4]
mov ecx, ebx
call fcn.10026ec0
add esp, 4
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
inc esi
cmp esi, dword [edi + 8]
jb 0x10027246
pop ebx
pop esi
xor eax, eax
pop edi
mov esp, ebp
pop ebp
ret
xor eax, eax
pop edi
mov esp, ebp
pop ebp
ret

Function at 0x100272a0
Capabilities:
Resume thread

Disassembly:
push edi
mov edi, ecx
cmp dword [edi], 0
je 0x10027326
push esi
xor esi, esi
cmp dword [edi + 8], esi
jbe 0x100272e6
push ebx
mov eax, dword ds:[edi]
push dword [eax + esi*4]
push 0
push 0x5a
call dword [sym.imp.KERNEL32.dll_OpenThread]
mov ebx, eax
test ebx, ebx
je 0x100272da
push ebx
call dword [sym.imp.KERNEL32.dll_ResumeThread]
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
inc esi
cmp esi, dword [edi + 8]
jb 0x100272b1
pop ebx
push dword [edi]
push 0
push dword [0x10072fa0]
call dword [sym.imp.KERNEL32.dll_HeapSize]
pop esi
cmp eax, 0xffffffff
je 0x10027311
nop dword [eax]
test eax, eax
je 0x10027311
mov ecx, dword [edi]
mov byte [ecx], 0
lea ecx, [ecx + 1]
sub eax, 1
jne 0x10027306
push dword ds:[edi]
push 0
push dword [0x10072fa0]
call dword [sym.imp.KERNEL32.dll_HeapFree]
pop edi
ret
Function at 0x10027340
Capabilities:
Allocate or change rwx memory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
mov eax, dword [0x10063040]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
imul esi, ecx, 0x2c
mov ebx, edx
mov dword [ebp - 8], 0
push edi
add esi, dword [0x10072fd4]
mov eax, dword [esi]
mov cl, byte [esi + 0x14]
and cl, 1
lea edi, [eax - 5]
cmove edi, eax
movzx eax, cl
lea ecx, [ebp - 8]
push ecx
push 0x40
lea eax, [eax*2 + 5]
push eax
push edi
mov dword [ebp - 0xc], eax
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x100273a9
pop edi
pop esi
mov eax, 0xa
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1002c6a1
mov esp, ebp
pop ebp
ret
test ebx, ebx
je 0x100273cb
mov byte ds:[edi], 0xe9
mov eax, dword [esi + 4]
sub eax, edi
sub eax, 5
mov dword [edi + 1], eax
test byte [esi + 0x14], 1
je 0x100273ec
mov eax, dword [esi]
mov word [eax], 0xf9eb
jmp 0x100273ec
mov eax, dword [esi + 0xc]
test byte [esi + 0x14], 1
mov dword [edi], eax
je 0x100273e6
mov ax, word [esi + 0x10]
mov word [edi + 4], ax
mov al, byte [esi + 0x12]
mov byte [edi + 6], al
jmp 0x100273ec
mov al, byte [esi + 0x10]
mov byte [edi + 4], al
lea eax, [ebp - 8]
push eax
push dword [ebp - 8]
push dword [ebp - 0xc]
push edi
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
push dword [ebp - 0xc]
push edi
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.KERNEL32.dll_FlushInstructionCache]
mov cl, bl
xor eax, eax
add cl, cl
shl bl, 2
xor cl, byte [esi + 0x14]
and cl, 2
xor cl, byte [esi + 0x14]
xor bl, cl
and bl, 4
xor bl, cl
mov ecx, dword [ebp - 4]
pop edi
mov byte [esi + 0x14], bl
xor ecx, ebp
pop esi
pop ebx
call fcn.1002c6a1
mov esp, ebp
pop ebp
ret
Function at 0x100300d2
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x101c
call fcn.1004a7b0
mov eax, dword [0x10063040]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0x14]
push ebx
push dword [ebp + 8]
mov dword [ebp - 0x100c], eax
call fcn.1003bb72
pop ecx
mov ecx, dword [ebp + 8]
mov ebx, eax
cmp dword [ecx + 8], 0
jne 0x10030114
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
jmp 0x10030270
mov eax, dword [ecx]
sub eax, dword [ecx + 4]
push esi
push edi
push 0
cdq
push 2
push edx
push eax
call fcn.1004a700
push dword [ebp - 0x100c]
mov ecx, ebx
mov dword [ebp - 0x1008], eax
mov esi, ebx
mov dword [ebp - 0x1018], edx
and ecx, 0x3f
sar esi, 6
imul edi, ecx, 0x38
push 0
mov eax, dword [esi*4 + 0x100658b8]
push dword [eax + edi + 0x24]
push dword [eax + edi + 0x20]
push ebx
call fcn.1003bd81
mov ecx, dword [esi*4 + 0x100658b8]
add esp, 0x14
mov dword [ebp - 0x1010], eax
mov eax, edx
mov edx, dword [ebp - 0x1010]
mov dword [ebp - 0x101c], eax
cmp edx, dword [ecx + edi + 0x20]
jne 0x10030269
cmp eax, dword [ecx + edi + 0x24]
jne 0x10030269
push 0
lea eax, [ebp - 0x1014]
push eax
push 0x1000
lea eax, [ebp - 0x1004]
push eax
push dword [ecx + edi + 0x18]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x10030269
push dword [ebp - 0x100c]
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.1003bd81
add esp, 0x14
test edx, edx
jl 0x10030269
jg 0x100301df
test eax, eax
jb 0x10030269
mov ebx, dword [ebp - 0x1018]
mov eax, dword [ebp - 0x1014]
test ebx, ebx
jg 0x10030269
jl 0x100301f9
cmp dword [ebp - 0x1008], eax
ja 0x10030269
lea edi, [ebp - 0x1004]
xor edx, edx
add edi, eax
lea ecx, [ebp - 0x1004]
xor esi, esi
cmp dword [ebp - 0x1008], edx
jne 0x10030217
test ebx, ebx
je 0x10030250
cmp ecx, edi
jae 0x10030250
mov al, byte [ecx]
cmp al, 0xd
jne 0x10030231
lea eax, [edi - 1]
cmp ecx, eax
jae 0x1003023d
cmp byte [ecx + 1], 0xa
jne 0x1003023d
inc ecx
jmp 0x1003023d
movzx eax, al
movsx eax, byte [eax + 0x10063240]
add ecx, eax
add esi, 1
adc edx, 0
inc ecx
cmp esi, dword [ebp - 0x1008]
jne 0x10030217
cmp edx, ebx
jne 0x10030217
lea eax, [ebp - 0x1004]
sub ecx, eax
mov eax, ecx
cdq
add eax, dword [ebp - 0x1010]
adc edx, dword [ebp - 0x101c]
jmp 0x1003026e
or edx, 0xffffffff
mov eax, edx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.1002c6a1
leave
ret

Function at 0x1003ac83
Capabilities:
Parse pe header

Disassembly:
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
je 0x1003acc2
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x1003acc2
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x1003acc2
mov eax, 0x10b
cmp word [ecx + 0x18], ax
jne 0x1003acc2
cmp dword [ecx + 0x74], 0xe
jbe 0x1003acc2
cmp dword [ecx + 0xe8], 0
setne al
ret
xor al, al
ret
Function at 0x1003c4f2
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword [ebp + 8]
mov ecx, eax
push ebx
mov ebx, dword [ebp + 0xc]
and eax, 0x3f
sar ecx, 6
push esi
push edi
imul edi, eax, 0x38
mov eax, dword [ecx*4 + 0x100658b8]
mov dword [ebp - 0xc], ecx
mov ecx, dword [edi + eax + 0x18]
mov dword [ebp - 0x14], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x1003c532
cmp byte [ebx], 0xa
jne 0x1003c532
or byte [edi + eax + 0x28], 4
jmp 0x1003c537
and byte [edi + eax + 0x28], 0xfb
add ecx, ebx
mov eax, ebx
mov dword [ebp - 0x10], ecx
mov esi, ebx
mov dword [ebp - 8], eax
cmp ebx, ecx
jae 0x1003c636
mov dl, byte [eax]
cmp dl, 0x1a
je 0x1003c619
inc eax
cmp dl, 0xd
je 0x1003c563
mov dword [ebp - 8], eax
mov byte [esi], dl
jmp 0x1003c589
cmp eax, ecx
jae 0x1003c597
mov cl, byte [eax]
xor eax, eax
cmp cl, 0xa
sete al
inc eax
add dword [ebp - 8], eax
cmp cl, 0xa
sete al
dec al
and al, 3
add al, 0xa
mov byte [esi], al
mov eax, dword [ebp - 8]
mov ecx, dword [ebp - 0x10]
xor edx, edx
inc edx
add esi, edx
cmp eax, ecx
jb 0x1003c54b
jmp 0x1003c636
push 0
lea eax, [ebp - 0x10]
push eax
push 1
lea eax, [ebp - 1]
push eax
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x1003c614
cmp dword [ebp - 0x10], 0
je 0x1003c614
mov ecx, dword [ebp - 0xc]
mov eax, dword [ecx*4 + 0x100658b8]
test byte [eax + edi + 0x28], 0x48
je 0x1003c5ee
mov dl, byte [ebp - 1]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
cmp dl, 0xa
jne 0x1003c5d9
mov byte [esi], dl
jmp 0x1003c5ea
mov byte [esi], 0xd
mov eax, dword [ecx*4 + 0x100658b8]
mov byte [eax + edi + 0x2a], dl
mov eax, dword [ebp - 0x14]
mov esi, eax
jmp 0x1003c636
cmp byte [ebp - 1], 0xa
jne 0x1003c5fd
cmp esi, ebx
jne 0x1003c5fd
mov byte [esi], 0xa
jmp 0x1003c635
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.1003bd9f
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x1003c636
mov byte [esi], 0xd
jmp 0x1003c635
mov ecx, dword [ebp - 0xc]
mov ecx, dword [ecx*4 + 0x100658b8]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x1003c633
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x1003c636
mov byte [esi], dl
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x1003c63f
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x1c
mov eax, dword [ebp + 8]
mov ecx, eax
push ebx
mov ebx, dword [ebp + 0xc]
and eax, 0x3f
push esi
sar ecx, 6
push edi
imul edi, eax, 0x38
mov dword [ebp - 8], ecx
mov eax, dword [ecx*4 + 0x100658b8]
push 0xa
pop edx
mov dword [ebp - 0x18], edx
mov ecx, dword [eax + edi + 0x18]
mov dword [ebp - 0x1c], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x1003c685
cmp word [ebx], dx
jne 0x1003c685
or byte [eax + edi + 0x28], 4
jmp 0x1003c68a
and byte [eax + edi + 0x28], 0xfb
lea edx, [ebx + ecx*2]
mov eax, ebx
mov dword [ebp - 0xc], edx
mov esi, ebx
mov dword [ebp - 4], eax
cmp ebx, edx
jae 0x1003c7ed
mov dword [ebp - 0x10], 0xd
movzx ecx, word [eax]
mov edx, ecx
mov dword [ebp - 0x14], edx
mov edx, dword [ebp - 0xc]
cmp ecx, 0x1a
je 0x1003c7cd
add eax, 2
cmp cx, word [ebp - 0x10]
je 0x1003c6cb
mov dword [ebp - 4], eax
mov word [esi], cx
jmp 0x1003c701
cmp eax, edx
jae 0x1003c70f
movzx eax, word [eax]
xor ecx, ecx
cmp ax, word [ebp - 0x18]
mov edx, eax
push 0xa
sete cl
xor eax, eax
lea ecx, [ecx*2 + 2]
add dword [ebp - 4], ecx
pop ecx
cmp dx, cx
mov edx, dword [ebp - 0xc]
sete al
dec eax
and eax, 3
add eax, ecx
mov word [esi], ax
mov eax, dword [ebp - 4]
push 2
pop ecx
add esi, ecx
cmp eax, edx
jb 0x1003c6a6
jmp 0x1003c7ed
push 0
lea eax, [ebp - 0x18]
push eax
push 2
lea eax, [ebp - 4]
push eax
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x1003c7c8
cmp dword [ebp - 0x18], 0
je 0x1003c7c8
mov edx, dword [ebp - 8]
push 0xa
mov eax, dword [edx*4 + 0x100658b8]
test byte [eax + edi + 0x28], 0x48
je 0x1003c79e
lea eax, [esi + 2]
mov dword [ebp - 0x1c], eax
mov ax, word [ebp - 4]
pop ecx
mov word [ebp - 2], ax
cmp ax, cx
jne 0x1003c762
mov word [esi], cx
jmp 0x1003c799
push 0xd
pop ecx
mov word [esi], cx
movzx ecx, ax
mov eax, dword [edx*4 + 0x100658b8]
mov dx, word [ebp - 2]
shr ecx, 8
push 0xa
mov byte [eax + edi + 0x2a], dl
mov edx, dword [ebp - 8]
mov eax, dword [edx*4 + 0x100658b8]
mov byte [eax + edi + 0x2b], cl
mov eax, dword [edx*4 + 0x100658b8]
pop ecx
mov byte [eax + edi + 0x2c], cl
mov esi, dword [ebp - 0x1c]
jmp 0x1003c7ed
pop eax
cmp word [ebp - 4], ax
jne 0x1003c7ae
cmp esi, ebx
jne 0x1003c7ae
mov word [esi], ax
jmp 0x1003c7ea
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.1003bd9f
add esp, 0x10
push 0xa
pop eax
cmp word [ebp - 4], ax
je 0x1003c7ed
push 0xd
pop eax
jmp 0x1003c7a9
mov edx, dword [ebp - 8]
mov edx, dword [edx*4 + 0x100658b8]
mov al, byte [edx + edi + 0x28]
test al, 0x40
jne 0x1003c7e7
or al, 2
mov byte [edx + edi + 0x28], al
jmp 0x1003c7ed
mov word [esi], cx
add esi, 2
sub esi, ebx
and esi, 0xfffffffe
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x1003ec5a
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x1004daf8
push 0x1004daf0
push str.FlsAlloc
push 0x1f
call fcn.1003eb19
mov esi, eax
add esp, 0x10
test esi, esi
je 0x1003ec8e
push dword [ebp + 8]
mov ecx, esi
call dword [0x1004b1d0]
call esi
jmp 0x1003ec94
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x1003ecd8
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x1004db08
push 0x1004db00
push str.FlsGetValue
push 0x21
call fcn.1003eb19
mov esi, eax
add esp, 0x10
test esi, esi
je 0x1003ed0f
push dword [ebp + 8]
mov ecx, esi
call dword [0x1004b1d0]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]

Function at 0x1003ed17
Capabilities:
Set thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x1004db10
push 0x1004db08
push str.FlsSetValue
push 0x22
call fcn.1003eb19
mov esi, eax
add esp, 0x10
test esi, esi
je 0x1003ed51
push dword [ebp + 0xc]
mov ecx, esi
push dword [ebp + 8]
call dword [0x1004b1d0]
call esi
pop esi
pop ebp
ret 8
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsSetValue]
Function at 0x10041d63
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
mov esi, eax
test esi, esi
je 0x10041e00
push ebx
push esi
call fcn.10041d2c
xor ebx, ebx
sub eax, esi
push ebx
push ebx
push ebx
push ebx
sar eax, 1
push eax
push esi
push ebx
push ebx
mov dword [ebp - 8], eax
call fcn.10041cc0
add esp, 0x24
mov dword [ebp - 4], eax
test eax, eax
jne 0x10041dad
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x10041dff
push edi
push eax
call fcn.1003d09e
mov edi, eax
pop ecx
push ebx
test edi, edi
jne 0x10041dcd
call fcn.1003d064
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x10041dfe
push ebx
push dword [ebp - 4]
push edi
push dword [ebp - 8]
push esi
push ebx
push ebx
call fcn.10041cc0
add esp, 0x20
test eax, eax
jne 0x10041dec
push edi
call fcn.1003d064
jmp 0x10041df4
push ebx
call fcn.1003d064
mov ebx, edi
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov eax, ebx
pop edi
pop ebx
pop esi
leave
ret

Function at 0x10041e03
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push esi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
mov esi, eax
test esi, esi
jne 0x10041e14
pop esi
ret
push ebx
push edi
push esi
call fcn.10041d2c
mov ebx, eax
sub ebx, esi
and ebx, 0xfffffffe
push ebx
call fcn.1003d09e
mov edi, eax
pop ecx
pop ecx
test edi, edi
je 0x10041e3c
push ebx
push esi
push edi
call fcn.1002e340
add esp, 0xc
push 0
call fcn.1003d064
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov eax, edi
pop edi
pop ebx
pop esi
ret

Function at 0x1004220c
Capabilities:
Set environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.10041e51
Function at 0x10048421
Capabilities:
Clear file content

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x2c
push ebx
mov ebx, dword [ebp + 8]
lea ecx, [ebp - 0x2c]
push esi
push edi
push dword [ebp + 0x10]
mov edi, dword [ebp + 0x14]
push dword [ebp + 0xc]
push ebx
call fcn.1004839d
mov eax, dword [ebp - 0x2c]
and eax, dword [ebp - 0x28]
cmp eax, 0xffffffff
je 0x10048590
mov eax, dword [ebp - 0x24]
and eax, dword [ebp - 0x20]
cmp eax, 0xffffffff
je 0x10048590
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 8], ecx
mov dword [ebp - 4], eax
test ecx, ecx
jl 0x10048545
jg 0x1004847d
test eax, eax
je 0x1004853b
push 1
push 0x1000
call fcn.1003e989
mov esi, eax
pop ecx
pop ecx
test esi, esi
jne 0x100484a0
push 0xc
pop ebx
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], ebx
jmp 0x10048532
push 0x8000
push ebx
call fcn.100482ce
pop ecx
pop ecx
mov ecx, dword [ebp - 0x1c]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0x18]
test eax, eax
jl 0x100484c9
jg 0x100484c4
cmp ecx, 0x1000
jb 0x100484c9
mov ecx, 0x1000
push edi
push ecx
push esi
push ebx
call fcn.1004667e
add esp, 0x10
cmp eax, 0xffffffff
je 0x1004850e
mov ecx, dword [ebp - 4]
cdq
sub ecx, eax
mov eax, dword [ebp - 8]
mov dword [ebp - 4], ecx
sbb eax, edx
mov dword [ebp - 8], eax
test eax, eax
jg 0x100484c4
jl 0x100484f5
test ecx, ecx
jne 0x100484b6
push dword [ebp - 0xc]
push ebx
call fcn.100482ce
push esi
call fcn.1003d064
add esp, 0xc
xor ebx, ebx
jmp 0x1004859e
cmp byte [edi + 0x24], 0
je 0x10048525
cmp dword [edi + 0x20], 5
jne 0x10048525
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], 0xd
cmp byte [edi + 0x1c], 0
je 0x10048530
mov ebx, dword [edi + 0x18]
jmp 0x10048532
xor ebx, ebx
push esi
call fcn.1003d064
pop ecx
jmp 0x1004859e
test ecx, ecx
jg 0x10048507
jl 0x10048545
test eax, eax
jae 0x10048507
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.1003bd9f
and eax, edx
add esp, 0x10
cmp eax, 0xffffffff
jne 0x10048565
cmp byte [edi + 0x1c], 0
je 0x10048507
jmp 0x10048596
push ebx
call fcn.10042a9c
pop ecx
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x10048507
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 0xd
mov byte [edi + 0x24], 1
mov dword [edi + 0x20], eax
pop ebx
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], ebx
jmp 0x1004859e
cmp byte [edi + 0x1c], 0
je 0x1004859b
mov ebx, dword [edi + 0x18]
jmp 0x1004859e
push 0x16
pop ebx
push 0
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
push dword [ebp - 0x14]
call fcn.1003bd9f
add esp, 0x10
mov eax, ebx
pop edi
pop esi
pop ebx
leave
ret

Function at 0x1004a650
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x1004a67d
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x1004a67d
mov edx, 0x10b
xor eax, eax
cmp word [ecx + 0x18], dx
sete al
pop ebp
ret
xor eax, eax
pop ebp
ret

Function at 0x401245
Capabilities:
Allocate or change rwx memory

Disassembly:
pop ebx
call fcn.0040123d
jmp 0x401194