joyce8/EMBER2024-capa huggingface dataset:
Function at 0x495c30
Capabilities:
Read file on windows

Disassembly:
mov eax, dword [esp + 4]
sub esp, 0xc
push esi
push edi
push 1
push eax
xor edi, edi
call fcn.004a74a0
mov esi, eax
cmp esi, 0xffffffff
je 0x495caa
push edi
lea ecx, [esp + 0x1c]
push ecx
push 0xa
lea edx, [esp + 0x14]
push edx
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x495ca3
cmp dword [esp + 0x18], 0xa
jne 0x495ca3
cmp dword [esp + 8], 0x38464947
jne 0x495ca3
mov ax, word [esp + 0xc]
cmp ax, 0x6139
je 0x495c84
cmp ax, 0x6137
jne 0x495ca3
movzx ecx, word [esp + 0xe]
mov eax, dword [esp + 0x1c]
movzx edx, word [esp + 0x10]
mov dword [eax], ecx
mov dword [eax + 4], edx
mov dword [eax + 8], 8
mov edi, 1
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, edi
pop edi
pop esi
add esp, 0xc
ret 8

Function at 0x495cc0
Capabilities:
Read file on windows

Disassembly:
sub esp, 0xb8
push ebx
push ebp
mov ebp, dword [esp + 0xc4]
push esi
push 1
push eax
xor esi, esi
call fcn.004a74a0
mov ebx, eax
cmp ebx, 0xffffffff
je 0x495e14
lea ecx, [esp + 0x90]
push ecx
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileInformationByHandle]
test eax, eax
je case.default.0x495d6e
mov edx, dword [esp + 0xb4]
push esi
push esi
add edx, 0xffffff80
push edx
push ebx
call fcn.004ac4b0
test eax, eax
je case.default.0x495d6e
push esi
lea eax, [esp + 0x10]
push eax
push 0x80
lea ecx, [esp + 0x1c]
push ecx
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je case.default.0x495d6e
cmp dword [esp + 0xc], 0x80
jne case.default.0x495d6e
cmp byte [esp + 0x10], 0x54
jne case.default.0x495d6e
cmp byte [esp + 0x11], 0x41
jne case.default.0x495d6e
cmp byte [esp + 0x12], 0x47
jne case.default.0x495d6e
cmp ebp, 6
ja case.default.0x495d6e
jmp dword [ebp*4 + 0x495e24]
push 0x1e
lea edx, [esp + 0x17]
push edx
push edi
call fcn.005210b0
jmp 0x495e08
push 0x1e
lea eax, [esp + 0x35]
push eax
push edi
call fcn.005210b0
jmp 0x495e08
push 0x1e
lea ecx, [esp + 0x53]
push ecx
push edi
call fcn.005210b0
jmp 0x495e08
push 4
lea edx, [esp + 0x71]
push edx
push edi
call fcn.005210b0
jmp 0x495e08
push 0x1e
lea eax, [esp + 0x75]
push eax
push edi
call fcn.005210b0
jmp 0x495e08
cmp byte [esp + 0x8d], 0
jne case.default.0x495d6e
mov al, byte [esp + 0x8e]
test al, al
je case.default.0x495d6e
movzx ecx, al
push ecx
push 0x5465b8
push edi
call fcn.0051fa10
add esp, 0xc
jmp 0x495e08
mov al, byte [esp + 0x8f]
cmp al, 0x7e
jae case.default.0x495d6e
movzx edx, al
mov eax, dword [edx*4 + 0x57ff60]
push eax
push edi
call fcn.0051f570
mov esi, 1
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, esi
pop esi
pop ebp
pop ebx
add esp, 0xb8
ret 4
Function at 0x49acf0
Capabilities:
Extract resource via kernel32 functions

