joyce8/EMBER2024-capa huggingface dataset:
Function at 0x493fbe
Capabilities:
Unmount volume via ioctl

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x108
push 0x104
push 0
lea eax, [ebp - 0x108]
push eax
call fcn.004a9cd0
add esp, 0xc
cmp dword [0x528494], 0
je 0x49402d
mov ecx, dword [ebp + 8]
mov edx, dword [ecx*4 + 0x52994c]
push edx
lea eax, [ebp - 0x108]
push eax
call fcn.0049445b
add esp, 8
test eax, eax
jne 0x49402b
mov ecx, dword [ebp + 8]
sub ecx, 1
imul ecx, ecx, 0xff
add ecx, 0x529e08
push ecx
push 0x525064
lea edx, [ebp - 0x108]
push edx
call fcn.004aa1dd
add esp, 0xc
jmp 0x49407c
mov eax, dword [ebp + 8]
movsx ecx, byte [eax + 0x5299c8]
cmp ecx, 0x43
jl 0x49405d
mov edx, dword [ebp + 8]
movsx eax, byte [edx + 0x5299c8]
push eax
push 0x525068
lea ecx, [ebp - 0x108]
push ecx
call fcn.004aa1dd
add esp, 0xc
jmp 0x49407c
mov edx, dword [ebp + 8]
movsx eax, byte [edx + 0x5299c8]
push eax
push 0x525070
lea ecx, [ebp - 0x108]
push ecx
call fcn.004aa1dd
add esp, 0xc
mov edx, dword [ebp + 0xc]
mov dword [edx], 0xffffffff
push 0
push 0
push 3
push 0
push 3
push 0xc0000000
lea eax, [ebp - 0x108]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ecx, dword [ebp + 0xc]
mov dword [ecx], eax
mov edx, dword [ebp + 0xc]
cmp dword [edx], 0xffffffff
jne 0x4940b2
xor eax, eax
jmp 0x494112
cmp dword [ebp + 0x10], 0
jne 0x4940bf
mov eax, 1
jmp 0x494112
push 0
lea eax, [ebp - 4]
push eax
push 0
push 0
push 0
push 0
push 0x90018
mov ecx, dword [ebp + 0xc]
mov edx, dword [ecx]
push edx
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
mov eax, dword [ebp + 8]
xor ecx, ecx
mov cl, byte [eax + 0x529990]
cmp ecx, 1
jne 0x49410d
push 0
lea edx, [ebp - 4]
push edx
push 0
push 0
push 0
push 0
push 0x90020
mov eax, dword [ebp + 0xc]
mov ecx, dword [eax]
push ecx
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
mov eax, 1
mov esp, ebp
pop ebp
ret

Function at 0x494346
Capabilities:
Get disk information via ioctl

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
mov dword [ebp - 0x18], 0xffffffff
mov dword [ebp - 4], 0
push 0
push 0
push 3
push 0
push 3
push 0
mov eax, dword [ebp + 8]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [ebp - 0x18], eax
cmp dword [ebp - 0x18], 0xffffffff
je 0x4943bc
push 0
lea ecx, [ebp - 8]
push ecx
push 0xc
lea edx, [ebp - 0x14]
push edx
push 0
push 0
push 0x2d1080
mov eax, dword [ebp - 0x18]
push eax
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0
je 0x4943b2
mov ecx, dword [ebp + 0xc]
mov edx, dword [ebp - 0x10]
mov dword [ecx], edx
mov eax, dword [ebp + 0xc]
mov ecx, dword [ebp - 0xc]
mov dword [eax + 4], ecx
mov edx, dword [ebp - 0x18]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 4]
mov esp, ebp
pop ebp
ret
Function at 0x4943c3
Capabilities:
Get disk information

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x108
push 0x104
push 0
lea eax, [ebp - 0x108]
push eax
call fcn.004a9cd0
add esp, 0xc
movsx ecx, byte [ebp + 8]
push ecx
push 0x525088
lea edx, [ebp - 0x108]
push edx
call fcn.004aa1dd
add esp, 0xc
lea eax, [ebp - 0x108]
push eax
call dword [sym.imp.KERNEL32.dll_GetDriveTypeA]
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 5
jne 0x494415
xor eax, eax
jmp 0x494457
push 0x104
push 0
lea ecx, [ebp - 0x108]
push ecx
call fcn.004a9cd0
add esp, 0xc
movsx edx, byte [ebp + 8]
push edx
push 0x52508c
lea eax, [ebp - 0x108]
push eax
call fcn.004aa1dd
add esp, 0xc
mov ecx, dword [ebp + 0xc]
push ecx
lea edx, [ebp - 0x108]
push edx
call fcn.00494346
add esp, 8
mov esp, ebp
pop ebp
ret

