joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4030d5
Capabilities:
Get token membership

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ecx
mov eax, dword fs:[0x30]
and dword [ebp - 4], 0
and dword [ebp - 8], 0
push ebx
push esi
push edi
push 0x44
pop edi
push edi
push 8
push dword [eax + 0x18]
xor bl, bl
call dword [sym.imp.ntdll.dll_RtlAllocateHeap]
mov esi, eax
test esi, esi
jne 0x40311f
push 0x401190
push 0x48
push 0x4011c0
push 1
call fcn.00405676
add esp, 0x10
jmp 0x4031a0
lea eax, [ebp - 8]
mov dword [ebp - 8], edi
push eax
push esi
xor edi, edi
push edi
push 0xb
call dword [sym.imp.ADVAPI32.dll_CreateWellKnownSid]
test eax, eax
jne 0x403155
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x4011d0
push 0x53
push 0x4011c0
push 1
call fcn.00405676
add esp, 0x14
jmp 0x40318e
lea eax, [ebp - 4]
push eax
push esi
push edi
call dword [sym.imp.ADVAPI32.dll_CheckTokenMembership]
test eax, eax
jne 0x403187
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x4011f8
push 0x5c
push 0x4011c0
push 1
call fcn.00405676
add esp, 0x14
mov dword [ebp - 4], edi
jmp 0x40318e
cmp dword [ebp - 4], 1
sete bl
mov ecx, dword fs:[0x30]
push esi
push edi
push dword [ecx + 0x18]
call dword [sym.imp.ntdll.dll_RtlFreeHeap]
pop edi
pop esi
mov al, bl
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x4032fd
Capabilities:
Get common file path

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x20c
mov eax, dword [0x409034]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
push edi
mov edi, 0x104
lea eax, [ebp - 0x20c]
push edi
push eax
xor esi, esi
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
cmp eax, edi
ja 0x403356
test eax, eax
je 0x403356
push 0x401378
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathAppendW]
test eax, eax
je 0x403356
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov esi, eax
mov ecx, dword [ebp - 4]
mov eax, esi
pop edi
xor ecx, ebp
pop esi
call fcn.00407b50
mov esp, ebp
pop ebp
ret
Function at 0x405980
Capabilities:
Write file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push esi
xor eax, eax
mov esi, edx
cmp byte [ebp + 0xc], al
push edi
push 0
setne al
dec eax
and eax, 0x80000000
push eax
push 4
push 0
push 1
push 4
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
cmp edi, 0xffffffff
jne 0x4059b8
mov esi, 0xc0000022
jmp 0x4059df
push 0
lea eax, [ebp - 4]
push eax
push dword [ebp + 8]
push esi
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
neg eax
sbb esi, esi
and esi, 0x3fffffde
add esi, 0xc0000022
push edi
call sub.KERNEL32.dll_CloseHandle
pop edi
mov eax, esi
pop esi
mov esp, ebp
pop ebp
ret 8

