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

Disassembly:
push esi
push edi
add esp, 0xfffffc4c
mov dword [esp + 8], ecx
mov dword [esp + 4], edx
mov dword [esp], eax
mov esi, 0x6ec737
lea edi, [esp + 0x84]
mov ecx, 0x40
rep movsd dword es:[edi], dword [esi]
mov esi, 0x6ec837
lea edi, [esp + 0x184]
mov ecx, 0x40
rep movsd dword es:[edi], dword [esi]
cmp dword [0x6f5838], 0
je 0x6d1f1e
mov word [esp + 0x78], 0x12d
mov byte [esp + 0x284], 0x18
mov eax, dword [esp]
push eax
call sub.kernel32.dll_lstrlenA_1
inc eax
push eax
mov edx, dword [esp + 4]
push edx
lea ecx, [esp + 0x28d]
push ecx
call fcn.006cb33c
add esp, 0xc
mov eax, dword [esp + 4]
push eax
call sub.kernel32.dll_lstrlenA_1
inc eax
push eax
mov edx, dword [esp + 8]
push edx
lea ecx, [esp + 0x2a1]
push ecx
call fcn.006cb33c
add esp, 0xc
mov eax, dword [esp + 8]
push eax
call sub.kernel32.dll_lstrlenA_1
inc eax
push eax
mov edx, dword [esp + 0xc]
push edx
lea ecx, [esp + 0x2b5]
push ecx
call fcn.006cb33c
add esp, 0xc
push 2
lea ecx, [esp + 0x80]
lea eax, [esp + 0x288]
mov dx, word [esp + 0x7c]
call fcn.006d780c
mov word [esp + 0x7a], ax
push 2
lea eax, [esp + 0x80]
push eax
lea edx, [esp + 0x82]
push edx
call fcn.006cb33c
add esp, 0xc
movsx eax, word [esp + 0x7a]
jmp 0x6d2914
mov eax, dword [esp]
call fcn.006d3468
mov dword [esp + 0x34], eax
mov eax, dword [esp + 4]
call fcn.006d3468
mov dword [esp + 0x38], eax
xor edx, edx
mov dword [esp + 0x3c], edx
lea ecx, [esp + 0xc]
mov dword [esp + 0x80], ecx
mov ecx, dword [esp + 0x3c]
mov eax, dword [esp + 0x34]
shl ecx, 3
mov edx, dword [esp + 0x80]
shl eax, cl
shr eax, 0x18
mov byte [edx], al
inc dword [esp + 0x3c]
inc dword [esp + 0x80]
cmp dword [esp + 0x3c], 3
jle 0x6d1f48
xor eax, eax
lea edx, [esp + 0x10]
mov dword [esp + 0x3c], eax
mov dword [esp + 0x80], edx
mov ecx, dword [esp + 0x3c]
mov eax, dword [esp + 0x38]
shl ecx, 3
mov edx, dword [esp + 0x80]
shl eax, cl
shr eax, 0x18
mov byte [edx], al
inc dword [esp + 0x3c]
inc dword [esp + 0x80]
cmp dword [esp + 0x3c], 3
jle 0x6d1f84
mov ecx, dword [esp + 8]
push ecx
call sub.kernel32.dll_lstrlenA_1
mov dword [esp + 0x40], eax
mov eax, dword [esp + 0x40]
inc eax
push eax
push 2
call sub.kernel32.dll_GlobalAlloc
mov dword [esp + 0x48], eax
mov edx, dword [esp + 0x48]
push edx
call sub.kernel32.dll_GlobalLock
mov dword [esp + 0x4c], eax
mov ecx, dword [esp + 8]
push ecx
mov eax, dword [esp + 0x50]
push eax
call sub.kernel32.dll_lstrcpyA
push 0x6efa45
push 1
push 1
push 0
call sub.kernel32.dll_CreateSemaphoreA
mov dword [esp + 0x44], eax
lea edx, [esp + 0x84]
push edx
call sub.kernel32.dll_lstrlenA_1
push eax
push 0
lea ecx, [esp + 0x8c]
push ecx
call fcn.006cb324
add esp, 0xc
lea eax, [esp + 0x184]
push eax
call sub.kernel32.dll_lstrlenA_1
push eax
push 0
lea edx, [esp + 0x18c]
push edx
call fcn.006cb324
add esp, 0xc
mov edx, 0x2f
mov eax, dword [esp + 0x4c]
call fcn.006ce92c
mov dword [esp + 0x50], eax
cmp dword [esp + 0x50], 0
jne 0x6d2074
mov ecx, dword [esp + 0x4c]
push ecx
lea eax, [esp + 0x188]
push eax
call sub.kernel32.dll_lstrcpyA
mov dword [esp + 0x3c], 0xffffffff
jmp 0x6d20a0
mov edx, dword [esp + 0x50]
sub edx, dword [esp + 0x4c]
inc edx
push edx
mov ecx, dword [esp + 0x50]
push ecx
lea eax, [esp + 0x18c]
push eax
call sub.kernel32.dll_lstrcpynA_1
mov edx, dword [esp + 0x50]
inc edx
push edx
mov ecx, dword [esp + 0x50]
push ecx
call sub.kernel32.dll_lstrcpyA
lea eax, [esp + 0x184]
call fcn.006d33b4
mov dword [esp + 0x54], eax
mov eax, dword [esp + 0x54]
call fcn.006d33e8
mov edx, dword [esp + 0x54]
push edx
call sub.kernel32.dll_lstrlenA_1
mov dword [esp + 0x40], eax
mov ecx, dword [esp + 0x54]
add ecx, dword [esp + 0x40]
add ecx, 0xfffffffe
mov dword [esp + 0x58], ecx
push 0
push 0
push 3
push 0
push 3
push 0x80000000
mov eax, dword [esp + 0x6c]
push eax
call sub.kernel32.dll_CreateFileA_1
mov dword [esp + 0x5c], eax
cmp dword [esp + 0x5c], 0xffffffff
jne 0x6d2118
mov edx, dword [esp + 0x48]
push edx
call sub.kernel32.dll_GlobalFree
mov ecx, dword [esp + 0x44]
push ecx
call sub.kernel32.dll_CloseHandle_1
mov eax, 0xffffff37
jmp 0x6d2914
push 0
lea edx, [esp + 0x6c]
push edx
push 8
lea ecx, [esp + 0x20]
push ecx
mov eax, dword [esp + 0x6c]
push eax
call sub.kernel32.dll_ReadFile_1
mov dword [esp + 0x64], eax
cmp dword [esp + 0x64], 0
jne 0x6d2163
mov edx, dword [esp + 0x48]
push edx
call sub.kernel32.dll_GlobalFree
mov ecx, dword [esp + 0x5c]
push ecx
call sub.kernel32.dll_CloseHandle_1
mov eax, dword [esp + 0x44]
push eax
call sub.kernel32.dll_CloseHandle_1
mov eax, 0xffffff34
jmp 0x6d2914
push 0
lea edx, [esp + 0x6c]
push edx
push 8
lea ecx, [esp + 0x28]
push ecx
mov eax, dword [esp + 0x6c]
push eax
call sub.kernel32.dll_ReadFile_1
mov dword [esp + 0x64], eax
cmp dword [esp + 0x64], 0
jne 0x6d21ae
mov edx, dword [esp + 0x48]
push edx
call sub.kernel32.dll_GlobalFree
mov ecx, dword [esp + 0x5c]
push ecx
call sub.kernel32.dll_CloseHandle_1
mov eax, dword [esp + 0x44]
push eax
call sub.kernel32.dll_CloseHandle_1
mov eax, 0xffffff34
jmp 0x6d2914
mov edx, dword [esp + 0x5c]
push edx
call sub.kernel32.dll_CloseHandle_1
push 0xffffffffffffffff
mov ecx, dword [esp + 0x48]
push ecx
call sub.kernel32.dll_WaitForSingleObject
push 0x6efa31
lea ecx, [esp + 0x28]
lea edx, [esp + 0x18]
lea eax, [esp + 0x10]
call fcn.006ced70
mov dword [esp + 0x74], eax
cmp dword [esp + 0x74], 0
je 0x6d2220
push 0x6efa31
lea ecx, [esp + 0x28]
lea edx, [esp + 0x18]
lea eax, [esp + 0x10]
call fcn.006ced70
mov dword [esp + 0x74], eax
cmp dword [esp + 0x74], 0
je 0x6d2220
push 0x6efa31
lea ecx, [esp + 0x28]
lea edx, [esp + 0x18]
lea eax, [esp + 0x10]
call fcn.006ced70
mov dword [esp + 0x74], eax
push 0
push 1
mov eax, dword [esp + 0x4c]
push eax
call sub.kernel32.dll_ReleaseSemaphore
cmp dword [esp + 0x74], 0
je 0x6d2252
mov edx, dword [esp + 0x48]
push edx
call sub.kernel32.dll_GlobalFree
mov ecx, dword [esp + 0x44]
push ecx
call sub.kernel32.dll_CloseHandle_1
mov eax, dword [esp + 0x74]
jmp 0x6d2914
push 0xffffffffffffffff
mov edx, dword [esp + 0x48]
push edx
call sub.kernel32.dll_WaitForSingleObject
push 0x6efa31
lea ecx, [esp + 0x30]
lea edx, [esp + 0x20]
lea eax, [esp + 0x10]
call fcn.006ced70
mov dword [esp + 0x74], eax
cmp dword [esp + 0x74], 0
je 0x6d22ba
push 0x6efa31
lea ecx, [esp + 0x30]
lea edx, [esp + 0x20]
lea eax, [esp + 0x10]
call fcn.006ced70
mov dword [esp + 0x74], eax
cmp dword [esp + 0x74], 0
je 0x6d22ba
push 0x6efa31
lea ecx, [esp + 0x30]
lea edx, [esp + 0x20]
lea eax, [esp + 0x10]
call fcn.006ced70
mov dword [esp + 0x74], eax
push 0
push 1
mov ecx, dword [esp + 0x4c]
push ecx
call sub.kernel32.dll_ReleaseSemaphore
cmp dword [esp + 0x74], 0
je 0x6d22ec
mov eax, dword [esp + 0x48]
push eax
call sub.kernel32.dll_GlobalFree
mov edx, dword [esp + 0x44]
push edx
call sub.kernel32.dll_CloseHandle_1
mov eax, dword [esp + 0x74]
jmp 0x6d2914
push 0x6efa4d
mov edx, dword [esp + 0x5c]
push edx
call sub.kernel32.dll_lstrcmpiA
test eax, eax
jne 0x6d2424
mov ecx, dword [esp + 0x54]
push ecx
call sub.kernel32.dll_lstrlenA_1
dec eax
push eax
mov eax, dword [esp + 0x58]
push eax
lea edx, [esp + 0x8c]
push edx
call sub.kernel32.dll_lstrcpynA_1
push 0x6efa50
lea ecx, [esp + 0x88]
push ecx
call sub.kernel32.dll_lstrcatA
lea eax, [esp + 0x84]
call fcn.006d73d0
push 0
push 0
push 2
push 0
push 3
push 0x40000000
lea edx, [esp + 0x9c]
push edx
call sub.kernel32.dll_CreateFileA_1
mov dword [esp + 0x5c], eax
cmp dword [esp + 0x5c], 0xffffffff
jne 0x6d2384
mov ecx, dword [esp + 0x48]
push ecx
call sub.kernel32.dll_GlobalFree
mov eax, dword [esp + 0x44]
push eax
call sub.kernel32.dll_CloseHandle_1
mov eax, 0xffffff37
jmp 0x6d2914
push 0
lea edx, [esp + 0x6c]
push edx
push 8
lea ecx, [esp + 0x30]
push ecx
mov eax, dword [esp + 0x6c]
push eax
call sub.kernel32.dll_WriteFile_1
mov dword [esp + 0x64], eax
cmp dword [esp + 0x64], 0
jne 0x6d23cf
mov edx, dword [esp + 0x48]
push edx
call sub.kernel32.dll_GlobalFree
mov ecx, dword [esp + 0x5c]
push ecx
call sub.kernel32.dll_CloseHandle_1
mov eax, dword [esp + 0x44]
push eax
call sub.kernel32.dll_CloseHandle_1
mov eax, 0xffffff33
jmp 0x6d2914
push 0
lea edx, [esp + 0x6c]
push edx
push 8
lea ecx, [esp + 0x38]
push ecx
mov eax, dword [esp + 0x6c]
push eax
call sub.kernel32.dll_WriteFile_1
mov dword [esp + 0x64], eax
cmp dword [esp + 0x64], 0
jne 0x6d241a
mov edx, dword [esp + 0x48]
push edx
call sub.kernel32.dll_GlobalFree
mov ecx, dword [esp + 0x5c]
push ecx
call sub.kernel32.dll_CloseHandle_1
mov eax, dword [esp + 0x44]
push eax
call sub.kernel32.dll_CloseHandle_1
mov eax, 0xffffff33
jmp 0x6d2914
mov edx, dword [esp + 0x5c]
push edx
call sub.kernel32.dll_CloseHandle_1
push 0x6efa54
mov ecx, dword [esp + 0x5c]
push ecx
call sub.kernel32.dll_lstrcmpiA
test eax, eax
jne 0x6d268d
mov eax, dword [esp + 0x54]
push eax
call sub.kernel32.dll_lstrlenA_1
dec eax
push eax
mov edx, dword [esp + 0x58]
push edx
lea ecx, [esp + 0x8c]
push ecx
call sub.kernel32.dll_lstrcpynA_1
push 0x6efa57
lea eax, [esp + 0x88]
push eax
call sub.kernel32.dll_lstrcatA
lea eax, [esp + 0x84]
call fcn.006d73d0
push 0
push 0
push 2
push 0
push 3
push 0x40000000
lea edx, [esp + 0x9c]
push edx
call sub.kernel32.dll_CreateFileA_1
mov dword [esp + 0x5c], eax
cmp dword [esp + 0x5c], 0xffffffff
jne 0x6d24bc
mov ecx, dword [esp + 0x48]
push ecx
call sub.kernel32.dll_GlobalFree
mov eax, dword [esp + 0x44]
push eax
call sub.kernel32.dll_CloseHandle_1
mov eax, 0xffffff37
jmp 0x6d2914
push 0
lea edx, [esp + 0x6c]
push edx
push 8
lea ecx, [esp + 0x30]
push ecx
mov eax, dword [esp + 0x6c]
push eax
call sub.kernel32.dll_WriteFile_1
mov dword [esp + 0x64], eax
cmp dword [esp + 0x64], 0
jne 0x6d2507
mov edx, dword [esp + 0x48]
push edx
call sub.kernel32.dll_GlobalFree
mov ecx, dword [esp + 0x5c]
push ecx
call sub.kernel32.dll_CloseHandle_1
mov eax, dword [esp + 0x44]
push eax
call sub.kernel32.dll_CloseHandle_1
mov eax, 0xffffff33
jmp 0x6d2914
push 0
lea edx, [esp + 0x6c]
push edx
push 8
lea ecx, [esp + 0x38]
push ecx
mov eax, dword [esp + 0x6c]
push eax
call sub.kernel32.dll_WriteFile_1
mov dword [esp + 0x64], eax
cmp dword [esp + 0x64], 0
jne 0x6d2552
mov edx, dword [esp + 0x48]
push edx
call sub.kernel32.dll_GlobalFree
mov ecx, dword [esp + 0x5c]
push ecx
call sub.kernel32.dll_CloseHandle_1
mov eax, dword [esp + 0x44]
push eax
call sub.kernel32.dll_CloseHandle_1
mov eax, 0xffffff33
jmp 0x6d2914
push 0
push 0
push 3
push 0
push 3
push 0x80000000
mov edx, dword [esp + 0x6c]
push edx
call sub.kernel32.dll_CreateFileA_1
mov dword [esp + 0x60], eax
cmp dword [esp + 0x60], 0xffffffff
jne 0x6d259e
mov ecx, dword [esp + 0x48]
push ecx
call sub.kernel32.dll_GlobalFree
mov eax, dword [esp + 0x5c]
push eax
call sub.kernel32.dll_CloseHandle_1
mov edx, dword [esp + 0x44]
push edx
call sub.kernel32.dll_CloseHandle_1
mov eax, 0xffffff37
jmp 0x6d2914
push 0
push 0
push 0x10
mov edx, dword [esp + 0x6c]
push edx
call sub.kernel32.dll_SetFilePointer_1
mov dword [esp + 0x6c], 1
push 0
lea ecx, [esp + 0x6c]
push ecx
push 1
lea eax, [esp + 0x7c]
push eax
mov edx, dword [esp + 0x70]
push edx
call sub.kernel32.dll_ReadFile_1
mov dword [esp + 0x64], eax
cmp dword [esp + 0x64], 0
jne 0x6d260b
mov ecx, dword [esp + 0x48]
push ecx
call sub.kernel32.dll_GlobalFree
mov eax, dword [esp + 0x60]
push eax
call sub.kernel32.dll_CloseHandle_1
mov edx, dword [esp + 0x5c]
push edx
call sub.kernel32.dll_CloseHandle_1
mov ecx, dword [esp + 0x44]
push ecx
call sub.kernel32.dll_CloseHandle_1
mov eax, 0xffffff35
jmp 0x6d2914
cmp dword [esp + 0x68], 0
je 0x6d2679
push 0
lea edx, [esp + 0x6c]
push edx
push 1
lea ecx, [esp + 0x7c]
push ecx
mov eax, dword [esp + 0x6c]
push eax
call sub.kernel32.dll_WriteFile_1
mov dword [esp + 0x64], eax
cmp dword [esp + 0x64], 0
jne 0x6d2667
mov edx, dword [esp + 0x48]
push edx
call sub.kernel32.dll_GlobalFree
mov ecx, dword [esp + 0x60]
push ecx
call sub.kernel32.dll_CloseHandle_1
mov eax, dword [esp + 0x5c]
push eax
call sub.kernel32.dll_CloseHandle_1
mov edx, dword [esp + 0x44]
push edx
call sub.kernel32.dll_CloseHandle_1
mov eax, 0xffffff33
jmp 0x6d2914
inc dword [esp + 0x6c]
cmp dword [esp + 0x6c], 0x100
jle 0x6d25b6
mov edx, dword [esp + 0x60]
push edx
call sub.kernel32.dll_CloseHandle_1
mov ecx, dword [esp + 0x5c]
push ecx
call sub.kernel32.dll_CloseHandle_1
push 0x6efa5b
mov eax, dword [esp + 0x5c]
push eax
call sub.kernel32.dll_lstrcmpiA
test eax, eax
jne 0x6d28f3
mov edx, dword [esp + 0x54]
push edx
call sub.kernel32.dll_lstrlenA_1
dec eax
push eax
mov ecx, dword [esp + 0x58]
push ecx
lea eax, [esp + 0x8c]
push eax
call sub.kernel32.dll_lstrcpynA_1
push 0x6efa5e
lea edx, [esp + 0x88]
push edx
call sub.kernel32.dll_lstrcatA
lea eax, [esp + 0x84]
call fcn.006d73d0
push 0
push 0
push 2
push 0
push 3
push 0x40000000
lea edx, [esp + 0x9c]
push edx
call sub.kernel32.dll_CreateFileA_1
mov dword [esp + 0x5c], eax
cmp dword [esp + 0x5c], 0xffffffff
jne 0x6d2725
mov ecx, dword [esp + 0x48]
push ecx
call sub.kernel32.dll_GlobalFree
mov eax, dword [esp + 0x44]
push eax
call sub.kernel32.dll_CloseHandle_1
mov eax, 0xffffff37
jmp 0x6d2914
push 0
lea edx, [esp + 0x6c]
push edx
push 8
lea ecx, [esp + 0x30]
push ecx
mov eax, dword [esp + 0x6c]
push eax
call sub.kernel32.dll_WriteFile_1
mov dword [esp + 0x64], eax
cmp dword [esp + 0x64], 0
jne 0x6d2770
mov edx, dword [esp + 0x48]
push edx
call sub.kernel32.dll_GlobalFree
mov ecx, dword [esp + 0x5c]
push ecx
call sub.kernel32.dll_CloseHandle_1
mov eax, dword [esp + 0x44]
push eax
call sub.kernel32.dll_CloseHandle_1
mov eax, 0xffffff33
jmp 0x6d2914
push 0
lea edx, [esp + 0x6c]
push edx
push 8
lea ecx, [esp + 0x38]
push ecx
mov eax, dword [esp + 0x6c]
push eax
call sub.kernel32.dll_WriteFile_1
mov dword [esp + 0x64], eax
cmp dword [esp + 0x64], 0
jne 0x6d27bb
mov edx, dword [esp + 0x48]
push edx
call sub.kernel32.dll_GlobalFree
mov ecx, dword [esp + 0x5c]
push ecx
call sub.kernel32.dll_CloseHandle_1
mov eax, dword [esp + 0x44]
push eax
call sub.kernel32.dll_CloseHandle_1
mov eax, 0xffffff33
jmp 0x6d2914
push 0
push 0
push 3
push 0
push 3
push 0x80000000
mov edx, dword [esp + 0x6c]
push edx
call sub.kernel32.dll_CreateFileA_1
mov dword [esp + 0x60], eax
cmp dword [esp + 0x5c], 0xffffffff
jne 0x6d2807
mov ecx, dword [esp + 0x48]
push ecx
call sub.kernel32.dll_GlobalFree
mov eax, dword [esp + 0x5c]
push eax
call sub.kernel32.dll_CloseHandle_1
mov edx, dword [esp + 0x44]
push edx
call sub.kernel32.dll_CloseHandle_1
mov eax, 0xffffff37
jmp 0x6d2914
push 0
push 0
push 0x10
mov edx, dword [esp + 0x6c]
push edx
call sub.kernel32.dll_SetFilePointer_1
mov dword [esp + 0x6c], 1
push 0
lea ecx, [esp + 0x6c]
push ecx
push 1
lea eax, [esp + 0x7c]
push eax
mov edx, dword [esp + 0x70]
push edx
call sub.kernel32.dll_ReadFile_1
mov dword [esp + 0x64], eax
cmp dword [esp + 0x64], 0
jne 0x6d2874
mov ecx, dword [esp + 0x48]
push ecx
call sub.kernel32.dll_GlobalFree
mov eax, dword [esp + 0x60]
push eax
call sub.kernel32.dll_CloseHandle_1
mov edx, dword [esp + 0x5c]
push edx
call sub.kernel32.dll_CloseHandle_1
mov ecx, dword [esp + 0x44]
push ecx
call sub.kernel32.dll_CloseHandle_1
mov eax, 0xffffff35
jmp 0x6d2914
cmp dword [esp + 0x68], 0
je 0x6d28df
push 0
lea edx, [esp + 0x6c]
push edx
push 1
lea ecx, [esp + 0x7c]
push ecx
mov eax, dword [esp + 0x6c]
push eax
call sub.kernel32.dll_WriteFile_1
mov dword [esp + 0x64], eax
cmp dword [esp + 0x64], 0
jne 0x6d28cd
mov edx, dword [esp + 0x48]
push edx
call sub.kernel32.dll_GlobalFree
mov ecx, dword [esp + 0x60]
push ecx
call sub.kernel32.dll_CloseHandle_1
mov eax, dword [esp + 0x5c]
push eax
call sub.kernel32.dll_CloseHandle_1
mov edx, dword [esp + 0x44]
push edx
call sub.kernel32.dll_CloseHandle_1
mov eax, 0xffffff33
jmp 0x6d2914
inc dword [esp + 0x6c]
cmp dword [esp + 0x6c], 0x100
jle 0x6d281f
mov edx, dword [esp + 0x60]
push edx
call sub.kernel32.dll_CloseHandle_1
mov ecx, dword [esp + 0x5c]
push ecx
call sub.kernel32.dll_CloseHandle_1
cmp dword [esp + 0x3c], 0xffffffff
jne 0x6d1fff
mov eax, dword [esp + 0x48]
push eax
call sub.kernel32.dll_GlobalFree
mov edx, dword [esp + 0x44]
push edx
call sub.kernel32.dll_CloseHandle_1
xor eax, eax
add esp, 0x3b4
pop edi
pop esi
ret