Function at 0x522ee0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x59c13d
mov eax, dword fs:[0]
push eax
sub esp, 0x38
mov eax, dword [0x61094c]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov dword [ebp - 0x40], edi
mov eax, dword [edi + 0x1c]
mov ecx, dword [eax]
test ecx, ecx
je 0x522f3c
mov edx, dword [edi + 0x2c]
mov esi, dword [edx]
lea eax, [esi + ecx]
cmp ecx, eax
jae 0x522f3c
lea eax, [esi - 1]
mov dword [edx], eax
mov ecx, dword [edi + 0x1c]
mov edx, dword [ecx]
lea eax, [edx + 1]
mov dword [ecx], eax
movzx eax, byte [edx]
jmp 0x52320e
cmp dword [edi + 0x4c], 0
jne 0x522f4a
or eax, 0xffffffff
jmp 0x52320e
mov esi, dword [edi + 0xc]
lea eax, [edi + 0x3c]
cmp dword [esi], eax
jne 0x522f68
mov edx, dword [edi + 0x54]
mov ecx, dword [edi + 0x50]
sub edx, ecx
mov dword [esi], ecx
mov eax, dword [edi + 0x1c]
mov dword [eax], ecx
mov eax, dword [edi + 0x2c]
mov dword [eax], edx
cmp dword [edi + 0x38], 0
mov eax, dword [edi + 0x4c]
jne 0x522f90
push eax
push 1
lea eax, [ebp - 0x12]
push 1
push eax
call fcn.0056a572
add esp, 0x10
cmp eax, 1
jne 0x522f42
movzx eax, byte [ebp - 0x12]
jmp 0x52320e
mov dword [ebp - 0x2c], 0
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x18], 0xf
mov byte [ebp - 0x2c], 0
push eax
mov dword [ebp - 4], 0
call fcn.005695cd
mov edx, eax
add esp, 4
mov dword [ebp - 0x44], edx
cmp edx, 0xffffffff
je 0x523183
mov ecx, dword [ebp - 0x18]
mov edi, dword [ebp - 0x1c]
mov dword [ebp - 0x3c], ecx
cmp edi, ecx
jae 0x522ff7
lea eax, [edi + 1]
cmp ecx, 0x10
mov dword [ebp - 0x1c], eax
lea eax, [ebp - 0x2c]
cmovae eax, dword [ebp - 0x2c]
mov byte [eax + edi], dl
mov byte [eax + edi + 1], 0
mov ecx, dword [ebp - 0x2c]
mov dword [ebp - 0x38], ecx
jmp 0x5230ca
mov eax, SysReAllocString
sub eax, edi
cmp eax, 1
jb 0x52322f
lea esi, [edi + 1]
or esi, 0xf
cmp esi, 0x7fffffff
jbe 0x52301c
mov esi, SysReAllocString
jmp 0x52303a
mov edx, ecx
mov eax, SysReAllocString
shr edx, 1
sub eax, edx
cmp ecx, eax
jbe 0x523032
mov esi, SysReAllocString
jmp 0x52303a
lea eax, [edx + ecx]
cmp esi, eax
cmovb esi, eax
xor ecx, ecx
mov eax, esi
add eax, 1
setb cl
neg ecx
or ecx, eax
push ecx
lea ecx, [ebp - 0x2c]
call fcn.00426ad0
cmp dword [ebp - 0x3c], 0x10
mov ebx, eax
lea eax, [edi + 1]
mov dword [ebp - 0x38], ebx
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x18], esi
push edi
jb 0x5230ac
mov esi, dword [ebp - 0x2c]
push esi
push ebx
call fcn.00555c60
mov ecx, dword [ebp - 0x3c]
add esp, 0xc
mov eax, dword [ebp - 0x44]
inc ecx
mov byte [edi + ebx], al
mov byte [edi + ebx + 1], 0
cmp ecx, 0x1000
jb 0x5230a0
mov edx, dword [esi - 4]
add ecx, 0x23
sub esi, edx
lea eax, [esi - 4]
cmp eax, 0x1f
ja 0x52322a
mov esi, edx
push ecx
push esi
call fcn.005541c2
add esp, 8
jmp 0x5230c7
lea eax, [ebp - 0x2c]
push eax
push ebx
call fcn.00555c60
mov eax, dword [ebp - 0x44]
add esp, 0xc
mov byte [edi + ebx], al
mov byte [edi + ebx + 1], 0
mov dword [ebp - 0x38], ebx
mov dword [ebp - 0x2c], ebx
mov ebx, dword [ebp - 0x40]
lea ecx, [ebp - 0x2c]
cmp dword [ebp - 0x18], 0x10
lea esi, [ebp - 0x2c]
mov edi, dword [ebp - 0x1c]
cmovae ecx, dword [ebp - 0x38]
mov ebx, dword [ebx + 0x38]
add edi, ecx
cmp dword [ebp - 0x18], 0x10
mov dword [ebp - 0x3c], ebx
cmovae esi, dword [ebp - 0x38]
mov eax, dword [ebx]
mov ebx, dword [eax + 0x18]
lea eax, [ebp - 0x34]
push eax
lea eax, [ebp - 0x10]
mov ecx, ebx
push eax
lea eax, [ebp - 0x11]
push eax
lea eax, [ebp - 0x30]
push eax
push edi
mov edi, dword [ebp - 0x40]
push esi
lea eax, [edi + 0x40]
push eax
call dword [0x5a0478]
mov ecx, dword [ebp - 0x3c]
call ebx
sub eax, 0
je 0x523127
sub eax, 1
jne 0x5231b6
lea eax, [ebp - 0x11]
cmp dword [ebp - 0x34], eax
lea eax, [ebp - 0x2c]
jne 0x5231cb
cmp dword [ebp - 0x18], 0x10
lea edx, [ebp - 0x2c]
mov edi, dword [ebp - 0x30]
cmovae eax, dword [ebp - 0x2c]
sub edi, eax
mov eax, dword [ebp - 0x1c]
cmp eax, edi
cmovb edi, eax
cmp dword [ebp - 0x18], 0x10
cmovae edx, dword [ebp - 0x2c]
sub eax, edi
mov dword [ebp - 0x1c], eax
inc eax
push eax
lea eax, [edx + edi]
push eax
push edx
call fcn.00555c60
mov eax, dword [ebp - 0x40]
push dword [eax + 0x4c]
call fcn.005695cd
mov edx, eax
add esp, 0x10
mov dword [ebp - 0x44], edx
cmp edx, 0xffffffff
jne 0x522fc7
or esi, 0xffffffff
mov edx, dword [ebp - 0x18]
cmp edx, 0x10
jb 0x52320c
mov ecx, dword [ebp - 0x2c]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x523202
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x52322a
jmp 0x523202
sub eax, 2
jne 0x523183
cmp dword [ebp - 0x18], 0x10
lea eax, [ebp - 0x2c]
cmovae eax, dword [ebp - 0x2c]
movsx esi, byte [eax]
jmp 0x523186
cmp dword [ebp - 0x18], 0x10
mov esi, dword [ebp - 0x1c]
cmovae eax, dword [ebp - 0x2c]
mov ecx, dword [ebp - 0x30]
sub esi, ecx
add esi, eax
test esi, esi
jle 0x5231fc
push dword [edi + 0x4c]
movsx eax, byte [esi + ecx - 1]
dec esi
push eax
call fcn.0056996f
add esp, 8
test esi, esi
jle 0x5231fc
mov ecx, dword [ebp - 0x30]
jmp 0x5231e1
movzx esi, byte [ebp - 0x11]
jmp 0x523186
push edx
push ecx
call fcn.005541c2
add esp, 8
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 - 0x10]
xor ecx, ebp
call fcn.00553d2a
mov esp, ebp
pop ebp
ret
call fcn.0055eb97
call fcn.004213b0
int3