Function at 0x4059ee
Capabilities:
Get windows directory from kuser_shared_data

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x20c
mov eax, dword [0x409034]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword fs:[0x30]
and dword [0x4093ac], 0
push ebx
push esi
push 0x2a0
push 8
push dword [eax + 0x18]
call dword [sym.imp.ntdll.dll_RtlAllocateHeap]
mov esi, eax
test esi, esi
jne 0x405a32
mov ebx, 0xc0000017
jmp 0x405b64
push edi
lea eax, [esi + 0x60]
push eax
call dword [sym.imp.ntdll.dll_RtlInitializeCriticalSection]
mov eax, dword fs:[0x30]
lea edi, [esi + 0x78]
push 6
pop ecx
mov ebx, dword [eax + 0x18]
xor eax, eax
rep stosd dword es:[edi], eax
test ebx, ebx
jne 0x405a5d
mov eax, dword fs:[0x30]
mov ebx, dword [eax + 0x18]
mov dword [esi + 0x78], ebx
mov edi, 0x1000
xor ebx, ebx
mov dword [esi + 0x84], edi
mov dword [esi + 0x7c], ebx
mov dword [esi + 0x80], ebx
mov dword [esi + 0x88], ebx
mov dword [esi + 0x8c], ebx
lea eax, [esi + 0x298]
push eax
push ebx
push ebx
push 0x4014e0
call dword [sym.imp.ntdll.dll_EtwEventRegister]
push 0x104
lea eax, [ebp - 0x20c]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
call sub.KERNEL32.dll_GetLastError
test eax, eax
je 0x405abc
mov ebx, 0xc0000001
jmp 0x405b58
lea eax, [ebp - 0x20c]
push 0x5c
push eax
call dword [sym.imp.msvcrt.dll_wcsrchr]
mov ebx, eax
pop ecx
pop ecx
test ebx, ebx
jne 0x405adb
lea ebx, [ebp - 0x20c]
jmp 0x405ade
add ebx, 2
call sub.KERNEL32.dll_GetCurrentProcessId
push eax
push ebx
push 0x401554
push 0x7ffe0030
push 0x402648
lea eax, [esi + 0x90]
push 0x104
push eax
call fcn.00405778
mov ebx, eax
add esp, 0x1c
test ebx, ebx
js 0x405b58
lea eax, [esi + 4]
mov dword [esi], eax
call fcn.00405870
mov ecx, dword [esi]
push ecx
push 0x401554
push ecx
push 0x40
mov dword [ecx + 0x50], eax
mov ecx, dword [esi]
pop edx
call fcn.004057e4
mov eax, dword [esi + 0x80]
cmp eax, edi
jbe 0x405b3e
mov edi, eax
test eax, eax
je 0x405b4e
lea eax, [edi - 1]
not eax
and eax, edi
cmp edi, eax
jne 0x405b4e
mov eax, dword [esi]
mov dword [eax + 0x4c], edi
xor ebx, ebx
mov dword [0x4093ac], esi
xor esi, esi
pop edi
test esi, esi
je 0x405b64
mov ecx, esi
call fcn.00405b7d
mov ecx, dword [ebp - 4]
mov eax, ebx
pop esi
xor ecx, ebp
pop ebx
call fcn.00407b50
mov esp, ebp
pop ebp
ret 4
Function at 0x405bf5
Capabilities:
Print debug messages

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
push esi
mov esi, ecx
mov dword [ebp - 4], edx
push edi
mov edi, dword [ebp + 8]
mov ebx, edx
mov eax, dword [esi]
mov dword [eax + 0x40], 0
mov dword [eax + 0x44], 0
lea eax, [esi + 0x60]
push eax
call dword [sym.imp.ntdll.dll_RtlEnterCriticalSection]
mov eax, dword [esi]
mov edx, dword [esi + 0x7c]
mov ecx, dword [eax + 0x4c]
test ecx, ecx
je 0x405c4d
cmp edi, ecx
jbe 0x405c3a
sub ebx, ecx
add ebx, edi
mov edi, ecx
lea eax, [edx + edi]
cmp eax, ecx
jbe 0x405c4d
sub edx, ecx
lea ecx, [esi + 0x78]
add edx, edi
call fcn.004058d9
test edi, edi
je 0x405d14
mov eax, dword [esi + 0x88]
lea ecx, [eax + edi]
cmp ecx, eax
jb 0x405d14
cmp ecx, dword [esi + 0x80]
jbe 0x405cd5
mov edx, dword [esi + 0x84]
dec edx
lea eax, [edx + ecx]
cmp eax, ecx
jb 0x405d14
mov ecx, dword [esi + 0x8c]
not edx
and eax, edx
mov dword [ebp - 8], eax
push eax
test ecx, ecx
jne 0x405cb6
push ecx
push dword [esi + 0x78]
call dword [sym.imp.ntdll.dll_RtlAllocateHeap]
mov dword [ebp - 0xc], eax
test eax, eax
je 0x405d14
push dword [ebp - 8]
push 0
push eax
call sub.msvcrt.dll_memset
mov eax, dword [ebp - 0xc]
add esp, 0xc
jmp 0x405cc2
push ecx
push 0
push dword [esi + 0x78]
call dword [sym.imp.ntdll.dll_RtlReAllocateHeap]
test eax, eax
je 0x405d14
mov dword [esi + 0x8c], eax
mov eax, dword [ebp - 8]
mov dword [esi + 0x80], eax
mov eax, dword [esi + 0x8c]
add eax, dword [esi + 0x88]
push edi
push ebx
push eax
call sub.msvcrt.dll_memcpy
mov eax, dword [esi + 0x88]
add esp, 0xc
lea ecx, [eax + edi]
cmp ecx, eax
jb 0x405d0d
mov dword [esi + 0x88], ecx
mov eax, dword [esi + 0x7c]
cmp eax, ecx
ja 0x405d08
mov eax, ecx
mov dword [esi + 0x7c], eax
jmp 0x405d14
or dword [esi + 0x88], 0xffffffff
lea edi, [esi + 0x60]
push edi
call dword [sym.imp.ntdll.dll_RtlLeaveCriticalSection]
mov ecx, dword [esi]
mov eax, dword [esi + 0x8c]
mov ebx, dword [ebp - 4]
cdq
mov dword [ecx + 0x40], eax
mov dword [ecx + 0x44], edx
mov ecx, dword [esi]
mov eax, dword [esi + 0x7c]
mov dword [ecx + 0x48], eax
mov eax, dword [esi]
test byte [eax + 0x50], 1
je 0x405d47
push ebx
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
mov eax, dword [esi]
test byte [eax + 0x50], 4
je 0x405d7b
push edi
call dword [sym.imp.ntdll.dll_RtlEnterCriticalSection]
mov eax, dword [esi]
lea ecx, [esi + 0x90]
mov edx, ebx
mov eax, dword [eax + 0x50]
shr eax, 3
and al, 1
movzx eax, al
push eax
push dword [ebp + 8]
call fcn.00405980
push edi
call dword [sym.imp.ntdll.dll_RtlLeaveCriticalSection]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
Function at 0x406cbc
Capabilities:
Check for peb beingdebugged flag

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
push ebx
push edi
mov edi, ecx
mov dword [ebp - 4], edx
mov dword [ebp - 0x14], edi
call sub.api_ms_win_core_processthreads_l1_1_2.dll_GetCurrentThreadId
mov dword [ebp - 0x10], eax
lea eax, [edi + 0x50]
push eax
mov dword [ebp - 0x18], eax
call dword [sym.imp.ntdll.dll_RtlEnterCriticalSection]
xor ebx, ebx
cmp dword [edi + 0x88], ebx
jbe 0x406dc2
lea ecx, [edi + 0x80]
push esi
push ebx
call fcn.00406f15
mov esi, eax
mov eax, dword [ebp - 0x10]
cmp dword [esi], eax
jne 0x406dae
cmp dword [esi + 0x14], 0
jne 0x406dab
mov ecx, dword [ebp - 4]
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x406d1b
sub ecx, edx
cmp dword [ebp + 8], 0
movzx edi, cx
mov dword [ebp - 0xc], edi
je 0x406d44
mov ecx, dword [ebp + 8]
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x406d36
sub ecx, edx
movzx eax, cx
jmp 0x406d47
push 0x10
pop eax
lea ecx, [eax + 2]
mov dword [ebp - 8], eax
mov eax, dword fs:[0x30]
add ecx, edi
push ecx
push 8
push dword [eax + 0x18]
call dword [sym.imp.ntdll.dll_RtlAllocateHeap]
mov edi, eax
test edi, edi
je 0x406dc1
mov edx, dword [ebp - 0xc]
mov eax, dword [ebp - 8]
add edx, 2
add eax, edx
cmp dword [ebp + 8], 0
je 0x406d85
push dword [ebp + 8]
push dword [ebp - 4]
push 0x40277c
jmp 0x406d8f
push 0
push dword [ebp - 4]
push 0x402784
push eax
push edi
call fcn.00405731
add esp, 0x14
test eax, eax
js 0x406dc1
push edi
lea eax, [esi + 0x10]
push eax
call dword [sym.imp.ntdll.dll_RtlInitAnsiString]
mov edi, dword [ebp - 0x14]
inc dword [esi + 0x18]
inc ebx
lea ecx, [edi + 0x80]
cmp ebx, dword [edi + 0x88]
jb 0x406cf8
pop esi
push dword [ebp - 0x18]
call dword [sym.imp.ntdll.dll_RtlLeaveCriticalSection]
pop edi
pop ebx
mov esp, ebp
pop ebp
ret 8

