Function at 0x520584
Capabilities:
Get file attributes

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffa8
lea eax, [ebp - 0x48]
push eax
push dword [ebp + 0xc]
call fcn.0066e728
add esp, 8
inc eax
jne 0x5205a3
xor eax, eax
jmp 0x5209c9
push 0x5c
push dword [ebp + 0xc]
call fcn.0066cb35
add esp, 8
mov dword [ebp - 0xc], eax
mov edx, dword [ebp - 0xc]
test edx, edx
jne 0x5205c1
xor eax, eax
jmp 0x5209c9
inc dword [ebp - 0xc]
xor edx, edx
mov dword [ebp - 0x10], edx
mov ecx, dword [ebp + 8]
mov eax, dword [ecx + 0xc]
mov dword [ebp - 4], eax
mov edx, dword [ebp - 4]
test edx, edx
je 0x520609
push dword [ebp - 0xc]
mov ecx, dword [ebp - 4]
push dword [ecx + 0x12c]
call fcn.0066cbe8
add esp, 8
test eax, eax
jne 0x5205fa
mov dword [ebp - 0x10], 1
jmp 0x520609
mov eax, dword [ebp - 4]
mov edx, dword [eax]
mov dword [ebp - 4], edx
mov ecx, dword [ebp - 4]
test ecx, ecx
jne 0x5205d9
mov eax, dword [ebp - 0x10]
test eax, eax
je 0x520676
mov edx, dword [ebp - 4]
mov cl, byte [edx + 0x121]
test cl, cl
jne 0x520657
mov eax, dword [0x7fd784]
dec eax
mov edx, dword [ebp - 4]
mov ecx, dword [edx + 0x110]
add eax, ecx
xor edx, edx
div dword [0x7fd784]
mov ecx, dword [0x6e75f8]
sub ecx, eax
mov eax, dword [0x7fd784]
mov edx, dword [ebp - 0x34]
add eax, edx
dec eax
cdq
idiv dword [0x7fd784]
add ecx, eax
mov dword [ebp - 0x14], ecx
jmp 0x520693
mov eax, dword [0x7fd784]
mov ecx, dword [ebp - 0x34]
add eax, ecx
dec eax
cdq
idiv dword [0x7fd784]
mov ecx, dword [0x6e75f8]
add eax, ecx
mov dword [ebp - 0x14], eax
jmp 0x520693
mov eax, dword [0x7fd784]
mov edx, dword [ebp - 0x34]
add eax, edx
dec eax
cdq
idiv dword [0x7fd784]
mov ecx, dword [0x6e75f8]
add eax, ecx
mov dword [ebp - 0x14], eax
mov eax, dword [ebp - 0x14]
mov edx, dword [0x7fd788]
cmp eax, edx
jle 0x5206cf
push 0x5a3b
call fcn.00402a64
pop ecx
push eax
push 0x9f2fb4
call fcn.00670e94
add esp, 8
push 0x9f2fb4
push 0
call fcn.004627e0
add esp, 8
xor eax, eax
jmp 0x5209c9
mov ecx, dword [ebp - 0x10]
test ecx, ecx
je 0x5207ad
mov eax, dword [ebp - 4]
mov edx, dword [eax + 0x14c]
test edx, edx
je 0x520701
mov ecx, dword [ebp - 4]
push dword [ecx + 0x14c]
call fcn.004506c8
pop ecx
mov eax, dword [ebp - 4]
xor edx, edx
mov dword [eax + 0x14c], edx
mov ecx, dword [ebp - 4]
mov eax, dword [ecx + 0x12c]
test eax, eax
je 0x520728
mov edx, dword [ebp - 4]
push dword [edx + 0x12c]
call fcn.004506c8
pop ecx
mov ecx, dword [ebp - 4]
xor eax, eax
mov dword [ecx + 0x12c], eax
mov edx, dword [ebp - 4]
mov ecx, dword [edx + 0x134]
test ecx, ecx
je 0x52074f
mov eax, dword [ebp - 4]
push dword [eax + 0x134]
call fcn.004506c8
pop ecx
mov edx, dword [ebp - 4]
xor ecx, ecx
mov dword [edx + 0x134], ecx
mov eax, dword [ebp - 4]
mov edx, dword [eax + 0x130]
test edx, edx
je 0x520776
mov ecx, dword [ebp - 4]
push dword [ecx + 0x130]
call fcn.004506c8
pop ecx
mov eax, dword [ebp - 4]
xor edx, edx
mov dword [eax + 0x130], edx
mov ecx, dword [ebp - 4]
mov al, byte [ecx + 0x121]
test al, al
jne 0x5207ec
push dword [ebp - 4]
call fcn.0051dc24
pop ecx
mov eax, dword [0x7fd784]
dec eax
mov edx, dword [ebp - 4]
mov ecx, dword [edx + 0x110]
add eax, ecx
xor edx, edx
div dword [0x7fd784]
sub dword [0x6e75f8], eax
jmp 0x5207ec
push 0x190
call fcn.00450668
pop ecx
mov dword [ebp - 4], eax
push 0x190
push 0
push dword [ebp - 4]
call fcn.0066c86c
add esp, 0xc
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0xc]
mov eax, dword [ebp - 4]
mov dword [eax], ecx
mov edx, dword [ebp + 8]
mov ecx, dword [ebp - 4]
mov dword [edx + 0xc], ecx
mov eax, dword [ebp - 4]
xor edx, edx
mov dword [eax + 0x130], edx
push dword [ebp - 0xc]
call fcn.00450628
pop ecx
mov ecx, dword [ebp - 4]
mov dword [ecx + 0x12c], eax
push dword [ebp + 0xc]
call fcn.00450628
pop ecx
mov edx, dword [ebp - 4]
mov dword [edx + 0x134], eax
mov eax, dword [ebp + 8]
mov ecx, dword [ebp - 4]
mov dword [ecx + 0x138], eax
mov eax, dword [ebp - 4]
mov byte [eax + 0x120], 0
lea edx, [ebp - 0x2c]
push edx
call fcn.00678ef4
pop ecx
mov dword [ebp - 0x20], eax
mov ecx, dword [ebp - 0x20]
test ecx, ecx
je 0x5208c5
mov eax, dword [ebp - 0x20]
mov dx, word [eax + 0x14]
add dx, 0x76c
mov word [ebp - 0x58], dx
mov ecx, dword [ebp - 0x20]
mov ax, word [ecx + 0x10]
inc eax
mov word [ebp - 0x56], ax
mov edx, dword [ebp - 0x20]
mov cx, word [edx + 0xc]
mov word [ebp - 0x52], cx
mov eax, dword [ebp - 0x20]
mov dx, word [eax + 8]
mov word [ebp - 0x50], dx
mov ecx, dword [ebp - 0x20]
mov ax, word [ecx + 4]
mov word [ebp - 0x4e], ax
mov edx, dword [ebp - 0x20]
mov cx, word [edx]
mov word [ebp - 0x4c], cx
mov word [ebp - 0x4a], 0
mov word [ebp - 0x54], 0
lea eax, [ebp - 0x1c]
push eax
lea edx, [ebp - 0x58]
push edx
call sub.KERNEL32.DLL_SystemTimeToFileTime
lea ecx, [ebp - 0x24]
push ecx
lea eax, [ebp - 0x22]
push eax
lea edx, [ebp - 0x1c]
push edx
call sub.KERNEL32.DLL_FileTimeToDosDateTime
movzx ecx, word [ebp - 0x22]
shl ecx, 0x10
movzx eax, word [ebp - 0x24]
add ecx, eax
mov edx, dword [ebp - 4]
mov dword [edx + 0x124], ecx
mov ecx, dword [0x6e761c]
test ecx, ecx
jne 0x5208ef
push dword [ebp + 0xc]
call sub.KERNEL32.DLL_GetFileAttributesA
test al, 2
je 0x5208ef
mov eax, dword [ebp - 4]
or dword [eax + 0x144], 0x100
mov edx, dword [ebp - 4]
or byte [edx + 0x21], 1
test byte [ebp - 0x43], 0x40
je 0x520968
mov ecx, dword [ebp - 4]
mov byte [ecx + 0x121], 1
push 0x7fdd4b
push dword [ebp - 0xc]
call fcn.0066c9a0
add esp, 8
test eax, eax
jne 0x520920
mov eax, dword [ebp + 8]
or word [eax + 0x3c], 2
jmp 0x5209c4
push 0x7fdd4d
push dword [ebp - 0xc]
call fcn.0066c9a0
add esp, 8
test eax, eax
jne 0x520941
mov edx, dword [ebp + 8]
or word [edx + 0x3c], 4
jmp 0x5209c4
push dword [ebp - 4]
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.00520dd8
add esp, 0xc
mov dword [ebp - 8], eax
push dword [ebp - 4]
push dword [ebp + 0xc]
push dword [ebp - 8]
call fcn.004562b8
add esp, 0xc
jmp 0x5209c4
mov ecx, dword [ebp - 0x34]
mov eax, dword [ebp - 4]
mov dword [eax + 0x110], ecx
mov eax, ecx
xor edx, edx
mov ecx, dword [ebp - 4]
mov dword [ecx + 0x118], eax
mov dword [ecx + 0x11c], edx
mov eax, dword [0x7fd784]
dec eax
mov edx, dword [ebp - 4]
mov ecx, dword [edx + 0x110]
add eax, ecx
xor edx, edx
div dword [0x7fd784]
add dword [0x6e75f8], eax
mov eax, dword [ebp - 4]
mov byte [eax + 0x121], 0
push dword [0x7fd780]
push dword [ebp - 4]
push dword [ebp + 8]
call fcn.0051e35c
add esp, 0xc
mov eax, 1
mov esp, ebp
pop ebp
ret