Function at 0x692b20
Capabilities:
Get file size
Read file on windows
Write file on windows

Disassembly:
push 0xffffffffffffffff
push 0x887e8b
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x90
push ebx
push ebp
push esi
mov esi, dword [esp + 0xbc]
xor ebx, ebx
push edi
cmp word [esi + 0xa], bx
mov dword [esp + 0x44], ebx
jne 0x6932c5
mov ecx, 0xf
xor eax, eax
lea edi, [esp + 0x61]
mov byte [esp + 0x60], bl
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea eax, [esp + 0x50]
lea ecx, [esp + 0x38]
push eax
lea edx, [esp + 0x44]
push ecx
lea eax, [esp + 0x30]
push edx
push eax
mov eax, dword [esp + 0xcc]
xor edx, edx
lea ecx, [esp + 0x70]
push 0x40
mov dl, byte [eax + 0x17]
push ecx
mov ecx, dword [eax + 0x1c]
push edx
mov edx, dword [eax + 0x30]
push ecx
push edx
mov dword [esp + 0x64], ebx
mov dword [esp + 0x5c], ebx
mov dword [esp + 0x4c], ebx
mov dword [esp + 0x74], ebx
call fcn.00694890
mov edi, eax
add esp, 0x24
cmp edi, ebx
mov dword [esp + 0x3c], edi
je 0x6932db
push edi
call fcn.0067ea20
mov ebp, eax
add esp, 4
cmp ebp, ebx
mov dword [esp + 0x20], ebp
je 0x6932f1
cmp edi, 9
mov eax, 1
je 0x692bfa
cmp edi, 0xc
je 0x692bfa
cmp edi, 0xe
je 0x692bfa
cmp edi, 0xf
je 0x692bfa
cmp edi, 0x10
je 0x692bfa
cmp edi, 0x11
jne 0x692bfc
xor eax, eax
mov ecx, dword [esp + 0xb0]
mov word [esi + 8], ax
lea eax, [esp + 0x34]
mov dword [esp + 0x34], ebx
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edx, dword [esp + 0x34]
mov edi, eax
mov eax, dword [esp + 0xb4]
push edx
push edi
push eax
call fcn.006a3ff0
add esp, 0xc
test eax, eax
je 0x693307
mov edx, dword [ebp]
push 0x1000
mov ecx, ebp
call dword [edx + 8]
mov cx, word [esi + 8]
xor edx, edx
cmp cx, bx
jne 0x692c53
mov edx, eax
jmp 0x692c67
cmp cx, 1
jne 0x692c5e
lea edx, [eax + 4]
jmp 0x692c67
cmp cx, 2
jne 0x692c67
lea edx, [eax + 8]
mov eax, dword [esp + 0xd0]
mov ebp, dword [esp + 0xb8]
mov dword [esp + 0x24], edx
mov dword [eax], 1
mov eax, dword [esp + 0x40]
cmp eax, ebx
je 0x692c8f
mov eax, dword [ebp + 0x24]
or al, 0x10
mov dword [ebp + 0x24], eax
cmp dword [esp + 0x38], ebx
je 0x692c9d
mov eax, dword [ebp + 0x24]
or al, 0x20
mov dword [ebp + 0x24], eax
cmp dword [esp + 0xb0], 0xffffffff
jne 0x692cc6
mov dword [0x9ddbd8], 1
mov dword [0x9ddbdc], 0x21a0
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [0x9ddbe0], eax
mov eax, dword [esp + 0xbc]
mov edx, dword [esp + 0x34]
xor ecx, ecx
mov dword [eax + 8], ebx
mov dword [eax + 0xc], ebx
xor eax, eax
or ecx, edi
or edx, eax
mov dword [esi + 0x10], ecx
mov dword [esi + 0x14], edx
mov edx, dword [esi + 0x10]
mov edi, dword [esi + 0x14]
mov eax, edx
and eax, 0xfff
xor ecx, ecx
mov ebx, eax
or ebx, ecx
je 0x692d2a
test edi, edi
ja 0x692d06
cmp edx, 0x1000
jbe 0x692d0e
mov ebx, eax
mov dword [esp + 0x58], ecx
jmp 0x692d14
mov ebx, edx
mov dword [esp + 0x58], edi
mov eax, edx
mov ecx, edi
sub eax, ebx
mov ebx, dword [esp + 0x58]
sbb ecx, ebx
add eax, 0x1000
adc ecx, 0
jmp 0x692d2e
mov eax, edx
mov ecx, edi
mov ebx, dword [esp + 0xbc]
mov dword [esi + 0x18], eax
mov eax, dword [esp + 0x28]
mov dword [esi + 0x1c], ecx
mov ecx, dword [esp + 0x3c]
mov dword [esi + 0x20], edx
mov dword [esi + 0x24], edi
lea edx, [ebx + 0x38]
mov dword [ebx + 0x34], ecx
push edx
lea ecx, [esp + 0x64]
push eax
push ecx
call fcn.006a3320
mov edx, dword [esp + 0x5c]
mov ecx, dword [esp + 0xd8]
add esp, 0xc
mov dword [ebx + 0x4c], edx
call fcn.00636d30
xor ecx, ecx
cmp ecx, eax
sbb ecx, ecx
and ecx, eax
lea eax, [ecx + 0xd8]
cmp eax, 0x1000
mov dword [ebx + 0x24], eax
ja 0x692d8e
mov eax, 0x1000
mov edx, dword [esp + 0x24]
mov dword [ebx + 0x24], eax
xor eax, eax
xor ecx, ecx
mov ax, word [esi + 8]
mov dword [esi + 0x28], ecx
sub eax, ecx
mov dword [esi + 0x2c], edx
mov dword [esi + 0x30], ecx
mov dword [esi + 0x34], 0x1000
je 0x692dc3
dec eax
je 0x692dbe
dec eax
jne 0x692dc3
mov ecx, 8
jmp 0x692dc3
mov ecx, 4
mov eax, dword [esp + 0xb0]
mov edi, dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 0
push 0
push 0
push eax
mov word [esi + 6], cx
call edi
mov ecx, dword [esp + 0xb4]
push 0
push 0
push 0
push ecx
call edi
mov edx, dword [ebp + 0x24]
or edx, 1
mov dword [ebp + 0x24], edx
mov dword [0x9ddbd8], 0
call dword [sym.imp.KERNEL32.dll_GetLastError]
lea edx, [esp + 0x1c]
mov dword [0x9ddbe0], eax
mov eax, dword [esp + 0xb4]
push 1
push edx
push 0
push eax
mov dword [esp + 0x2c], 0
call edi
mov ecx, dword [esp + 0xb4]
push 0
push 0
push 0
push ecx
mov dword [esp + 0x6c], eax
call edi
mov ecx, dword [0x992ee4]
mov edx, ebp
xor eax, eax
push 0x40
mov dword [edx], ecx
mov ecx, dword [0x992ee8]
push ebp
mov dword [esp + 0x20], eax
mov dword [edx + 4], ecx
mov ecx, dword [0x992eec]
mov dword [edx + 8], ecx
mov ecx, dword [0x992ef0]
mov word [ebp + 0x30], 0x40
mov dword [ebp + 0x20], 0x40001
mov dword [edx + 0xc], ecx
mov word [ebp + 0x3e], 0x50
mov dword [ebp + 0x34], eax
call fcn.006a3300
push ebp
mov dword [ebp + 0x34], eax
call fcn.00697530
add esp, 0xc
test eax, eax
je 0x692eef
mov eax, dword [ebp + 0x20]
cmp eax, 0x40001
je 0x692ea4
cmp eax, 0x40002
jne 0x692eef
cmp word [ebp + 0x3e], 0x50
jne 0x692eef
mov eax, dword [ebp + 0x34]
mov dword [ebp + 0x34], 0
push eax
push 0x40
push ebp
mov dword [esp + 0x1c], eax
call fcn.006a32b0
mov edx, dword [esp + 0x1c]
add esp, 0xc
test eax, eax
mov dword [ebp + 0x34], edx
je 0x692eef
mov eax, dword [esp + 0xb4]
push 0x40
push ebp
push eax
call fcn.00691b60
add esp, 0xc
test eax, eax
je 0x692eef
mov dword [esp + 0x18], 1
mov edx, dword [esp + 0x5c]
mov eax, dword [esp + 0xb4]
lea ecx, [esp + 0x1c]
push 0
push ecx
push edx
push eax
call edi
mov eax, dword [esp + 0x18]
test eax, eax
jne 0x692f46
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, 0x10
mov dword [0x9ddbd8], edi
mov dword [0x9ddbdc], 0x29d8
call esi
mov dword [0x9ddbe0], eax
mov dword [0x9ddbd8], edi
mov dword [0x9ddbdc], 0x1d74
call esi
jmp 0x693337
mov ecx, dword [esi + 0x10]
xor eax, eax
mov dword [esp + 0x1c], eax
mov dword [esp + 0x10], eax
or ecx, dword [esi + 0x14]
jne 0x692f7f
mov edx, dword [ebx + 0x24]
mov eax, dword [esp + 0xb4]
push 0
push 0
push edx
push eax
call edi
mov dword [esp + 0x1c], 1
mov dword [esp + 0x10], 0
jmp 0x693216
push 0x1000
call fcn.008325b4
mov ecx, dword [esp + 0x28]
mov dword [esp + 0x1c], eax
push ecx
call fcn.008325b4
mov edx, dword [ebx + 0x24]
add esp, 8
mov dword [esp + 0x14], eax
xor eax, eax
push eax
mov dword [esp + 0x34], eax
mov dword [esp + 0x58], eax
push eax
mov eax, dword [esp + 0xbc]
push edx
push eax
call edi
mov ebx, dword [esp + 0x18]
mov ecx, 0x400
xor eax, eax
mov edi, ebx
rep stosd dword es:[edi], eax
mov ecx, dword [esp + 0x24]
mov edi, dword [esp + 0x14]
mov edx, ecx
push 0
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
mov ecx, dword [esp + 0xb4]
lea eax, [esp + 0x30]
push eax
push 0x1000
push ebx
push ecx
mov dword [esp + 0x40], 0
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x6930f5
mov eax, dword [esp + 0x2c]
xor edi, edi
cmp eax, edi
je 0x69310b
lea edx, [esp + 0x54]
lea eax, [esp + 0x30]
push edx
lea ecx, [esp + 0x4c]
push eax
lea edx, [esp + 0x2c]
push ecx
mov ecx, dword [esp + 0x34]
lea eax, [esp + 0x20]
push edx
push eax
mov eax, dword [esp + 0x34]
push 0x1000
push ebx
lea edx, [esp + 0x7c]
push ecx
mov cx, word [esi + 8]
push edx
push eax
push ecx
mov dword [esp + 0x74], edi
call fcn.00691c60
add esp, 0x2c
cmp eax, edi
jne 0x693118
mov ecx, dword [esp + 0x48]
xor eax, eax
mov ax, word [esi + 8]
mov ebx, ecx
sub eax, edi
je 0x6930a8
dec eax
je 0x69308e
dec eax
jne 0x6930aa
mov eax, dword [esp + 0x14]
push ecx
mov edi, eax
add eax, 8
push eax
call fcn.006a3300
mov dword [edi + 4], eax
add esp, 8
lea edi, [ebx + 8]
jmp 0x6930aa
mov eax, dword [esp + 0x14]
push ecx
mov edi, eax
add eax, 4
push eax
call fcn.006a3300
mov dword [edi], eax
add esp, 8
lea edi, [ebx + 4]
jmp 0x6930aa
mov edi, ecx
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0xb4]
lea edx, [esp + 0x4c]
push 0
push edx
push edi
push eax
push ecx
mov dword [esp + 0x60], 0
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x69319c
cmp dword [esp + 0x4c], edi
jb 0x6931b2
mov eax, dword [esi + 0x28]
test eax, eax
jne 0x6930e9
mov dword [esi + 0x2c], edi
inc eax
mov dword [esi + 0x30], edi
mov dword [esi + 0x28], eax
jmp 0x692fb8
mov dword [0x9ddbd8], 0xd
mov dword [0x9ddbdc], 0x1d99
jmp 0x693187
mov dword [esp + 0x1c], 1
jmp 0x6931dd
jge 0x693173
push 0x9b5220
lea ecx, [esp + 0x24]
call fcn.00617650
mov edx, dword [esp + 0x28]
mov eax, dword [esp + 0x2c]
mov ecx, dword [esp + 0x3c]
push 0x1dae
push edx
push eax
push ecx
lea edx, [esp + 0x30]
push str.Error:_Encrypt_Data_Failed__File__Algrithm_d__DataLen_lu_KeyLen_lu__LINE_d
push edx
mov dword [esp + 0xc0], edi
call fcn.0061aed0
mov eax, dword [esp + 0x38]
push eax
call fcn.006a5ed0
add esp, 0x1c
lea ecx, [esp + 0x20]
mov dword [esp + 0xa8], 0xffffffff
call fcn.00617ec0
mov dword [0x9ddbd8], 0x11
mov dword [0x9ddbdc], 0x1db2
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [0x9ddbe0], eax
mov dword [esp + 0x10], 1
jmp 0x6931dd
mov dword [0x9ddbd8], 0xe
mov dword [0x9ddbdc], 0x1dbd
jmp 0x6931c6
mov dword [0x9ddbd8], 0xe
mov dword [0x9ddbdc], 0x1dc5
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, dword [esp + 0x18]
mov dword [0x9ddbe0], eax
mov dword [esp + 0x10], 1
xor edi, edi
cmp ebx, edi
je 0x6931ec
push ebx
call fcn.008325dd
add esp, 4
mov eax, dword [esp + 0x14]
cmp eax, edi
je 0x693201
push eax
call fcn.008325dd
add esp, 4
mov dword [esp + 0x14], edi
mov eax, dword [esp + 0x30]
cmp eax, edi
je 0x693216
push eax
call fcn.008325dd
add esp, 4
mov dword [esp + 0x30], edi
mov ecx, dword [esp + 0xb4]
push ecx
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
mov eax, dword [esp + 0x1c]
test eax, eax
je 0x69333c
mov eax, dword [esp + 0x10]
test eax, eax
jne 0x69333c
mov edi, dword [esp + 0xcc]
mov dword [esp + 0x44], 1
mov ecx, edi
xor ebx, ebx
call fcn.00636d30
test eax, eax
je 0x693261
mov ecx, edi
call fcn.00637450
mov ebx, eax
mov edi, dword [ebp + 0x24]
test ebx, ebx
jne 0x69326d
and edi, 0xffffffb1
jmp 0x693285
push ebx
or edi, 8
call fcn.00696050
add esp, 4
test eax, eax
je 0x693282
and edi, 0xffffffbf
jmp 0x693285
or edi, 0x40
cmp edi, dword [ebp + 0x24]
je 0x69328d
mov dword [ebp + 0x24], edi
mov edx, dword [esp + 0xcc]
mov eax, dword [esp + 0xc8]
mov ecx, dword [esp + 0xc4]
push edx
mov edx, dword [esp + 0xc0]
push eax
mov eax, dword [esp + 0xbc]
push ecx
push esi
push edx
push ebp
push eax
call fcn.006985c0
add esp, 0x1c
test eax, eax
je 0x69331d
jmp 0x69333c
mov dword [0x9ddbd8], 1
mov dword [0x9ddbdc], 0x1d13
jmp 0x693331
mov dword [0x9ddbd8], 0xb
mov dword [0x9ddbdc], 0x1d29
jmp 0x693331
mov dword [0x9ddbd8], 0xc
mov dword [0x9ddbdc], 0x1d31
jmp 0x693331
mov dword [0x9ddbd8], 0x25
mov dword [0x9ddbdc], 0x1d43
jmp 0x693331
mov dword [0x9ddbd8], 0x10
mov dword [0x9ddbdc], 0x1df7
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [0x9ddbe0], eax
mov ecx, dword [esp + 0xa0]
mov eax, dword [esp + 0x44]
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x9c
ret