Function at 0x406f55
Capabilities:
Access peb ldr_data
Get ntdll base address

Disassembly:
mov edi, edi
push ebx
push esi
mov esi, ecx
xor ebx, ebx
push edi
cmp dword [esi + 0x14], ebx
je 0x406f6f
push dword [esi + 0x14]
push ebx
push dword [esi]
call dword [sym.imp.ntdll.dll_RtlFreeHeap]
push 6
pop ecx
xor eax, eax
mov edi, esi
rep stosd dword es:[edi], eax
push 6
pop ecx
mov edi, esi
rep stosd dword es:[edi], eax
mov eax, dword fs:[0x30]
pop edi
mov eax, dword [eax + 0x18]
mov dword [esi], eax
xor eax, eax
mov dword [esi + 8], ebx
mov dword [esi + 0xc], ebx
mov dword [esi + 0x14], ebx
mov dword [esi + 0x10], 4
mov dword [esi + 4], 0x1c
pop esi
pop ebx
ret 8
Function at 0x4070ef
Capabilities:
Access peb ldr_data
Get ntdll base address

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ecx
push ebx
push esi
mov esi, ecx
xor ebx, ebx
push edi
cmp dword [esi + 0x14], ebx
je 0x40710e
push dword [esi + 0x14]
push ebx
push dword [esi]
call dword [sym.imp.ntdll.dll_RtlFreeHeap]
push 6
pop ecx
xor eax, eax
mov edi, esi
rep stosd dword es:[edi], eax
push 6
pop ecx
mov edi, esi
rep stosd dword es:[edi], eax
mov eax, dword fs:[0x30]
push 0x28
pop ecx
mov edx, ecx
mov edi, dword [eax + 0x18]
lea eax, [ebp - 8]
mov dword [esi + 4], ecx
xor ecx, ecx
push eax
mov dword [esi], edi
mov dword [esi + 0x10], 0x40
mov dword [esi + 8], ebx
mov dword [esi + 0xc], ebx
mov dword [esi + 0x14], ebx
call fcn.0040603c
test eax, eax
jns 0x407157
mov ebx, 0xc0000095
jmp 0x407199
lea eax, [ebp - 4]
push eax
push 0x28
pop edx
push 0x40
pop ecx
call fcn.0040603c
test eax, eax
js 0x407150
push dword [ebp - 4]
push ebx
push edi
call dword [sym.imp.ntdll.dll_RtlAllocateHeap]
mov edi, eax
test edi, edi
je 0x407194
push dword [ebp - 4]
push ebx
push edi
call sub.msvcrt.dll_memset
add esp, 0xc
mov dword [esi + 0x14], edi
mov dword [esi + 0xc], 0x40
jmp 0x4071b5
mov ebx, 0xc0000017
cmp dword [esi + 0x14], 0
je 0x4071ac
push dword [esi + 0x14]
push 0
push dword [esi]
call dword [sym.imp.ntdll.dll_RtlFreeHeap]
push 6
pop ecx
xor eax, eax
mov edi, esi
rep stosd dword es:[edi], eax
pop edi
pop esi
mov eax, ebx
pop ebx
mov esp, ebp
pop ebp
ret 0xc