Disassembly:
sub esp, 0x144
push ebx
push ebp
push esi
xor ebx, ebx
push edi
xor ebp, ebp
mov esi, eax
mov dword [esp + 0x10], ebx
xor edi, edi
jmp 0x49ad10
mov eax, dword [edi + 0x5803e0]
mov ecx, dword [esp + 0x158]
push eax
push ecx
call fcn.00518f70
test eax, eax
je 0x49ad42
add edi, 0xc
add ebp, 1
cmp edi, 0x60
jb 0x49ad10
pop edi
pop esi
pop ebp
mov eax, ebx
pop ebx
add esp, 0x144
ret 4
mov eax, dword [0x58b3c8]
lea ebp, [ebp + ebp*2]
add ebp, ebp
movzx edx, word [ebp + ebp + 0x5803e8]
add ebp, ebp
push 0xa
push edx
push eax
call dword [0x58af3c]
mov ebx, eax
test ebx, ebx
je 0x49ae7c
mov ecx, dword [0x58b3c8]
push ebx
push ecx
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov edi, eax
test edi, edi
jle 0x49ae7c
mov edx, dword [0x58b3c8]
push ebx
push edx
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov ebx, eax
test ebx, ebx
mov dword [esp + 0x14], ebx
je 0x49ae7c
push ebx
call dword [sym.imp.KERNEL32.dll_LockResource]
test eax, eax
mov dword [esp + 0x18], eax
je 0x49ae62
lea eax, [esp + 0x44]
push eax
call fcn.0051ec40
mov ecx, dword [0x58b3c8]
push ecx
lea edx, [esp + 0x48]
push edx
call fcn.004aaa50
mov ecx, dword [esp + 0x4c]
lea eax, [esp + 0x1c]
push eax
push ecx
call fcn.004ab1f0
lea edx, [esp + 0x44]
push edx
call fcn.00522920
mov eax, dword [esp + 0x28]
mov ecx, dword [esp + 0x24]
push 0
push 0
push 0
push 0
push 0
push 1
push eax
push ecx
mov eax, edi
cdq
push edx
mov edx, dword [ebp + 0x5803e4]
push eax
push edx
mov ebx, esi
call fcn.00499330
mov eax, dword [esp + 0x18]
push eax
mov eax, edi
mov ecx, esi
call fcn.00499280
call fcn.00498be0
mov ecx, dword [esi]
mov edx, dword [0x58b364]
push 0
push ecx
mov dword [esi + 0x54], 1
mov eax, dword [edx + 8]
push 0x401
push eax
call dword [0x58b03c]
mov ebx, dword [esp + 0x14]
push ebx
mov esi, 1
call dword [sym.imp.KERNEL32.dll_FreeResource]
pop edi
mov eax, esi
pop esi
pop ebp
pop ebx
add esp, 0x144
ret 4
mov esi, dword [esp + 0x10]
push ebx
call dword [sym.imp.KERNEL32.dll_FreeResource]
pop edi
mov eax, esi
pop esi
pop ebp
pop ebx
add esp, 0x144
ret 4
mov eax, dword [esp + 0x10]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x144
ret 4
Function at 0x49ff20
Capabilities:
Get keyboard layout

Disassembly:
sub esp, 0x208
cmp byte [0x57e667], 0
je 0x49ffb5
mov eax, esi
call fcn.0049fe30
test eax, eax
je 0x49ffb5
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push eax
call dword [sym.imp.USER32.dll_GetKeyboardLayout]
push eax
push 0
push esi
call dword [0x58b030]
test eax, eax
je 0x49ffb5
lea ecx, [esi - 0x10]
shl eax, 0x10
cmp ecx, 0x80
ja case.0x49ff6e.19
movzx ecx, byte [ecx + 0x49ffcc]
jmp dword [ecx*4 + 0x49ffc0]
or eax, 0x2000000
jmp case.0x49ff6e.19
or eax, 0x1000000
push 0x104
lea edx, [esp + 4]
push edx
push eax
call dword [0x58b000]
test eax, eax
je 0x49ffb5
mov ecx, dword [esp + 0x20c]
lea eax, [esp]
push eax
push ecx
call fcn.0051f5c0
mov eax, 1
add esp, 0x208
ret 4
xor eax, eax
add esp, 0x208
ret 4
Function at 0x4a0420
Capabilities:
Accept command line arguments

Disassembly:
sub esp, 0x110
lea eax, [esp]
push eax
call fcn.0051ec40
call dword [sym.imp.KERNEL32.dll_GetCommandLineW]
push eax
lea ecx, [esp + 4]
push ecx
call fcn.0051f5c0
mov edx, dword [esp + 8]
push 0
push 0
push edx
call fcn.00404e00
mov dword [0x58b3a4], eax
lea eax, [esp]
push eax
call fcn.00522920
add esp, 0x110
ret

