Function at 0x475860
Capabilities:
Clear file content
Get common file path
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x53957d
mov eax, dword fs:[0]
push eax
mov eax, 0x1030c
call fcn.00502a70
mov eax, dword [0x57d54c]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, edx
mov esi, ecx
xorps xmm0, xmm0
mov dword [ebp - 0x248], 0
movq qword [ebp - 0x250], xmm0
mov dword [ebp - 0x250], 0
mov dword [ebp - 0x24c], 0
mov dword [ebp - 0x248], 0
lea ecx, [ebp - 0x250]
mov dword [ebp - 4], 0
call fcn.00476080
mov eax, dword [ebp - 0x250]
mov ecx, dword [ebp - 0x24c]
cmp eax, ecx
je 0x4758fb
nop dword [eax + eax]
cmp esi, dword [eax]
je 0x475914
add eax, 4
cmp eax, ecx
jne 0x4758f0
mov dword [ebp - 0x244], esi
cmp dword [ebp - 0x248], ecx
je 0x47591e
mov dword [ecx], esi
add dword [ebp - 0x24c], 4
jmp 0x475931
mov edi, 1
jmp 0x475f64
lea eax, [ebp - 0x244]
push eax
push ecx
lea ecx, [ebp - 0x250]
call fcn.004777f0
lea ecx, [ebp - 0x280]
call fcn.00408060
push 0x20a
lea eax, [ebp - 0x240]
mov byte [ebp - 4], 1
push 0
push eax
call fcn.00504c70
add esp, 0xc
call fcn.00407680
mov esi, eax
mov eax, dword [esi + 4]
test eax, eax
je 0x475997
movaps xmm0, xmmword [0x565ac0]
lea ecx, [ebp - 0x268]
push ecx
push eax
movups xmmword [ebp - 0x268], xmm0
mov dword [ebp - 0x258], 0x61507265
mov dword [ebp - 0x254], 0x576874
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [esi + 0x20], eax
push 0
push 0x23
lea eax, [ebp - 0x240]
push eax
push 0
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
test eax, eax
je 0x475a11
lea ecx, [ebp - 0x240]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4759b7
sub ecx, edx
sar ecx, 1
cmp ecx, 1
jbe 0x475a11
push ecx
lea eax, [ebp - 0x240]
push eax
lea ecx, [ebp - 0x280]
call fcn.0040aad0
push 1
push 0x55fb5c
lea ecx, [ebp - 0x280]
call fcn.0040ac20
mov ecx, edi
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4759f5
sub ecx, edx
sar ecx, 1
push ecx
push edi
lea ecx, [ebp - 0x280]
call fcn.0040ac20
push 0x10044
lea eax, [ebp - 0x102f8]
push 0
push eax
call fcn.00504c70
lea eax, [ebp - 0x102bc]
mov dword [ebp - 0x102f8], 0
mov dword [ebp - 0x102c8], eax
lea esi, [ebp - 0x102bc]
neg eax
mov dword [ebp - 0x102f4], 0
and eax, 3
mov dword [ebp - 0x102e8], 0
mov dword [ebp - 0x10300], eax
add esp, 0xc
add eax, esi
mov dword [ebp - 0x102e4], 0
mov dword [ebp - 0x102c4], eax
lea eax, [ebp - 0x2bc]
mov dword [ebp - 0x102e0], 0
mov dword [ebp - 0x102d8], 0
mov dword [ebp - 0x2bc], 0
mov dword [ebp - 0x2b8], 0
mov dword [ebp - 0x102c0], eax
mov byte [ebp - 4], 2
mov esi, str.xml_version_1.0__encoding_UTF_8_
inc esi
cmp byte [esi], 0
jne 0x475ab1
sub esi, str.xml_version_1.0__encoding_UTF_8_
lea ecx, [ebp - 0x102c8]
inc esi
push esi
call fcn.004775f0
mov edi, eax
test esi, esi
je 0x475aee
mov edx, str.xml_version_1.0__encoding_UTF_8_
mov ecx, edi
sub edx, edi
nop dword [eax]
mov al, byte [edx + ecx]
lea ecx, [ecx + 1]
mov byte [ecx - 1], al
sub esi, 1
jne 0x475ae0
sub esp, 0xc
lea ecx, [ebp - 0x102c8]
push edi
push 7
call fcn.004773e0
cmp dword [ebp - 0x102e0], 0
mov ecx, eax
je 0x475b1e
mov eax, dword [ebp - 0x102dc]
mov dword [ecx + 0x28], eax
mov eax, dword [ebp - 0x102dc]
mov dword [eax + 0x2c], ecx
jmp 0x475b2b
mov dword [ecx + 0x28], 0
mov dword [ebp - 0x102e0], ecx
sub esp, 0xc
mov dword [ebp - 0x102dc], ecx
lea eax, [ebp - 0x102f8]
mov dword [ecx + 0x2c], 0
mov dword [ecx + 0x10], eax
lea ecx, [ebp - 0x102c8]
push str.InsLog
push 1
call fcn.004773e0
mov esi, dword [ebp - 0x250]
mov edx, eax
mov dword [ebp - 0x244], edx
cmp esi, dword [ebp - 0x24c]
je 0x475d1a
mov ebx, dword [ebp - 0x102c4]
neg ebx
and ebx, 3
add ebx, dword [ebp - 0x102c4]
lea eax, [ebx + 0x30]
cmp eax, dword [ebp - 0x102c0]
jbe 0x475be4
mov eax, dword [ebp - 0x2bc]
push 0x1000a
test eax, eax
je 0x475b9f
call eax
jmp 0x475ba4
call fcn.0050243a
mov edx, eax
add esp, 4
mov eax, dword [ebp - 0x102c8]
mov ecx, edx
neg ecx
and ecx, 3
add ecx, edx
mov dword [ecx], eax
add ecx, 4
mov ebx, ecx
mov dword [ebp - 0x102c8], edx
neg ebx
mov dword [ebp - 0x102c4], ecx
lea eax, [edx + 0x1000a]
and ebx, 3
mov edx, dword [ebp - 0x244]
add ebx, ecx
mov dword [ebp - 0x102c0], eax
lea eax, [ebx + 0x30]
mov dword [ebp - 0x102c4], eax
mov eax, str.Item
mov dword [ebx], 0
mov dword [ebx + 4], 0
mov dword [ebx + 0x10], 0
mov dword [ebx + 0x14], 1
mov dword [ebx + 0x18], 0
mov dword [ebx + 0x20], 0
nop dword [eax + eax]
inc eax
cmp byte [eax], 0
jne 0x475c20
sub eax, str.Item
mov dword [ebx], str.Item
mov dword [ebx + 8], eax
cmp dword [edx + 0x18], 0
je 0x475c48
mov eax, dword [edx + 0x1c]
mov dword [ebx + 0x28], eax
mov eax, dword [edx + 0x1c]
mov dword [eax + 0x2c], ebx
jmp 0x475c52
mov dword [ebx + 0x28], 0
mov dword [edx + 0x18], ebx
push 0xa
mov dword [edx + 0x1c], ebx
lea eax, [ebp - 0x30]
push 0x1e
push eax
mov dword [ebx + 0x10], edx
mov dword [ebx + 0x2c], 0
push dword [esi]
call fcn.0051a015
add esp, 0x10
lea edi, [ebp - 0x30]
cmp byte [ebp - 0x30], 0
je 0x475c86
nop word [eax + eax]
inc edi
cmp byte [edi], 0
jne 0x475c80
lea eax, [ebp - 0x30]
sub edi, eax
lea ecx, [ebp - 0x102c8]
inc edi
push edi
call fcn.004775f0
mov dword [ebp - 0x102fc], eax
test edi, edi
je 0x475cc4
lea edx, [ebp - 0x30]
mov ecx, eax
sub edx, eax
nop dword [eax]
mov al, byte [edx + ecx]
lea ecx, [ecx + 1]
mov byte [ecx - 1], al
sub edi, 1
jne 0x475cb0
mov eax, dword [ebp - 0x102fc]
sub esp, 8
lea ecx, [ebp - 0x102c8]
push eax
push str.labelid
call fcn.00479a70
cmp dword [ebx + 0x20], 0
mov ecx, eax
je 0x475cee
mov eax, dword [ebx + 0x24]
mov dword [ecx + 0x14], eax
mov eax, dword [ebx + 0x24]
mov dword [eax + 0x18], ecx
jmp 0x475cf8
mov dword [ecx + 0x14], 0
mov dword [ebx + 0x20], ecx
mov edx, dword [ebp - 0x244]
add esi, 4
mov dword [ebx + 0x24], ecx
mov dword [ecx + 0x10], ebx
mov dword [ecx + 0x18], 0
cmp esi, dword [ebp - 0x24c]
jne 0x475b70
cmp dword [ebp - 0x102e0], 0
je 0x475d37
mov eax, dword [ebp - 0x102dc]
mov dword [edx + 0x28], eax
mov eax, dword [ebp - 0x102dc]
mov dword [eax + 0x2c], edx
jmp 0x475d44
mov dword [edx + 0x28], 0
mov dword [ebp - 0x102e0], edx
mov dword [ebp - 0x102dc], edx
lea eax, [ebp - 0x102f8]
lea ecx, [ebp - 0x298]
mov dword [edx + 0x10], eax
mov dword [edx + 0x2c], 0
call fcn.004082f0
push 0
lea eax, [ebp - 0x298]
mov byte [ebp - 4], 3
push 0
push eax
lea edx, [ebp - 0x102f8]
lea ecx, [ebp - 0x102fc]
call fcn.00477ae0
mov ebx, dword [ebp - 0x288]
lea eax, [ebp - 0x298]
add esp, 0xc
lea esi, [ebp - 0x280]
cmp dword [ebp - 0x284], 0x10
lea ecx, [ebp - 0x2b0]
cmovae eax, dword [ebp - 0x298]
cmp dword [ebp - 0x26c], 8
mov dword [ebp - 0x102fc], eax
cmovae esi, dword [ebp - 0x280]
push esi
call fcn.00408010
lea ecx, [ebp - 0x268]
mov byte [ebp - 4], 4
call fcn.00408060
push esi
lea ecx, [ebp - 0x10318]
mov byte [ebp - 4], 5
call fcn.00408010
push ecx
lea edx, [ebp - 0x268]
mov byte [ebp - 4], 6
lea ecx, [ebp - 0x10318]
call fcn.00475370
add esp, 4
mov byte [ebp - 4], 5
lea ecx, [ebp - 0x10318]
call fcn.00407f10
cmp dword [ebp - 0x254], 8
lea ecx, [ebp - 0x268]
cmovae ecx, dword [ebp - 0x268]
call fcn.004750b0
push 0
push 0x80
push 4
push 0
push 2
push 0x40000000
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
cmp edi, 0xffffffff
jne 0x475e6a
lea ecx, [ebp - 0x268]
mov byte [ebp - 4], 4
call fcn.00407f10
lea ecx, [ebp - 0x2b0]
mov byte [ebp - 4], 3
call fcn.00407f10
xor edi, edi
jmp 0x475ece
push 0
lea eax, [ebp - 0x244]
mov dword [ebp - 0x244], 0
push eax
push ebx
push dword [ebp - 0x102fc]
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push edi
mov esi, eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test esi, esi
je 0x475eae
cmp dword [ebp - 0x244], ebx
jne 0x475eae
mov edi, 1
jmp 0x475eb0
xor edi, edi
lea ecx, [ebp - 0x268]
mov byte [ebp - 4], 4
call fcn.00407f10
lea ecx, [ebp - 0x2b0]
mov byte [ebp - 4], 3
call fcn.00407f10
lea ecx, [ebp - 0x298]
mov byte [ebp - 4], 2
call fcn.004081f0
mov byte [ebp - 4], 8
lea eax, [ebp - 0x102bc]
mov edx, dword [ebp - 0x102c8]
cmp edx, eax
je 0x475f29
mov ecx, edx
mov eax, ecx
neg eax
and eax, 3
mov esi, dword [ecx + eax]
mov eax, dword [ebp - 0x2b8]
test eax, eax
je 0x475f0c
push edx
call eax
jmp 0x475f12
push ecx
call fcn.00502435
lea eax, [ebp - 0x102bc]
add esp, 4
mov edx, esi
mov ecx, esi
mov dword [ebp - 0x102c8], edx
cmp esi, eax
jne 0x475ef3
lea eax, [ebp - 0x102bc]
mov dword [ebp - 0x102c8], eax
lea ecx, [ebp - 0x102bc]
mov eax, dword [ebp - 0x10300]
add eax, ecx
lea ecx, [ebp - 0x280]
mov dword [ebp - 0x102c4], eax
lea eax, [ebp - 0x2bc]
mov dword [ebp - 0x102c0], eax
mov byte [ebp - 4], 0
call fcn.00407f10
mov dword [ebp - 4], 0xffffffff
mov edx, dword [ebp - 0x250]
test edx, edx
je 0x475fc2
mov ecx, dword [ebp - 0x248]
mov eax, edx
sub ecx, edx
and ecx, 0xfffffffc
cmp ecx, 0x1000
jb 0x475f9a
mov edx, dword [edx - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x475fe0
push ecx
push edx
call fcn.00502404
add esp, 8
mov dword [ebp - 0x250], 0
mov dword [ebp - 0x24c], 0
mov dword [ebp - 0x248], 0
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00501e95
mov esp, ebp
pop ebp
ret
call fcn.00509bb8
int3