Function at 0x402110
Capabilities:
Create directory
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x48b041
mov eax, dword fs:[0]
push eax
sub esp, 0x470
mov eax, dword [0x4ad658]
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 eax, dword [ebp + 8]
xor ebx, ebx
push 0x206
mov esi, ecx
lea edx, [ebp - 0x21a]
xor ecx, ecx
push ebx
mov dword [ebp - 0x474], ebx
push edx
mov dword [ebp - 0x478], eax
mov word [ebp - 0x21c], cx
call fcn.00469070
add esp, 0xc
lea eax, [ebp - 0x21c]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
mov edx, dword [section..data]
mov eax, dword [edx + 0xc]
mov ecx, section..data
call eax
add eax, 0x10
mov dword [ebp - 0x470], eax
lea ecx, [ebp - 0x21c]
push ecx
push 0x498164
lea edi, [ebp - 0x470]
mov dword [ebp - 4], ebx
call fcn.0040e610
mov edi, dword [ebp - 0x470]
add esp, 8
lea edx, [ebp - 0x46c]
push edx
push edi
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
cmp eax, 0xffffffff
je 0x4021e5
test byte [ebp - 0x46c], 0x10
je 0x4021e5
push eax
call dword [sym.imp.KERNEL32.dll_FindClose]
jmp 0x4022c3
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x4022c3
mov eax, dword [section..data]
mov edx, dword [eax + 0xc]
mov ecx, section..data
call edx
add eax, 0x10
mov dword [ebp - 0x474], eax
lea eax, [ebp - 0x21c]
push eax
push str._sBaidu
lea edi, [ebp - 0x474]
mov byte [ebp - 4], 1
call fcn.0040e610
mov edi, dword [ebp - 0x474]
add esp, 8
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
push ebx
test eax, eax
jne 0x40226f
xor ecx, ecx
mov dword [esi + 0x14], 7
mov dword [esi + 0x10], ebx
mov eax, 0x49adcc
mov word [esi], cx
call fcn.00412480
lea eax, [edi - 0x10]
mov byte [ebp - 4], bl
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jmp 0x40234d
mov ecx, dword [ebp - 0x470]
push ecx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x4022a4
mov eax, 0x49adcc
mov ecx, esi
call fcn.00412570
lea eax, [edi - 0x10]
mov byte [ebp - 4], bl
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jmp 0x40234d
lea eax, [edi - 0x10]
mov byte [ebp - 4], bl
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4022c3
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov edx, dword [section..data]
mov eax, dword [edx + 0xc]
mov ecx, section..data
call eax
add eax, 0x10
mov dword [ebp - 0x474], eax
mov eax, dword [ebp - 0x478]
mov byte [ebp - 4], 2
cmp dword [eax + 0x14], 8
jb 0x4022ee
mov eax, dword [eax]
mov ecx, dword [ebp - 0x470]
push eax
push ecx
push str._s_s
lea edi, [ebp - 0x474]
call fcn.0040e610
mov edi, dword [ebp - 0x474]
add esp, 0xc
xor edx, edx
mov dword [esi + 0x14], 7
mov dword [esi + 0x10], ebx
mov eax, edi
mov word [esi], dx
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
cmp cx, bx
jne 0x402323
sub eax, edx
sar eax, 1
push eax
mov eax, edi
call fcn.00412480
lea eax, [edi - 0x10]
mov byte [ebp - 4], bl
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x402359
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x470]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x402382
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, esi
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.00464d49
mov esp, ebp
pop ebp
ret