Function at 0x4a05b0
Capabilities:
Terminate process

Disassembly:
push ecx
push edi
push str.EVERYTHING_TASKBAR_NOTIFICATION
call fcn.004a9750
mov edi, eax
test edi, edi
je 0x4a0635
lea eax, [esp + 4]
push eax
push edi
call dword [sym.imp.USER32.dll_GetWindowThreadProcessId]
test eax, eax
je 0x4a0635
mov ecx, dword [esp + 4]
push esi
push ecx
push 0
push 0x100000
call dword [sym.imp.KERNEL32.dll_OpenProcess]
push 0
push 0
push 0x10
push edi
mov esi, eax
call dword [0x58b03c]
push 0xea60
push esi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp eax, 0x102
jne 0x4a062d
push 0
push esi
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
test eax, eax
jne 0x4a062d
push str.Timed_out_while_waiting_for_Everything.exe_to_close
push str._main_close_existing_process
push 0x1c4
push str.._srcmain.c
call fcn.0048dda0
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop esi
pop edi
pop ecx
ret
Function at 0x4a1a50
Capabilities:
Accept command line arguments

Disassembly:
sub esp, 0x348
mov eax, dword [0x58b3a4]
push ebp
push esi
push edi
xor edi, edi
cmp dword [eax + 0xc], edi
mov dword [esp + 0xc], edi
je 0x4a1a75
mov eax, dword [eax + 0xc]
cmp byte [eax], 0
je 0x4a1a75
mov esi, eax
jmp 0x4a1a84
mov eax, dword [0x58b0f4]
mov cl, byte [eax]
neg cl
sbb ecx, ecx
and ecx, eax
mov esi, ecx
lea edx, [esp + 0x134]
push edx
call fcn.0051ec40
lea eax, [esp + 0x134]
push str.EVERYTHING_TASKBAR_NOTIFICATION
push eax
call fcn.0051fa10
add esp, 8
test esi, esi
je 0x4a1adc
push 0x561d54
lea ecx, [esp + 0x138]
push ecx
call fcn.0051ede0
push esi
lea edx, [esp + 0x138]
push edx
call fcn.0051ede0
push 0x546f38
lea eax, [esp + 0x138]
push eax
call fcn.0051ede0
mov ecx, dword [esp + 0x13c]
push ecx
call fcn.004a9750
lea edx, [esp + 0x134]
push edx
mov ebp, eax
call fcn.00522920
test ebp, ebp
je 0x4a1c53
push ebx
lea eax, [esp + 0x28]
push eax
call fcn.0051ec40
lea ecx, [esp + 0x248]
push ecx
call fcn.0051ec40
call dword [sym.imp.KERNEL32.dll_GetCommandLineW]
push eax
lea edx, [esp + 0x2c]
push edx
call fcn.0051f5c0
lea eax, [esp + 0x248]
push eax
call fcn.004aad30
lea ecx, [esp + 0x18]
push ecx
push ebp
call dword [sym.imp.USER32.dll_GetWindowThreadProcessId]
mov edx, dword [esp + 0x18]
push edx
call dword [0x581e38]
mov eax, dword [esp + 0x28]
mov ecx, dword [esp + 0x248]
lea edi, [ecx + eax + 6]
push edi
call fcn.004a2340
mov edx, dword [esp + 0x35c]
mov esi, eax
mov dword [esi], edx
mov eax, dword [esp + 0x28]
mov ecx, dword [esp + 0x30]
add eax, 1
push eax
push ecx
lea ebx, [esi + 4]
push ebx
call fcn.00545633
mov edx, dword [esp + 0x254]
mov eax, dword [esp + 0x25c]
mov ecx, dword [esp + 0x34]
add edx, 1
push edx
push eax
lea edx, [ebx + ecx + 1]
push edx
call fcn.00545633
add esp, 0x18
lea eax, [esp + 0x14]
push eax
push 0x7530
push 9
push 0
push 0
push 0x400
mov dword [esp + 0x38], edi
mov edi, dword [0x58b050]
push ebp
mov dword [esp + 0x38], 0
mov dword [esp + 0x40], esi
call edi
test eax, eax
pop ebx
je 0x4a1c14
cmp dword [esp + 0x10], 0
je 0x4a1c0d
lea ecx, [esp + 0x10]
push ecx
push 0x7530
push 9
lea edx, [esp + 0x24]
push edx
push 0
push 0x4a
push ebp
call edi
push str.send_message_ok_n
mov dword [esp + 0x10], 1
push 0xff00ff00
jmp 0x4a1c1e
push str.version_send_message_bad_version_n
jmp 0x4a1c19
push str.version_send_message_failed_n
push 0xffff0000
call fcn.0048dc30
add esp, 8
push esi
call fcn.004a23a0
lea eax, [esp + 0x244]
push eax
call fcn.00522920
lea ecx, [esp + 0x24]
push ecx
call fcn.00522920
mov eax, dword [esp + 0xc]
pop edi
pop esi
pop ebp
add esp, 0x348
ret 4
mov eax, edi
pop edi
pop esi
pop ebp
add esp, 0x348
ret 4
Function at 0x4a1cf0
Capabilities:
Check for time delay via gettickcount

