Function at 0x4bf8b0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4cb402
mov eax, dword fs:[0]
push eax
push ecx
sub esp, 0x2c
push ebx
push esi
push edi
mov eax, dword [0x5142b0]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov dword [ebp - 0x3c], ecx
mov dword [ebp - 4], 0
mov dword [ebp - 0x14], 0
mov dword [ebp - 0x1c], 0xffffffff
mov byte [ebp - 4], 1
push 0x4eb746
lea eax, [ebp + 8]
push eax
call fcn.0040c560
add esp, 8
movzx ecx, al
test ecx, ecx
jne 0x4bf928
push 0x4f5a5c
lea edx, [ebp + 8]
push edx
call fcn.0040c560
add esp, 8
movzx eax, al
test eax, eax
je 0x4bf953
push str.NEEDTOSEE_::_CSWFileKeyValue::WriteTemplinefile______Shut_Down_Temperory_filename_empty_n
call fcn.00423ad0
add esp, 4
mov dword [ebp - 0x20], 0xc0000001
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call fcn.00401ed0
mov eax, dword [ebp - 0x20]
jmp 0x4bfb46
cmp dword [ebp + 0xc], 0
je 0x4bf95f
cmp dword [ebp + 0x10], 0
jne 0x4bf97d
mov dword [ebp - 0x24], 0xc0000002
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call fcn.00401ed0
mov eax, dword [ebp - 0x24]
jmp 0x4bfb46
push 0
push 2
mov ecx, dword [ebp + 0x1c]
push ecx
push 0
push 1
mov edx, dword [ebp + 0x14]
push edx
lea ecx, [ebp + 8]
call fcn.00402650
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x1c], eax
cmp dword [ebp - 0x1c], 0xffffffff
jne 0x4bf9dc
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x18], eax
mov eax, dword [ebp - 0x18]
push eax
push str._CSWFileKeyValue::WriteTemplinefile__:_Could_not_Open_a_file_errcode_:__ld_n
call fcn.00423db0
add esp, 8
mov ecx, dword [ebp - 0x18]
mov dword [ebp - 0x28], ecx
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call fcn.00401ed0
mov eax, dword [ebp - 0x28]
jmp 0x4bfb46
push 0
lea edx, [ebp - 0x14]
push edx
mov eax, dword [ebp + 0x10]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp - 0x1c]
push edx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x4bfa46
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x18], eax
mov eax, dword [ebp - 0x18]
push eax
push str._CSWFileKeyValue::WriteTemplinefile__:_Could_not_WriteFile1_a_file_errcode_:__ld_n
call fcn.00423db0
add esp, 8
cmp dword [ebp - 0x1c], 0xffffffff
je 0x4bfa29
mov ecx, dword [ebp - 0x1c]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x1c], 0xffffffff
mov edx, dword [ebp - 0x18]
mov dword [ebp - 0x2c], edx
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call fcn.00401ed0
mov eax, dword [ebp - 0x2c]
jmp 0x4bfb46
push 0
lea eax, [ebp - 0x14]
push eax
push 0x4f5ce4
call fcn.00490910
add esp, 4
push eax
push 0x4f5dcc
mov ecx, dword [ebp - 0x1c]
push ecx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x4bfabb
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x18], eax
mov edx, dword [ebp - 0x18]
push edx
push str._CSWFileKeyValue::WriteTemplinefile__:_Could_not_WriteFile2_a_file_errcode_:__ld_n
call fcn.00423db0
add esp, 8
cmp dword [ebp - 0x1c], 0xffffffff
je 0x4bfa9e
mov eax, dword [ebp - 0x1c]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x1c], 0xffffffff
mov ecx, dword [ebp - 0x18]
mov dword [ebp - 0x30], ecx
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call fcn.00401ed0
mov eax, dword [ebp - 0x30]
jmp 0x4bfb46
cmp dword [ebp - 0x1c], 0xffffffff
je 0x4bfad2
mov edx, dword [ebp - 0x1c]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x1c], 0xffffffff
mov dword [ebp - 0x34], 0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call fcn.00401ed0
mov eax, dword [ebp - 0x34]
jmp 0x4bfb46
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x18