Function at 0x40b190
Capabilities:
Check if file exists
Create directory
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x104
mov eax, dword [ebp + 0xc]
push ebx
and eax, 7
push esi
cmp eax, 2
push edi
jne 0x40b34d
mov esi, dword [ebp + 8]
mov ecx, dword [0x41b7e4]
xor ebx, ebx
mov al, byte [esi]
lea edi, [esi + 1]
mov byte [ecx], al
mov dword [ebp + 0xc], ebx
mov ecx, edi
mov eax, dword [0x41b7e4]
cmp byte [eax], bl
je 0x40b1d8
inc eax
mov dword [0x41b7e4], eax
mov dl, byte [ecx]
mov byte [eax], dl
inc ecx
jmp 0x40b1c2
push dword [0x41b7f8]
call fcn.0040b7d0
test eax, eax
pop ecx
je 0x40b208
mov ecx, dword [0x41b7e8]
mov al, byte [esi]
mov byte [ecx], al
mov eax, dword [0x41b7e8]
cmp byte [eax], bl
je 0x40b215
inc eax
mov dword [0x41b7e8], eax
mov cl, byte [edi]
mov byte [eax], cl
inc edi
jmp 0x40b1f2
push 0x41b7e8
push esi
call fcn.0040b064
pop ecx
pop ecx
mov eax, dword [0x41b7e4]
push 1
sub eax, dword [0x41b7f8]
pop esi
cmp eax, 0x102
jle 0x40b22d
mov dword [ebp + 0xc], esi
push dword [0x41b7dc]
call fcn.0040d570
inc eax
push eax
call fcn.0040d7b0
push dword [0x41b7dc]
mov edi, eax
push edi
call fcn.0040d6c0
push edi
call fcn.0040d44a
add esp, 0x14
push edi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x40b2f0
cmp dword [0x4346a8], ebx
jne 0x40b28b
push dword [0x41b7f8]
call fcn.0040d8ea
push dword [0x41b7dc]
call fcn.0040d8ea
pop ecx
pop ecx
push 2
pop ebx
jmp 0x40b2e2
cmp dword [ebp + 0xc], ebx
jne 0x40b323
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
test eax, eax
je 0x40b2f4
push dword [0x41b7dc]
mov dword [0x41b7e0], esi
push 0xaa
call fcn.0040bb0d
pop ecx
pop ecx
mov eax, dword [0x41b7e4]
mov byte [eax], 0x2f
mov eax, dword [0x41b7e8]
inc dword [0x41b7e4]
mov byte [eax], 0x2f
inc dword [0x41b7e8]
mov eax, dword [0x41b7e8]
mov byte [eax], bl
mov eax, dword [0x41b7e4]
mov byte [eax], bl
push edi
call fcn.0040d8ea
pop ecx
mov eax, ebx
jmp 0x40b7a1
test al, 0x10
jne 0x40b31e
push 0x417ff0
call fcn.0040ee8c
push dword [0x41b7f8]
call fcn.0040d8ea
push dword [0x41b7dc]
call fcn.0040d8ea
add esp, 0xc
push 3
jmp 0x40b288
cmp dword [ebp + 0xc], ebx
je 0x40b2b8
push 0x417ff0
call fcn.0040ee8c
push dword [0x41b7f8]
call fcn.0040d8ea
push dword [0x41b7dc]
call fcn.0040d8ea
add esp, 0xc
push 4
jmp 0x40b288
cmp eax, 4
jne 0x40b398
push dword [0x41b7dc]
push dword [ebp + 8]
call fcn.0040d6c0
push dword [0x41b7dc]
call fcn.0040d8ea
push dword [0x41b7f8]
call fcn.0040d8ea
add esp, 0x10
xor ebx, ebx
mov dword [0x41b7e8], ebx
mov dword [0x41b7e4], ebx
mov dword [0x41b7dc], ebx
mov dword [0x41b7f8], ebx
jmp 0x40b79a
cmp eax, 3
jne 0x40b453
mov esi, dword [ebp + 8]
mov ecx, dword [0x41b7e4]
xor ebx, ebx
mov al, byte [esi]
lea edi, [esi + 1]
mov dword [ebp + 0xc], ebx
mov byte [ecx], al
mov dword [ebp + 8], edi
mov eax, dword [0x41b7e4]
cmp byte [eax], bl
je 0x40b403
inc eax
mov ecx, eax
mov dword [0x41b7e4], eax
sub ecx, dword [0x41b7f8]
cmp ecx, 0x105
jl 0x40b3f7
dec eax
push 0x417ff0
mov dword [0x41b7e4], eax
mov byte [eax], bl
call fcn.0040ee8c
mov eax, dword [0x41b7e4]
pop ecx
mov dword [ebp + 0xc], 1
mov ecx, dword [ebp + 8]
inc dword [ebp + 8]
mov cl, byte [ecx]
mov byte [eax], cl
jmp 0x40b3b9
mov eax, dword [0x417bd4]
test byte [eax + 0x28], 0x20
jne 0x40b433
push dword [0x41b7f8]
call fcn.0040b7d0
test eax, eax
pop ecx
jne 0x40b433
push 0x41b7e8
push esi
call fcn.0040b064
pop ecx
pop ecx
mov eax, dword [ebp + 0xc]
jmp 0x40b7a1
mov ecx, dword [0x41b7e8]
mov al, byte [esi]
mov byte [ecx], al
mov eax, dword [0x41b7e8]
cmp byte [eax], bl
je 0x40b42b
inc eax
mov dword [0x41b7e8], eax
mov cl, byte [edi]
mov byte [eax], cl
inc edi
jmp 0x40b43d
cmp eax, 1
jne 0x40b5ea
mov eax, dword [0x41b7ec]
mov ecx, dword [0x41b7fc]
lea eax, [ecx + eax + 1]
push eax
call fcn.0040d7b0
xor ebx, ebx
pop ecx
cmp eax, ebx
mov dword [0x41b7f8], eax
je 0x40b4a8
mov eax, dword [0x41b7ec]
mov ecx, dword [0x41b7fc]
lea eax, [ecx + eax + 1]
push eax
call fcn.0040d7b0
cmp eax, ebx
pop ecx
mov dword [0x41b7dc], eax
jne 0x40b4af
push dword [0x41b7f8]
call fcn.0040d8ea
pop ecx
push 0xa
jmp 0x40b7a0
mov eax, dword [0x417bd4]
test byte [eax + 0x28], 0x20
je 0x40b57a
cmp dword [0x41b7f0], ebx
je 0x40b4cb
mov eax, dword [ebp + 8]
jmp 0x40b4d4
mov eax, dword [0x41b7f4]
cmp eax, ebx
je 0x40b4e6
cmp byte [eax + 1], 0x3a
jne 0x40b4e6
movsx eax, byte [eax]
push eax
call fcn.0040df8e
pop ecx
jmp 0x40b51e
lea eax, [ebp + 8]
mov esi, 0x104
push eax
lea eax, [ebp - 0x104]
push eax
push esi
push 0x417bbc
call dword [sym.imp.KERNEL32.dll_GetFullPathNameA]
cmp eax, esi
jbe 0x40b50d
push 1
jmp 0x40b7a0
movsx eax, byte [ebp - 0x104]
sub eax, 0x60
mov dword [0x41b7d8], eax
add al, 0x60
mov ecx, dword [0x41b7f8]
mov byte [ecx], al
mov ecx, dword [0x41b7f8]
mov edx, dword [0x4346b0]
movsx eax, byte [ecx]
sub eax, 0x60
cmp edx, ebx
mov dword [0x41b7d8], eax
je 0x40b560
cmp byte [ecx], 0x61
jl 0x40b560
cmp edx, 1
jne 0x40b55c
push eax
call fcn.0040b7a6
pop ecx
mov ecx, dword [0x41b7f8]
test eax, eax
je 0x40b560
mov byte [ecx], bl
jmp 0x40b5ab
push ecx
call fcn.0040d8ea
push dword [0x41b7dc]
call fcn.0040d8ea
pop ecx
pop ecx
push 0x4e
jmp 0x40b7a0
cmp dword [0x41b7f0], ebx
je 0x40b594
push dword [ebp + 8]
push dword [0x41b7f8]
call fcn.0040d6c0
pop ecx
pop ecx
jmp 0x40b5ab
cmp dword [0x41b7fc], ebx
jle 0x40b5a4
push dword [0x41b7f4]
jmp 0x40b585
mov eax, dword [0x41b7f8]
mov byte [eax], bl
mov eax, dword [0x41b7f8]
mov ecx, dword [0x41b7dc]
mov dword [0x41b7e4], eax
mov dword [0x41b7e8], ecx
mov al, byte [eax]
mov byte [ecx], al
mov eax, dword [0x41b7e8]
cmp byte [eax], bl
je 0x40b79a
inc eax
inc dword [0x41b7e4]
mov ecx, dword [0x41b7e4]
mov dword [0x41b7e8], eax
mov cl, byte [ecx]
mov byte [eax], cl
jmp 0x40b5c5
xor ebx, ebx
cmp eax, ebx
jne 0x40b781
mov esi, dword [ebp + 8]
cmp esi, ebx
jne 0x40b602
xor eax, eax
jmp 0x40b731
push esi
call fcn.0040d570
cmp eax, ebx
pop ecx
mov dword [0x41b7fc], eax
jle 0x40b79a
xor edi, edi
cmp dword [0x417e3c], 1
mov dword [ebp + 8], ebx
mov dword [ebp + 0xc], 2
jle 0x40b644
movsx eax, byte [esi]
push 0x103
push eax
call fcn.0040e0c8
pop ecx
pop ecx
mov ecx, eax
mov eax, dword [0x41b7fc]
jmp 0x40b657
movsx ecx, byte [esi]
mov edx, dword [str.________________________________H]
mov cx, word [edx + ecx*2]
and ecx, 0x103
cmp ecx, ebx
je 0x40b668
cmp byte [esi + 1], 0x3a
jne 0x40b668
mov dword [ebp + 8], 1
cmp byte [eax + esi - 1], 0x2f
jne 0x40b680
dec eax
push 1
mov dword [0x41b7fc], eax
pop edi
mov byte [eax + esi], bl
mov eax, dword [0x41b7fc]
cmp dword [ebp + 8], ebx
je 0x40b69b
cmp eax, 2
jne 0x40b69b
cmp edi, ebx
jne 0x40b719
mov dword [ebp + 0xc], 3
jmp 0x40b719
cmp eax, ebx
jle 0x40b719
push esi
call fcn.0040d570
inc eax
push eax
call fcn.0040d7b0
mov edi, eax
push esi
push edi
call fcn.0040d6c0
push edi
call fcn.0040d44a
add esp, 0x14
push edi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x40b70d
cmp dword [0x4346a8], ebx
jne 0x40b6dd
push edi
call fcn.0040d8ea
pop ecx
push 2
jmp 0x40b730
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
test eax, eax
jne 0x40b700
push edi
call fcn.0040d8ea
mov dword [esp], 0x417ff0
call fcn.0040ee8c
pop ecx
push 3
jmp 0x40b730
push esi
push 0xaa
call fcn.0040bb0d
pop ecx
pop ecx
push edi
call fcn.0040d8ea
mov eax, dword [0x41b7fc]
pop ecx
mov edi, dword [ebp + 0xc]
add eax, edi
push eax
call fcn.0040d7b0
cmp eax, ebx
pop ecx
mov dword [0x41b7f4], eax
jne 0x40b739
push 0xa
pop eax
mov dword [0x41b7fc], ebx
jmp 0x40b7a1
push esi
push eax
call fcn.0040d6c0
pop ecx
cmp edi, 3
pop ecx
jne 0x40b75c
mov eax, dword [0x41b7fc]
mov ecx, dword [0x41b7f4]
mov byte [ecx + eax], 0x2e
inc dword [0x41b7fc]
mov eax, dword [0x41b7f4]
mov ecx, dword [0x41b7fc]
mov byte [eax + ecx], 0x2f
inc dword [0x41b7fc]
mov eax, dword [0x41b7f4]
mov ecx, dword [0x41b7fc]
mov byte [eax + ecx], bl
jmp 0x40b79a
cmp eax, 5
jne 0x40b79e
cmp dword [0x41b7fc], ebx
jle 0x40b79a
push dword [0x41b7f4]
call fcn.0040d8ea
pop ecx
xor eax, eax
jmp 0x40b7a1
push 0x63
pop eax
pop edi
pop esi
pop ebx
leave
ret