Disassembly:
sub esp, 0x328
push ebx
push ebp
push esi
mov esi, dword [sym.imp.KERNEL32.dll_GetTickCount]
push edi
call esi
mov edi, eax
mov dword [esp + 0x10], edi
call esi
sub eax, edi
cmp eax, 0x7530
ja 0x4a1e3a
mov ebx, dword [0x58af20]
mov ebp, dword [sym.imp.KERNEL32.dll_GetLastError]
xor edi, edi
jmp 0x4a1d30
lea eax, [esp + 0x124]
push eax
call fcn.0051ec40
lea ecx, [esp + 0x14]
push ecx
call fcn.0051ec40
lea edx, [esp + 0x14]
push str.EVERYTHING_MUTEX
push edx
call fcn.0051fa10
add esp, 8
call fcn.004a1a20
test eax, eax
je 0x4a1d7a
call fcn.004a1a20
push eax
lea eax, [esp + 0x18]
push 0x561d74
push eax
call fcn.0051fb90
add esp, 0xc
mov ecx, dword [esp + 0x1c]
push ecx
lea edx, [esp + 0x128]
push edx
call fcn.00522b90
lea eax, [esp + 0x14]
push eax
call fcn.00522920
push edi
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov eax, dword [0x58b390]
cmp eax, edi
je 0x4a1db3
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [0x58b390], edi
mov eax, dword [esp + 0x12c]
cmp word [eax], di
je 0x4a1dda
nop
cmp word [eax], 0x5c
jne 0x4a1dcb
mov word [eax], 0x5f
add eax, 2
cmp word [eax], di
jne 0x4a1dc0
mov eax, dword [esp + 0x12c]
push eax
push edi
push edi
call ebx
mov dword [0x58b390], eax
call ebp
lea ecx, [esp + 0x124]
push ecx
mov esi, eax
call fcn.00522920
cmp esi, 0xb7
jne 0x4a1e62
mov edx, dword [0x58b3a4]
test dword [edx + 4], 0x800000
jne 0x4a1e49
mov eax, dword [esp + 0x33c]
push eax
call fcn.004a1a50
test eax, eax
jne 0x4a1e3a
push 0x64
call dword [sym.imp.KERNEL32.dll_Sleep]
call dword [sym.imp.KERNEL32.dll_GetTickCount]
sub eax, dword [esp + 0x10]
cmp eax, 0x7530
jbe 0x4a1d30
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x328
ret 4
pop edi
pop esi
pop ebp
mov dword [0x58b394], 1
xor eax, eax
pop ebx
add esp, 0x328
ret 4
mov ecx, dword [0x58b3a4]
mov eax, dword [ecx + 8]
pop edi
shr eax, 0x17
pop esi
not eax
pop ebp
and eax, 1
pop ebx
add esp, 0x328
ret 4

Function at 0x4a23e0
Capabilities:
Send data
Send data on socket

Disassembly:
push ebx
push ebp
push esi
mov esi, dword [esp + 0x18]
test esi, esi
push edi
mov edi, dword [esp + 0x18]
jle 0x4a2418
mov ebx, dword [esp + 0x14]
mov ebp, dword [sym.imp.WS2_32.dll_send]
lea ebx, [ebx]
push 0
push esi
push edi
push ebx
call ebp
cmp eax, 0xffffffff
je 0x4a2424
test eax, eax
je 0x4a2424
sub esi, eax
add edi, eax
test esi, esi
jg 0x4a2400
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
ret 0xc
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
ret 0xc
Function at 0x4a2490
Capabilities:
Receive data
Receive data on socket