Function at 0x4071d9
Capabilities:
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x1c
mov eax, dword [0x409034]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
and dword [ebp - 0x1c], 0
push esi
push edi
mov edi, ecx
lea ecx, [ebp - 0x1c]
push ecx
push 0x14
lea ecx, [ebp - 0x18]
and dword [edi], 0
push ecx
push 2
push eax
push edx
call dword [sym.imp.ntdll.dll_ZwQueryValueKey]
mov esi, eax
test esi, esi
jns 0x407237
cmp esi, 0xc0000034
je 0x40726a
push esi
push 0x402798
push 0x30b
push 0x4027b8
push 1
call fcn.00405676
add esp, 0x14
jmp 0x40726a
cmp dword [ebp - 0x14], 4
jne 0x40724c
cmp dword [ebp - 0x10], 4
jne 0x40724c
mov eax, dword [ebp - 0xc]
xor esi, esi
mov dword [edi], eax
jmp 0x40726a
push 0x4027d4
push 0x312
push 0x4027b8
push 1
call fcn.00405676
add esp, 0x10
mov esi, 0xc0000024
mov ecx, dword [ebp - 4]
mov eax, esi
pop edi
xor ecx, ebp
pop esi
call fcn.00407b50
mov esp, ebp
pop ebp
ret 4
Function at 0x4072e1
Capabilities:
Check for peb beingdebugged flag

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ecx
push esi
push edi
push 0x402824
lea eax, [ebp - 8]
xor edi, edi
push eax
mov esi, ecx
mov dword [ebp - 8], edi
mov dword [ebp - 4], edi
call dword [sym.imp.ntdll.dll_RtlInitUnicodeString]
mov ecx, dword [ebp - 8]
xor eax, eax
mov word [esi], ax
add ecx, 0x7a
mov eax, dword fs:[0x30]
mov word [esi + 2], cx
mov edx, dword [eax + 0x18]
movzx eax, cx
push eax
push 8
push edx
call dword [sym.imp.ntdll.dll_RtlAllocateHeap]
mov dword [esi + 4], eax
test eax, eax
jne 0x407354
movzx eax, word [esi + 2]
mov edi, 0xc0000017
push eax
push 0x402848
push 0x4e8
push 0x402878
push 1
call fcn.00405676
add esp, 0x14
jmp 0x40736b
lea eax, [ebp - 8]
push eax
push esi
call dword [sym.imp.ntdll.dll_RtlAppendUnicodeStringToString]
push 0x4025b8
push esi
call dword [sym.imp.ntdll.dll_RtlAppendUnicodeToString]
mov eax, edi
pop edi
pop esi
mov esp, ebp
pop ebp
ret

