Function at 0x46d830
Capabilities:
Copy file

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffd0
push ebx
push esi
push edi
xor eax, eax
mov dword [ebp - 0x2c], eax
mov dword [ebp - 0x30], eax
mov dword [ebp - 4], eax
mov dword [ebp - 8], eax
mov dword [ebp - 0xc], eax
mov dword [ebp - 0x10], eax
xor eax, eax
push ebp
push 0x46da74
push dword fs:[eax]
mov dword fs:[eax], esp
call fcn.004aaa90
mov al, 3
call fcn.0046d78c
fstp qword [ebp - 0x18]
wait
mov al, 1
call fcn.0046d78c
fcomp qword [ebp - 0x18]
fnstsw ax
sahf
jbe 0x46da47
xor eax, eax
call fcn.00629a18
lea edx, [ebp - 4]
mov al, 2
call fcn.00621750
lea edx, [ebp - 8]
mov al, 4
call fcn.00621750
call fcn.0064d5b0
mov dword [ebp - 0x28], eax
mov eax, dword [0x66f9cc]
inc byte [eax]
lea edx, [ebp - 0x2c]
xor eax, eax
call fcn.00621750
lea eax, [ebp - 0x2c]
mov edx, 0x46da88
call fcn.00403ab4
mov edx, dword [ebp - 0x2c]
mov eax, dword [ebp - 0x28]
call fcn.0064fd4c
mov eax, dword [0x66f9cc]
dec byte [eax]
xor ebx, ebx
jmp 0x46da0e
mov eax, dword [ebp - 0x28]
mov eax, dword [eax + 0x1c]
lea esi, [eax + ebx*4]
mov eax, dword [esi]
call fcn.0040351c
cmp eax, 0x11
jne 0x46da0d
mov eax, dword [esi]
cmp byte [eax], 0x2a
jne 0x46da0d
xor eax, eax
mov edx, eax
add edx, edx
add edx, 2
mov ecx, dword [esi]
movzx edx, byte [ecx + edx - 1]
mov ecx, dword [0x66f438]
mov dl, byte [ecx + edx]
shl edx, 4
mov ecx, eax
add ecx, ecx
add ecx, 2
mov edi, dword [esi]
movzx ecx, byte [edi + ecx]
mov edi, dword [0x66f438]
add dl, byte [edi + ecx]
lea ecx, [ebp - 0x20]
add ecx, eax
mov byte [ecx], dl
inc eax
cmp eax, 8
jne 0x46d8fe
inc ebx
jmp 0x46d9ff
mov eax, dword [ebp - 0x28]
mov eax, dword [eax + 0x14]
lea esi, [eax + ebx*4]
inc ebx
cmp dword [esi], 0
je 0x46d9ff
mov eax, dword [esi]
cmp byte [eax], 0x2a
jne 0x46d961
dec ebx
jmp 0x46da0e
lea edx, [ebp - 0xc]
mov eax, dword [esi]
call fcn.00654c74
fld qword [ebp - 0x18]
fcomp qword [ebp - 0x20]
fnstsw ax
sahf
jae 0x46d9ff
mov edx, dword [ebp - 4]
mov eax, dword [ebp - 0xc]
call fcn.00655098
test al, al
je 0x46d9ff
mov eax, dword [ebp - 0xc]
call fcn.00653bb0
cmp ax, 0x21
jne 0x46d9ad
mov byte [ebp - 0x21], 0
lea eax, [ebp - 0xc]
call fcn.00653bf4
lea eax, [ebp - 0xc]
call fcn.00653bf4
jmp 0x46d9b1
mov byte [ebp - 0x21], 1
mov eax, dword [ebp - 4]
call fcn.00403aa8
mov edx, eax
inc edx
lea ecx, [ebp - 0x2c]
mov eax, dword [ebp - 0xc]
call fcn.006547d0
mov ecx, dword [ebp - 0x2c]
lea eax, [ebp - 0x10]
mov edx, dword [ebp - 8]
call fcn.00403b14
lea edx, [ebp - 0x2c]
mov eax, dword [ebp - 0x10]
call fcn.00655234
mov eax, dword [ebp - 0x2c]
call fcn.006219e4
mov al, byte [ebp - 0x21]
xor al, 1
neg al
sbb eax, eax
push eax
mov eax, dword [ebp - 0x10]
push eax
mov eax, dword [ebp - 0xc]
push eax
call sub.kernel32.dll_CopyFileW
mov eax, dword [ebp - 0x28]
cmp ebx, dword [eax + 0x24]
jl 0x46d941
jmp 0x46da0e
inc ebx
mov eax, dword [ebp - 0x28]
cmp ebx, dword [eax + 0x24]
jl 0x46d8d8
mov eax, dword [ebp - 0x28]
call fcn.004028c0
push 0
lea edx, [ebp - 0x2c]
mov al, 3
call fcn.00621750
mov eax, dword [ebp - 0x2c]
push eax
lea edx, [ebp - 0x30]
mov al, 1
call fcn.00621750
mov eax, dword [ebp - 0x30]
mov cl, 1
pop edx
call fcn.00622630
call fcn.004aaa88
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x46da7b
lea eax, [ebp - 0x30]
mov edx, 2
call fcn.00403898
lea eax, [ebp - 0x10]
mov edx, 4
call fcn.00403898
ret