Function at 0x40b630
Capabilities:
Terminate process
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff0
sub esp, 0x50
mov ebx, dword [ebp + 0xc]
mov edi, dword [ebp + 8]
xorps xmm0, xmm0
movaps xmmword [esp + 0x30], xmm0
movaps xmmword [esp + 0x20], xmm0
movaps xmmword [esp + 0x10], xmm0
mov dword [esp + 8], 0
push 0x1b6
push 0
push edi
call fcn.004210e0
add esp, 0xc
mov esi, eax
test eax, eax
jns 0x40b6d4
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
test bl, 0x10
je 0x40b686
cmp dword [eax], 2
je 0x40b956
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
test bl, 2
je 0x40b8fa
cmp dword [eax], 2
jne 0x40b8fa
push 0x1b6
push 0x100
push edi
call fcn.004210e0
add esp, 0xc
mov esi, eax
test bl, 8
je 0x40b6cc
test esi, esi
js 0x40b6cc
push edi
push str.Creating_regular_file__s_n
call fcn.0040b9a0
add esp, 8
jmp 0x40b6d4
test esi, esi
js 0x40b8fa
lea eax, [esp + 0x10]
push eax
push esi
call sub.api_ms_win_crt_filesystem_l1_1_0.dll__fstat32i64
add esp, 8
test eax, eax
js 0x40b8e6
mov edi, dword [ebp + 0x10]
push esi
call sub.api_ms_win_crt_stdio_l1_1_0.dll__close_1
add esp, 4
movzx eax, word [esp + 0x16]
and eax, 0xf000
movzx eax, ax
test edi, edi
je 0x40b713
xor ecx, ecx
cmp eax, 0x3000
sete cl
mov dword [edi], ecx
test bl, 1
je 0x40b733
cmp eax, 0x3000
je 0x40b733
push dword [ebp + 8]
push str._s_is_not_a_block_special_device._n
call fcn.0040b9a0
add esp, 8
xor edi, edi
jmp 0x40b7ab
mov edi, 1
test bl, 4
je 0x40b7ab
lea eax, [esp + 8]
push 0
push eax
call fcn.00429880
add esp, 8
test eax, eax
js 0x40b7ab
mov ebx, dword [ebp + 8]
push ebx
push 0x48bdb6
push dword [esp + 0x10]
call fcn.004278f0
add esp, 0xc
mov esi, eax
mov eax, dword [esp + 8]
test esi, esi
je 0x40b7a2
push ebx
push 0x48bdbb
push eax
call fcn.004278f0
add esp, 0xc
mov edi, eax
push dword [esp + 8]
call fcn.00429900
add esp, 4
test edi, edi
je 0x40b7b5
push edi
push esi
push ebx
push str._s_contains_a__s_file_system_labelled__s_n
call fcn.0040b9a0
add esp, 0x10
jmp 0x40b7c4
push eax
call fcn.00429900
add esp, 4
mov eax, edi
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret
push esi
push ebx
push str._s_contains_a__s_file_system_n
call fcn.0040b9a0
add esp, 0xc
push 3
push 0x48be0b
push esi
call sub.api_ms_win_crt_string_l1_1_0.dll_strncmp
add esp, 0xc
test eax, eax
jne 0x40b8cf
mov dword [esp + 0xc], 0
mov dword [esp + 4], 0
mov eax, dword [0x48ae08]
mov eax, dword [eax]
sub esp, 0x1c
lea ecx, [esp + 0x28]
mov dword [esp + 0x18], ecx
mov dword [esp + 0x14], eax
movaps xmm0, xmmword [0x48bcd0]
movups xmmword [esp + 4], xmm0
mov eax, dword [ebp + 8]
mov dword [esp], eax
call fcn.0041d760
add esp, 0x1c
test eax, eax
jne 0x40b8cf
mov eax, dword [esp + 0xc]
mov ebx, dword [eax + 0x10]
mov eax, dword [ebx + 0x2c]
test eax, eax
je 0x40b86f
mov dword [esp + 4], eax
movzx eax, byte [ebx + 0x88]
mov byte [esp + 3], al
lea eax, [esp + 4]
push eax
call dword [sym.imp.api_ms_win_crt_time_l1_1_0.dll__ctime32]
add esp, 4
cmp byte [esp + 3], 0
je 0x40b893
add ebx, 0x88
push eax
push ebx
push 0x40
push str._tlast_mounted_on__.s_on__s
call fcn.0040b9a0
add esp, 0x10
jmp 0x40b8c2
mov eax, dword [ebx + 0x108]
test eax, eax
je 0x40b89b
mov dword [esp + 4], eax
lea eax, [esp + 4]
push eax
call dword [sym.imp.api_ms_win_crt_time_l1_1_0.dll__ctime32]
add esp, 4
push eax
push str._tcreated_on__s
jmp 0x40b8ba
push eax
push str._tlast_mounted_on__s
jmp 0x40b8ba
mov eax, dword [ebx + 0x30]
test eax, eax
je 0x40b8c2
mov dword [esp + 4], eax
lea eax, [esp + 4]
push eax
call dword [sym.imp.api_ms_win_crt_time_l1_1_0.dll__ctime32]
add esp, 4
push eax
push str._tlast_modified_on__s
call fcn.0040b9a0
add esp, 8
lea eax, [esp + 0xc]
push eax
call fcn.00413f60
add esp, 4
push esi
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
add esp, 4
push edi
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
add esp, 4
jmp 0x40b72f
push str.stat
call sub.api_ms_win_crt_runtime_l1_1_0.dll_perror
add esp, 4
push 1
call sub.api_ms_win_crt_runtime_l1_1_0.dll_exit
push 2
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
add esp, 4
mov esi, eax
mov ebx, edi
mov edi, dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__errno]
call edi
push dword [eax]
call fcn.004227d0
add esp, 4
push eax
push ebx
push str.Could_not_open__s:__s_n
push esi
call 0x40b980
add esp, 0x10
call edi
cmp dword [eax], 2
jne 0x40b94f
push 2
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
add esp, 4
push eax
push 1
push 0x45
push str._nThe_device_apparently_does_not_exist__did_you_specify_it_correctly__n
call sub.api_ms_win_crt_stdio_l1_1_0.dll_fwrite
add esp, 0x10
push 1
call sub.api_ms_win_crt_runtime_l1_1_0.dll_exit
push 2
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
add esp, 4
push edi
push str.The_file__s_does_not_exist_and_no_size_was_specified._n
push eax
call 0x40b980
add esp, 0xc
push 1
call sub.api_ms_win_crt_runtime_l1_1_0.dll_exit
nop word [eax + eax]
push eax
mov eax, dword [esp + 8]
mov ecx, dword [esp + 0xc]
lea edx, [esp + 0x10]
mov dword [esp], edx
push edx
push ecx
push eax
call fcn.00424a80
add esp, 0xc
pop eax
ret