Function at 0x501ea0
Capabilities:
Create directory

Disassembly:
push 0xffffffffffffffff
push 0x5cfc04
mov eax, dword fs:[0]
push eax
sub esp, 0xec
mov eax, dword [0x65d4e4]
xor eax, esp
mov dword [esp + 0xe8], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x65d4e4]
xor eax, esp
push eax
lea eax, [esp + 0x100]
mov dword fs:[0], eax
mov ebp, dword [esp + 0x110]
xor ebx, ebx
cmp ebp, ebx
mov ecx, ebp
jne 0x501eef
mov ecx, 0x62b600
mov edi, 0xf
mov eax, ecx
mov dword [esp + 0xf8], edi
mov dword [esp + 0xf4], ebx
mov byte [esp + 0xe4], bl
lea esi, [eax + 1]
mov edi, edi
mov dl, byte [eax]
add eax, 1
test dl, dl
jne 0x501f10
sub eax, esi
push eax
push ecx
lea ecx, [esp + 0xe8]
call fcn.00409790
push 1
push 0x5f4230
lea ecx, [esp + 0x30]
mov dword [esp + 0x110], ebx
mov dword [esp + 0x48], edi
mov dword [esp + 0x44], ebx
mov byte [esp + 0x34], 0
call fcn.00409790
push 1
push 0x5f422c
lea ecx, [esp + 0x4c]
mov byte [esp + 0x110], 1
mov dword [esp + 0x64], edi
mov dword [esp + 0x60], ebx
mov byte [esp + 0x50], 0
call fcn.00409790
lea eax, [esp + 0x28]
push eax
lea ecx, [esp + 0x48]
push ecx
lea edx, [esp + 0xe8]
push edx
mov byte [esp + 0x114], 2
call fcn.004fc450
mov esi, 0x10
add esp, 0xc
cmp dword [esp + 0x5c], esi
jb 0x501fac
mov eax, dword [esp + 0x48]
push eax
call fcn.00595eb8
add esp, 4
cmp dword [esp + 0x40], esi
mov dword [esp + 0x5c], edi
mov dword [esp + 0x58], ebx
mov byte [esp + 0x48], 0
mov byte [esp + 0x108], 0
jb 0x501fd4
mov ecx, dword [esp + 0x2c]
push ecx
call fcn.00595eb8
add esp, 4
push 0x5f4230
lea edx, [esp + 0xe4]
push edx
lea eax, [esp + 0x1c]
push eax
call fcn.004fe540
add esp, 0xc
push 1
push 2
lea ecx, [esp + 0x68]
mov byte [esp + 0x110], 3
call fcn.0040b040
cmp byte [ebp], 0x5c
mov byte [esp + 0x108], 4
jne 0x502023
lea ecx, [esp + 0x60]
push 0x5f4230
push ecx
call fcn.00409b60
add esp, 8
mov edi, dword [esp + 0x1c]
mov esi, dword [esp + 0x18]
xor ebp, ebp
test esi, esi
mov dword [esp + 0x24], ebx
je 0x502194
mov ecx, edi
sub ecx, esi
mov eax, 0x92492493
imul ecx
add edx, ecx
sar edx, 4
mov eax, edx
shr eax, 0x1f
add eax, edx
cmp ebp, eax
jae 0x502194
cmp dword [ebx + esi + 0x14], 0
je 0x502131
test esi, esi
je 0x502080
sub edi, esi
mov eax, 0x92492493
imul edi
add edx, edi
sar edx, 4
mov eax, edx
shr eax, 0x1f
add eax, edx
cmp ebp, eax
jb 0x502089
call fcn.005b1933
mov esi, dword [esp + 0x18]
lea eax, [ebx + esi]
push 0x5f4230
push eax
lea edx, [esp + 0x68]
push edx
call fcn.00409240
add esp, 8
push eax
call fcn.00409b60
add esp, 8
lea eax, [esp + 0x28]
push eax
lea ecx, [esp + 0x64]
call fcn.004094f0
cmp dword [eax + 0x14], 3
mov esi, 0x10
setbe bl
cmp dword [esp + 0x40], esi
jb 0x5020d5
mov ecx, dword [esp + 0x2c]
push ecx
call fcn.00595eb8
add esp, 4
test bl, bl
jne 0x502125
lea edx, [esp + 0x28]
push edx
lea ecx, [esp + 0x64]
call fcn.004094f0
cmp dword [eax + 0x18], esi
jb 0x5020f1
mov eax, dword [eax + 4]
jmp 0x5020f4
add eax, 4
push 0
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
test eax, eax
sete bl
cmp dword [esp + 0x40], esi
jb 0x502115
mov eax, dword [esp + 0x2c]
push eax
call fcn.00595eb8
add esp, 4
test bl, bl
je 0x502125
call sub.WS2_32.dll_WSAGetLastError
cmp eax, 0xb7
jne 0x50213c
mov edi, dword [esp + 0x1c]
mov esi, dword [esp + 0x18]
mov ebx, dword [esp + 0x24]
add ebp, 1
add ebx, 0x1c
jmp 0x50202d
lea ecx, [esp + 0xac]
mov byte [esp + 0x108], 3
call fcn.00409e00
lea ecx, [esp + 0xac]
push ecx
mov dword [esp + 0xb0], vtable.std::ios_base.0
call fcn.005cdcde
add esp, 4
lea ecx, [esp + 0x14]
call fcn.00438d60
cmp dword [esp + 0xf8], esi
jb 0x50218d
mov edx, dword [esp + 0xe4]
push edx
call fcn.00595eb8
add esp, 4
xor eax, eax
jmp 0x50221a
lea ecx, [esp + 0xac]
mov byte [esp + 0x108], 3
call fcn.00409e00
lea eax, [esp + 0xac]
push eax
mov dword [esp + 0xb0], vtable.std::ios_base.0
call fcn.005cdcde
mov eax, dword [esp + 0x1c]
xor esi, esi
add esp, 4
cmp eax, esi
je 0x5021ef
mov ecx, dword [esp + 0x24]
push ecx
mov ecx, dword [esp + 0x20]
lea edx, [esp + 0x18]
push edx
push ecx
push eax
call fcn.00438f10
mov edx, dword [esp + 0x28]
push edx
call fcn.00595eb8
add esp, 0x14
cmp dword [esp + 0xf8], 0x10
mov dword [esp + 0x18], esi
mov dword [esp + 0x1c], esi
mov dword [esp + 0x20], esi
jb 0x502215
mov eax, dword [esp + 0xe4]
push eax
call fcn.00595eb8
add esp, 4
mov eax, 1
mov ecx, dword [esp + 0x100]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0xe8]
xor ecx, esp
call fcn.005b1988
add esp, 0xf8
ret