Function at 0x447f1c
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x430
mov dword [ebp - 0x10], esi
mov esi, edx
mov dword [ebp - 0x18], ebx
mov ebx, eax
mov dword [ebp - 0x14], edi
mov dword [ebp - 0xc], ecx
cmp dword [esi], 3
je 0x448630
mov ecx, dword [ebx + 0x108]
cmp ecx, 0xfffffffc
je 0x4485dc
cmp ecx, 0xfffffffd
je 0x447f7c
cmp ecx, 0xfffffffe
jne 0x447f69
test byte [ebx + 0x181], 4
je 0x447fff
jmp 0x44867e
cmp ecx, 0xffffffff
jne 0x447f9c
test byte [ebx + 0x181], 4
je 0x447fe3
jmp 0x44866c
movzx eax, byte [ebx + 0x181]
test al, 4
je 0x44801b
test byte [ebx + 0x178], 1
jne 0x44801b
jne 0x447fff
jne 0x447fe3
mov edx, dword [esi + 4]
test edx, edx
je 0x44818a
mov eax, dword [esi + 8]
cmp eax, 0x100
lea ecx, [ebp - 0x222]
mov dword [ebp - 8], ecx
jl 0x447fbf
mov eax, 0x100
push eax
push edx
push ecx
mov dword [ebp - 4], eax
call fcn.004cd9d0
add esp, 0xc
mov edi, dword [ebp - 8]
mov eax, dword [ebp - 4]
mov dword [ebp - 0x1c], 1
mov byte [edi + eax], 0
movsx edx, byte [edi]
jmp 0x44805b
push str.FOR_PRINT
call fcn.0047cbc0
mov edi, eax
add esp, 4
mov dword [ebp - 8], edi
test edi, edi
je 0x448337
jmp 0x448035
push str.FOR_TYPE
call fcn.0047cbc0
mov edi, eax
add esp, 4
mov dword [ebp - 8], edi
test edi, edi
je 0x448359
jmp 0x448035
push str.FOR_ACCEPT
call fcn.0047cbc0
mov edi, eax
add esp, 4
mov dword [ebp - 8], edi
test edi, edi
je 0x4485ba
mov dword [ebp - 0x1c], 1
mov ecx, edi
xor eax, eax
movzx edx, byte [ecx + eax]
test edx, edx
je 0x448055
movzx edx, byte [ecx + eax + 1]
add eax, 2
test edx, edx
jne 0x448040
dec eax
mov dword [ebp - 4], eax
movsx edx, byte [edi]
cmp edx, 0x20
jne 0x448071
test eax, eax
jle 0x448084
inc edi
dec eax
mov dword [ebp - 8], edi
mov dword [ebp - 4], eax
cmp byte [edi], 0x20
je 0x448060
test eax, eax
jle 0x448084
test byte [eax + edi - 1], 0xdf
jne 0x4480b2
dec eax
mov dword [ebp - 4], eax
test eax, eax
jg 0x448075
jne 0x4480b2
test byte [ebx + 0x181], 4
je 0x4480b2
mov eax, ebx
lea edx, [ebp - 8]
lea ecx, [ebp - 4]
call fcn.00448690
test eax, eax
jne 0x4480a5
mov edi, dword [ebp - 8]
jmp 0x4480b2
mov ebx, dword [ebp - 0x18]
mov esi, dword [ebp - 0x10]
mov edi, dword [ebp - 0x14]
mov esp, ebp
pop ebp
ret
cmp dword [ebp - 0x1c], 0
jne 0x4480bc
xor ecx, ecx
jmp 0x44812d
mov eax, dword [ebp - 4]
push edi
push ebx
mov byte [edi + eax], 0
call fcn.0042d240
add esp, 8
cmp eax, 0xffffffff
je 0x448397
cmp dword [0x518340], 0
jne 0x4480e4
cmp eax, 0xfffffffa
je 0x448117
cmp eax, 1
je 0x448117
test eax, eax
jne 0x4480f7
push 0xfffffffffffffff6
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
jmp 0x44811f
cmp eax, 2
jne 0x448106
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
jmp 0x44811f
mov dword [ebp - 0x1c], 0
mov ecx, 1
mov edi, dword [ebp - 8]
jmp 0x44812d
push 0xfffffffffffffff5
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
xor ecx, ecx
mov dword [ebx + 0xec], eax
mov dword [ebp - 0x1c], ecx
mov edi, dword [ebp - 8]
mov esi, dword [ebp - 0xc]
mov dl, byte [edi]
inc edi
mov byte [esi], dl
inc esi
test dl, dl
jne 0x448130
mov edx, dword [ebp + 0x14]
cmp dword [0x518340], 0
je 0x44815b
cmp dword [ebp - 0x1c], 0
jne 0x44816a
cmp dword [ebx + 0xec], 0xffffffff
je 0x44837b
jmp 0x44816a
cmp dword [ebp - 0x1c], 0
jne 0x44816a
cmp dword [ebx + 0xec], 0xffffffff
je 0x44816e
test ecx, ecx
je 0x448176
mov dword [edx], 1
jmp 0x44817b
mov eax, dword [ebp - 0x1c]
mov dword [edx], eax
xor eax, eax
mov ebx, dword [ebp - 0x18]
mov esi, dword [ebp - 0x10]
mov edi, dword [ebp - 0x14]
mov esp, ebp
pop ebp
ret
push ecx
push str.FORT_d
lea eax, [ebp - 0x222]
push eax
call fcn.0047c0e0
lea eax, [ebp - 0x222]
push eax
call fcn.0047cbc0
mov edi, eax
add esp, 0x10
mov dword [ebp - 8], edi
test edi, edi
je 0x4481df
mov ecx, edi
xor eax, eax
movzx edx, byte [ecx + eax]
test edx, edx
je 0x4481cd
movzx edx, byte [ecx + eax + 1]
add eax, 2
test edx, edx
jne 0x4481b8
dec eax
mov dword [ebp - 4], eax
movsx edx, byte [edi]
mov dword [ebp - 0x1c], 1
jmp 0x44805b
mov eax, dword [ebx + 0x108]
add eax, 4
cmp eax, 0xa
ja case.0x4481f1.1
jmp dword [eax*4 + 0x4ee76c]
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
mov edi, 0x4eb8c4
mov dword [ebx + 0xec], eax
mov dword [ebp - 8], edi
jmp 0x44823e
push 0xfffffffffffffff5
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
mov edi, 0x4eb8c4
mov dword [ebx + 0xec], eax
mov dword [ebp - 8], edi
jmp 0x44823e
push 0xfffffffffffffff6
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
mov edi, str.CONIN_
mov dword [ebx + 0xec], eax
mov dword [ebp - 8], edi
test edi, edi
je 0x44832b
mov ecx, edi
xor eax, eax
movzx edx, byte [ecx + eax]
test edx, edx
je 0x44825f
movzx edx, byte [ecx + eax + 1]
add eax, 2
test edx, edx
jne 0x44824a
dec eax
mov dword [ebp - 4], eax
movsx edx, byte [edi]
mov dword [ebp - 0x1c], 0
jmp 0x44805b
mov dword [ebp - 0x1c], 1
test byte [ebx + 0x181], 4
jne 0x448316
test byte [ebx + 0x179], 0x20
je 0x4482cb
mov edi, dword [ebx + 0x60]
mov ecx, edi
mov dword [ebp - 8], edi
xor eax, eax
movzx edx, byte [ecx + eax]
test edx, edx
je 0x4482ad
movzx edx, byte [ecx + eax + 1]
add eax, 2
test edx, edx
jne 0x448298
dec eax
mov dword [ebp - 4], eax
cmp dword [esi], 0
je 0x4482c3
mov dword [esi], 0
movsx edx, byte [edi]
jmp 0x44805b
movsx edx, byte [edi]
jmp 0x44805b
push dword [ebx + 0x108]
push str.fort._d
lea eax, [ebp - 0x222]
push eax
call fcn.0047c0e0
add esp, 0xc
lea ecx, [ebp - 0x222]
xor eax, eax
movzx edx, byte [ecx + eax]
test edx, edx
je 0x448302
movzx edx, byte [ecx + eax + 1]
add eax, 2
test edx, edx
jne 0x4482ed
dec eax
mov dword [ebp - 4], eax
lea edi, [ebp - 0x222]
mov dword [ebp - 8], edi
movsx edx, byte [edi]
jmp 0x44805b
xor eax, eax
lea edi, [ebp - 0x222]
mov dword [ebp - 8], edi
mov byte [edi], al
mov dword [ebp - 4], eax
jmp 0x448086
mov dword [ebp - 0x1c], 0
jmp 0x448278
push 0xfffffffffffffff5
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
mov edi, 0x4eb8c4
mov dword [ebx + 0xec], eax
mov dword [ebp - 8], edi
mov dword [ebp - 0x1c], 0
jmp 0x44803c
push 0xfffffffffffffff5
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
mov edi, 0x4eb8c4
mov dword [ebx + 0xec], eax
mov dword [ebp - 8], edi
mov dword [ebp - 0x1c], 0
jmp 0x44803c
test ecx, ecx
jne 0x44816e
mov eax, dword [ebp - 0x1c]
mov dword [ebx + 0xec], 0
mov dword [edx], eax
jmp 0x44817b
mov eax, dword [esi + 0xc]
test byte [ebx + 0x181], 8
jne 0x4483ad
test eax, eax
je 0x44848f
jmp 0x4483b5
test eax, eax
je 0x448594
mov edi, dword [esi + 0x10]
cmp edi, 0xff
jg 0x44842c
push edi
push eax
lea edx, [ebp - 0x121]
push edx
call fcn.004cd9d0
add esp, 0xc
mov byte [ebp + edi - 0x121], 0
lea edx, [ebp - 0x121]
cmp byte [ebp - 0x121], 0x20
jne 0x4483f3
test edi, edi
jle 0x448407
inc edx
dec edi
cmp byte [edx], 0x20
je 0x4483e8
test edi, edi
jle 0x448407
test byte [edi + edx - 1], 0xdf
jne 0x4484c2
dec edi
test edi, edi
jg 0x4483f7
mov dword [ebp - 0x424], 0
cmp dword [esi], 3
je 0x4484d6
mov eax, edi
add eax, dword [ebp - 4]
add eax, dword [ebp - 0x424]
cmp eax, 0x100
jle 0x44843e
mov eax, 0x2b
mov ebx, dword [ebp - 0x18]
mov esi, dword [ebp - 0x10]
mov edi, dword [ebp - 0x14]
mov esp, ebp
pop ebp
ret
push edi
push edx
push dword [ebp - 0xc]
call fcn.004cd9d0
add esp, 0xc
mov eax, dword [ebp - 0xc]
cmp dword [ebp - 0x424], 0
lea edx, [edi + eax]
je 0x448463
movzx eax, byte [0x4ee930]
mov byte [edx], al
push dword [ebp - 4]
push dword [ebp - 8]
add edx, dword [ebp - 0x424]
push edx
call fcn.004cd9d0
add esp, 0xc
mov eax, dword [ebp - 4]
xor ecx, ecx
add eax, dword [ebp - 0xc]
add edi, dword [ebp - 0x424]
mov byte [edi + eax], 0
jmp 0x44813a
lea eax, [ebp - 0x20]
push eax
lea edi, [ebp - 0x121]
push edi
push 0x101
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_GetFullPathNameA]
test eax, eax
je 0x4484b9
cmp eax, 0x101
jae 0x4484b9
mov dword [ebp - 8], edi
mov dword [ebp - 4], eax
xor edx, edx
xor edi, edi
jmp 0x448407
xor eax, eax
cmp byte [edi + edx], 0x5c
setne al
mov dword [ebp - 0x424], eax
jmp 0x448411
test byte [ebx + 0x179], 0x20
jne 0x44841a
cmp dword [esi + 0xc], 0
je 0x448521
lea edi, [ebp - 0x323]
push edi
push 0
push 0x4ee940
push edx
call dword [sym.imp.KERNEL32.dll_GetTempFileNameA]
test byte [ebx + 0x181], 8
je 0x44850d
lea edi, [ebp - 0x321]
mov esi, dword [ebp - 0xc]
mov dl, byte [edi]
inc edi
mov byte [esi], dl
inc esi
test dl, dl
jne 0x448510
xor ecx, ecx
jmp 0x44813a
test byte [ebx + 0x181], 8
je 0x448540
mov byte [ebp - 0x424], 0x2e
lea edx, [ebp - 0x424]
mov byte [ebp - 0x423], 0
jmp 0x4484e9
push str.FORT_TMPDIR
call fcn.0047cbc0
add esp, 4
test eax, eax
je 0x44856e
mov edi, eax
lea esi, [ebp - 0x424]
mov dl, byte [edi]
inc edi
mov byte [esi], dl
inc esi
test dl, dl
jne 0x448559
lea edx, [ebp - 0x424]
jmp 0x4484e9
lea esi, [ebp - 0x424]
push esi
push 0x100
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
test eax, eax
mov edx, esi
jne 0x4484e9
mov edx, 0
jmp 0x4484e9
cmp dword [esi], 3
je 0x4485a3
mov edi, dword [ebp - 8]
xor ecx, ecx
jmp 0x44812d
test byte [ebx + 0x179], 0x20
je 0x44848f
mov edi, dword [ebp - 8]
xor ecx, ecx
jmp 0x44812d
push 0xfffffffffffffff6
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
mov edi, str.CONIN_
mov dword [ebx + 0xec], eax
mov dword [ebp - 8], edi
mov dword [ebp - 0x1c], 0
jmp 0x44803c
movzx eax, byte [ebx + 0x181]
test al, 4
je 0x4485f4
test byte [ebx + 0x178], 1
je 0x447f83
push str.FOR_READ
call fcn.0047cbc0
mov edi, eax
add esp, 4
mov dword [ebp - 8], edi
test edi, edi
jne 0x448035
push 0xfffffffffffffff6
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
mov edi, str.CONIN_
mov dword [ebx + 0xec], eax
mov dword [ebp - 8], edi
mov dword [ebp - 0x1c], 0
jmp 0x44803c
test byte [ebx + 0x179], 0x20
jne 0x447f3e
push str.SCRATCH
lea edi, [ebp - 0x222]
push edi
call fcn.0047c0e0
add esp, 8
mov dword [ebp - 8], edi
mov eax, 7
mov dword [ebp - 4], 7
mov dword [ebp - 0x1c], 1
jmp 0x4480bf
test byte [ebx + 0x178], 1
jne 0x447fe3
jmp 0x447f9c
test byte [ebx + 0x178], 1
jne 0x447fff
jmp 0x447f9a