Function at 0x403b70
Capabilities:
Get common file path

Disassembly:
sub esp, 0x1c4
push ebx
push ebp
push esi
push edi
push 0x1c
lea eax, [esp + 0x124]
push eax
mov edi, 0x104
xor ebx, ebx
push fcn.00403a70
mov dword [esp + 0x1c], edi
mov byte [esp + 0x28], bl
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
mov ebp, dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
jne 0x403bac
xor eax, eax
jmp 0x403be1
mov edx, dword [esp + 0x124]
push 0x103
lea ecx, [esp + 0x20]
push ecx
push edx
call ebp
mov byte [esp + eax + 0x1c], bl
lea eax, [esp + 0x1c]
push eax
call fcn.00403440
lea eax, [esp + 0x20]
add esp, 4
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
cmp cl, bl
jne 0x403bd8
sub eax, edx
mov edx, dword [esp + 0x10]
mov esi, dword [esp + 0x1d8]
sub edx, eax
cmp eax, ebx
mov dword [esp + 0x10], edx
jbe 0x403c1d
push ebx
push ebx
mov ecx, edx
push esi
push ecx
lea edx, [esp + eax + 0x2c]
push edx
call fcn.004076f0
lea eax, [esp + 0x30]
push 4
push eax
call fcn.00406710
add esp, 0x1c
test eax, eax
je 0x40406b
push 0x103
lea ecx, [esp + 0x20]
push ecx
push ebx
mov dword [esp + 0x1c], edi
call ebp
lea edx, [esp + 0x1c]
push edx
mov byte [esp + eax + 0x20], bl
call fcn.00403440
lea eax, [esp + 0x20]
add esp, 4
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
cmp cl, bl
jne 0x403c46
sub eax, edx
mov edx, dword [esp + 0x10]
sub edx, eax
cmp eax, ebx
mov dword [esp + 0x10], edx
jbe 0x403c84
push ebx
push ebx
mov ecx, edx
push esi
push ecx
lea edx, [esp + eax + 0x2c]
push edx
call fcn.004076f0
lea eax, [esp + 0x30]
push 4
push eax
call fcn.00406710
add esp, 0x1c
test eax, eax
je 0x40406b
push ebx
push ebx
push esi
lea ecx, [esp + 0x28]
push edi
push ecx
call fcn.004076b0
lea edx, [esp + 0x30]
push 4
push edx
call fcn.00406710
add esp, 0x1c
test eax, eax
je 0x40406b
mov eax, esi
call fcn.00403ad0
mov edi, eax
cmp dword [esp + 0x1e4], ebx
je 0x403d47
push 0x96
lea eax, [esp + 0x140]
push eax
push str.SYBASE
call fcn.00407560
add esp, 0xc
cmp eax, ebx
je 0x403d47
push ebx
push ebx
push eax
lea ecx, [esp + 0x28]
push 0x104
push ecx
call fcn.004076b0
lea edx, [esp + 0x30]
push ebx
push edx
call fcn.004033b0
push ebx
push ebx
push 0x416458
lea eax, [esp + 0x44]
push 0x104
push eax
call fcn.004076f0
lea ecx, [esp + 0x4c]
push ebx
push ecx
call fcn.004033b0
push ebx
push ebx
push esi
lea edx, [esp + 0x60]
push 0x104
push edx
call fcn.004076f0
add esp, 0x4c
lea eax, [esp + 0x1c]
push 4
push eax
call fcn.00406710
add esp, 8
test eax, eax
je 0x40406b
mov eax, str.win32_
lea edx, [eax + 1]
nop
mov cl, byte [eax]
inc eax
cmp cl, bl
jne 0x403d50
sub eax, edx
mov dword [esp + 0x18], eax
je 0x403e95
push edi
push str.win32_
call fcn.0040a866
add esp, 8
test eax, eax
je 0x403e95
lea ecx, [esp + 0x1c]
push 0x104
push ecx
call fcn.00403a70
add esp, 8
cmp eax, ebx
jbe 0x403df7
lea edx, [esp + 0x10]
push edx
lea edx, [esp + 0x18]
push edx
mov ecx, 0x104
sub ecx, eax
push 0x416454
push ecx
lea eax, [esp + eax + 0x2c]
push eax
mov dword [esp + 0x24], ecx
call fcn.004076f0
mov eax, dword [esp + 0x24]
lea ecx, [esp + 0x24]
push ecx
mov ecx, dword [esp + 0x2c]
lea edx, [esp + 0x2c]
push edx
push edi
push eax
push ecx
call fcn.004076f0
mov edx, dword [esp + 0x38]
mov eax, dword [esp + 0x3c]
push ebx
push ebx
push esi
push edx
push eax
call fcn.004076f0
lea ecx, [esp + 0x58]
push 4
push ecx
call fcn.00406710
add esp, 0x44
test eax, eax
je 0x40406b
push 0x103
lea edx, [esp + 0x20]
push edx
push ebx
call ebp
mov byte [esp + eax + 0x1c], bl
lea eax, [esp + 0x1c]
push eax
call fcn.00403440
lea eax, [esp + 0x20]
add esp, 4
lea edx, [eax + 1]
lea esp, [esp]
mov cl, byte [eax]
inc eax
cmp cl, bl
jne 0x403e20
sub eax, edx
mov ecx, eax
je 0x403e95
lea edx, [esp + 0x10]
push edx
lea edx, [esp + 0x18]
push edx
mov eax, 0x104
sub eax, ecx
push 0x416454
push eax
mov dword [esp + 0x20], eax
lea eax, [esp + ecx + 0x2c]
push eax
call fcn.004076f0
mov eax, dword [esp + 0x24]
lea ecx, [esp + 0x24]
push ecx
mov ecx, dword [esp + 0x2c]
lea edx, [esp + 0x2c]
push edx
push edi
push eax
push ecx
call fcn.004076f0
mov edx, dword [esp + 0x38]
mov eax, dword [esp + 0x3c]
push ebx
push ebx
push esi
push edx
push eax
call fcn.004076f0
lea ecx, [esp + 0x58]
push 4
push ecx
call fcn.00406710
add esp, 0x44
test eax, eax
je 0x40406b
push 0x104
lea edx, [esp + 0x20]
push edx
push str.Location
push 0x415218
mov byte [esp + 0x2c], bl
call fcn.00407540
add esp, 0x10
test eax, eax
je 0x403f07
lea eax, [esp + 0x1c]
push ebx
push eax
call fcn.004033b0
lea ecx, [esp + 0x18]
push ecx
lea edx, [esp + 0x20]
push edx
push edi
lea eax, [esp + 0x30]
push 0x104
push eax
call fcn.004076f0
mov ecx, dword [esp + 0x2c]
mov edx, dword [esp + 0x30]
push ebx
push ebx
push esi
push ecx
push edx
call fcn.004076f0
lea eax, [esp + 0x4c]
push 4
push eax
call fcn.00406710
add esp, 0x38
test eax, eax
je 0x40406b
push 0x104
lea ecx, [esp + 0x20]
push ecx
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
lea edx, [esp + 0x1c]
push ebx
push edx
call fcn.004033b0
push ebx
push ebx
push esi
lea eax, [esp + 0x30]
push 0x104
push eax
call fcn.004076f0
lea ecx, [esp + 0x38]
push 4
push ecx
call fcn.00406710
add esp, 0x24
test eax, eax
je 0x40406b
push 0x104
lea edx, [esp + 0x20]
push edx
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
lea eax, [esp + 0x1c]
push ebx
push eax
call fcn.004033b0
push ebx
push ebx
push esi
lea ecx, [esp + 0x30]
push 0x104
push ecx
call fcn.004076f0
lea edx, [esp + 0x38]
push 4
push edx
call fcn.00406710
add esp, 0x24
test eax, eax
je 0x40406b
lea eax, [esp + 0x1c]
push eax
push str.PATH
push esi
call fcn.0040a74d
mov al, byte [esp + 0x28]
add esp, 0xc
cmp al, bl
jne 0x40406b
push 0x96
lea ecx, [esp + 0x140]
push ecx
push str.ASDIR
call fcn.00407560
add esp, 0xc
cmp eax, ebx
jne 0x40400c
push 0x96
lea edx, [esp + 0x140]
push edx
push str.ASANY9
call fcn.00407560
add esp, 0xc
cmp eax, ebx
jne 0x40400c
push 0x96
lea eax, [esp + 0x140]
push eax
push str.ASANY
call fcn.00407560
add esp, 0xc
cmp eax, ebx
je 0x4040b0
push ebx
push ebx
push eax
lea ecx, [esp + 0x28]
push 0x104
push ecx
call fcn.004076b0
lea edx, [esp + 0x30]
push ebx
push edx
call fcn.004033b0
lea eax, [esp + 0x2c]
push eax
lea ecx, [esp + 0x34]
push ecx
push edi
lea edx, [esp + 0x44]
push 0x104
push edx
call fcn.004076f0
mov eax, dword [esp + 0x40]
mov ecx, dword [esp + 0x44]
push ebx
push ebx
push esi
push eax
push ecx
call fcn.004076f0
add esp, 0x44
lea edx, [esp + 0x1c]
push 4
push edx
call fcn.00406710
add esp, 8
test eax, eax
jne 0x4040b0
lea eax, [esp + 0x1c]
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
cmp cl, bl
jne 0x404072
sub eax, edx
mov esi, eax
mov eax, dword [esp + 0x1e0]
lea ecx, [esi + 1]
cmp ecx, eax
ja 0x4040a3
push ebx
push ebx
lea edx, [esp + 0x24]
push edx
push eax
mov eax, dword [esp + 0x1ec]
push eax
call fcn.004076b0
add esp, 0x14
pop edi
mov eax, esi
pop esi
pop ebp
pop ebx
add esp, 0x1c4
ret
mov ecx, dword [esp + 0x1dc]
pop edi
pop esi
pop ebp
mov byte [ecx], bl
xor eax, eax
pop ebx
add esp, 0x1c4
ret