Function at 0x40ab33
Capabilities:
Extract resource via kernel32 functions
Get common file path
Write file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x63f0
call fcn.00408ba0
push esi
push edi
xor eax, eax
mov al, byte [0x416510]
and eax, 1
test eax, eax
jne 0x40ab76
mov cl, byte [0x416510]
or cl, 1
mov byte [0x416510], cl
mov ecx, 0x416508
call fcn.0040c340
push 0x40bac1
call fcn.0040c644
add esp, 4
mov dword [ebp - 0x6138], 0xffffffff
cmp dword [ebp + 0xc], 0
je 0x40ab9e
mov edx, dword [ebp + 0xc]
push edx
lea eax, [ebp - 0x6134]
push eax
call fcn.00406f60
add esp, 8
jmp 0x40add5
mov dword [ebp - 0x627c], 0xffffffff
push 0x100
lea ecx, [ebp - 0x6134]
push ecx
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
push 0x5c
lea edx, [ebp - 0x6134]
push edx
call fcn.00402880
add esp, 8
mov dword [ebp - 0x6284], eax
push 0x415ba4
mov eax, dword [ebp - 0x6284]
push eax
call fcn.00406f60
add esp, 8
lea ecx, [ebp - 0x6278]
push ecx
lea edx, [ebp - 0x6134]
push edx
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov dword [ebp - 0x627c], eax
mov dword [ebp - 0x6280], 0
cmp dword [ebp - 0x627c], 0
je 0x40ac5d
cmp dword [ebp - 0x627c], 0xffffffff
je 0x40ac5d
lea eax, [ebp - 0x624c]
push eax
push 0x5c
lea ecx, [ebp - 0x6134]
push ecx
call fcn.00402880
add esp, 8
add eax, 1
push eax
call fcn.00406f60
add esp, 8
mov edx, dword [ebp - 0x627c]
push edx
call dword [sym.imp.KERNEL32.dll_FindClose]
mov dword [ebp - 0x6280], 1
jmp 0x40adad
mov eax, dword [ebp - 0x6284]
mov byte [eax], 0
push 0x5c
lea ecx, [ebp - 0x6134]
push ecx
call fcn.00402880
add esp, 8
mov dword [ebp - 0x6284], eax
cmp dword [ebp - 0x6284], 0
je 0x40ac9a
push 0x415bac
mov edx, dword [ebp - 0x6284]
push edx
call fcn.00406f60
add esp, 8
lea eax, [ebp - 0x6278]
push eax
lea ecx, [ebp - 0x6134]
push ecx
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov dword [ebp - 0x627c], eax
cmp dword [ebp - 0x627c], 0
je 0x40ad06
cmp dword [ebp - 0x627c], 0xffffffff
je 0x40ad06
lea edx, [ebp - 0x624c]
push edx
push 0x5c
lea eax, [ebp - 0x6134]
push eax
call fcn.00402880
add esp, 8
add eax, 1
push eax
call fcn.00406f60
add esp, 8
mov ecx, dword [ebp - 0x627c]
push ecx
call dword [sym.imp.KERNEL32.dll_FindClose]
mov dword [ebp - 0x6280], 1
jmp 0x40adad
push 0x415bb4
lea edx, [ebp - 0x6134]
push edx
call fcn.0040c492
add esp, 4
push eax
call fcn.00402800
add esp, 8
mov dword [ebp - 0x6284], eax
cmp dword [ebp - 0x6284], 0
je 0x40ad46
push 0x415bbc
mov eax, dword [ebp - 0x6284]
push eax
call fcn.00406f60
add esp, 8
lea ecx, [ebp - 0x6278]
push ecx
lea edx, [ebp - 0x6134]
push edx
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov dword [ebp - 0x627c], eax
cmp dword [ebp - 0x627c], 0
je 0x40adad
cmp dword [ebp - 0x627c], 0xffffffff
je 0x40adad
lea eax, [ebp - 0x624c]
push eax
push 0x5c
lea ecx, [ebp - 0x6134]
push ecx
call fcn.00402880
add esp, 8
add eax, 1
push eax
call fcn.00406f60
add esp, 8
mov edx, dword [ebp - 0x627c]
push edx
call dword [sym.imp.KERNEL32.dll_FindClose]
mov dword [ebp - 0x6280], 1
cmp dword [ebp - 0x627c], 0
jne 0x40add5
push 0x415bc4
push 0x5c
lea eax, [ebp - 0x6134]
push eax
call fcn.00402880
add esp, 8
push eax
call fcn.00406f60
add esp, 8
push 0x3000
push 0
lea ecx, [ebp - 0x6030]
push ecx
call fcn.00407390
add esp, 0xc
cmp dword [0x416558], 0
jne 0x40b076
lea edx, [ebp - 0x3000]
push edx
lea eax, [ebp - 0x6030]
push eax
lea ecx, [ebp - 0x6134]
push ecx
call fcn.0040b44a
add esp, 0xc
test eax, eax
jne 0x40ae20
xor eax, eax
jmp 0x40b444
mov esi, dword [ebp + 8]
mov ecx, 0xc
lea edi, [ebp - 0x3030]
rep movsd dword es:[edi], dword [esi]
lea edx, [ebp - 0x3030]
mov dword [ebp + 8], edx
mov eax, dword [ebp + 8]
mov cl, byte [eax + 0x1f]
mov byte [ebp - 0x6288], cl
mov dword [ebp - 0x6034], 0
jmp 0x40ae60
mov edx, dword [ebp - 0x6034]
add edx, 1
mov dword [ebp - 0x6034], edx
cmp dword [ebp - 0x6034], 8
jae 0x40aea0
mov eax, dword [ebp + 8]
add eax, dword [ebp - 0x6034]
mov cl, byte [eax]
xor cl, byte [ebp - 0x6288]
mov edx, dword [ebp + 8]
add edx, dword [ebp - 0x6034]
mov byte [edx], cl
mov eax, dword [ebp + 8]
add eax, dword [ebp - 0x6034]
mov cl, byte [eax]
xor cl, 0x60
mov edx, dword [ebp + 8]
add edx, dword [ebp - 0x6034]
mov byte [edx], cl
jmp 0x40ae51
mov dword [ebp - 0x6034], 0
jmp 0x40aebb
mov eax, dword [ebp - 0x6034]
add eax, 1
mov dword [ebp - 0x6034], eax
cmp dword [ebp - 0x6034], 0x18
jae 0x40aeff
mov ecx, dword [ebp + 8]
add ecx, dword [ebp - 0x6034]
mov dl, byte [ecx + 8]
xor dl, byte [ebp - 0x6288]
mov eax, dword [ebp + 8]
add eax, dword [ebp - 0x6034]
mov byte [eax + 8], dl
mov ecx, dword [ebp + 8]
add ecx, dword [ebp - 0x6034]
mov dl, byte [ecx + 8]
xor dl, 0x80
mov eax, dword [ebp + 8]
add eax, dword [ebp - 0x6034]
mov byte [eax + 8], dl
jmp 0x40aeac
mov dword [ebp - 0x6034], 0
jmp 0x40af1a
mov ecx, dword [ebp - 0x6034]
add ecx, 1
mov dword [ebp - 0x6034], ecx
cmp dword [ebp - 0x6034], 8
jae 0x40af5d
mov edx, dword [ebp + 8]
add edx, dword [ebp - 0x6034]
mov al, byte [edx + 0x20]
xor al, byte [ebp - 0x6288]
mov ecx, dword [ebp + 8]
add ecx, dword [ebp - 0x6034]
mov byte [ecx + 0x20], al
mov edx, dword [ebp + 8]
add edx, dword [ebp - 0x6034]
mov al, byte [edx + 0x20]
xor al, 0xe0
mov ecx, dword [ebp + 8]
add ecx, dword [ebp - 0x6034]
mov byte [ecx + 0x20], al
jmp 0x40af0b
mov dword [ebp - 0x6034], 0
jmp 0x40af78
mov edx, dword [ebp - 0x6034]
add edx, 1
mov dword [ebp - 0x6034], edx
cmp dword [ebp - 0x6034], 8
jae 0x40afbc
mov eax, dword [ebp + 8]
add eax, dword [ebp - 0x6034]
mov cl, byte [eax + 0x28]
xor cl, byte [ebp - 0x6288]
mov edx, dword [ebp + 8]
add edx, dword [ebp - 0x6034]
mov byte [edx + 0x28], cl
mov eax, dword [ebp + 8]
add eax, dword [ebp - 0x6034]
mov cl, byte [eax + 0x28]
xor cl, 0x88
mov edx, dword [ebp + 8]
add edx, dword [ebp - 0x6034]
mov byte [edx + 0x28], cl
jmp 0x40af69
mov eax, dword [ebp + 8]
mov byte [eax + 0x1f], 0
mov ecx, dword [ebp + 8]
movsx edx, byte [ecx + 0x28]
cmp edx, 0x23
jne 0x40afe5
mov eax, dword [ebp + 8]
movsx ecx, byte [eax + 0x2f]
test ecx, ecx
jne 0x40afe5
mov edx, dword [ebp + 8]
movsx eax, byte [edx]
cmp eax, 0x24
je 0x40afec
mov ecx, dword [ebp + 8]
mov byte [ecx + 8], 0
mov dword [ebp - 0x6138], 0
jmp 0x40b007
mov edx, dword [ebp - 0x6138]
add edx, 1
mov dword [ebp - 0x6138], edx
cmp dword [ebp - 0x6138], 0x80
jge 0x40b076
mov eax, dword [ebp - 0x6138]
imul eax, eax, 0x60
lea ecx, [ebp + eax - 0x6028]
push ecx
mov edx, dword [ebp + 8]
add edx, 8
push edx
call fcn.00406e50
add esp, 8
test eax, eax
jne 0x40b074
mov eax, dword [ebp + 8]
add eax, 0x20
push eax
call fcn.0040c693
fstp qword [ebp - 0x63ec]
add esp, 4
mov ecx, dword [ebp - 0x6138]
imul ecx, ecx, 0x60
lea edx, [ebp + ecx - 0x6010]
push edx
call fcn.0040c693
add esp, 4
fcomp qword [ebp - 0x63ec]
fnstsw ax
test ah, 1
jne 0x40b074
jmp 0x40b076
jmp 0x40aff8
cmp dword [ebp - 0x6138], 0x80
jl 0x40b08f
cmp dword [0x416558], 0
je 0x40b442
mov ecx, 0x416508
call fcn.0040c370
and eax, 0xff
test eax, eax
jne 0x40b2d1
mov dword [ebp - 0x6290], 0
mov dword [ebp - 0x6294], 0
lea eax, [ebp - 0x6294]
push eax
push 0x340053
call dword [sym.imp.SpLicN.dll_Ordinal_3]
add esp, 8
mov dword [ebp - 0x6290], eax
lea ecx, [ebp - 0x639c]
push ecx
push 0x100
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
push 0x415bd4
lea edx, [ebp - 0x639c]
push edx
call fcn.00406f70
add esp, 8
mov eax, dword [ebp - 0x6294]
mov dword [ebp - 0x629c], eax
mov ecx, dword [ebp - 0x6290]
mov dword [ebp - 0x628c], ecx
push 0
push 0
push 2
push 0
push 1
push 0xc0000000
lea edx, [ebp - 0x639c]
push edx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [ebp - 0x6298], eax
cmp dword [ebp - 0x6298], 0xffffffff
je 0x40b2b0
push 0x415bdc
mov eax, dword [ebp - 0x629c]
and eax, 0xffff
push eax
mov ecx, dword [ebp - 0x628c]
push ecx
call dword [sym.imp.KERNEL32.dll_FindResourceA]
mov dword [ebp - 0x63b4], eax
mov edx, dword [ebp - 0x63b4]
push edx
mov eax, dword [ebp - 0x628c]
push eax
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov dword [ebp - 0x63b0], eax
mov ecx, dword [ebp - 0x63b4]
push ecx
mov edx, dword [ebp - 0x628c]
push edx
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov dword [ebp - 0x63ac], eax
mov eax, dword [ebp - 0x63ac]
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov dword [ebp - 0x63a8], eax
mov ecx, dword [ebp - 0x63b0]
add ecx, 8
push ecx
call fcn.0040c685
add esp, 4
mov dword [ebp - 0x63e0], eax
mov edx, dword [ebp - 0x63e0]
mov dword [ebp - 0x63a4], edx
mov eax, dword [ebp - 0x63b0]
push eax
mov ecx, dword [ebp - 0x63a8]
push ecx
mov edx, dword [ebp - 0x63a4]
push edx
call fcn.00407050
add esp, 0xc
mov byte [ebp - 0x63a0], 0x8f
mov eax, dword [ebp - 0x63a4]
mov dword [ebp - 0x63b8], eax
mov dword [ebp - 0x6034], 0
jmp 0x40b22b
mov ecx, dword [ebp - 0x6034]
add ecx, 1
mov dword [ebp - 0x6034], ecx
mov edx, dword [ebp - 0x63b8]
add edx, 1
mov dword [ebp - 0x63b8], edx
mov eax, dword [ebp - 0x6034]
cmp eax, dword [ebp - 0x63b0]
jge 0x40b251
mov ecx, dword [ebp - 0x63b8]
mov dl, byte [ecx]
xor dl, byte [ebp - 0x63a0]
mov eax, dword [ebp - 0x63b8]
mov byte [eax], dl
jmp 0x40b20d
mov ecx, dword [ebp - 0x63a4]
mov byte [ecx], 0x4d
mov edx, dword [ebp - 0x63a4]
mov byte [edx + 1], 0x5a
push 0
lea eax, [ebp - 0x63b0]
push eax
mov ecx, dword [ebp - 0x63b0]
push ecx
mov edx, dword [ebp - 0x63a4]
push edx
mov eax, dword [ebp - 0x6298]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov ecx, dword [ebp - 0x6298]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edx, dword [ebp - 0x63a4]
mov dword [ebp - 0x63e4], edx
mov eax, dword [ebp - 0x63e4]
push eax
call fcn.004022ae
add esp, 4
push fcn.0040aa00
lea ecx, [ebp - 0x639c]
push ecx
mov ecx, 0x416508
call fcn.0040c390
test eax, eax
jne 0x40b2d1
xor eax, eax
jmp 0x40b444
cmp dword [0x416558], 0
je 0x40b2f3
push 0
mov edx, dword [ebp + 8]
push edx
mov eax, dword [ebp + 0xc]
push eax
mov ecx, 0x416508
call fcn.0040c450
jmp 0x40b444
push 0x416554
lea ecx, [ebp - 0x6030]
push ecx
mov edx, dword [ebp + 8]
push edx
mov ecx, 0x416508
call fcn.0040c450
test eax, eax
jne 0x40b318
xor eax, eax
jmp 0x40b444
push 0x10
push 0
lea eax, [ebp - 0x63d8]
push eax
call fcn.00407390
add esp, 0xc
lea ecx, [ebp - 0x63d8]
push ecx
call dword [sym.imp.KERNEL32.dll_GetLocalTime]
mov edx, dword [ebp - 0x6138]
imul edx, edx, 0x60
lea eax, [ebp + edx - 0x2fcc]
mov dword [ebp - 0x63c4], eax
mov ecx, dword [ebp - 0x6138]
imul ecx, ecx, 0x60
lea edx, [ebp + ecx - 0x2fd0]
mov dword [ebp - 0x63bc], edx
mov eax, dword [ebp - 0x63bc]
movsx ecx, byte [eax]
imul ecx, ecx, 0x16e
mov edx, dword [ebp - 0x63bc]
movsx eax, byte [edx + 1]
imul eax, eax, 0x1f
add ecx, eax
mov edx, dword [ebp - 0x63bc]
movsx eax, byte [edx + 2]
add ecx, eax
mov dword [ebp - 0x63c8], ecx
mov ecx, dword [ebp - 0x63c4]
movsx edx, byte [ecx]
imul edx, edx, 0x16e
mov eax, dword [ebp - 0x63c4]
movsx ecx, byte [eax + 1]
imul ecx, ecx, 0x1f
add edx, ecx
mov eax, dword [ebp - 0x63c4]
movsx ecx, byte [eax + 2]
add edx, ecx
mov dword [ebp - 0x63dc], edx
mov edx, dword [ebp - 0x63d8]
and edx, 0xffff
sub edx, 0x7d0
imul edx, edx, 0x16e
mov eax, dword [ebp - 0x63d6]
and eax, 0xffff
imul eax, eax, 0x1f
add edx, eax
mov ecx, dword [ebp - 0x63d2]
and ecx, 0xffff
add edx, ecx
mov dword [ebp - 0x63c0], edx
mov edx, dword [ebp - 0x63c0]
cmp edx, dword [ebp - 0x63c8]
jb 0x40b430
mov eax, dword [ebp - 0x63c0]
cmp eax, dword [ebp - 0x63dc]
ja 0x40b430
mov ecx, dword [ebp - 0x63dc]
sub ecx, dword [ebp - 0x63c0]
mov dword [ebp - 0x63f0], ecx
jmp 0x40b43a
mov dword [ebp - 0x63f0], 0
mov eax, dword [ebp - 0x63f0]
jmp 0x40b444
xor eax, eax
pop edi
pop esi
mov esp, ebp
pop ebp
ret