Function at 0x402260
Capabilities:
Check if file exists
Read file on windows

Disassembly:
push 0xffffffffffffffff
push 0x4c5598
mov eax, dword fs:[0]
push eax
sub esp, 0x10c
mov eax, dword [0x4e5d60]
xor eax, esp
mov dword [esp + 0x108], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x4e5d60]
xor eax, esp
push eax
lea eax, [esp + 0x120]
mov dword fs:[0], eax
mov eax, dword [esp + 0x130]
mov dword [esp + 0x20], eax
xor ebx, ebx
mov dword [esp + 0x128], ebx
call fcn.004990cf
xor ecx, ecx
cmp eax, ebx
setne cl
cmp ecx, ebx
jne 0x4022c9
push 0x80004005
call fcn.0040f160
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [esp + 0x1c], eax
mov byte [esp + 0x128], 1
mov edi, dword [esp + 0x134]
cmp dword [edi - 0xc], ebx
jne 0x40230b
add eax, 0xfffffff0
or edi, 0xffffffff
mov byte [esp + 0x128], bl
lea ecx, [eax + 0xc]
mov edx, edi
lock xadd dword [ecx], edx
dec edx
test edx, edx
jmp 0x4026ed
lea ecx, [esp + 0x24]
push 0x4cbc10
push ecx
call fcn.00401bb0
add esp, 8
push eax
lea ecx, [esp + 0x20]
mov byte [esp + 0x12c], 2
call fcn.0040ebc0
mov byte [esp + 0x128], 1
mov eax, dword [esp + 0x24]
add eax, 0xfffffff0
or edi, 0xffffffff
lea edx, [eax + 0xc]
mov ecx, edi
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x402359
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov esi, dword [esp + 0x1c]
push esi
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x402383
lea eax, [esi - 0x10]
mov byte [esp + 0x128], bl
lea ecx, [eax + 0xc]
mov edx, edi
lock xadd dword [ecx], edx
dec edx
test edx, edx
jmp 0x4026ed
push 0x4cbc38
lea ecx, [esp + 0x1c]
push esi
push ecx
mov dword [esp + 0x24], ebx
call fcn.004a6ee5
add esp, 0xc
test eax, eax
jne 0x4026d7
mov eax, dword [esp + 0x18]
cmp eax, ebx
je 0x4026d7
push 2
push ebx
push eax
call fcn.004a6fc2
mov edx, dword [esp + 0x24]
add esp, 0xc
push edx
call fcn.004a71e4
add esp, 4
push ebx
mov esi, eax
mov eax, dword [esp + 0x1c]
push ebx
push eax
call fcn.004a6fc2
add esp, 0xc
mov dword [esp + 0xb0], 0xf
mov dword [esp + 0xac], ebx
mov byte [esp + 0x9c], bl
lea eax, [esi + 2]
mov byte [esp + 0x128], 3
cmp eax, ebx
ja 0x402410
push edi
push eax
lea ecx, [esp + 0xa0]
call fcn.0040e6e0
jmp 0x40241d
push ebx
lea edi, [esp + 0x9c]
call fcn.0040bad0
cmp dword [esp + 0xac], ebx
ja 0x40242b
call fcn.004c0b0c
cmp dword [esp + 0xb0], 0x10
mov eax, dword [esp + 0x9c]
jae 0x402443
lea eax, [esp + 0x9c]
mov ecx, dword [esp + 0x18]
push ecx
push esi
push 1
push eax
call fcn.004a74f2
mov edx, dword [esp + 0x28]
push edx
mov esi, eax
call fcn.004a7586
add esp, 0x14
mov dword [esp + 0x18], ebx
cmp esi, ebx
je 0x402528
xor edi, edi
lea eax, [esp + 0x98]
call fcn.0040b120
cmp byte [eax], 0xef
jne 0x4024eb
mov edi, 1
lea eax, [esp + 0x98]
call fcn.0040b120
cmp byte [eax], 0xbb
jne 0x4024eb
mov edi, 2
lea eax, [esp + 0x98]
call fcn.0040b120
cmp byte [eax], 0xbf
jne 0x4024eb
lea eax, [esp + 0x24]
push eax
lea ebx, [esp + 0x54]
lea edi, [esp + 0x9c]
call fcn.0040b0d0
call fcn.0040b950
mov esi, dword [eax]
mov ebp, dword [eax + 4]
lea ebx, [esp + 0x48]
call fcn.0040b0d0
mov ecx, dword [eax + 4]
mov edx, dword [eax]
push ebp
push esi
push ecx
push edx
lea eax, [esp + 0x68]
push eax
mov ecx, edi
push ecx
call fcn.0040afb0
xor ebx, ebx
lea ecx, [esp + 0x98]
lea esi, [esp + 0xb4]
call fcn.0048b7f0
mov edi, 0x4a
mov byte [esp + 0x128], 4
cmp dword [esp + 0xc4], edi
je 0x40254e
lea ecx, [esp + 0xb4]
mov byte [esp + 0x128], 3
call fcn.004013e0
lea ecx, [esp + 0x98]
call fcn.0040eb40
lea ecx, [esp + 0x1c]
call fcn.0040ed20
lea ecx, [esp + 0x134]
call fcn.0040ed20
jmp 0x402720
push str.session
lea ecx, [esp + 0x30]
call fcn.0040e6a0
lea eax, [esp + 0x2c]
lea ecx, [esp + 0xb4]
mov byte [esp + 0x128], 5
call fcn.00401480
lea ecx, [esp + 0x2c]
mov esi, eax
mov byte [esp + 0x128], 4
call fcn.0040eb40
cmp dword [esi + 0x10], edi
jne 0x402514
push str.startup_urls
lea ecx, [esp + 0x64]
call fcn.0040e6a0
lea eax, [esp + 0x60]
mov ecx, esi
mov byte [esp + 0x128], 6
call fcn.00401480
lea ecx, [esp + 0x60]
mov esi, eax
call fcn.0040eb40
cmp dword [esi + 0x10], 0x4b
jne 0x402514
mov ecx, dword [esi + 0x60]
sub ecx, dword [esi + 0x5c]
lea ebx, [esi + 0x50]
mov eax, 0x4ec4ec4f
imul ecx
sar edx, 5
mov eax, edx
shr eax, 0x1f
add eax, edx
xor ebp, ebp
test eax, eax
jle 0x40269b
lea ecx, [esp + 0x24]
call fcn.0040ec60
push ebp
mov eax, ebx
mov byte [esp + 0x12c], 7
call fcn.0040b700
cmp dword [eax + 0x10], 0x4c
jne 0x402672
lea edx, [esp + 0x7c]
mov ecx, eax
call fcn.00401640
mov byte [esp + 0x128], 8
cmp dword [eax + 0x18], 8
jb 0x402623
mov eax, dword [eax + 4]
jmp 0x402626
add eax, 4
lea ecx, [esp + 0x2c]
call fcn.0040b150
mov ecx, dword [esp + 0x20]
mov byte [esp + 0x128], 9
mov esi, dword [ecx + 0x14]
mov eax, dword [esi + 4]
lea edx, [esp + 0x2c]
push edx
push eax
push esi
call fcn.0040d6a0
mov ecx, dword [esp + 0x20]
mov edi, eax
call fcn.0040d740
mov dword [esi + 4], edi
mov eax, dword [edi + 4]
lea esi, [esp + 0x2c]
mov dword [eax], edi
call fcn.0040b1c0
lea esi, [esp + 0x7c]
call fcn.0040b1c0
lea ecx, [esp + 0x24]
call fcn.0040ed20
mov ecx, dword [ebx + 0x10]
sub ecx, dword [ebx + 0xc]
mov eax, 0x4ec4ec4f
imul ecx
sar edx, 5
mov ecx, edx
shr ecx, 0x1f
inc ebp
add ecx, edx
cmp ebp, ecx
jl 0x4025e6
lea ecx, [esp + 0xb4]
mov byte [esp + 0x128], 3
call fcn.004013e0
lea ecx, [esp + 0x98]
call fcn.0040eb40
lea ecx, [esp + 0x1c]
call fcn.0040ed20
lea ecx, [esp + 0x134]
call fcn.0040ed20
mov eax, 1
jmp 0x402722
lea eax, [esi - 0x10]
mov byte [esp + 0x128], bl
lea edx, [eax + 0xc]
mov ecx, edi
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x4026f9
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [esp + 0x128], edi
mov eax, dword [esp + 0x134]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
lock xadd dword [ecx], edi
dec edi
test edi, edi
jg 0x402720
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
xor eax, eax
mov ecx, dword [esp + 0x120]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x108]
xor ecx, esp
call fcn.004a6859
add esp, 0x118
ret 8