Function at 0x494506
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x22c
mov dword [0x529cc4], 0xff
mov dword [0x529cc0], 0xff
mov dword [ebp - 0x11c], 0
jmp 0x49453e
mov eax, dword [ebp - 0x11c]
add eax, 1
mov dword [ebp - 0x11c], eax
cmp dword [ebp - 0x11c], 0x18
jge 0x494596
mov ecx, dword [ebp - 0x11c]
mov edx, dword [ebp - 0x11c]
mov dword [ecx*8 + 0x529890], edx
mov dword [ebp - 0x124], 0
jmp 0x494575
mov eax, dword [ebp - 0x124]
add eax, 1
mov dword [ebp - 0x124], eax
cmp dword [ebp - 0x124], 4
jge 0x494594
mov ecx, dword [ebp - 0x11c]
mov edx, dword [ebp - 0x124]
mov byte [edx + ecx*8 + 0x529894], 0xff
jmp 0x494566
jmp 0x49452f
mov byte [ebp - 0x128], 0
push 0x104
push 0
lea eax, [ebp - 0x118]
push eax
call fcn.004a9cd0
add esp, 0xc
push 0x104
lea ecx, [ebp - 0x118]
push ecx
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
test eax, eax
je 0x4945d5
mov dl, byte [ebp - 0x118]
mov byte [ebp - 0x128], dl
mov byte [ebp - 0x10], 0
push 0x104
push 0
lea eax, [ebp - 0x22c]
push eax
call fcn.004a9cd0
add esp, 0xc
push 0x104
lea ecx, [ebp - 0x22c]
push ecx
call fcn.00491e37
add esp, 8
mov dl, byte [ebp - 0x22c]
mov byte [ebp - 0x10], dl
mov dword [ebp - 0x11c], 0
jmp 0x494627
mov eax, dword [ebp - 0x11c]
add eax, 1
mov dword [ebp - 0x11c], eax
cmp dword [ebp - 0x11c], 0x18
jge 0x4946d2
mov ecx, dword [ebp - 0x11c]
add ecx, 0x43
mov byte [ebp - 0x120], cl
push 8
push 0
lea edx, [ebp - 8]
push edx
call fcn.004a9cd0
add esp, 0xc
lea eax, [ebp - 8]
push eax
mov cl, byte [ebp - 0x120]
push ecx
call fcn.004943c3
add esp, 8
test eax, eax
je 0x4946cd
mov edx, dword [ebp - 8]
mov dword [ebp - 0xc], edx
mov eax, dword [ebp - 4]
sub eax, 1
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 4
jl 0x494681
jmp 0x494618
cmp dword [ebp - 0x14], 0
jge 0x494689
jmp 0x494618
mov ecx, dword [ebp - 0xc]
mov edx, dword [ebp - 0x14]
mov al, byte [ebp - 0x120]
mov byte [edx + ecx*8 + 0x529894], al
movsx ecx, byte [ebp - 0x120]
movsx edx, byte [ebp - 0x128]
cmp ecx, edx
jne 0x4946b6
mov eax, dword [ebp - 0xc]
mov dword [0x529cc4], eax
movsx ecx, byte [ebp - 0x120]
movsx edx, byte [ebp - 0x10]
cmp ecx, edx
jne 0x4946cd
mov eax, dword [ebp - 0xc]
mov dword [0x529cc0], eax
jmp 0x494618
mov esp, ebp
pop ebp
ret
Function at 0x49564c
Capabilities:
Print debug messages
Unmount volume via ioctl

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x414
mov dword [ebp - 0x410], 0
cmp dword [ebp + 8], 0xffffffff
jne 0x495677
push str._Inquiry_And_ReadFlashID_:_Device_handle_is_not_valid_n
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
xor eax, eax
jmp 0x495765
push 0
lea eax, [ebp - 0x414]
push eax
push 0
push 0
push 0
push 0
push 0x90018
mov ecx, dword [ebp + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
push 0
lea edx, [ebp - 0x414]
push edx
push 0
push 0
push 0
push 0
push 0x90020
mov eax, dword [ebp + 8]
push eax
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
push 0x400
lea ecx, [ebp - 0x400]
push ecx
mov edx, dword [ebp + 8]
push edx
lea eax, [ebp - 0x40c]
push eax
call fcn.00495769
add esp, 0x10
mov dword [ebp - 0x410], eax
push 0
lea ecx, [ebp - 0x414]
push ecx
push 0
push 0
push 0
push 0
push 0x9001c
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
push 0
lea eax, [ebp - 0x414]
push eax
push 0
push 0
push 0
push 0
push 0x90028
mov ecx, dword [ebp + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
cmp dword [ebp - 0x410], 0
je 0x49575f
cmp dword [ebp + 0x10], 0x400
ja 0x495747
mov edx, dword [ebp + 0x10]
push edx
lea eax, [ebp - 0x400]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call fcn.004aa370
add esp, 0xc
jmp 0x49575f
push 0x400
lea edx, [ebp - 0x400]
push edx
mov eax, dword [ebp + 0xc]
push eax
call fcn.004aa370
add esp, 0xc
mov eax, dword [ebp - 0x410]
mov esp, ebp
pop ebp
ret

Function at 0x4976f0
Capabilities:
Check os version

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xa4
mov dword [ebp - 0x94], 0x94
lea eax, [ebp - 0x94]
push eax
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
mov dword [ebp - 0xa0], eax
mov dword [ebp - 0xa4], 0
mov dword [ebp - 0x9c], 0
mov dword [ebp - 0x98], 0
cmp dword [ebp - 0x90], 4
jne 0x497752
cmp dword [ebp - 0x8c], 0x5a
je 0x497750
mov dword [ebp - 0xa4], 1
jmp 0x497781
cmp dword [ebp - 0x90], 5
jne 0x497781
cmp dword [ebp - 0x8c], 0
jne 0x49776e
mov dword [ebp - 0x9c], 1
cmp dword [ebp - 0x8c], 1
jne 0x497781
mov dword [ebp - 0x98], 1
mov eax, dword [ebp - 0xa4]
mov esp, ebp
pop ebp
ret

Function at 0x49778b
Capabilities:
Check os version

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xa4
mov dword [ebp - 0x94], 0x94
lea eax, [ebp - 0x94]
push eax
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
mov dword [ebp - 0xa0], eax
mov dword [ebp - 0xa4], 0
mov dword [ebp - 0x9c], 0
mov dword [ebp - 0x98], 0
cmp dword [ebp - 0x90], 4
jne 0x4977ed
cmp dword [ebp - 0x8c], 0x5a
je 0x4977eb
mov dword [ebp - 0xa4], 1
jmp 0x49781c
cmp dword [ebp - 0x90], 5
jne 0x49781c
cmp dword [ebp - 0x8c], 0
jne 0x497809
mov dword [ebp - 0x9c], 1
cmp dword [ebp - 0x8c], 1
jne 0x49781c
mov dword [ebp - 0x98], 1
mov eax, dword [ebp - 0x9c]
mov esp, ebp
pop ebp
ret
Function at 0x4978e0
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10c
push esi
push edi
cmp dword [0x52b004], 0
je 0x49791e
mov edi, 0x5251c8
lea edx, [ebp - 0x100]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov eax, ecx
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
jmp 0x497946
mov edi, 0x5251f4
lea edx, [ebp - 0x100]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov eax, ecx
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [ebp + 8]
push ecx
lea edx, [ebp - 0x100]
push edx
call fcn.004a9f40
add esp, 8
lea eax, [ebp - 0x108]
push eax
push 0x20019
push 0
lea ecx, [ebp - 0x100]
push ecx
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
mov dword [ebp - 0x10c], eax
cmp dword [ebp - 0x108], 0xffffffff
je 0x4979c6
mov dword [ebp - 0x104], 0xff
lea edx, [ebp - 0x104]
push edx
mov eax, dword [ebp + 0xc]
push eax
push 0
push 0
push str.CreateFileName
mov ecx, dword [ebp - 0x108]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov dword [ebp - 0x10c], eax
mov edx, dword [ebp - 0x108]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x49d85d
Capabilities:
Enumerate files on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x55c
mov dword [ebp - 0x558], 0
mov eax, dword [ebp + 0x14]
mov dword [ebp - 4], eax
mov ecx, dword [ebp + 0x10]
push ecx
mov edx, dword [ebp + 0xc]
push edx
push str._s_s
lea eax, [ebp - 0x108]
push eax
call fcn.004aa1dd
add esp, 0x10
push 0x52b018
mov ecx, dword [ebp - 4]
push ecx
call fcn.004a9f30
add esp, 8
mov edx, dword [ebp + 8]
push edx
lea eax, [ebp - 0x310]
push eax
call fcn.004a9f30
add esp, 8
mov ecx, dword [ebp + 0x10]
push ecx
mov edx, dword [ebp + 0xc]
push edx
lea eax, [ebp - 0x310]
push eax
push str._s_s_s
lea ecx, [ebp - 0x554]
push ecx
call fcn.004aa1dd
add esp, 0x14
lea edx, [ebp - 0x450]
push edx
lea eax, [ebp - 0x554]
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov dword [ebp - 0x55c], eax
cmp dword [ebp - 0x55c], 0xffffffff
jne 0x49d903
xor eax, eax
jmp 0x49da01
mov dword [ebp - 8], 0
mov dword [ebp - 0x558], 0
mov ecx, dword [ebp + 0xc]
push ecx
call dword [sym.imp.USER32.dll_CharUpperA]
mov edx, dword [ebp + 0x10]
push edx
call dword [sym.imp.USER32.dll_CharUpperA]
cmp dword [ebp - 8], 0
jne 0x49d9d8
lea eax, [ebp - 0x424]
push eax
lea ecx, [ebp - 0x20c]
push ecx
call fcn.004a9f30
add esp, 8
lea edx, [ebp - 0x20c]
push edx
call dword [sym.imp.USER32.dll_CharUpperA]
mov eax, dword [ebp + 0xc]
push eax
lea ecx, [ebp - 0x20c]
push ecx
call fcn.004aa930
add esp, 8
test eax, eax
je 0x49d9a9
mov edx, dword [ebp + 0x10]
push edx
lea eax, [ebp - 0x20c]
push eax
call fcn.004aa930
add esp, 8
test eax, eax
je 0x49d9a9
lea ecx, [ebp - 0x310]
push ecx
mov edx, dword [ebp - 4]
push edx
call fcn.004a9f30
add esp, 8
lea eax, [ebp - 0x424]
push eax
mov ecx, dword [ebp - 4]
push ecx
call fcn.004a9f40
add esp, 8
lea edx, [ebp - 0x450]
push edx
mov eax, dword [ebp - 0x55c]
push eax
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x49d9d3
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x12
jne 0x49d9d3
mov dword [ebp - 8], 1
jmp 0x49d928
mov ecx, dword [ebp - 0x55c]
push ecx
call dword [sym.imp.KERNEL32.dll_FindClose]
mov edx, dword [ebp - 4]
push edx
mov eax, dword [ebp + 0x14]
push eax
call fcn.004a9f30
add esp, 8
mov ecx, dword [ebp - 4]
push ecx
call fcn.004aabc0
add esp, 4
mov esp, ebp
pop ebp
ret
Function at 0x4ac6f9
Capabilities:
Accept command line arguments
Terminate process

Disassembly:
push 0x60
push 0x4f2a40
call fcn.004b0d68
and dword [ebp - 4], 0
lea eax, [ebp - 0x70]
push eax
call dword [sym.imp.KERNEL32.dll_GetStartupInfoA]
or dword [ebp - 4], 0xffffffff
mov ebx, 0x94
push ebx
push 0
mov edi, dword [sym.imp.KERNEL32.dll_GetProcessHeap]
call edi
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov esi, eax
test esi, esi
je 0x4ac8b0
mov dword [esi], ebx
push esi
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
push esi
push 0
test eax, eax
jne 0x4ac756
call edi
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
jmp 0x4ac8b0
mov eax, dword [esi + 0x10]
mov dword [0x52d0c4], eax
mov eax, dword [esi + 4]
mov dword [0x52d0d0], eax
mov eax, dword [esi + 8]
mov dword [0x52d0d4], eax
mov eax, dword [esi + 0xc]
and eax, 0x7fff
mov dword [0x52d0c8], eax
call edi
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
cmp dword [0x52d0c4], 2
je 0x4ac794
or byte [0x52d0c9], 0x80
mov eax, dword [0x52d0d0]
shl eax, 8
add eax, dword [0x52d0d4]
mov dword [0x52d0cc], eax
call fcn.004ac69d
mov dword [ebp - 0x1c], eax
xor ebx, ebx
inc ebx
push ebx
call fcn.004b28a8
pop ecx
test eax, eax
jne 0x4ac7c5
push 0x1c
call fcn.004ac679
pop ecx
call fcn.004b08db
test eax, eax
jne 0x4ac7d6
push 0x10
call fcn.004ac679
pop ecx
mov dword [ebp - 4], ebx
call fcn.004b6df6
test eax, eax
jge 0x4ac7ea
push 0x1b
call fcn.004ac654
pop ecx
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
mov dword [0x52ec40], eax
call fcn.004b6cd0
mov dword [0x52d108], eax
call fcn.004b6c2f
test eax, eax
jge 0x4ac810
push 8
call fcn.004ac654
pop ecx
call fcn.004b69e5
test eax, eax
jge 0x4ac821
push 9
call fcn.004ac654
pop ecx
call fcn.004ab367
mov dword [ebp - 0x28], eax
test eax, eax
je 0x4ac834
push eax
call fcn.004ac654
pop ecx
call fcn.004b697c
mov dword [ebp - 0x20], eax
test byte [ebp - 0x44], bl
je 0x4ac847
movzx eax, word [ebp - 0x40]
jmp 0x4ac84a
push 0xa
pop eax
push eax
push dword [ebp - 0x20]
push 0
push 0x400000
call fcn.004c3427
mov esi, eax
mov dword [ebp - 0x2c], esi
cmp dword [ebp - 0x1c], 0
jne 0x4ac86b
push esi
call fcn.004ab47c
call fcn.004ab49e
jmp 0x4ac89d
or dword [ebp - 4], 0xffffffff
mov eax, esi
jmp 0x4ac8b5
mov eax, 0xff
call fcn.004b0da3
ret
Function at 0x4acf8b
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
mov edi, dword [ebp + 0x10]
xor ebx, ebx
test edi, edi
jne 0x4acfa8
call fcn.004adc35
mov dword [eax], 0x16
xor eax, eax
jmp 0x4ad011
xor ecx, ecx
push esi
mov edx, 0x8c
inc ecx
call fcn.004b3b0a
mov esi, eax
test esi, esi
je 0x4acffc
push esi
call fcn.004b06c8
mov eax, dword [ebp + 0x14]
or dword [esi + 4], 0xffffffff
mov dword [esi + 0x50], eax
mov eax, dword [ebp + 0x1c]
test eax, eax
pop ecx
mov dword [esi + 0x4c], edi
jne 0x4acfda
lea eax, [ebp + 0x10]
push eax
push dword [ebp + 0x18]
push esi
push 0x4acef6
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateThread]
test eax, eax
jne 0x4ad010
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
push esi
call fcn.004aa6ad
test ebx, ebx
pop ecx
je 0x4ad00e
push ebx
call fcn.004adc5b
pop ecx
xor eax, eax
pop esi
pop edi
pop ebx
pop ebp
ret
Function at 0x4b0fd6
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x41c
push edi
xor edi, edi
cmp dword [ebp + 0x10], edi
mov dword [ebp - 0x10], edi
mov dword [ebp - 0x14], edi
jne 0x4b0ff4
xor eax, eax
jmp 0x4b1162
mov eax, dword [ebp + 8]
push ebx
mov ebx, dword [ebp + 8]
and eax, 0x1f
sar ebx, 5
push esi
lea esi, [eax + eax*8]
lea ebx, [ebx*4 + 0x52d8c0]
mov eax, dword [ebx]
shl esi, 2
test byte [eax + esi + 4], 0x20
je 0x4b1027
push 2
push edi
push edi
push dword [ebp + 8]
call fcn.004b9b82
add esp, 0x10
mov eax, dword [ebx]
add eax, esi
test byte [eax + 4], 0x80
je 0x4b10f9
cmp dword [ebp + 0x10], edi
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0xc], eax
mov dword [ebp - 4], edi
jbe 0x4b1131
mov ecx, dword [ebp - 0xc]
sub ecx, dword [ebp + 0xc]
lea eax, [ebp - 0x41c]
mov dword [ebp - 8], edi
cmp ecx, dword [ebp + 0x10]
jae 0x4b1082
mov edx, dword [ebp - 0xc]
inc dword [ebp - 0xc]
mov dl, byte [edx]
inc ecx
cmp dl, 0xa
jne 0x4b1073
inc dword [ebp - 0x14]
mov byte [eax], 0xd
inc eax
inc dword [ebp - 8]
mov byte [eax], dl
inc eax
inc dword [ebp - 8]
cmp dword [ebp - 8], 0x400
jl 0x4b1056
mov edi, eax
lea eax, [ebp - 0x41c]
sub edi, eax
push 0
lea eax, [ebp - 0x18]
push eax
push edi
lea eax, [ebp - 0x41c]
push eax
mov eax, dword [ebx]
push dword [eax + esi]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x4b10c2
mov eax, dword [ebp - 0x18]
add dword [ebp - 0x10], eax
cmp eax, edi
jl 0x4b10cb
mov eax, dword [ebp - 0xc]
sub eax, dword [ebp + 0xc]
xor edi, edi
cmp eax, dword [ebp + 0x10]
jb 0x4b1047
jmp 0x4b10cd
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 4], eax
xor edi, edi
mov eax, dword [ebp - 0x10]
cmp eax, edi
jne 0x4b115d
cmp dword [ebp - 4], edi
je 0x4b1131
push 5
pop esi
cmp dword [ebp - 4], esi
jne 0x4b1126
call fcn.004adc35
mov dword [eax], 9
call fcn.004adc48
mov dword [eax], esi
jmp 0x4b1158
push edi
lea ecx, [ebp - 0x18]
push ecx
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [eax]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x4b111b
mov eax, dword [ebp - 0x18]
mov dword [ebp - 4], edi
mov dword [ebp - 0x10], eax
jmp 0x4b10cd
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 4], eax
jmp 0x4b10cd
push dword [ebp - 4]
call fcn.004adc5b
pop ecx
jmp 0x4b1158
mov eax, dword [ebx]
test byte [eax + esi + 4], 0x40
je 0x4b1146
mov eax, dword [ebp + 0xc]
cmp byte [eax], 0x1a
jne 0x4b1146
xor eax, eax
jmp 0x4b1160
call fcn.004adc35
mov dword [eax], 0x1c
call fcn.004adc48
mov dword [eax], edi
or eax, 0xffffffff
jmp 0x4b1160
sub eax, dword [ebp - 0x14]
pop esi
pop ebx
pop edi
leave
ret
Function at 0x4b652e
Capabilities:
Get system information on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x4c
push ebx
push esi
push edi
push 4
pop eax
call fcn.004aa330
mov esi, esp
push 0x1c
lea eax, [ebp - 0x28]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x4b65c9
mov ebx, dword [ebp - 0x24]
lea eax, [ebp - 0x4c]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemInfo]
mov ecx, dword [ebp - 0x48]
mov eax, dword [0x52d0c4]
lea edi, [ecx - 1]
not edi
and edi, esi
sub edi, ecx
mov esi, eax
dec esi
neg esi
sbb esi, esi
and esi, 0xfffffff1
add esi, 0x11
imul esi, ecx
add esi, ebx
cmp edi, esi
mov dword [ebp - 8], ecx
jb 0x4b65c9
cmp eax, 1
je 0x4b65ea
mov dword [ebp - 4], ebx
mov ebx, 0x1000
push 0x1c
lea eax, [ebp - 0x28]
push eax
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x4b65c9
mov eax, dword [ebp - 0x1c]
add dword [ebp - 4], eax
test dword [ebp - 0x18], ebx
je 0x4b6596
test byte [ebp - 0x13], 1
mov eax, dword [ebp - 0x28]
mov dword [ebp - 4], eax
je 0x4b65c5
xor eax, eax
inc eax
jmp 0x4b6609
cmp edi, eax
jae 0x4b65cd
xor eax, eax
jmp 0x4b6609
cmp eax, esi
jae 0x4b65d4
mov dword [ebp - 4], esi
push 4
push ebx
push dword [ebp - 8]
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov eax, dword [0x52d0c4]
jmp 0x4b65ed
mov dword [ebp - 4], edi
dec eax
neg eax
sbb eax, eax
and eax, 0x103
lea ecx, [ebp - 0xc]
push ecx
inc eax
push eax
push dword [ebp - 8]
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
lea esp, [ebp - 0x58]
pop edi
pop esi
pop ebx
leave
ret
Function at 0x4b6611
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
mov ecx, dword [ebp + 8]
xor eax, eax
cmp ecx, dword [eax*8 + 0x5279b0]
je 0x4b6629
inc eax
cmp eax, 0x12
jb 0x4b661a
push esi
mov esi, eax
shl esi, 3
cmp ecx, dword [esi + 0x5279b0]
mov dword [ebp + 8], esi
jne 0x4b676f
mov eax, dword [0x52d110]
cmp eax, 1
push ebx
je 0x4b673f
test eax, eax
jne 0x4b665e
cmp dword [0x526fe4], 1
je 0x4b673f
cmp ecx, 0xfc
je 0x4b676e
push edi
push 6
pop ecx
mov esi, str.Runtime_Error__n_nProgram:
mov edi, 0x52d348
rep movsd dword es:[edi], dword [esi]
push 0x104
mov ebx, 0x52d362
push ebx
movsw word es:[edi], word [esi]
push 0
mov byte [0x52d466], 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x4b66ac
push 5
pop ecx
mov esi, str._program_name_unknown_
mov edi, 0x52d362
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
movsb byte es:[edi], byte [esi]
mov eax, ebx
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4b66b1
sub eax, edx
inc eax
cmp eax, 0x3c
jbe 0x4b66e4
mov eax, ebx
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4b66c5
sub eax, edx
push 3
lea eax, [eax + 0x52d327]
push 0x4f726c
push eax
call fcn.004bad80
add esp, 0xc
mov edx, 0x52d348
mov edi, edx
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x4b66ec
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x5279b4]
mov esi, 0x4f7268
movsw word es:[edi], word [esi]
movsb byte es:[edi], byte [esi]
mov esi, eax
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4b6707
mov edi, edx
sub eax, esi
dec edi
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x4b6713
mov ecx, eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
push 0x12010
mov ecx, eax
and ecx, 3
push str.Microsoft_Visual_C_Runtime_Library
push edx
rep movsb byte es:[edi], byte [esi]
call fcn.004bc8ec
add esp, 0xc
pop edi
jmp 0x4b676e
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
test eax, eax
je 0x4b676e
mov esi, dword [esi + 0x5279b4]
mov ecx, esi
lea edx, [ecx + 1]
mov bl, byte [ecx]
inc ecx
test bl, bl
jne 0x4b6756
push 0
sub ecx, edx
lea edx, [ebp - 4]
push edx
push ecx
push esi
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
pop ebx
pop esi
leave
ret