Function at 0x407515
Capabilities:
Check for peb beingdebugged flag

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ecx
push ebx
movzx ebx, word [edx]
xor eax, eax
mov dword [ebp - 4], edx
push edi
mov edi, ecx
test bx, bx
jne 0x407536
xor ecx, ecx
and dword [edi + 4], eax
mov dword [edi], ecx
jmp 0x40759e
lea eax, [ebx + 1]
cmp ax, bx
jb 0x407590
and dword [ebp - 8], 0
mov word [edi + 2], ax
mov eax, dword fs:[0x30]
mov ecx, dword [eax + 0x18]
movzx eax, word [edi + 2]
push eax
push 8
push ecx
call dword [sym.imp.ntdll.dll_RtlAllocateHeap]
mov ecx, eax
mov dword [edi + 4], ecx
test ecx, ecx
jne 0x40756d
mov eax, 0xc0000017
jmp 0x40759e
mov eax, dword [ebp - 4]
push esi
mov esi, ebx
push esi
push dword [eax + 4]
push ecx
call sub.msvcrt.dll_memcpy
mov eax, dword [edi + 4]
add esp, 0xc
mov byte [esi + eax], 0
mov eax, dword [ebp - 8]
mov word [edi], bx
pop esi
jmp 0x40759e
mov eax, 0xffff
mov word [edi + 2], ax
mov eax, 0xc0000095
pop edi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x40761c
Capabilities:
Check for peb beingdebugged flag

Disassembly:
mov edi, edi
push esi
mov esi, ecx
test esi, esi
je 0x407656
cmp dword [esi + 4], 0
je 0x40764f
movzx eax, word [esi + 2]
push eax
push 0x42
push dword [esi + 4]
call sub.msvcrt.dll_memset
mov ecx, dword fs:[0x30]
add esp, 0xc
mov edx, dword [esi + 4]
mov ecx, dword [ecx + 0x18]
call fcn.004071c5
and dword [esi], 0
and dword [esi + 4], 0
pop esi
ret

Function at 0x407b40
Capabilities:
Encrypt data using rc4 prga

Disassembly:
pushal
push ebp
mov ebp, esp
sub esp, 0x108
invalid
inc ebp
in al, dx
push es
add byte [eax], al
Function at 0x407c03
Capabilities:
Encrypt data using rc4 prga

