Function at 0x407120
Capabilities:
Check if file exists
Execute command
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x414863
mov eax, dword fs:[0]
push eax
sub esp, 0x104
mov eax, dword [0x41b00c]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
sub esp, 0x18
mov dword [ebp - 4], 1
lea eax, [ebp + 8]
mov ecx, esp
push eax
call fcn.004038e0
lea ecx, [ebp - 0x2c]
call fcn.00407c90
add esp, 0x18
lea eax, [ebp - 0x2c]
mov byte [ebp - 4], 2
push eax
lea ecx, [ebp - 0xf8]
call fcn.004038e0
cmp dword [ebp - 0xe4], 0x10
lea eax, [ebp - 0xf8]
cmovae eax, dword [ebp - 0xf8]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
mov ecx, dword [ebp - 0xe4]
cmp eax, 0xffffffff
jne 0x4071f6
cmp ecx, 0x10
jb 0x4071de
mov edx, dword [ebp - 0xf8]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x4071d4
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x407405
push ecx
push edx
call fcn.0041342f
add esp, 8
mov ecx, dword [ebp - 0x1c]
mov eax, 0x7fffffff
sub eax, ecx
cmp eax, 7
jb 0x4078a2
jmp 0x40740b
test al, 0x10
je 0x4073d3
cmp ecx, 0x10
jb 0x407232
mov edx, dword [ebp - 0xf8]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x407228
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x407405
push ecx
push edx
call fcn.0041342f
add esp, 8
push 0xb0
lea eax, [ebp - 0xdc]
push 0
push eax
call sub.VCRUNTIME140.dll_memset
add esp, 4
lea eax, [ebp + 8]
lea ecx, [ebp - 0xdc]
push 2
push eax
call fcn.00402a40
cmp dword [ebp - 0x8c], 0
jne 0x407589
mov eax, dword [ebp - 0xdc]
mov eax, dword [eax + 4]
mov dword [ebp + eax - 0xdc], vtable.std::basic_ofstream_char__struct_std::char_traits_char__.0
mov eax, dword [ebp - 0xdc]
mov ecx, dword [eax + 4]
lea eax, [ecx - 0x68]
mov dword [ebp + ecx - 0xe0], eax
mov byte [ebp - 4], 5
cmp dword [ebp - 0x8c], 0
mov dword [ebp - 0xd8], vtable.std::basic_filebuf_char__struct_std::char_traits_char__.0
je 0x4072d4
mov eax, dword [ebp - 0xcc]
lea ecx, [ebp - 0x9c]
cmp dword [eax], ecx
jne 0x4072d4
mov edx, dword [ebp - 0x84]
mov ecx, dword [ebp - 0x88]
sub edx, ecx
mov dword [eax], ecx
mov eax, dword [ebp - 0xbc]
mov dword [eax], ecx
mov eax, dword [ebp - 0xac]
mov dword [eax], edx
cmp byte [ebp - 0x90], 0
je 0x4072e8
lea ecx, [ebp - 0xd8]
call fcn.00403d10
lea ecx, [ebp - 0xd8]
call dword [sym.imp.MSVCP140.dll_public_virtual:_void___thiscall_std::basic_streambuf_char__struct_std::char_traits_char__::destructor_void_]
lea ecx, [ebp - 0xd4]
call dword [sym.imp.MSVCP140.dll_public_virtual:_void___thiscall_std::basic_ostream_char__struct_std::char_traits_char__::destructor_void_]
lea ecx, [ebp - 0x74]
call dword [sym.imp.MSVCP140.dll_public_virtual:_void___thiscall_std::basic_ios_char__struct_std::char_traits_char__::destructor_void_]
mov ecx, dword [ebp - 0x18]
cmp ecx, 0x10
jb 0x40733d
mov edx, dword [ebp - 0x2c]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x407333
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x407857
push ecx
push edx
call fcn.0041342f
add esp, 8
mov ecx, dword [ebp + 0x1c]
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x18], 0xf
mov byte [ebp - 0x2c], 0
cmp ecx, 0x10
jb 0x407383
mov edx, dword [ebp + 8]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x407379
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x407857
push ecx
push edx
call fcn.0041342f
add esp, 8
mov ecx, dword [ebp + 0x20]
mov dword [ebp + 0x18], 0
mov dword [ebp + 0x1c], 0xf
mov byte [ebp + 8], 0
test ecx, ecx
je 0x4073c9
mov edx, dword [ebp + 0x28]
mov eax, ecx
sub edx, ecx
cmp edx, 0x1000
jb 0x4073bf
mov ecx, dword [eax - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x407857
push edx
push ecx
call fcn.0041342f
add esp, 8
mov eax, 1
jmp 0x407886
cmp ecx, 0x10
jb 0x4071de
mov edx, dword [ebp - 0xf8]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x4071d4
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x4071d4
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
cmp dword [ebp - 0x18], 0x10
lea eax, [ebp - 0x2c]
push ecx
cmovae eax, dword [ebp - 0x2c]
push eax
push 7
push 0x4165c8
push ecx
push dword [ebp - 0xe0]
lea ecx, [ebp - 0x110]
call fcn.00409e00
mov byte [ebp - 4], 3
mov edx, dword [ebp - 0xfc]
mov eax, edx
mov ecx, dword [ebp - 0x100]
sub eax, ecx
cmp eax, 1
jb 0x407471
lea eax, [ecx + 1]
cmp edx, 0x10
mov dword [ebp - 0x100], eax
lea eax, [ebp - 0x110]
cmovae eax, dword [ebp - 0x110]
mov word [eax + ecx], 0x22
lea eax, [ebp - 0x110]
jmp 0x407492
push 1
push 0x4165c4
mov byte [ebp - 0xe0], 0
lea ecx, [ebp - 0x110]
push dword [ebp - 0xe0]
push 1
call fcn.004047e0
mov dword [ebp - 0xe8], 0
xorps xmm0, xmm0
movups xmmword [ebp - 0xf8], xmm0
mov dword [ebp - 0xe4], 0
movups xmm0, xmmword [eax]
movups xmmword [ebp - 0xf8], xmm0
movq xmm0, qword [eax + 0x10]
movq qword [ebp - 0xe8], xmm0
mov dword [eax + 0x10], 0
mov dword [eax + 0x14], 0xf
mov byte [eax], 0
lea eax, [ebp - 0xf8]
cmp dword [ebp - 0xe4], 0x10
cmovae eax, dword [ebp - 0xf8]
push eax
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_system]
mov ecx, dword [ebp - 0xe4]
add esp, 4
cmp ecx, 0x10
jb 0x40752c
mov edx, dword [ebp - 0xf8]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x407522
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x407583
push ecx
push edx
call fcn.0041342f
add esp, 8
mov byte [ebp - 4], 2
mov ecx, dword [ebp - 0xfc]
mov dword [ebp - 0xe8], 0
mov dword [ebp - 0xe4], 0xf
mov byte [ebp - 0xf8], 0
cmp ecx, 0x10
jb 0x407232
mov edx, dword [ebp - 0x110]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x407228
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x407228
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
mov byte [ebp - 4], 6
mov esi, dword [ebp + 0x20]
mov edi, dword [ebp + 0x24]
cmp esi, edi
je 0x4075a7
mov dl, byte [esi]
lea ecx, [ebp - 0xdc]
call fcn.00404a00
inc esi
jmp 0x407593
lea ecx, [ebp - 0xd8]
call fcn.00403d10
test eax, eax
jne 0x4075ce
push eax
mov eax, dword [ebp - 0xdc]
lea ecx, [ebp - 0xdc]
push 2
add ecx, dword [eax + 4]
call dword [sym.imp.MSVCP140.dll_public:_void___thiscall_std::basic_ios_char__struct_std::char_traits_char__::setstate_int__bool_]
mov dword [ebp - 4], 4
mov eax, dword [ebp - 0xdc]
mov eax, dword [eax + 4]
mov dword [ebp + eax - 0xdc], vtable.std::basic_ofstream_char__struct_std::char_traits_char__.0
mov eax, dword [ebp - 0xdc]
mov ecx, dword [eax + 4]
lea eax, [ecx - 0x68]
mov dword [ebp + ecx - 0xe0], eax
mov byte [ebp - 4], 9
cmp dword [ebp - 0x8c], 0
mov dword [ebp - 0xd8], vtable.std::basic_filebuf_char__struct_std::char_traits_char__.0
je 0x407643
mov eax, dword [ebp - 0xcc]
lea ecx, [ebp - 0x9c]
cmp dword [eax], ecx
jne 0x407643
mov edx, dword [ebp - 0x84]
mov ecx, dword [ebp - 0x88]
sub edx, ecx
mov dword [eax], ecx
mov eax, dword [ebp - 0xbc]
mov dword [eax], ecx
mov eax, dword [ebp - 0xac]
mov dword [eax], edx
cmp byte [ebp - 0x90], 0
je 0x407657
lea ecx, [ebp - 0xd8]
call fcn.00403d10
lea ecx, [ebp - 0xd8]
call dword [sym.imp.MSVCP140.dll_public_virtual:_void___thiscall_std::basic_streambuf_char__struct_std::char_traits_char__::destructor_void_]
lea ecx, [ebp - 0xd4]
call dword [sym.imp.MSVCP140.dll_public_virtual:_void___thiscall_std::basic_ostream_char__struct_std::char_traits_char__::destructor_void_]
lea ecx, [ebp - 0x74]
call dword [sym.imp.MSVCP140.dll_public_virtual:_void___thiscall_std::basic_ios_char__struct_std::char_traits_char__::destructor_void_]
mov ecx, dword [ebp - 0x18]
cmp ecx, 0x10
jb 0x4076ac
mov edx, dword [ebp - 0x2c]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x4076a2
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x407857
push ecx
push edx
call fcn.0041342f
add esp, 8
mov ecx, dword [ebp + 0x1c]
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x18], 0xf
mov byte [ebp - 0x2c], 0
cmp ecx, 0x10
jb 0x4076f2
mov edx, dword [ebp + 8]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x4076e8
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x407857
push ecx
push edx
call fcn.0041342f
add esp, 8
mov ecx, dword [ebp + 0x20]
mov dword [ebp + 0x18], 0
mov dword [ebp + 0x1c], 0xf
mov byte [ebp + 8], 0
test ecx, ecx
je 0x407738
mov edx, dword [ebp + 0x28]
mov eax, ecx
sub edx, ecx
cmp edx, 0x1000
jb 0x40772e
mov ecx, dword [eax - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x407857
push edx
push ecx
call fcn.0041342f
add esp, 8
xor eax, eax
jmp 0x407886
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push ecx
push edx
call fcn.0041342f
add esp, 8
lea ecx, [ebp + 0x20]
mov dword [ebp + 0x18], 0
mov dword [ebp + 0x1c], 0xf
mov byte [ebp + 8], 0
call fcn.00403780
mov eax, 2
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.00412ed8
mov esp, ebp
pop ebp
ret
call fcn.00401480
int3