Disassembly:
sub esp, 0x14
push ebx
push ebp
xor ecx, ecx
push esi
push edi
mov dword [esp + 0x18], ecx
xor esi, esi
mov dword [esp + 0x14], ecx
mov eax, dword [0x57e6a8]
test eax, eax
mov dword [esp + 0x10], ecx
je 0x4a24b8
cmp ecx, eax
jg 0x4a256e
push 0x10000
call fcn.004a2340
cmp dword [esp + 0x18], 0
mov dword [esp + 0x1c], eax
je 0x4a24d1
mov dword [esi], eax
jmp 0x4a24d5
mov dword [esp + 0x18], eax
lea esi, [eax + 4]
lea ebx, [eax + 0x10000]
cmp esi, ebx
mov dword [esp + 0x20], eax
mov dword [eax], 0
jae 0x4a2549
lea esp, [esp]
mov ecx, dword [esp + 0x28]
push 2
mov eax, ebx
sub eax, esi
push eax
push esi
push ecx
call dword [sym.imp.WS2_32.dll_recv]
cmp eax, 0xffffffff
je 0x4a257a
test eax, eax
mov edi, esi
je 0x4a25e9
add eax, esi
cmp esi, eax
jae 0x4a2524
cmp byte [edi], 0xa
je 0x4a2598
add edi, 1
cmp edi, eax
jb 0x4a2518
mov edx, dword [esp + 0x28]
push 0
mov ebp, edi
sub ebp, esi
push ebp
push esi
push edx
call dword [sym.imp.WS2_32.dll_recv]
cmp eax, ebp
jne 0x4a2692
cmp edi, ebx
mov esi, edi
jb 0x4a24f0
mov eax, dword [esp + 0x1c]
mov esi, dword [esp + 0x20]
xor ecx, ecx
cmp byte [ebx - 1], 0xd
setne cl
sub ecx, 1
and ecx, eax
mov dword [esp + 0x14], ecx
mov ecx, dword [esp + 0x10]
add ecx, 0xfffc
jmp 0x4a24a3
push eax
push ecx
push str._d____d_n
jmp 0x4a269b
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push str.recv__d_n
push 0xffff0000
call fcn.0048dc30
add esp, 0xc
jmp 0x4a26a8
mov edx, dword [esp + 0x28]
mov ebp, edi
push 0
sub ebp, esi
lea ebx, [ebp + 1]
push ebx
push esi
push edx
call dword [sym.imp.WS2_32.dll_recv]
cmp eax, ebx
je 0x4a25be
push ebx
push eax
push str.ret__d___p_d1__d_n
jmp 0x4a269b
test ebp, ebp
je 0x4a25dd
cmp byte [edi - 1], 0xd
mov dword [esp + 0x14], 0
jne 0x4a25d3
add edi, 0xffffffff
mov eax, edi
sub eax, esi
add dword [esp + 0x10], eax
jmp 0x4a25e9
cmp dword [esp + 0x14], 0
je 0x4a25e9
sub dword [esp + 0x10], 1
mov edx, dword [esp + 0x10]
mov ecx, dword [0x57e6a8]
lea eax, [edx + 1]
cmp eax, ecx
jle 0x4a2606
push ecx
push edx
push str.buflen__d__1____d_n
jmp 0x4a269b
mov ebx, dword [esp + 0x2c]
cmp eax, dword [ebx + 4]
jle 0x4a2616
push eax
push ebx
call fcn.0051ec60
mov ebp, dword [ebx + 8]
sub edi, esi
mov esi, dword [esp + 0x18]
test esi, esi
je 0x4a267f
mov ebx, dword [esi]
test ebx, ebx
je 0x4a2663
cmp dword [esp + 0x14], esi
jne 0x4a2649
push 0xfffb
lea ecx, [esi + 4]
push ecx
push ebp
call fcn.00545633
add esp, 0xc
add ebp, 0xfffb
jmp 0x4a2673
push 0xfffc
lea edx, [esi + 4]
push edx
push ebp
call fcn.00545633
add esp, 0xc
add ebp, 0xfffc
jmp 0x4a2673
push edi
lea eax, [esi + 4]
push eax
push ebp
call fcn.00545633
add esp, 0xc
add ebp, edi
push esi
call fcn.004a23a0
test ebx, ebx
mov esi, ebx
jne 0x4a2623
pop edi
pop esi
mov byte [ebp], 0
pop ebp
mov eax, 1
pop ebx
add esp, 0x14
ret 8
sub edi, esi
push edi
push eax
push str.ret__d___p_d__d_n
push 0xffff0000
call fcn.0048dc30
add esp, 0x10
mov eax, dword [esp + 0x18]
test eax, eax
je 0x4a26be
mov esi, dword [eax]
push eax
call fcn.004a23a0
test esi, esi
mov eax, esi
jne 0x4a26b0
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x14
ret 8
Function at 0x4a26d0
Capabilities:
Receive data
Receive data on socket