Disassembly:
mov dword [ebp - 0x24], 0x40deb0
mov eax, dword [ebp - 0x3c]
imul ecx, dword [ebp - 0xc], 1
xor edx, edx
div ecx
mov dword [ebp - 0x74], eax
mov edi, eax
mov dword [ebp - 0x28], edi
mov eax, 0x12
mov ecx, dword [ebp - 0x14]
cdq
idiv ecx
mov ebx, eax
add ebx, dword [ebp - 0x1c]
mov eax, dword [ebp - 0x10]
add eax, dword [ebp - 0x1c]
cmp ebx, eax
jae 0x407c17
mov eax, dword [ebp - 8]
mov al, byte [eax + ebx]
mov byte [ebp - 1], al
movzx eax, byte [ebp - 1]
mov edx, dword [ebp - 0x28]
add edx, dword [ebp - 0x18]
and edx, 0xff
add byte [eax], al
add byte [ecx], dh
ror byte [eax + 0x458bff45], 1
clc
add byte [eax], al
add byte [ecx], dh
ror byte [eax + 0x458bff45], 1
clc
mov dl, byte [ebp - 1]
mov byte [eax + ebx], dl
inc ebx
jmp 0x407be3
mov dword [ebp - 0x20], 0x49f000
inc dword [ebp - 0x3c]
mov eax, dword [ebp - 0x14]
sub eax, 2
cmp eax, dword [ebp - 0x3c]
jae 0x407bb9
mov dword [ebp - 0x4c], 0x4378b0
mov dword [ebp - 0x50], 0x5b4000
mov eax, dword [ebp - 0xc]
add eax, dword [ebp - 0x14]
mov esi, eax
sub esi, 0xa
jmp 0x407c5a
mov eax, dword [ebp - 0x24]
mov al, byte [eax + esi]
mov byte [ebp - 1], al
mov eax, dword [ebp - 0x20]
mov dl, byte [ebp - 1]
mov byte [eax + esi], dl
inc esi
cmp esi, 0x299ac
jb 0x407c47
mov eax, dword [ebp - 0xc]
sub eax, 4
mov dword [ebp - 0x30], eax
mov eax, dword [ebp - 0x30]
mov edx, dword [ebp - 0x4c]
mov al, byte [edx + eax]
mov byte [ebp - 1], al
mov eax, dword [ebp - 0x30]
mov edx, dword [ebp - 0x50]
mov cl, byte [ebp - 1]
mov byte [edx + eax], cl
inc dword [ebp - 0x30]
inc ebp
sar byte [eax + 0xdae4], 1
cmp eax, dword [ebp - 0x30]
ja 0x407c6b
mov dword [ebp - 0x2c], 0x4458b0
mov dword [ebp - 0x54], 0x10000000
mov dword [ebp - 0x58], 0x44909c
Function at 0x402000
Capabilities:
Get thread local storage value

Disassembly:
push esi
push ebx
sub esp, 0x14
mov dword [esp], 0x408044
call sym._EnterCriticalSection_4
mov ebx, dword [0x40803c]
sub esp, 4
test ebx, ebx
je 0x40204b
nop
mov eax, dword [ebx]
mov dword [esp], eax
call sym._TlsGetValue_4
sub esp, 4
mov esi, eax
call sym._GetLastError_0
test eax, eax
jne 0x402044
test esi, esi
je 0x402044
mov eax, dword [ebx + 4]
mov dword [esp], esi
call eax
mov ebx, dword [ebx + 8]
test ebx, ebx
jne 0x402020
mov dword [esp], 0x408044
call sym._LeaveCriticalSection_4
sub esp, 4
add esp, 0x14
pop ebx
pop esi
ret

Function at 0x402230
Capabilities:
Write file on windows

Disassembly:
push esi
push ebx
sub esp, 0x14
mov eax, dword [sym.imp.msvcrt.dll__iob]
mov dword [esp + 8], 0x17
mov dword [esp + 4], 1
lea esi, [esp + 0x24]
mov dword [esp], str.Mingw_runtime_failure:_n
lea ebx, [eax + 0x40]
mov dword [esp + 0xc], ebx
call sym._fwrite
mov eax, dword [esp + 0x20]
mov dword [esp + 8], esi
mov dword [esp], ebx
mov dword [esp + 4], eax
call sym._vfprintf
call sym._abort
lea esi, [esi]

Function at 0x402280
Capabilities:
Allocate or change rwx memory

Disassembly:
push ebp
push edi
mov edi, ecx
push esi
push ebx
mov ebx, eax
mov esi, edx
sub esp, 0x4c
lea eax, [esp + 0x24]
mov dword [esp + 8], 0x1c
mov dword [esp], ebx
mov dword [esp + 4], eax
call sym._VirtualQuery_12
sub esp, 0xc
test eax, eax
je 0x402358
mov eax, dword [esp + 0x38]
cmp eax, 0x40
je 0x4022be
cmp eax, 4
jne 0x4022e0
mov dword [esp + 8], edi
mov dword [esp + 4], esi
mov dword [esp], ebx
call sym._memcpy
add esp, 0x4c
pop ebx
pop esi
pop edi
pop ebp
ret
mov eax, dword [esp + 0x30]
lea ebp, [esp + 0x20]
mov dword [esp + 8], 0x40
mov dword [esp + 0xc], ebp
mov dword [esp + 4], eax
mov eax, dword [esp + 0x24]
mov dword [esp], eax
call sym._VirtualProtect_16
sub esp, 0x10
mov edx, dword [esp + 0x38]
mov dword [esp + 8], edi
mov dword [esp + 4], esi
mov dword [esp], ebx
mov dword [esp + 0x1c], edx
call sym._memcpy
mov edx, dword [esp + 0x1c]
cmp edx, 0x40
je 0x4022ce
cmp edx, 4
je 0x4022ce
mov eax, dword [esp + 0x20]
mov dword [esp + 0xc], ebp
mov dword [esp + 8], eax
mov eax, dword [esp + 0x30]
mov dword [esp + 4], eax
mov eax, dword [esp + 0x24]
mov dword [esp], eax
call sym._VirtualProtect_16
sub esp, 0x10
add esp, 0x4c
pop ebx
pop esi
pop edi
pop ebp
ret
mov dword [esp + 8], ebx
mov dword [esp + 4], 0x1c
mov dword [esp], str.__VirtualQuery_failed_for__d_bytes_at_address__p
call fcn.00402230
Function at 0x404110
Capabilities:
Accept command line arguments

