Function at 0x402600
Capabilities:
Read file on windows
Resolve function by parsing pe exports
Write file on windows

Disassembly:
push 0xffffffffffffffff
push 0x439316
mov eax, dword fs:[0]
push eax
sub esp, 0x5b4
mov eax, dword [0x449cd0]
xor eax, esp
mov dword [esp + 0x5b0], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x449cd0]
xor eax, esp
push eax
lea eax, [esp + 0x5c8]
mov dword fs:[0], eax
mov esi, dword [esp + 0x5d8]
mov edi, dword [esp + 0x5e0]
mov ebx, dword [esp + 0x5dc]
mov dword [esp + 0x20], esi
mov dword [esp + 0x24], edi
call fcn.00410194
xor ecx, ecx
test eax, eax
setne cl
test ecx, ecx
jne 0x402672
push 0x80004005
call fcn.00401330
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [esp + 0x18], eax
mov dword [esp + 0x5d0], 0
call fcn.00410194
xor ecx, ecx
test eax, eax
setne cl
test ecx, ecx
jne 0x4026a7
push 0x80004005
call fcn.00401330
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [esp + 0x14], eax
push 0x104
lea ecx, [esp + 0xc4]
push 0
push ecx
mov byte [esp + 0x5dc], 1
call fcn.0041ec20
push 0x8000
call fcn.0040f12f
mov ebp, eax
add esp, 0x10
test ebp, ebp
jne 0x402750
push eax
push str.EncryptFileToLdCab_failed_with_chFileContent__NULL
mov ecx, 0x44b3c5
call fcn.0040aa20
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
or ecx, 0xffffffff
lea edx, [eax + 0xc]
mov byte [esp + 0x5d0], 0
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40271e
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
mov dword [esp + 0x5d0], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x402749
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
xor al, al
jmp 0x402aae
push 0x8000
push 0
push ebp
call fcn.0041ec20
push 0x98
lea ecx, [esp + 0x38]
push 0
push ecx
call fcn.0041ec20
push 0x400
lea edx, [esp + 0x1e0]
push 0
push edx
call fcn.0041ec20
push 2
push 0
push 0
push esi
call fcn.0041ed36
push edi
push ebx
call fcn.00401eb0
push 0
push 0
push 0x43b71c
push edx
push eax
lea eax, [esp + 0x78]
push eax
call fcn.004011d0
add esp, 0x54
mov ecx, 0x26
lea esi, [esp + 0x28]
lea edi, [esp + 0x1c4]
rep movsd dword es:[edi], dword [esi]
mov esi, dword [esp + 0x20]
push esi
push 0x400
lea ecx, [esp + 0x1cc]
push 1
push ecx
call fcn.0041e3d0
mov edx, dword [ebx + 0xc]
push 2
push 0
push 0
push esi
mov dword [esp + 0x3c], edx
call fcn.0041ed36
mov ebx, dword [ebx + 4]
add esp, 0x20
test ebx, ebx
je 0x40296c
mov eax, ebx
test ebx, ebx
je 0x402998
mov ebx, dword [ebx]
add eax, 8
push eax
lea ecx, [esp + 0x1c]
call fcn.00401c60
mov eax, dword [esp + 0x24]
lea edx, [esp + 0xc0]
sub edx, eax
nop
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x402820
lea edi, [esp + 0xc0]
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x402832
mov ax, word [0x43b574]
mov word [edi], ax
mov eax, dword [esp + 0x18]
mov ecx, eax
lea esp, [esp]
mov dl, byte [eax]
inc eax
test dl, dl
jne 0x402850
lea edi, [esp + 0xc0]
sub eax, ecx
mov esi, ecx
dec edi
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x402863
mov ecx, eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0xc0]
push ecx
call fcn.00407e00
add esp, 4
test eax, eax
je 0x402896
dec dword [esp + 0x1c]
jmp 0x402964
lea edx, [esp + 0xc0]
push 0x43b560
push edx
call fcn.0041e83b
mov edi, eax
add esp, 8
test edi, edi
je 0x40299d
push edi
call fcn.0041e452
add esp, 4
test eax, eax
jne 0x402913
push edi
push 0x8000
push 1
push ebp
call fcn.0041e75a
push 0xd
mov esi, eax
push str.Tipray_LdSafe
push esi
push ebp
call fcn.0040ee70
mov eax, dword [esp + 0x40]
push eax
push esi
push 1
push ebp
call fcn.0041e3d0
add esp, 0x30
cmp esi, eax
jne 0x402a19
push 0x8000
push 0
push ebp
call fcn.0041ec20
push edi
call fcn.0041e452
add esp, 0x10
test eax, eax
je 0x4028c2
push edi
call fcn.0041e1f2
dec dword [esp + 0x20]
lea ecx, [esp + 0xc4]
push ecx
push str.EncryptFileToLdCab_Handle_File_Success
lea edx, [esp + 0x20]
push str._s:_s
push edx
call fcn.00401ce0
mov eax, dword [esp + 0x28]
add esp, 0x14
push 0
push eax
mov ecx, 0x44b3c5
call fcn.0040aa20
push 0x104
lea ecx, [esp + 0xc4]
push 0
push ecx
call fcn.0041ec20
add esp, 0xc
test ebx, ebx
jne 0x4027f9
cmp dword [esp + 0x1c], 0
je 0x402a50
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
mov byte [esp + 0x5d0], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jmp 0x402712
call fcn.0040feea
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.EncryptFileToLdCab_failed_with_error_fopen_NULL__file_error_code:
lea edx, [esp + 0x1c]
push str._s__d
push edx
call fcn.00401ce0
mov eax, dword [esp + 0x24]
add esp, 0x10
push 0
push eax
mov ecx, 0x44b3c5
call fcn.0040aa20
lea ecx, [esp + 0xc0]
push ecx
push str.When_open_file:
lea edx, [esp + 0x1c]
push str._s__s
push edx
call fcn.00401ce0
mov esi, dword [esp + 0x24]
add esp, 0x10
push 0
push esi
mov ecx, 0x44b3c5
call fcn.0040aa20
lea eax, [esi - 0x10]
mov byte [esp + 0x5d0], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jmp 0x402712
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.EncryptFileToLdCab_failed_with_fwrite_error_iTempRead__iTempWrite_error_code:
lea ecx, [esp + 0x1c]
push str._s__d
push ecx
call fcn.00401ce0
mov esi, dword [esp + 0x24]
add esp, 0x10
push 0
push esi
mov ecx, 0x44b3c5
call fcn.0040aa20
lea eax, [esi - 0x10]
jmp 0x4026fd
push ebp
call fcn.0040f13a
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
add esp, 4
mov byte [esp + 0x5d0], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x402a81
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
mov dword [esp + 0x5d0], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x402aac
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov al, 1
mov ecx, dword [esp + 0x5c8]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x5b0]
xor ecx, esp
call fcn.0041d4f4
add esp, 0x5c0
ret