Disassembly:
sub esp, 8
push ebx
push ebp
mov ebp, dword [esp + 0x14]
xor ecx, ecx
push esi
push edi
mov dword [esp + 0x14], ecx
xor esi, esi
mov dword [esp + 0x10], ecx
mov eax, dword [0x57e6a8]
test eax, eax
je 0x4a26f4
cmp ecx, eax
jg 0x4a2756
push 0x10000
call fcn.004a2340
cmp dword [esp + 0x14], 0
mov edi, eax
je 0x4a270b
mov dword [esi], edi
jmp 0x4a270f
mov dword [esp + 0x14], edi
lea esi, [edi + 4]
lea ebx, [edi + 0x10000]
cmp esi, ebx
mov dword [esp + 0x1c], edi
mov dword [edi], 0
jae 0x4a2744
push 0
mov eax, ebx
sub eax, esi
push eax
push esi
push ebp
call dword [sym.imp.WS2_32.dll_recv]
cmp eax, 0xffffffff
je 0x4a275f
test eax, eax
je 0x4a277a
add esi, eax
cmp esi, ebx
jb 0x4a2726
add dword [esp + 0x10], 0xfffc
mov esi, dword [esp + 0x1c]
mov ecx, dword [esp + 0x10]
jmp 0x4a26e7
push eax
push ecx
push str._d____d_n
jmp 0x4a279a
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push str.recv__d_n
push 0xffff0000
call fcn.0048dc30
add esp, 0xc
jmp 0x4a27a7
mov edx, dword [esp + 0x10]
mov ecx, esi
sub ecx, edi
lea ecx, [edx + ecx - 4]
mov edx, dword [0x57e6a8]
lea eax, [ecx + 1]
cmp eax, edx
jle 0x4a27ca
push edx
push ecx
push str.buflen__d1____d_n
push 0xffff0000
call fcn.0048dc30
add esp, 0x10
mov eax, dword [esp + 0x14]
test eax, eax
je 0x4a27be
nop
mov esi, dword [eax]
push eax
call fcn.004a23a0
test esi, esi
mov eax, esi
jne 0x4a27b0
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 8
ret 8
mov edi, dword [esp + 0x20]
cmp eax, dword [edi + 4]
jle 0x4a27da
push eax
push edi
call fcn.0051ec60
mov ebx, dword [edi + 8]
mov edi, dword [esp + 0x14]
test edi, edi
je 0x4a2830
cmp edi, dword [esp + 0x1c]
mov ebp, dword [edi]
jne 0x4a280c
mov eax, esi
sub eax, edi
sub eax, 4
push eax
lea ecx, [edi + 4]
push ecx
push ebx
call fcn.00545633
mov edx, esi
add esp, 0xc
sub edx, edi
lea ebx, [ebx + edx - 4]
jmp 0x4a2824
push 0xfffc
lea eax, [edi + 4]
push eax
push ebx
call fcn.00545633
add esp, 0xc
add ebx, 0xfffc
push edi
call fcn.004a23a0
test ebp, ebp
mov edi, ebp
jne 0x4a27e5
pop edi
pop esi
pop ebp
mov byte [ebx], 0
mov eax, 1
pop ebx
add esp, 8
ret 8
Function at 0x4a2850
Capabilities:
Read file on windows

