Function at 0x4090f0
Capabilities:
Get common file path
Resolve function by parsing pe exports
Write file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x41e688
mov eax, dword fs:[0]
push eax
sub esp, 0xe0
mov eax, dword [0x426020]
xor eax, esp
mov dword [esp + 0xd8], eax
push ebx
push esi
push edi
mov eax, dword [0x426020]
xor eax, esp
push eax
lea eax, [esp + 0xf0]
mov dword fs:[0], eax
fldz
xor eax, eax
mov dword [esp + 0x54], eax
mov dword [esp + 0x70], eax
mov dword [esp + 0x34], eax
xor ecx, ecx
mov word [esp + 0x2c], cx
fst dword [esp + 0x80]
fldz
xor edx, edx
fstp qword [esp + 0x3c]
mov dword [esp + 0x44], eax
mov dword [esp + 0x48], eax
fst dword [esp + 0x30]
fstp dword [esp + 0x64]
mov dword [esp + 0x4c], eax
mov word [esp + 0x28], dx
movzx ecx, word [0x4231d4]
imul ecx, ecx, 0xe6651507
mov word [0x4231d4], cx
mov dword [esp + 0xa0], 0xf
mov dword [esp + 0x9c], eax
mov byte [esp + 0x8c], al
push 0x118
mov dword [esp + 0xfc], eax
call fcn.0040b2a8
push eax
mov dword [esp + 0x8c], eax
call fcn.004019b0
add esp, 8
mov edx, dword [esp + 0x4c]
mov dword [esp + 0x38], edx
fild dword [esp + 0x38]
fadd dword [0x425bec]
call fcn.0040b410
mov dword [esp + 0x54], eax
fld dword [0x425bec]
fadd qword [0x41f370]
push 0
fstp dword [0x425bec]
call fcn.0040b17a
mov esi, dword [esp + 0x4c]
add esp, 4
cmp edx, esi
mov dword [esp + 0x74], eax
mov dword [esp + 0x78], edx
jg 0x40921a
jl 0x40920c
cmp eax, dword [esp + 0x44]
jae 0x40921a
xor esi, esi
mov dword [esp + 0x44], 0
mov dword [esp + 0x48], esi
mov cx, word [0x4232a8]
movsx edi, cx
mov ecx, 0xd859a378
sub ecx, edi
mov di, word [esp + 0x28]
movsx ebx, di
mov edi, 1
add word [0x4232a8], di
add ebx, 0x40e4f7c8
cmp ebx, ecx
je 0x409260
mov ecx, dword [0x424e88]
add ecx, 0x837856c
mov word [esp + 0x2c], cx
add dword [0x424e88], edi
sub eax, dword [esp + 0x44]
sbb edx, esi
mov dword [esp + 0x18], edx
js 0x409c28
jg 0x40927d
cmp eax, 0x708
jbe 0x409c28
mov esi, dword [esp + 0x74]
mov edx, dword [esp + 0x78]
mov dword [esp + 0x44], esi
shr esi, 9
push 0x408
lea edi, [esi + 0x55]
push 0x423350
mov dword [esp + 0x50], edx
mov dword [esp + 0x40], 0
mov dword [esp + 0x58], esi
mov dword [esp + 0x1c], edi
call fcn.00401450
push 0xd
push 0x425ecc
mov dword [esp + 0x8c], eax
call fcn.00401450
push 0xaf1
push 0x424ea8
mov dword [esp + 0x84], eax
call fcn.00401450
push 0x31e
push 0x423f70
mov dword [esp + 0x88], eax
call fcn.00401450
add esp, 0x20
mov dword [esp + 0x60], eax
cmp esi, edi
je 0x409888
mov eax, dword [0x427820]
push 0
push eax
call fcn.00401170
add esp, 8
test eax, eax
jne 0x40932a
mov ecx, dword [0x427828]
mov edx, dword [0x427364]
push ecx
push edx
call fcn.00402620
add esp, 8
movzx eax, word [0x425b50]
movsx ecx, ax
mov dword [esp + 0x1c], ecx
fild dword [esp + 0x1c]
fld dword [0x4231c8]
fsub qword [0x41f9d8]
fsubp st(1)
call fcn.0040b410
mov edx, dword [esp + 0x50]
mov ecx, dword [esp + 0x68]
mov word [0x425b50], ax
fld dword [0x4231c8]
mov eax, dword [esp + 0x60]
fadd qword [0x41f370]
push edx
push eax
push ecx
fstp dword [0x4231c8]
lea edx, [esp + 0xb0]
push edx
call fcn.00402270
push 0x8b
push 0x4259b0
call fcn.00401450
fld qword [0x423180]
fadd qword [0x41f370]
mov ebx, eax
add esp, 0x18
fstp qword [0x423180]
fld qword [0x423180]
movzx eax, word [0x4239a0]
fadd qword [0x41f9d0]
movsx ecx, ax
mov dword [esp + 0x1c], ecx
fild dword [esp + 0x1c]
fsubp st(1)
fcomp qword [0x41f9c8]
fnstsw ax
test ah, 0x44
jp 0x4093f7
mov dx, word [0x425b5c]
movsx eax, dx
mov dword [esp + 0x1c], eax
fild dword [esp + 0x1c]
fadd dword [esp + 0x64]
fstp dword [esp + 0x64]
inc word [0x425b5c]
mov eax, dword [esp + 0x6c]
mov esi, eax
lea ecx, [ecx]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x409400
mov edi, ebx
sub eax, esi
dec edi
lea esp, [esp]
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x409410
mov ecx, eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
push 0x2710
rep movsb byte es:[edi], byte [esi]
push 0
lea ecx, [esp + 0x90]
push ecx
lea edx, [esp + 0xb0]
push ebx
push edx
call fcn.00408870
push 0x8b
fldz
push 0
mov dword [esp + 0x38], 0
fstp qword [esp + 0x38]
push ebx
call fcn.0040b830
push ebx
call fcn.0040b1cb
mov eax, dword [esp + 0xb0]
add esp, 0x24
cmp dword [esp + 0xa0], 0x10
jae 0x40947f
lea eax, [esp + 0x8c]
mov ecx, dword [esp + 0x9c]
mov edx, dword [esp + 0x7c]
push ecx
push eax
push edx
call fcn.00408500
add esp, 0xc
cmp eax, 9
jl 0x409814
mov ecx, dword [esp + 0x8c]
mov edi, 0x10
cmp dword [esp + 0xa0], edi
jae 0x4094ba
lea ecx, [esp + 0x8c]
mov edx, dword [ecx]
xor ecx, ecx
cmp ecx, dword [esp + 0x78]
jg 0x4094e3
jl 0x4094cc
cmp edx, dword [esp + 0x74]
jae 0x4094e3
fld dword [esp + 0x30]
fsubr qword [0x41f9c0]
fmul qword [esp + 0x3c]
fstp qword [esp + 0x3c]
jmp 0x409814
lea esi, [eax - 1]
cmp esi, dword [esp + 0x9c]
jbe 0x4094f4
call fcn.0040c1bc
mov eax, dword [esp + 0x8c]
cmp dword [esp + 0xa0], edi
jae 0x40950b
lea eax, [esp + 0x8c]
mov byte [eax + esi], 0
mov esi, dword [esp + 0xa0]
mov ebx, dword [esp + 0x8c]
mov eax, ebx
cmp esi, edi
jae 0x40952a
lea eax, [esp + 0x8c]
lea ecx, [esp + 0xa4]
add eax, 8
mov dl, byte [eax]
cmp dl, byte [ecx]
jne 0x409554
test dl, dl
je 0x409550
mov dl, byte [eax + 1]
cmp dl, byte [ecx + 1]
jne 0x409554
add eax, 2
add ecx, 2
test dl, dl
jne 0x409534
xor eax, eax
jmp 0x409559
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
jne 0x409814
cmp esi, edi
jb 0x409609
mov edi, ebx
test ebx, ebx
je 0x40959c
mov eax, ebx
cmp esi, 0x10
jae 0x40957d
lea eax, [esp + 0x8c]
cmp eax, edi
ja 0x40959c
mov eax, ebx
cmp esi, 0x10
jae 0x40958f
lea eax, [esp + 0x8c]
mov ecx, dword [esp + 0x9c]
add eax, ecx
cmp edi, eax
jbe 0x4095a1
call fcn.0040c1bc
mov dx, word [0x425f28]
mov cx, word [esp + 0x2c]
inc dword [esp + 0x2c]
movsx eax, dx
movsx edx, cx
sub eax, edx
lea esi, [esp + 0x88]
mov dword [esp + 0x5c], edi
cmp eax, 0x64836077
je 0x409650
mov eax, dword [esp + 0x70]
add eax, 0x16923a7e
mov dword [esp + 0x1c], eax
fild dword [esp + 0x1c]
fld dword [esp + 0x30]
fucompp
fnstsw ax
test ah, 0x44
jnp 0x409615
mov cx, word [esp + 0x28]
movsx edx, cx
mov ecx, dword [esp + 0x54]
mov eax, 0x8f1a2a5b
sub eax, edx
imul eax, ecx
mov dword [esp + 0x54], eax
jmp 0x409650
lea edi, [esp + 0x8c]
jmp 0x40956f
fld qword [0x423278]
fsub qword [0x41f370]
fstp qword [0x423278]
fld qword [0x423278]
mov dx, word [esp + 0x2c]
movsx eax, dx
mov dword [esp + 0x1c], eax
fild dword [esp + 0x1c]
faddp st(1)
call fcn.0040b410
mov word [esp + 0x2c], ax
lea esp, [esp]
mov edx, dword [esp + 0xa0]
mov ebx, dword [esp + 0x8c]
mov eax, ebx
cmp edx, 0x10
jae 0x40966c
lea eax, [esp + 0x8c]
mov ecx, dword [esp + 0x9c]
lea edi, [eax + ecx]
test edi, edi
je 0x4096a0
mov eax, ebx
cmp edx, 0x10
jae 0x409688
lea eax, [esp + 0x8c]
cmp eax, edi
ja 0x4096a0
mov eax, ebx
cmp edx, 0x10
jae 0x40969a
lea eax, [esp + 0x8c]
add eax, ecx
cmp edi, eax
jbe 0x4096a5
call fcn.0040c1bc
cmp esi, 0xfffffffc
je 0x4096be
test esi, esi
je 0x4096b9
lea ecx, [esp + 0x88]
cmp esi, ecx
je 0x4096be
call fcn.0040c1bc
cmp dword [esp + 0x5c], edi
je 0x409738
cmp esi, 0xfffffffc
je 0x4096f0
test esi, esi
jne 0x4096d2
call fcn.0040c1bc
cmp dword [esi + 0x18], 0x10
jb 0x4096dd
mov eax, dword [esi + 4]
jmp 0x4096e0
lea eax, [esi + 4]
mov edx, dword [esi + 0x14]
add edx, eax
cmp dword [esp + 0x5c], edx
jb 0x4096f0
call fcn.0040c1bc
mov eax, dword [esp + 0x5c]
mov byte [eax], 0
cmp esi, 0xfffffffc
je 0x409723
test esi, esi
jne 0x409705
call fcn.0040c1bc
cmp dword [esi + 0x18], 0x10
jb 0x409710
mov eax, dword [esi + 4]
jmp 0x409713
lea eax, [esi + 4]
mov ecx, dword [esi + 0x14]
add ecx, eax
cmp dword [esp + 0x5c], ecx
jb 0x409723
call fcn.0040c1bc
fld qword [0x41f9b8]
inc dword [esp + 0x5c]
fstp qword [0x423328]
jmp 0x409650
push 0x7e
push 0x4259b0
call fcn.00401450
xor ebx, ebx
push ebx
push ebx
lea edx, [esp + 0x98]
mov esi, eax
push edx
lea eax, [esp + 0xb8]
push esi
push eax
call fcn.00408870
fldz
push 0x7e
push ebx
mov dword [esp + 0x40], ebx
fstp qword [esp + 0x40]
push esi
call fcn.0040b830
push esi
call fcn.0040b1cb
push 0xc
push 0x42314c
call fcn.00401450
add esp, 0x34
mov esi, eax
lea ecx, [eax + 1]
lea ecx, [ecx]
mov dl, byte [eax]
inc eax
test dl, dl
jne 0x409790
sub eax, ecx
push eax
push 0xffffffffffffffff
push esi
lea ecx, [esp + 0x94]
call fcn.00404750
mov ecx, dword [0x425e04]
mov dword [esp + 0x1c], ecx
fild dword [esp + 0x1c]
mov edi, eax
fld qword [0x423778]
fadd qword [0x41f9b0]
fadd qword [0x41f9a8]
fsubp st(1)
call fcn.0040b410
mov dword [0x425e04], eax
fld qword [0x423778]
fadd qword [0x41f370]
xor eax, eax
push esi
fstp qword [0x423778]
mov dword [esi], eax
fldz
mov dword [esi + 4], eax
mov dword [esp + 0x20], ebx
fstp qword [esp + 0x20]
mov dword [esi + 8], eax
call fcn.0040b1cb
mov edx, dword [esp + 0xa0]
add edx, 0xfffffff5
add esp, 4
cmp edi, edx
je 0x409829
mov eax, dword [esp + 0x50]
inc eax
mov dword [esp + 0x50], eax
cmp eax, dword [esp + 0x14]
jne 0x409300
jmp 0x409888
push 0xb
push edi
lea ecx, [esp + 0x90]
call fcn.00405000
mov eax, dword [esp + 0x70]
add eax, 0x5fd2305
mov dword [esp + 0x14], eax
fild dword [esp + 0x14]
mov dword [esp + 0x38], 1
fsub qword [0x425ef0]
fcomp qword [0x41f9a0]
fnstsw ax
fld qword [0x425ef0]
fadd qword [0x41f370]
fstp qword [0x425ef0]
test ah, 1
jne 0x409888
fld dword [0x423824]
fadd qword [0x41f998]
fstp dword [0x423824]
fldz
mov esi, dword [esp + 0x7c]
xor edi, edi
push 0x408
push edi
mov dword [esp + 0x1c], edi
fstp qword [esp + 0x1c]
push esi
call fcn.0040b830
push esi
call fcn.0040b1cb
fldz
mov ecx, dword [esp + 0x7c]
xor eax, eax
mov dword [ecx], eax
mov dword [ecx + 4], eax
mov dword [ecx + 8], eax
mov dword [esp + 0x24], edi
fstp qword [esp + 0x24]
push ecx
mov byte [ecx + 0xc], al
call fcn.0040b1cb
fldz
mov esi, dword [esp + 0x74]
push 0x31e
push edi
mov dword [esp + 0x30], edi
fstp qword [esp + 0x30]
push esi
call fcn.0040b830
push esi
call fcn.0040b1cb
fldz
mov cx, word [0x42386c]
mov edx, dword [0x425e14]
mov esi, dword [esp + 0x8c]
movsx eax, cx
sub eax, edx
sub eax, 0x4d21e8dd
mov word [0x42386c], ax
dec dword [0x425e14]
push 0xaf1
push edi
mov dword [esp + 0x40], edi
push esi
fstp qword [esp + 0x44]
call fcn.0040b830
push esi
call fcn.0040b1cb
push 0x40
lea eax, [esp + 0xdc]
push edi
push eax
call fcn.0040b830
add esp, 0x40
cmp dword [esp + 0x38], edi
je 0x409c28
mov ecx, dword [esp + 0x84]
push 0x708
push ecx
call fcn.00403120
add esp, 8
cmp dword [esp + 0x9c], 0x200
jbe 0x409c28
push 0x370
call fcn.0040b2a8
add esp, 4
mov ebx, eax
push ebx
push 0xeb
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
fld dword [esp + 0x30]
fsub qword [0x41f990]
call fcn.0040b410
mov word [esp + 0x28], ax
fld dword [esp + 0x30]
fsub qword [0x41f370]
fstp dword [esp + 0x30]
call dword [sym.imp.KERNEL32.dll_GetTickCount]
push eax
push ebx
call fcn.00401810
inc dword [esp + 0x3c]
mov edx, dword [esp + 0x3c]
mov dword [esp + 0x1c], edx
fild dword [esp + 0x1c]
push 3
push 0x423f60
fadd qword [esp + 0x4c]
fstp qword [esp + 0x4c]
call fcn.00401450
mov esi, eax
push esi
push ebx
call fcn.0040bd2e
fldz
mov edi, eax
xor eax, eax
mov dword [esp + 0x2c], eax
fstp qword [esp + 0x2c]
mov word [esi], ax
push esi
mov byte [esi + 2], al
call fcn.0040b1cb
mov eax, dword [0x423830]
mov dword [esp + 0x30], eax
fild dword [esp + 0x30]
add esp, 0x1c
fld dword [0x425ebc]
fadd qword [0x41f988]
fcompp
fnstsw ax
fld dword [0x425ebc]
fsub qword [0x41f370]
fstp dword [0x425ebc]
test ah, 5
jp 0x409a82
mov ecx, dword [0x425e2c]
inc dword [0x425e2c]
sub ecx, 0xf2ca08c
cmp ecx, 0x561a5f9c
je 0x409a82
movzx edx, word [0x425e08]
movsx ecx, dx
movzx edx, word [0x423f18]
mov eax, 0x1e442c39
sub eax, ecx
movsx ecx, dx
mov edx, dword [0x42326c]
sub eax, ecx
imul edx, eax
mov dword [0x42326c], edx
cmp dword [esp + 0xa0], 0x10
mov eax, dword [esp + 0x8c]
jae 0x409a9a
lea eax, [esp + 0x8c]
mov ecx, dword [esp + 0x9c]
push edi
push 1
push ecx
push eax
call fcn.0040bbe8
fld dword [0x4237a4]
fadd dword [esp + 0x40]
push edi
fadd qword [0x41f980]
fadd dword [0x425e68]
fstp dword [0x425e68]
call fcn.0040ba0a
add esp, 0x14
push 0x104
lea eax, [ebx + 0x104]
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
push 0x15
push 0x425b18
call fcn.00401450
push 0x20
push 0x423ea0
mov edi, eax
call fcn.00401450
fld qword [0x423988]
fadd qword [0x41f978]
mov esi, eax
add esp, 0x10
fcomp qword [0x41f970]
fnstsw ax
fld qword [0x423988]
fadd qword [0x41f370]
fstp qword [0x423988]
test ah, 0x41
jp 0x409b3d
mov edx, dword [esp + 0x34]
add edx, 0x1309a7d9
mov word [esp + 0x28], dx
mov eax, dword [0x427820]
push eax
push esi
lea eax, [ebx + 0x104]
push eax
push edi
lea eax, [ebx + 0x208]
push 0x168
push eax
call fcn.0040b8e4
fldz
xor eax, eax
mov dword [esi], eax
mov dword [esi + 4], eax
mov dword [esi + 8], eax
mov dword [esi + 0xc], eax
mov dword [esi + 0x10], eax
mov dword [esi + 0x14], eax
mov dword [esp + 0x2c], eax
fstp qword [esp + 0x2c]
mov dword [esi + 0x18], eax
push esi
mov dword [esi + 0x1c], eax
call fcn.0040b1cb
fldz
xor eax, eax
mov dword [edi], eax
mov dword [edi + 4], eax
mov dword [edi + 8], eax
mov dword [edi + 0xc], eax
mov dword [esp + 0x30], eax
fstp qword [esp + 0x30]
mov dword [edi + 0x10], eax
push edi
mov byte [edi + 0x14], al
call fcn.0040b1cb
mov ecx, dword [0x427820]
push 1
push ecx
call fcn.00401170
lea eax, [ebx + 0x208]
push eax
push ebx
call fcn.00402620
mov dx, word [esp + 0x58]
movsx eax, dx
add eax, dword [esp + 0x64]
add esp, 0x30
mov dword [esp + 0x14], eax
fild dword [esp + 0x14]
fld dword [esp + 0x80]
dec dword [esp + 0x28]
fsub qword [0x41f968]
fucompp
fnstsw ax
test ah, 0x44
jnp 0x409c07
fld qword [0x423338]
fsub qword [0x41f960]
fstp qword [0x423338]
push 0x370
push 0
push ebx
call fcn.0040b830
push ebx
call fcn.0040b1cb
add esp, 0x10
push 0x15f90
call dword [sym.imp.KERNEL32.dll_Sleep]
push 0x3e8
call dword [sym.imp.KERNEL32.dll_Sleep]
fld dword [0x425e10]
mov ecx, dword [esp + 0x4c]
fadd qword [0x41f958]
mov dword [esp + 0x14], ecx
fild dword [esp + 0x14]
fmulp st(1)
call fcn.0040b410
mov edx, dword [0x427820]
push 0
push edx
mov dword [esp + 0x54], eax
call fcn.00401170
add esp, 8
test eax, eax
jne 0x4091bd
fld qword [esp + 0x3c]
fadd qword [0x41f370]
fstp qword [esp + 0x3c]
mov ax, word [0x4231b8]
movsx ecx, ax
mov dword [esp + 0x14], ecx
fild dword [esp + 0x14]
fld qword [esp + 0x3c]
fadd qword [esp + 0x3c]
fsubp st(1)
call fcn.0040b410
mov edx, dword [0x427828]
mov word [0x4231b8], ax
mov eax, dword [0x427364]
push edx
push eax
call fcn.00402620
jmp 0x4091ba