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

Disassembly:
sub esp, 0x44
push ebx
push esi
mov esi, dword [esp + 0x50]
xor ebx, ebx
cmp dword [esi + 8], ebx
je 0x1000390e
mov al, byte [esi]
push ebx
lea ecx, [esp + 0x20]
mov byte [esp + 0x20], al
call dword [sym.imp.MSVCP60.dll_private:_void___thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Tidy_bool_]
mov ecx, dword [sym.imp.MSVCP60.dll_unsigned_int_const_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::npos]
mov edx, dword [ecx]
lea ecx, [esp + 0x1c]
push edx
push ebx
push esi
call dword [sym.imp.MSVCP60.dll_public:_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int______thiscall_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::assign_class_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int___const___unsigned_int__unsigned_int_]
mov eax, dword [esp + 0x20]
cmp eax, ebx
jne 0x10003847
mov eax, dword [sym.imp.MSVCP60.dll_unsigned_short_int_const__private:_static_unsigned_short_int_const____cdecl_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Nullstr_void_::_2::_C]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x10003895
mov edx, dword [esp + 0x20]
shr eax, 4
and al, 1
cmp edx, ebx
mov byte [esp + 0x50], al
je 0x10003a62
mov cl, byte [edx - 1]
cmp cl, bl
je 0x1000387f
cmp cl, 0xff
je 0x1000387f
dec cl
pop esi
mov byte [edx - 1], cl
pop ebx
add esp, 0x44
ret
add edx, 0xfffffffe
push edx
call fcn.100061b2
mov al, byte [esp + 0x54]
add esp, 4
pop esi
pop ebx
add esp, 0x44
ret
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
call esi
cmp eax, 2
je 0x100038c9
call esi
cmp eax, 3
je 0x100038c9
mov ecx, dword [esp + 0x20]
cmp ecx, ebx
je 0x1000390e
mov al, byte [ecx - 1]
cmp al, bl
je 0x10003902
cmp al, 0xff
je 0x10003902
dec al
pop esi
mov byte [ecx - 1], al
xor al, al
pop ebx
add esp, 0x44
ret
mov eax, dword [esp + 0x20]
cmp eax, ebx
jne 0x100038d6
mov eax, dword [sym.imp.MSVCP60.dll_unsigned_short_int_const__private:_static_unsigned_short_int_const____cdecl_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Nullstr_void_::_2::_C]
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x10003916
mov ecx, dword [esp + 0x20]
cmp ecx, ebx
je 0x1000390e
mov al, byte [ecx - 1]
cmp al, bl
je 0x10003902
cmp al, 0xff
je 0x10003902
dec al
pop esi
mov byte [ecx - 1], al
xor al, al
pop ebx
add esp, 0x44
ret
add ecx, 0xfffffffe
push ecx
call fcn.100061b2
add esp, 4
pop esi
xor al, al
pop ebx
add esp, 0x44
ret
mov eax, dword [esp + 0x20]
cmp eax, ebx
jne 0x10003923
mov eax, dword [sym.imp.MSVCP60.dll_unsigned_short_int_const__private:_static_unsigned_short_int_const____cdecl_std::basic_string_unsigned_short_int__struct_std::char_traits_unsigned_short_int___class_std::allocator_unsigned_short_int__::_Nullstr_void_::_2::_C]
push ebx
push 0x2000000
push 3
push ebx
push ebx
push 0x60000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
cmp esi, 0xffffffff
je 0x10003a34
lea eax, [esp + 0xc]
push edi
push eax
lea ecx, [esp + 0x18]
push ebx
push ecx
push ebx
push ebx
push 4
push 1
push esi
mov dword [esp + 0x30], ebx
call dword [sym.imp.ADVAPI32.dll_GetSecurityInfo]
lea edx, [esp + 0x54]
lea eax, [esp + 0x18]
push edx
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push 1
push eax
mov dword [esp + 0x80], ebx
mov byte [esp + 0x44], bl
mov byte [esp + 0x45], bl
mov byte [esp + 0x46], bl
mov byte [esp + 0x47], bl
mov byte [esp + 0x48], bl
mov byte [esp + 0x49], 1
call dword [sym.imp.ADVAPI32.dll_AllocateAndInitializeSid]
mov ecx, 7
xor eax, eax
lea edi, [esp + 0x34]
lea edx, [esp + 0xc]
rep stosd dword es:[edi], eax
mov ecx, dword [esp + 0x54]
mov eax, dword [esp + 0x14]
mov dword [esp + 0x4c], ecx
push edx
lea ecx, [esp + 0x34]
push eax
push ecx
push 1
mov dword [esp + 0x44], 1
mov dword [esp + 0x40], 0x10000000
mov dword [esp + 0x48], 3
mov dword [esp + 0x58], 2
mov dword [esp + 0x54], ebx
mov dword [esp + 0x1c], ebx
call dword [sym.imp.ADVAPI32.dll_SetEntriesInAclA]
mov eax, dword [esp + 0xc]
cmp eax, ebx
je 0x10003a06
push ebx
push eax
push ebx
push ebx
push 4
push 1
push esi
call dword [sym.imp.ADVAPI32.dll_SetSecurityInfo]
mov edx, dword [esp + 0x54]
push edx
call dword [sym.imp.ADVAPI32.dll_FreeSid]
mov eax, dword [esp + 0xc]
mov edi, dword [sym.imp.KERNEL32.dll_LocalFree]
push eax
call edi
mov ecx, dword [esp + 0x10]
push ecx
call edi
mov edx, dword [esp + 0x14]
push edx
call edi
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
mov ecx, dword [esp + 0x20]
cmp ecx, ebx
je 0x10003a60
mov al, byte [ecx - 1]
cmp al, bl
je 0x10003a54
cmp al, 0xff
je 0x10003a54
dec al
pop esi
mov byte [ecx - 1], al
mov al, 1
pop ebx
add esp, 0x44
ret
add ecx, 0xfffffffe
push ecx
call fcn.100061b2
add esp, 4
mov al, 1
pop esi
pop ebx
add esp, 0x44
ret