Function at 0x10041e90
Capabilities:
Get file size
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x100c0f60
mov eax, dword fs:[0]
push eax
sub esp, 0x64
mov eax, dword [0x1010b070]
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
mov dword [ebp - 0x64], esi
mov ecx, dword [esi + 0x20]
call fcn.10048880
test eax, eax
je 0x1004214c
push 0xe
push str.dr_padcket.dat
lea ecx, [ebp - 0x38]
mov dword [ebp - 0x24], 0xf
mov dword [ebp - 0x28], 0
mov byte [ebp - 0x38], 0
call fcn.10005859
lea eax, [ebp - 0x38]
mov dword [ebp - 4], 0
push eax
lea eax, [ebp - 0x50]
push eax
call fcn.10042170
mov byte [ebp - 4], 2
mov eax, dword [ebp - 0x24]
cmp eax, 0x10
jb 0x10041f53
mov ecx, dword [ebp - 0x38]
inc eax
cmp eax, 0x1000
jb 0x10041f4a
test cl, 0x1f
je 0x10041f26
call fcn.100906d1
mov eax, dword [ecx - 4]
cmp eax, ecx
jb 0x10041f32
call fcn.100906d1
sub ecx, eax
cmp ecx, 4
jae 0x10041f3e
call fcn.100906d1
cmp ecx, 0x23
jbe 0x10041f48
call fcn.100906d1
mov ecx, eax
push ecx
call fcn.1008a772
add esp, 4
cmp dword [ebp - 0x3c], 0x10
lea eax, [ebp - 0x50]
push 0
cmovae eax, dword [ebp - 0x50]
push 0x80
push 4
push 0
push 0
push 0xc0000000
push eax
mov dword [ebp - 0x24], 0xf
mov dword [ebp - 0x28], 0
mov byte [ebp - 0x38], 0
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
cmp edi, 0xffffffff
je 0x10042102
push 0
push edi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ebx, eax
cmp ebx, 0x100000
jbe 0x10041fb3
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x10042102
push 2
push 0
push 0
push edi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push ecx
lea ecx, [ebp - 0x70]
call fcn.10043c00
call fcn.1003fbb0
mov ecx, dword [esi + 0x20]
mov dword [ebp - 0x60], eax
mov dword [ebp - 0x5c], edx
call fcn.10048810
mov esi, eax
test esi, esi
je 0x100420f3
mov ecx, esi
call fcn.100407a0
test eax, eax
je 0x100420ca
call fcn.10040780
add eax, 0x15180
adc edx, 0
cmp dword [ebp - 0x5c], edx
jg 0x100420ca
jl 0x10042016
cmp dword [ebp - 0x60], eax
jae 0x100420ca
mov ecx, esi
call fcn.1003fce0
mov dword [ebp - 0x54], eax
call fcn.10040780
mov ecx, dword [ebp - 0x6c]
sub ecx, dword [ebp - 0x70]
mov dword [ebp - 0x20], eax
dec ecx
mov eax, dword [ebp - 0x54]
mov word [ebp - 0x14], cx
mov dword [ebp - 0x1c], edx
mov cx, word [eax + 0x14]
mov word [ebp - 0x18], cx
lea ecx, [ebp - 0x70]
mov ax, word [eax + 0x1c]
mov word [ebp - 0x16], ax
lea eax, [ebp - 0x14]
push eax
push 0
call fcn.10043be0
push eax
mov ecx, esi
call fcn.1003fc30
mov ecx, eax
call fcn.100406c0
test al, al
je 0x100420ca
push 0
lea eax, [ebp - 0x58]
push eax
push 0x10
lea eax, [ebp - 0x20]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov ecx, dword [ebp - 0x54]
add ecx, 4
cmp dword [ecx + 0x14], 0x10
jb 0x1004208b
mov ecx, dword [ecx]
push 0
lea eax, [ebp - 0x58]
push eax
movzx eax, word [ebp - 0x18]
push eax
push ecx
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push 0
lea eax, [ebp - 0x58]
push eax
movzx eax, word [ebp - 0x14]
lea ecx, [ebp - 0x70]
push eax
push 0
call fcn.10043be0
push eax
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
movzx ecx, word [ebp - 0x18]
movzx eax, word [ebp - 0x14]
add eax, ebx
lea ebx, [ecx + 0x10]
add ebx, eax
test esi, esi
je 0x100420d6
push ecx
mov ecx, esi
call fcn.10039720
cmp ebx, 0x100000
ja 0x100420f3
mov eax, dword [ebp - 0x64]
mov ecx, dword [eax + 0x20]
call fcn.10048810
mov esi, eax
test esi, esi
jne 0x10041fe6
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea ecx, [ebp - 0x70]
call fcn.10043bf0
mov eax, dword [ebp - 0x3c]
cmp eax, 0x10
jb 0x1004214c
mov ecx, dword [ebp - 0x50]
inc eax
cmp eax, 0x1000
jb 0x10042143
test cl, 0x1f
je 0x1004211f
call fcn.100906d1
mov eax, dword [ecx - 4]
cmp eax, ecx
jb 0x1004212b
call fcn.100906d1
sub ecx, eax
cmp ecx, 4
jae 0x10042137
call fcn.100906d1
cmp ecx, 0x23
jbe 0x10042141
call fcn.100906d1
mov ecx, eax
push ecx
call fcn.1008a772
add esp, 4
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.1008a777
mov esp, ebp
pop ebp
ret