Disassembly:
lea ecx, [esp + 4]
and esp, 0xfffffff0
push dword [ecx - 4]
push ebp
mov ebp, esp
push esi
push ebx
push ecx
sub esp, 0x6c
call sym.___main
call sym._GetCommandLineA_0
mov ebx, eax
lea eax, [ebp - 0x5c]
mov dword [esp], eax
call sym._GetStartupInfoA_4
sub esp, 4
test ebx, ebx
jne 0x404146
jmp 0x40417e
add ebx, 1
movzx eax, byte [ebx]
cmp al, 0x20
je 0x404143
cmp al, 9
je 0x404143
cmp al, 0x22
jne 0x404167
jmp 0x4041c6
cmp al, 9
je 0x404173
add ebx, 1
movzx eax, byte [ebx]
test al, 0xdf
jne 0x404160
jmp 0x404173
add ebx, 1
movzx eax, byte [ebx]
cmp al, 0x20
je 0x404170
cmp al, 9
je 0x404170
test byte [ebp - 0x30], 1
mov esi, 0xa
je 0x40418d
movzx esi, word [ebp - 0x2c]
mov dword [esp], 0
call sym._GetModuleHandleA_4
sub esp, 4
mov dword [esp + 0xc], esi
mov dword [esp + 8], ebx
mov dword [esp + 4], 0
mov dword [esp], eax
call dbg.WinMain@16
sub esp, 0x10
lea esp, [ebp - 0xc]
pop ecx
pop ebx
pop esi
pop ebp
lea esp, [ecx - 4]
ret
test al, al
je 0x4041d2
mov edx, ebx
add ebx, 1
movzx eax, byte [ebx]
cmp al, 0x22
jne 0x4041c2
cmp al, 0x22
jne 0x404173
lea ebx, [edx + 2]
jmp 0x404173
Function at 0x404e63
Capabilities:
Get disk information

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x4b8
push ebx
push esi
mov esi, dword [ebp + 8]
test esi, esi
je 0x404f13
cmp dword [ebp + 0xc], 0
je 0x404f13
lea eax, [ebp - 0x4b8]
push eax
push 0x3e8
call dword [sym.imp.KERNEL32.dll_GetLogicalDriveStringsW]
test eax, eax
je 0x404f13
mov ax, word [ebp - 0x4b8]
xor ebx, ebx
test ax, ax
je 0x404f13
mov ecx, ebx
movzx edx, ax
mov ax, word [ebp + ecx - 0x4b6]
mov word [ebp - 6], ax
xor eax, eax
mov word [ebp - 4], ax
lea eax, [ebp - 0xd0]
push 0x64
push eax
lea eax, [ebp - 8]
mov word [ebp - 8], dx
push eax
call dword [sym.imp.KERNEL32.dll_QueryDosDeviceW]
test eax, eax
je 0x404efe
lea eax, [ebp - 0xd0]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
push eax
mov dword [ebp + 8], eax
lea eax, [ebp - 0xd0]
push eax
push esi
call fcn.005628b1
add esp, 0xc
test eax, eax
je 0x404f19
add ebx, 4
lea ecx, [ebx + ebx]
movzx eax, word [ebp + ecx - 0x4b8]
mov edx, eax
test ax, ax
jne 0x404eac
xor eax, eax
pop esi
pop ebx
leave
ret
lea eax, [ebp - 8]
push eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
call fcn.00405543
mov ecx, dword [ebp + 8]
lea eax, [esi + ecx*2]
push eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
call fcn.00405504
xor eax, eax
inc eax
jmp 0x404f15