Function at 0x411400
Capabilities:
Read file on windows
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x529b4b
mov eax, dword fs:[0]
push eax
sub esp, 0x98
mov eax, dword [0x58c8c0]
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 esi, ecx
push 0xffffffffffffffff
lea ecx, [esi + 0x20]
push 0
mov dword [ebp - 0xa4], ecx
call fcn.00402920
mov eax, dword [esi + 4]
mov ecx, 0x544714
test al, 0x40
je 0x411455
mov ecx, 0x54470c
jmp 0x41145e
test al, 0x20
je 0x41145e
mov ecx, 0x544704
mov eax, dword [ebp + 8]
push ecx
push eax
mov dword [esi], 0
call fcn.0050cce2
add esp, 8
mov dword [esi], eax
test eax, eax
jne 0x411483
mov ecx, esi
call fcn.0040e5b0
jmp 0x4117f1
mov ecx, dword [esi + 4]
xor edi, edi
mov byte [ebp - 0x91], 1
mov dword [esi + 0x18], 1
test cl, 0x10
je 0x4116db
push 2
push edi
push eax
call fcn.00509c20
mov ecx, dword [esi]
push ecx
call fcn.00509b31
mov edx, dword [esi]
push edi
push edi
push edx
mov dword [esi + 0x10], eax
call fcn.00509c20
mov eax, dword [esi + 0x10]
mov ebx, 0x400
add esp, 0x1c
cmp eax, ebx
jge 0x4114d6
mov ebx, eax
test ebx, ebx
je 0x4117a3
push ebx
call fcn.0041a1b4
mov ecx, dword [esi]
push ecx
push 1
push ebx
push eax
mov dword [ebp - 0x9c], eax
call fcn.00509980
add esp, 0x14
cmp eax, 1
sete al
mov byte [ebp - 0x91], al
test al, al
je 0x4116c7
and dword [esi + 4], 0xfffffffa
mov dword [ebp - 0xa0], edi
cmp dword [0x5883d8], edi
je 0x411593
xor eax, eax
lea esp, [esp]
mov ecx, dword [eax + 0x5883dc]
test ecx, ecx
jle 0x41154d
cmp edi, ebx
jge 0x41154d
mov ecx, dword [ebp - 0x9c]
mov cl, byte [ecx + edi]
mov edx, dword [eax + 0x5883d8]
cmp cl, byte [edi + edx]
mov ecx, dword [eax + 0x5883dc]
jne 0x41154d
inc edi
cmp edi, ecx
jl 0x41152a
mov eax, dword [ebp - 0xa0]
cmp edi, ecx
je 0x41156d
inc eax
mov dword [ebp - 0xa0], eax
xor edi, edi
shl eax, 4
cmp dword [eax + 0x5883d8], edi
jne 0x411520
jmp 0x411593
shl eax, 4
mov edx, dword [eax + 0x5883e4]
or edx, dword [esi + 4]
mov dword [esi + 4], edx
cmp edi, 2
jne 0x411584
mov dword [esi + 0x18], edi
mov eax, dword [eax + 0x5883e0]
push eax
lea ecx, [esi + 0x3c]
call fcn.00403630
cmp ebx, edi
jle 0x4115a5
mov ecx, dword [esi]
push 0
push edi
push ecx
call fcn.00509c20
add esp, 0xc
xor eax, eax
cmp edi, eax
jne 0x4116a9
xor edx, edx
mov dword [ebp - 0x18], 7
mov dword [ebp - 0x1c], eax
mov word [ebp - 0x2c], dx
mov dword [ebp - 4], eax
mov eax, dword [ebp - 0x9c]
push ebx
push eax
push ecx
mov eax, esp
lea ecx, [ebp - 0x90]
mov dword [ebp - 0x98], esp
mov dword [eax], 0x5411ec
call fcn.0040d6d0
xor ecx, ecx
lea eax, [ebx + 1]
mov edx, 2
mul edx
seto cl
mov byte [ebp - 4], 1
neg ecx
or ecx, eax
push ecx
call fcn.0041a1b4
add esp, 4
mov dword [ebp - 0x98], eax
cmp dword [ebp - 0x18], ebx
jge 0x411618
push ebx
lea ecx, [ebp - 0x2c]
call fcn.0040cd80
push ecx
mov eax, esp
mov dword [ebp - 0x50], ebx
mov dword [eax], str.UTF_16
mov eax, dword [ebp - 0x98]
mov dword [ebp - 0xa0], esp
push eax
lea ecx, [ebp - 0x90]
call fcn.0040d770
mov ebx, dword [ebp - 0x98]
mov ecx, dword [ebp - 0x1c]
push eax
push ebx
push ecx
push 0
lea ecx, [ebp - 0x2c]
call fcn.0040d330
push ebx
call fcn.0041a1a9
cmp dword [ebp - 0x18], 8
mov ecx, dword [ebp - 0x2c]
mov dword [ebp - 0x98], esp
mov eax, esp
jae 0x41166c
lea ecx, [ebp - 0x2c]
lea edx, [ebp - 0x48]
push edx
mov dword [eax], ecx
call fcn.0040edf0
add esp, 8
push eax
lea ecx, [esi + 0x3c]
mov byte [ebp - 4], 2
call fcn.00403690
lea ecx, [ebp - 0x48]
call fcn.00402e30
lea ecx, [ebp - 0x90]
call fcn.0040cb80
lea ecx, [ebp - 0x2c]
mov dword [ebp - 4], 0xffffffff
call fcn.00402e30
cmp dword [esi + 0x4c], 0
jne 0x4116c7
mov eax, dword [ebp - 0x9c]
cmp byte [eax], 0x3c
jne 0x4116c7
push 0x5411ec
lea ecx, [esi + 0x3c]
call fcn.00403630
mov ecx, dword [ebp - 0x9c]
push ecx
call fcn.0041a1a9
add esp, 4
jmp 0x411796
test cl, 0x20
je 0x4117a3
test cl, 0x40
je 0x411701
push 2
push 0
push eax
call fcn.00509c20
mov edx, dword [esi]
push edx
call fcn.00509b31
add esp, 0x10
mov dword [esi + 0x10], eax
xor ecx, ecx
cmp dword [0x5883d8], ecx
je 0x4117a3
mov edx, dword [esi + 4]
xor eax, eax
test dword [eax + 0x5883e4], edx
jne 0x41172c
inc ecx
mov eax, ecx
shl eax, 4
cmp dword [eax + 0x5883d8], edi
jne 0x411714
jmp 0x4117a3
shl ecx, 4
mov ebx, ecx
mov edi, dword [ebx + 0x5883dc]
cmp edi, 2
jne 0x41173f
mov dword [esi + 0x18], edi
mov edx, dword [ebx + 0x5883e0]
mov eax, edx
lea ecx, [eax + 2]
mov dword [ebp - 0x98], ecx
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x411750
sub eax, dword [ebp - 0x98]
lea ecx, [esi + 0x3c]
sar eax, 1
push eax
push edx
call fcn.004031e0
cmp dword [esi + 0x10], 0
je 0x411777
xor edi, edi
jmp 0x4117a3
mov edx, dword [esi]
mov eax, dword [ebx + 0x5883d8]
push edx
push 1
push edi
push eax
call fcn.0050952c
add esp, 0x10
cmp eax, 1
sete byte [ebp - 0x91]
cmp byte [ebp - 0x91], 0
je 0x411477
test byte [esi + 4], 0x40
je 0x4117b1
mov ecx, dword [esi + 0x10]
mov dword [esi + 0x14], ecx
jmp 0x4117b4
mov dword [esi + 0x14], edi
test edi, edi
je 0x4117eb
mov edx, dword [ebp - 0xa4]
push 0xffffffffffffffff
push 0xffffffffffffffff
push 0
push ecx
mov eax, esp
mov dword [ebp - 0x98], esp
push ecx
mov dword [eax], 0
mov eax, esp
mov dword [ebp - 0x98], esp
push edx
mov dword [eax], 0x5446fc
call fcn.00411200
add esp, 0x18
mov al, byte [ebp - 0x91]
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.005089e3
mov esp, ebp
pop ebp
ret 4