Disassembly:
sub esp, 0xc
push ebx
push ebp
mov ebp, dword [esp + 0x18]
push edi
mov ebx, eax
xor edi, edi
cmp ebx, 0x50
mov dword [esp + 0x1c], edi
push ebx
jb 0x4a2a10
call fcn.004a2380
mov edi, eax
test edi, edi
je 0x4a2a03
push 0
push 0
push 0
push ebp
call fcn.004ac4b0
test eax, eax
je 0x4a29e9
push 0
lea eax, [esp + 0x14]
push eax
push ebx
push edi
push ebp
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x4a29db
mov eax, dword [esp + 0x10]
cmp eax, ebx
jne 0x4a29d3
lea ecx, [edi + 3]
mov edx, str.NTFS
mov dword [esp + 0xc], 8
mov eax, ecx
sub edx, ecx
movzx ebx, byte [edx + eax]
movzx ebp, byte [eax]
sub ebp, ebx
jne 0x4a29b0
mov ebx, 1
add eax, ebx
sub dword [esp + 0xc], ebx
jne 0x4a28c7
movzx eax, byte [edi + 0xd]
movzx ecx, word [edi + 0xb]
imul eax, ecx
test eax, eax
mov dword [esi + 0x10], eax
je 0x4a29a7
movzx eax, word [edi + 0xb]
test eax, eax
mov dword [esi + 0x18], eax
je 0x4a299e
mov cl, byte [edi + 0x40]
test cl, cl
jle 0x4a291b
movsx edx, cl
imul edx, dword [esi + 0x10]
mov dword [esi + 0x14], edx
jmp 0x4a2924
neg ecx
mov eax, ebx
shl eax, cl
mov dword [esi + 0x14], eax
cmp dword [esi + 0x14], 0
je 0x4a2995
mov ecx, dword [edi + 0x30]
mov dword [esi], ecx
mov edx, dword [edi + 0x34]
mov dword [esi + 4], edx
mov eax, dword [edi + 0x48]
mov dword [esi + 8], eax
mov eax, dword [esi]
mov ecx, dword [edi + 0x4c]
push edx
push eax
push str.mft_lcn__I64u_n
mov dword [esi + 0xc], ecx
call fcn.0048dc10
mov ecx, dword [esi + 0xc]
mov edx, dword [esi + 8]
push ecx
push edx
push str.serial_number__I64u_n
call fcn.0048dc10
mov eax, dword [esi + 0x10]
push eax
push str.bytes_per_cluster__u_n
call fcn.0048dc10
mov ecx, dword [esi + 0x14]
push ecx
push str.bytes_per_file_record__u_n
call fcn.0048dc10
add esp, 0x28
push edi
mov dword [esp + 0x20], ebx
call fcn.004a23a0
pop edi
pop ebp
mov eax, ebx
pop ebx
add esp, 0xc
ret 4
push 0
push str.invalid_bytes_per_file_record__u_n
jmp 0x4a29f5
push 0
push str.invalid_bytes_per_sector__u_n
jmp 0x4a29f5
push 0
push str.invalid_bytes_per_cluster__u_n
jmp 0x4a29f5
push 8
push ecx
push str.bad_NTFS_signature:__t_n
call fcn.0048dc10
add esp, 0xc
push edi
call fcn.004a23a0
mov eax, dword [esp + 0x1c]
pop edi
pop ebp
pop ebx
add esp, 0xc
ret 4
push eax
push str.unable_to_read_all_of_NTFS_boot_sector:__u_n
jmp 0x4a29f5
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.failed_to_read_NTFS_boot_sector:__u_n
jmp 0x4a29f5
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.failed_to_set_file_pointer_to_boot_sector__u_n
call fcn.0048dc10
add esp, 8
push edi
call fcn.004a23a0
mov eax, dword [esp + 0x1c]
pop edi
pop ebp
pop ebx
add esp, 0xc
ret 4
push str.bad_sector_size__u_n
call fcn.0048dc10
add esp, 8
mov eax, edi
pop edi
pop ebp
pop ebx
add esp, 0xc
ret 4
Function at 0x4a2ad0
Capabilities:
Read file on windows

