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

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
mov eax, 0x106c
call fcn.00426ac0
mov eax, dword [ebp + 0xc]
mov eax, dword [ebp + 8]
mov dword [ebp - 0x1054], eax
mov eax, dword [0x43d080]
xor eax, ebp
mov dword [ebp - 0x10], eax
mov dword [ebp - 0x1050], 0xee382a49
mov eax, dword [ebp - 0x1050]
mov dword [ebp - 0x1058], eax
sub eax, 0x8821a39a
je 0x40ac83
jmp 0x40a7cc
mov eax, dword [ebp - 0x1058]
sub eax, 0x8dd3789f
je 0x40abb6
jmp 0x40a7e2
mov eax, dword [ebp - 0x1058]
sub eax, 0x8e9bc1c3
je 0x40ad00
jmp 0x40a7f8
mov eax, dword [ebp - 0x1058]
sub eax, 0x94849ebf
je 0x40ae67
jmp 0x40a80e
mov eax, dword [ebp - 0x1058]
sub eax, 0xa695199d
je 0x40ad7c
jmp 0x40a824
mov eax, dword [ebp - 0x1058]
sub eax, 0xb20d002e
je 0x40b014
jmp 0x40a83a
mov eax, dword [ebp - 0x1058]
sub eax, 0xc528eee2
je 0x40ab0c
jmp 0x40a850
mov eax, dword [ebp - 0x1058]
sub eax, 0xcede2970
je 0x40ae7d
jmp 0x40a866
mov eax, dword [ebp - 0x1058]
sub eax, 0xd450074e
je 0x40afbc
jmp 0x40a87c
mov eax, dword [ebp - 0x1058]
sub eax, 0xe7ebe363
je 0x40ae46
jmp 0x40a892
mov eax, dword [ebp - 0x1058]
sub eax, 0xeba48244
je 0x40afd9
jmp 0x40a8a8
mov eax, dword [ebp - 0x1058]
sub eax, 0xee382a49
je 0x40aaa7
jmp 0x40a8be
mov eax, dword [ebp - 0x1058]
sub eax, 0xee581c0c
je 0x40ac1c
jmp 0x40a8d4
mov eax, dword [ebp - 0x1058]
sub eax, 0xeef845f4
je 0x40af28
jmp 0x40a8ea
mov eax, dword [ebp - 0x1058]
sub eax, 0xf0779829
je 0x40adc5
jmp 0x40a900
mov eax, dword [ebp - 0x1058]
sub eax, 0x809421b
je 0x40af0d
jmp 0x40a916
mov eax, dword [ebp - 0x1058]
sub eax, 0x897fe2b
je 0x40ab51
jmp 0x40a92c
mov eax, dword [ebp - 0x1058]
sub eax, 0xb7a00be
je 0x40aefe
jmp 0x40a942
mov eax, dword [ebp - 0x1058]
sub eax, 0xb9a941b
je 0x40ae8c
jmp 0x40a958
mov eax, dword [ebp - 0x1058]
sub eax, 0xf9da05a
je 0x40ad27
jmp 0x40a96e
mov eax, dword [ebp - 0x1058]
sub eax, 0x2026b25c
je 0x40b005
jmp 0x40a984
mov eax, dword [ebp - 0x1058]
sub eax, 0x2464e64a
je 0x40abf4
jmp 0x40a99a
mov eax, dword [ebp - 0x1058]
sub eax, 0x2d6d9a7e
je 0x40af4e
jmp 0x40a9b0
mov eax, dword [ebp - 0x1058]
sub eax, 0x39ba6a5f
je 0x40afad
jmp 0x40a9c6
mov eax, dword [ebp - 0x1058]
sub eax, 0x3a1ea820
je 0x40ab60
jmp 0x40a9dc
mov eax, dword [ebp - 0x1058]
sub eax, 0x3cc25581
je 0x40ab3b
jmp 0x40a9f2
mov eax, dword [ebp - 0x1058]
sub eax, 0x4cecb9de
je 0x40ac32
jmp 0x40aa08
mov eax, dword [ebp - 0x1058]
sub eax, 0x4e03ae54
je 0x40acf1
jmp 0x40aa1e
mov eax, dword [ebp - 0x1058]
sub eax, 0x541dbb19
je 0x40af6c
jmp 0x40aa34
mov eax, dword [ebp - 0x1058]
sub eax, 0x5eeaf37b
je 0x40ae25
jmp 0x40aa4a
mov eax, dword [ebp - 0x1058]
sub eax, 0x6c8f9d5a
je 0x40af5d
jmp 0x40aa60
mov eax, dword [ebp - 0x1058]
sub eax, 0x75bc7dd8
je 0x40ae16
jmp 0x40aa76
mov eax, dword [ebp - 0x1058]
sub eax, 0x7c884bb0
je 0x40abd9
jmp 0x40aa8c
mov eax, dword [ebp - 0x1058]
sub eax, 0x7f764ee8
je 0x40aea7
jmp 0x40aaa2
jmp 0x40b01e
mov eax, dword [ebp - 0x1054]
mov dword [ebp - 0x1040], eax
mov eax, dword [ebp - 0x1040]
xor ecx, ecx
mov dword [esp], eax
mov dword [esp + 4], 0x80000000
mov dword [esp + 8], 1
mov dword [esp + 0xc], 0
mov dword [esp + 0x10], 3
mov dword [esp + 0x14], 0x80
mov dword [esp + 0x18], 0
call dword [sym.imp.KERNEL32.dll_CreateFileA]
sub esp, 0x1c
mov dword [ebp - 0x1038], eax
mov dword [ebp - 0x1050], 0xc528eee2
jmp 0x40b01e
mov eax, dword [ebp - 0x1038]
mov dword [ebp - 0x1044], eax
mov edx, 0xffffffff
mov eax, 0x3a1ea820
mov ecx, 0x3cc25581
cmp dword [ebp - 0x1044], edx
cmove eax, ecx
mov dword [ebp - 0x1050], eax
jmp 0x40b01e
mov byte [ebp - 0x1039], 0
mov dword [ebp - 0x1050], 0x897fe2b
jmp 0x40b01e
mov dword [ebp - 0x1050], 0xd450074e
jmp 0x40b01e
mov eax, dword [ebp + 0xc]
xor ecx, ecx
mov dword [esp], eax
mov dword [esp + 4], 0x40000000
mov dword [esp + 8], 0
mov dword [esp + 0xc], 0
mov dword [esp + 0x10], 2
mov dword [esp + 0x14], 0x80
mov dword [esp + 0x18], 0
call dword [sym.imp.KERNEL32.dll_CreateFileA]
sub esp, 0x1c
mov dword [ebp - 0x1048], eax
mov dword [ebp - 0x1050], 0x8dd3789f
jmp 0x40b01e
mov edx, 0xffffffff
mov eax, 0xee581c0c
mov ecx, 0x7c884bb0
cmp dword [ebp - 0x1048], edx
cmove eax, ecx
mov dword [ebp - 0x1050], eax
jmp 0x40b01e
mov eax, dword [ebp - 0x1044]
mov dword [ebp - 0x1034], eax
mov dword [ebp - 0x1050], 0x2464e64a
jmp 0x40b01e
mov eax, dword [ebp - 0x1034]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
sub esp, 4
mov byte [ebp - 0x1039], 0
mov dword [ebp - 0x1050], 0xd450074e
jmp 0x40b01e
mov byte [ebp - 0x1049], 0
mov dword [ebp - 0x1050], 0x4cecb9de
jmp 0x40b01e
mov eax, dword [0x43e5a4]
mov ecx, dword [0x43e5a0]
mov edx, eax
sub edx, 0x5cc6a9f9
sub edx, 1
add edx, 0x5cc6a9f9
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
mov dl, al
and dl, cl
xor al, cl
or dl, al
mov eax, 0x2026b25c
mov ecx, 0x8821a39a
test dl, 1
cmovne eax, ecx
mov dword [ebp - 0x1050], eax
jmp 0x40b01e
mov ecx, dword [0x43e5a4]
mov eax, dword [0x43e5a0]
xor esi, esi
sub esi, 1
mov edx, ecx
add edx, esi
imul ecx, edx
and ecx, 1
cmp ecx, 0
sete bl
cmp eax, 0xa
setl dh
mov al, bl
xor al, 0xff
mov ah, dh
xor ah, 0xff
mov cl, 1
xor cl, 1
mov dl, al
and dl, 0xff
and bl, cl
mov ch, ah
and ch, 0xff
and dh, cl
or dl, bl
or ch, dh
xor dl, ch
or al, ah
xor al, 0xff
or cl, 1
and al, cl
or dl, al
mov eax, 0x2026b25c
mov ecx, 0x4e03ae54
test dl, 1
cmovne eax, ecx
mov dword [ebp - 0x1050], eax
jmp 0x40b01e
mov dword [ebp - 0x1050], 0x8e9bc1c3
jmp 0x40b01e
lea eax, [ebp - 0x1010]
mov dword [ebp - 0x1030], eax
mov eax, dword [ebp - 0x1044]
mov dword [ebp - 0x102c], eax
mov dword [ebp - 0x1050], 0xf9da05a
jmp 0x40b01e
mov ecx, dword [ebp - 0x1030]
mov edx, dword [ebp - 0x102c]
lea eax, [ebp - 0x1018]
xor esi, esi
mov dword [esp], edx
mov dword [esp + 4], ecx
mov dword [esp + 8], 0x1000
mov dword [esp + 0xc], eax
mov dword [esp + 0x10], 0
call dword [sym.imp.KERNEL32.dll_ReadFile]
sub esp, 0x14
mov edx, eax
mov eax, 0xa695199d
mov ecx, 0x5eeaf37b
cmp edx, 0
cmovne eax, ecx
mov dword [ebp - 0x1050], eax
jmp 0x40b01e
mov eax, dword [0x43e5a4]
mov ecx, dword [0x43e5a0]
xor esi, esi
sub esi, 1
mov edx, eax
add edx, esi
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
mov dl, al
and dl, cl
xor al, cl
or dl, al
mov eax, 0xb20d002e
mov ecx, 0xf0779829
test dl, 1
cmovne eax, ecx
mov dword [ebp - 0x1050], eax
jmp 0x40b01e
mov eax, dword [0x43e5a4]
mov ecx, dword [0x43e5a0]
mov edx, eax
sub edx, 0xbbb6e554
sub edx, 1
add edx, 0xbbb6e554
imul eax, edx
and eax, 1
cmp eax, 0
sete al
cmp ecx, 0xa
setl cl
mov dl, al
and dl, cl
xor al, cl
or dl, al
mov eax, 0xb20d002e
mov ecx, 0x75bc7dd8
test dl, 1
cmovne eax, ecx
mov dword [ebp - 0x1050], eax
jmp 0x40b01e
mov dword [ebp - 0x1050], 0x541dbb19
jmp 0x40b01e
cmp dword [ebp - 0x1018], 0
sete al
and al, 1
mov byte [ebp - 0x1025], al
mov dword [ebp - 0x1050], 0xe7ebe363
jmp 0x40b01e
mov dl, byte [ebp - 0x1025]
mov eax, 0xb9a941b
mov ecx, 0x94849ebf
test dl, 1
cmovne eax, ecx
mov dword [ebp - 0x1050], eax
jmp 0x40b01e
mov byte [ebp - 0x1049], 1
mov dword [ebp - 0x1050], 0xcede2970
jmp 0x40b01e
mov dword [ebp - 0x1050], 0x541dbb19
jmp 0x40b01e
mov eax, dword [ebp - 0x1018]
mov dword [ebp - 0x1024], eax
mov dword [ebp - 0x1050], 0x7f764ee8
jmp 0x40b01e
lea edx, [ebp - 0x1010]
mov esi, dword [ebp - 0x1048]
mov ecx, dword [ebp - 0x1024]
lea eax, [ebp - 0x1014]
xor edi, edi
mov dword [esp], esi
mov dword [esp + 4], edx
mov dword [esp + 8], ecx
mov dword [esp + 0xc], eax
mov dword [esp + 0x10], 0
call dword [sym.imp.KERNEL32.dll_WriteFile]
sub esp, 0x14
mov edx, eax
mov eax, 0xb7a00be
mov ecx, 0x809421b
cmp edx, 0
cmovne eax, ecx
mov dword [ebp - 0x1050], eax
jmp 0x40b01e
mov dword [ebp - 0x1050], 0x541dbb19
jmp 0x40b01e
mov eax, dword [ebp - 0x1014]
mov dword [ebp - 0x1020], eax
mov dword [ebp - 0x1050], 0xeef845f4
jmp 0x40b01e
mov esi, dword [ebp - 0x1018]
mov edx, dword [ebp - 0x1020]
mov eax, 0x6c8f9d5a
mov ecx, 0x2d6d9a7e
cmp edx, esi
cmovne eax, ecx
mov dword [ebp - 0x1050], eax
jmp 0x40b01e
mov dword [ebp - 0x1050], 0x541dbb19
jmp 0x40b01e
mov dword [ebp - 0x1050], 0x8e9bc1c3
jmp 0x40b01e
mov eax, dword [ebp - 0x1044]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
sub esp, 4
mov eax, dword [ebp - 0x1048]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
sub esp, 4
mov al, byte [ebp - 0x1049]
and al, 1
mov byte [ebp - 0x1039], al
mov dword [ebp - 0x1050], 0x39ba6a5f
jmp 0x40b01e
mov dword [ebp - 0x1050], 0xd450074e
jmp 0x40b01e
mov al, byte [ebp - 0x1039]
and al, 1
mov byte [ebp - 0x1019], al
mov dword [ebp - 0x1050], 0xeba48244
jmp 0x40b01e
mov al, byte [ebp - 0x1019]
and al, 1
movzx eax, al
mov dword [ebp - 0x105c], eax
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00426ab0
mov eax, dword [ebp - 0x105c]
add esp, 0x106c
pop esi
pop edi
pop ebx
pop ebp
ret
mov dword [ebp - 0x1050], 0x8821a39a
jmp 0x40b01e
mov dword [ebp - 0x1050], 0xf0779829
jmp 0x40a7b0