Function at 0x408cb0
Capabilities:
Set file attributes

Disassembly:
push ebp
mov ebp, esp
push eax
mov eax, 2
add esp, 0xfffff004
push eax
dec eax
jne 0x408cb9
mov eax, dword [ebp - 4]
add esp, 0xffffffac
push ebx
push esi
push edi
xor ecx, ecx
mov dword [ebp - 0xc], ecx
mov byte [ebp - 5], dl
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
call fcn.00403af4
mov ebx, 0x40a188
xor eax, eax
push ebp
push 0x409055
push dword fs:[eax]
mov dword fs:[eax], esp
xor eax, eax
push ebp
push 0x409025
push dword fs:[eax]
mov dword fs:[eax], esp
mov edx, 0x409068
lea eax, [ebp - 0x2014]
call fcn.00402a58
lea eax, [ebp - 0x2018]
mov dl, byte [ebx + 3]
mov byte [eax + 1], dl
mov byte [eax], 1
lea edx, [ebp - 0x2018]
lea eax, [ebp - 0x2014]
mov cl, 2
call fcn.00402a28
lea edx, [ebp - 0x2014]
lea eax, [ebp - 0x201c]
call fcn.00402a58
lea eax, [ebp - 0x2018]
mov dl, byte [ebx + 0x14]
mov byte [eax + 1], dl
mov byte [eax], 1
lea edx, [ebp - 0x2018]
lea eax, [ebp - 0x201c]
mov cl, 3
call fcn.00402a28
lea edx, [ebp - 0x201c]
lea eax, [ebp - 0x2024]
call fcn.00402a58
lea eax, [ebp - 0x2018]
mov dl, byte [ebx + 0xb]
mov byte [eax + 1], dl
mov byte [eax], 1
lea edx, [ebp - 0x2018]
lea eax, [ebp - 0x2024]
mov cl, 4
call fcn.00402a28
lea edx, [ebp - 0x2024]
lea eax, [ebp - 0x202c]
call fcn.00402a58
lea eax, [ebp - 0x2018]
mov dl, byte [ebx + 0xb]
mov byte [eax + 1], dl
mov byte [eax], 1
lea edx, [ebp - 0x2018]
lea eax, [ebp - 0x202c]
mov cl, 5
call fcn.00402a28
lea edx, [ebp - 0x202c]
lea eax, [ebp - 0x2034]
call fcn.00402a58
lea eax, [ebp - 0x2018]
mov dl, byte [ebx]
mov byte [eax + 1], dl
mov byte [eax], 1
lea edx, [ebp - 0x2018]
lea eax, [ebp - 0x2034]
mov cl, 6
call fcn.00402a28
lea edx, [ebp - 0x2034]
lea eax, [ebp - 0x203c]
call fcn.00402a58
lea eax, [ebp - 0x2018]
mov dl, byte [ebx + 0x19]
mov byte [eax + 1], dl
mov byte [eax], 1
lea edx, [ebp - 0x2018]
lea eax, [ebp - 0x203c]
mov cl, 7
call fcn.00402a28
lea edx, [ebp - 0x203c]
lea eax, [ebp - 0x2048]
call fcn.00402a58
lea eax, [ebp - 0x2018]
mov dl, byte [ebx + 0x18]
mov byte [eax + 1], dl
mov byte [eax], 1
lea edx, [ebp - 0x2018]
lea eax, [ebp - 0x2048]
mov cl, 8
call fcn.00402a28
lea edx, [ebp - 0x2048]
lea eax, [ebp - 0x2058]
call fcn.00402a58
mov edx, 0x40906c
lea eax, [ebp - 0x2058]
mov cl, 0xc
call fcn.00402a28
lea edx, [ebp - 0x2058]
lea eax, [ebp - 0xc]
call fcn.004038e0
mov byte [ebp - 6], 0
push 0x80
mov eax, dword [ebp - 4]
call fcn.00403b04
mov ebx, eax
push ebx
call sub.kernel32.dll_SetFileAttributesA
push 0
push 0xa7
push 3
push 0
push 0
push 0xc0000000
push ebx
call sub.kernel32.dll_CreateFileA
mov edi, eax
cmp edi, 0xffffffff
jne 0x408edd
mov byte [ebp - 6], 0
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x409037
lea edx, [ebp - 0x2010]
mov ecx, 0x2000
mov eax, edi
call fcn.00404a04
mov ebx, eax
mov eax, dword [ebp - 0xc]
call fcn.00403b04
mov esi, eax
mov ecx, esi
lea eax, [ebp - 0x2010]
mov edx, 0x2000
call fcn.004071c8
test eax, eax
je 0x408f24
push edi
call sub.kernel32.dll_CloseHandle
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x409037
cmp ebx, 0xd
jbe 0x408f60
mov byte [ebp + ebx - 0x201e], 0
push esi
lea eax, [ebp + ebx - 0x201d]
push eax
call sub.kernel32.dll_lstrcpyA
push 1
push 0
mov eax, ebx
neg eax
push eax
push edi
call sub.kernel32.dll_SetFilePointer
lea edx, [ebp - 0x2010]
mov ecx, ebx
mov eax, edi
call fcn.00404a34
mov dword [ebp - 0x10], eax
cmp ebx, 0x2000
jne 0x409010
mov esi, 1
lea edx, [ebp - 0x2010]
mov ecx, 0x2000
mov eax, edi
call fcn.00404a04
mov ebx, eax
cmp ebx, 0x32
jbe 0x408fae
jmp 0x408fa5
mov eax, dword [ebp - 0xc]
call fcn.00403b04
push eax
lea eax, [ebp + esi - 0x2011]
push eax
call sub.kernel32.dll_lstrcpyA
add esi, 0x32
mov eax, ebx
sub eax, 0x32
cmp esi, eax
jbe 0x408f8c
test ebx, ebx
jbe 0x408fe0
push 1
push 0
mov eax, ebx
neg eax
push eax
push edi
call sub.kernel32.dll_SetFilePointer
lea edx, [ebp - 0x2010]
mov ecx, ebx
mov eax, edi
call fcn.00404a34
mov dword [ebp - 0x10], eax
cmp byte [ebp - 5], 0
je 0x408fe0
push 5
call sub.kernel32.dll_Sleep
mov eax, dword [ebp - 0x10]
xor edx, edx
cmp edx, 0xffffffff
jne 0x409004
cmp eax, 0xffffffff
jne 0x409004
mov byte [ebp - 6], 0
mov eax, edi
call fcn.00405a94
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x409037
cmp ebx, 0x2000
je 0x408f6c
mov eax, edi
call fcn.00405a94
mov byte [ebp - 6], 1
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x409037
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x40905c
lea eax, [ebp - 0xc]
call fcn.00403764
lea eax, [ebp - 4]
call fcn.00403764
ret