Disassembly:
push ecx
mov eax, dword [esp + 8]
push ebp
mov ebp, dword [esp + 0x10]
push 0
push ebp
push eax
push edi
call fcn.004ac4b0
test eax, eax
je 0x4a2b02
push 0
lea ecx, [esp + 8]
push ecx
push esi
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x4a2b02
cmp dword [esp + 4], esi
je 0x4a2b23
mov edx, dword [esp + 0xc]
push ebp
push edx
push str.read_error__I64x_n
push 0xffff0000
call fcn.0048dc30
push esi
push 0
push ebx
call fcn.00545659
add esp, 0x1c
pop ebp
pop ecx
ret 8
Function at 0x4a72d0
Capabilities:
Check if file exists

Disassembly:
sub esp, 0x214
push esi
push edi
lea eax, [esp + 8]
push eax
call fcn.0051ec40
mov edi, dword [esp + 0x220]
push edi
lea ecx, [esp + 0xc]
push ecx
call fcn.00523040
mov edx, dword [esp + 0x230]
mov eax, dword [esp + 0x22c]
mov ecx, dword [esp + 0x228]
push 0
push edx
mov edx, dword [esp + 0x22c]
push eax
mov eax, dword [esp + 0x1c]
push 0
push ecx
push edx
push eax
call dword [0x58af1c]
lea ecx, [esp + 8]
push ecx
mov esi, eax
call fcn.00522920
cmp esi, 0xffffffff
jne 0x4a7361
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
call ebx
cmp eax, 2
je 0x4a7353
push edi
call ebx
push eax
push str.CreateFileW__:__d:_Failed_to_open_file__s_n
call fcn.0048dc10
add esp, 0xc
pop ebx
pop edi
mov eax, esi
pop esi
add esp, 0x214
ret 0x14
pop edi
mov eax, esi
pop esi
add esp, 0x214
ret 0x14

Function at 0x4a7370
Capabilities:
Move file

Disassembly:
sub esp, 0x428
push ebx
push ebp
push esi
push edi
lea eax, [esp + 0x224]
push eax
call fcn.0051ec40
lea ecx, [esp + 0x10]
push ecx
call fcn.0051ec40
mov esi, dword [esp + 0x43c]
push esi
lea edx, [esp + 0x228]
push edx
call fcn.00523040
mov edi, dword [esp + 0x440]
push edi
lea eax, [esp + 0x14]
push eax
call fcn.00523040
mov ebp, dword [esp + 0x444]
mov edx, dword [esp + 0x18]
mov eax, dword [esp + 0x22c]
xor ecx, ecx
test ebp, ebp
setne cl
or ecx, 2
push ecx
push edx
push eax
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
test eax, eax
jne 0x4a743e
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
call ebx
cmp eax, 0x78
je 0x4a7402
push edi
push esi
push eax
push str.MoveFileExW__:_GetLastError__:__d:_Failed_to_move_file_from__s_to__s_n
call fcn.0048dc10
add esp, 0x10
xor esi, esi
jmp 0x4a746b
test ebp, ebp
je 0x4a7411
mov ecx, dword [esp + 0x18]
push ecx
call dword [0x58af28]
mov edx, dword [esp + 0x18]
mov eax, dword [esp + 0x22c]
push edx
push eax
call dword [0x58af8c]
test eax, eax
jne 0x4a743e
push edi
push esi
call ebx
push eax
push str.MoveFileW__:_GetLastError__:__d:_Failed_to_move_file_from__s_to__s_n
call fcn.0048dc10
add esp, 0x10
xor esi, esi
jmp 0x4a746b
mov eax, dword [esp + 0x448]
mov ecx, dword [esp + 0x18]
mov edx, dword [esp + 0x22c]
neg eax
push ecx
sbb eax, eax
push edx
and eax, 0x1ffff
mov esi, 1
push 5
add eax, esi
push eax
call dword [0x58afac]
lea ecx, [esp + 0x10]
push ecx
call fcn.00522920
lea edx, [esp + 0x224]
push edx
call fcn.00522920
pop edi
mov eax, esi
pop esi
pop ebp
pop ebx
add esp, 0x428
ret 0x10

Function at 0x4a8fb0
Capabilities:
Get file size

Disassembly:
mov ecx, dword [esp + 4]
push esi
mov esi, dword [esp + 0xc]
lea eax, [esi + 4]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
cmp eax, 0xffffffff
mov dword [esi], eax
pop esi
jne 0x4a8fdb
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
je 0x4a8fdb
xor eax, eax
ret 8
mov eax, 1
ret 8