Function at 0x405a10
Capabilities:
Get common file path
Move file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x44a9a3
mov eax, dword fs:[0]
push eax
sub esp, 0x26c
mov eax, dword [0x461040]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x278], edx
mov edi, ecx
mov dword [ebp - 0x264], edi
mov dword [ebp - 0x26c], edi
mov dword [ebp - 0x274], edi
mov eax, edx
mov dword [ebp - 0x268], 0
cmp dword [edx + 0x14], 7
jbe 0x405a6b
mov eax, dword [edx]
lea ecx, [ebp - 0x218]
push ecx
push 0
push 0x4595b4
push eax
call dword [sym.imp.KERNEL32.dll_GetTempFileNameW]
test eax, eax
jne 0x405ab7
xorps xmm0, xmm0
movups xmmword [edi], xmm0
movq qword [edi + 0x10], xmm0
movups xmmword [edi], xmm0
mov dword [edi + 0x10], eax
mov dword [edi + 0x14], eax
mov dword [edi + 0x10], eax
mov dword [edi + 0x14], 7
mov word [edi], ax
mov dword [ebp - 4], eax
mov dword [ebp - 0x268], 1
jmp 0x405ff7
lea ecx, [ebp - 0x218]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x405ac0
sub ecx, edx
mov dword [ebp - 0x250], 0
sar ecx, 1
lea eax, [ebp - 0x218]
push ecx
xorps xmm0, xmm0
mov dword [ebp - 0x24c], 0
push eax
lea ecx, [ebp - 0x260]
movups xmmword [ebp - 0x260], xmm0
call fcn.00403b90
mov dword [ebp - 4], 3
lea eax, [ebp - 0x260]
push 1
sub esp, 0x18
mov dword [ebp - 0x26c], esp
mov esi, esp
sub esp, 0x18
mov ecx, esp
mov dword [ebp - 0x270], esp
push eax
call fcn.00402b30
mov byte [ebp - 4], 4
mov byte [ebp - 4], 3
mov ecx, esi
call fcn.00409b40
add esp, 0x18
mov byte [ebp - 4], 5
mov byte [ebp - 4], 3
lea ecx, [ebp - 0x230]
call fcn.00409e60
mov byte [ebp - 4], 8
mov eax, dword [ebp - 0x24c]
cmp eax, 7
jbe 0x405b91
mov ecx, dword [ebp - 0x260]
lea eax, [eax*2 + 2]
mov edx, ecx
cmp eax, 0x1000
jb 0x405b86
mov ecx, dword [edx - 4]
sub edx, ecx
lea eax, [edx - 4]
cmp eax, 0x1f
ja 0x406019
test ecx, ecx
je 0x405b91
push ecx
call dword [sym.imp.KERNEL32.dll_LocalFree]
xor eax, eax
mov dword [ebp - 0x250], 0
push 3
xorps xmm0, xmm0
mov dword [ebp - 0x24c], 7
push 0x4595ac
lea ecx, [ebp - 0x248]
mov word [ebp - 0x260], ax
movups xmmword [ebp - 0x248], xmm0
mov dword [ebp - 0x238], eax
mov dword [ebp - 0x234], eax
call fcn.00403b90
mov byte [ebp - 4], 9
lea eax, [ebp - 0x248]
mov edx, dword [ebp - 0x234]
cmp edx, 7
mov ecx, dword [ebp - 0x248]
cmova eax, ecx
cmp word [eax], 0x2e
jne 0x405c5f
mov esi, dword [ebp - 0x238]
lea edi, [ebp - 0x248]
cmp edx, 7
lea eax, [ebp - 0x248]
cmova eax, ecx
cmova edi, ecx
sub edi, eax
mov ecx, 1
sar edi, 1
mov eax, esi
sub eax, edi
cmp eax, ecx
cmovb ecx, eax
cmp edx, 7
lea eax, [ebp - 0x248]
cmova eax, dword [ebp - 0x248]
sub esi, ecx
lea edx, [eax + edi*2]
mov eax, esi
sub eax, edi
lea ecx, [edx + ecx*2]
lea eax, [eax*2 + 2]
push eax
push ecx
push edx
call fcn.0042af20
mov edi, dword [ebp - 0x264]
add esp, 0xc
mov dword [ebp - 0x238], esi
mov eax, dword [ebp - 0x220]
mov ecx, eax
mov edx, dword [ebp - 0x21c]
mov esi, dword [ebp - 0x230]
mov dword [ebp - 0x264], eax
test ecx, ecx
je 0x405cee
dec ecx
cmp ecx, 0xffffffff
je 0x405d4a
nop word [eax + eax]
cmp edx, 7
lea eax, [ebp - 0x230]
cmova eax, esi
cmp word [eax + ecx*2], 0x5c
je 0x405cbc
cmp edx, 7
lea eax, [ebp - 0x230]
cmova eax, esi
cmp word [eax + ecx*2], 0x2e
je 0x405ce8
dec ecx
cmp ecx, 0xffffffff
jne 0x405c90
mov ecx, dword [ebp - 0x264]
cmp ecx, edx
jae 0x405d51
lea eax, [ecx + 1]
cmp edx, 7
mov dword [ebp - 0x220], eax
lea eax, [ebp - 0x230]
cmova eax, esi
mov dword [eax + ecx*2], 0x2e
jmp 0x405d66
mov eax, dword [ebp - 0x264]
cmp ecx, 0xffffffff
je 0x405cbc
cmp ecx, eax
ja 0x405d23
cmp edx, 7
mov dword [ebp - 0x220], ecx
lea eax, [ebp - 0x230]
cmova eax, esi
xor edx, edx
mov word [eax + ecx*2], dx
mov edx, dword [ebp - 0x21c]
mov ecx, dword [ebp - 0x220]
mov esi, dword [ebp - 0x230]
jmp 0x405cc2
sub ecx, eax
push 0
push ecx
lea ecx, [ebp - 0x230]
call fcn.00404620
mov edx, dword [ebp - 0x21c]
mov ecx, dword [ebp - 0x220]
mov esi, dword [ebp - 0x230]
jmp 0x405cc2
mov ecx, eax
jmp 0x405cc2
push 0x2e
push dword [ebp - 0x274]
lea ecx, [ebp - 0x230]
push 1
call fcn.00404700
cmp dword [ebp - 0x234], 7
lea ecx, [ebp - 0x248]
mov esi, dword [ebp - 0x220]
cmova ecx, dword [ebp - 0x248]
mov eax, dword [ebp - 0x21c]
mov edx, dword [ebp - 0x238]
sub eax, esi
mov dword [ebp - 0x26c], edx
mov dword [ebp - 0x270], ecx
mov dword [ebp - 0x264], esi
cmp edx, eax
ja 0x405df1
cmp dword [ebp - 0x21c], 7
lea eax, [esi + edx]
mov dword [ebp - 0x220], eax
lea esi, [ebp - 0x230]
cmova esi, dword [ebp - 0x230]
mov eax, dword [ebp - 0x264]
lea ecx, [esi + eax*2]
lea eax, [edx + edx]
push eax
push dword [ebp - 0x270]
push ecx
call fcn.0042af20
mov eax, dword [ebp - 0x26c]
add esp, 0xc
add eax, dword [ebp - 0x264]
xor ecx, ecx
mov word [esi + eax*2], cx
jmp 0x405e05
push edx
push ecx
push dword [ebp - 0x274]
lea ecx, [ebp - 0x230]
push edx
call fcn.00404b20
lea eax, [ebp - 0x260]
push eax
lea ecx, [ebp - 0x230]
call fcn.00409890
mov byte [ebp - 4], 0xa
cmp dword [eax + 0x14], 7
jbe 0x405e23
mov eax, dword [eax]
push eax
lea eax, [ebp - 0x218]
push eax
call dword [sym.imp.KERNEL32.dll_MoveFileW]
mov esi, eax
mov byte [ebp - 4], 9
lea ecx, [ebp - 0x260]
call fcn.00403d40
test esi, esi
jne 0x405f35
mov edx, dword [ebp - 0x278]
lea ecx, [ebp - 0x260]
push 0x4595ac
push 0x4595b4
call fcn.00405a10
add esp, 8
mov byte [ebp - 4], 0xb
lea eax, [ebp - 0x218]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
xorps xmm0, xmm0
xor eax, eax
movups xmmword [edi], xmm0
mov dword [edi + 0x10], esi
movups xmm0, xmmword [ebp - 0x260]
mov dword [edi + 0x14], esi
mov word [ebp - 0x260], ax
movups xmmword [edi], xmm0
movq xmm0, qword [ebp - 0x250]
movq qword [edi + 0x10], xmm0
mov dword [ebp - 0x250], esi
mov dword [ebp - 0x24c], 7
mov byte [ebp - 4], 0xb
mov dword [ebp - 0x268], 1
mov byte [ebp - 4], 9
lea ecx, [ebp - 0x260]
call fcn.00403d40
mov byte [ebp - 4], 8
mov eax, dword [ebp - 0x234]
cmp eax, 7
jbe 0x405f13
mov ecx, dword [ebp - 0x248]
lea eax, [eax*2 + 2]
mov edx, ecx
cmp eax, 0x1000
jb 0x405f08
mov ecx, dword [edx - 4]
sub edx, ecx
lea eax, [edx - 4]
cmp eax, 0x1f
ja 0x406014
test ecx, ecx
je 0x405f13
push ecx
call dword [sym.imp.KERNEL32.dll_LocalFree]
xor eax, eax
mov dword [ebp - 0x238], 0
mov dword [ebp - 0x234], 7
mov word [ebp - 0x248], ax
jmp 0x405fe5
xorps xmm0, xmm0
xor eax, eax
movups xmmword [edi], xmm0
mov dword [edi + 0x10], 0
movups xmm0, xmmword [ebp - 0x230]
mov dword [edi + 0x14], 0
mov word [ebp - 0x230], ax
movups xmmword [edi], xmm0
movq xmm0, qword [ebp - 0x220]
movq qword [edi + 0x10], xmm0
mov dword [ebp - 0x220], 0
mov dword [ebp - 0x21c], 7
mov byte [ebp - 4], 9
mov dword [ebp - 0x268], 1
mov byte [ebp - 4], 8
mov eax, dword [ebp - 0x234]
cmp eax, 7
jbe 0x405fc8
mov ecx, dword [ebp - 0x248]
lea eax, [eax*2 + 2]
mov edx, ecx
cmp eax, 0x1000
jb 0x405fbd
mov ecx, dword [edx - 4]
sub edx, ecx
lea eax, [edx - 4]
cmp eax, 0x1f
ja 0x406019
test ecx, ecx
je 0x405fc8
push ecx
call dword [sym.imp.KERNEL32.dll_LocalFree]
xor eax, eax
mov dword [ebp - 0x238], 0
mov dword [ebp - 0x234], 7
mov word [ebp - 0x248], ax
mov dword [ebp - 4], 0
lea ecx, [ebp - 0x230]
call fcn.00403d40
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00429557
mov esp, ebp
pop ebp
ret
call fcn.0042e352
call fcn.0042e352
int3