Function at 0x40a810
Capabilities:
Accept command line arguments
Delete file
Read .ini file
Resolve function by parsing pe exports

Disassembly:
push 0xffffffffffffffff
push 0x43f548
mov eax, dword fs:[0]
push eax
mov eax, 0x24a8
call fcn.0042a970
mov eax, dword [0x453544]
xor eax, esp
mov dword [esp + 0x24a0], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x453544]
xor eax, esp
push eax
lea eax, [esp + 0x24bc]
mov dword fs:[0], eax
mov ebp, dword [esp + 0x24cc]
lea eax, [esp + 0x50]
mov esi, ecx
push eax
mov dword [esp + 0x30], ebp
mov dword [esp + 0x58], esi
call dword [sym.imp.KERNEL32.dll_GetCommandLineW]
push eax
call dword [sym.imp.SHELL32.dll_CommandLineToArgvW]
mov ebx, eax
test ebx, ebx
je 0x40b316
cmp dword [esp + 0x50], 1
jle 0x40b316
lea ecx, [esp + 0x58]
call fcn.0041a427
mov dword [esp + 0x24c4], 0
mov ecx, dword [ebx + 4]
push 0
push ecx
lea ecx, [esp + 0x60]
call fcn.0041a4b5
test eax, eax
je 0x40a9ef
mov edx, dword [ebx + 4]
push edx
push 0
push str.status
push 0x448958
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileIntW]
test eax, eax
je 0x40b297
push 0
lea eax, [esp + 0x74]
push eax
push 0x14
push 0x30
mov dword [esp + 0x80], 0x14
call dword [sym.imp.USER32.dll_SystemParametersInfoW]
mov ecx, dword [esp + 0x7c]
mov eax, dword [esp + 0x78]
push 0
push ecx
push eax
push 0
push 0
mov edi, ecx
push 0
mov ecx, ebp
mov esi, eax
call fcn.00412d2d
push 0
push edi
push esi
push 0
push 0
add ebp, 0x74
push 0
mov ecx, ebp
call fcn.00412d2d
mov ecx, dword [ebx + 4]
push ecx
push 0x3ff
lea edx, [esp + 0xcbc]
push edx
push 0x4471b0
push str.ServerIp
push str.login
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringW]
lea eax, [esp + 0xcb4]
push eax
call fcn.00401380
add esp, 4
mov esi, eax
lea edi, [eax + 1]
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x40a958
sub eax, edi
mov ecx, esi
call fcn.004043f0
push eax
mov dword [esp + 0x1c], eax
call fcn.004013e0
add esp, 4
push 0
push 0x447f38
push 0x4474e0
mov ecx, 0x457880
mov edi, eax
call fcn.0041361e
cmp eax, 1
jne 0x40aa1b
push edi
lea ecx, [esp + 0x18]
call fcn.00401c70
lea ecx, [esp + 0x14]
mov byte [esp + 0x24c4], 1
call fcn.00404480
test al, al
jne 0x40aa0a
lea ecx, [esp + 0x18]
push ecx
mov ecx, 0x28f0
call fcn.0040b4c0
add esp, 4
push 0
mov byte [esp + 0x24c8], 2
mov eax, dword [eax]
push 0
push eax
call fcn.00416dca
lea ecx, [esp + 0x18]
call fcn.00401730
lea ecx, [esp + 0x14]
call fcn.00401730
lea ecx, [esp + 0x58]
mov dword [esp + 0x24c4], 0xffffffff
call fcn.0041a44d
xor al, al
jmp 0x40b31b
lea ecx, [esp + 0x14]
mov byte [esp + 0x24c4], 0
call fcn.00401730
push edi
push 0x454bac
push 0
push 0
push 4
push 1
push ebp
call fcn.00412b9c
push esi
call fcn.0040bffc
mov edx, dword [esp + 0x38]
push edx
call fcn.0040bffc
push edi
call fcn.0040bffc
add esp, 0x28
lea esi, [esp + 0x1c]
mov ecx, ebp
call fcn.00409310
mov ecx, dword [esp + 0x2c]
mov byte [esp + 0x24c4], 3
mov ecx, dword [ecx + 0xcc]
push ecx
push 0x454bbc
push 0
push 0
push 4
push 0x6c
push eax
call fcn.00414405
add esp, 0x1c
mov ecx, esi
mov byte [esp + 0x24c4], 0
call fcn.004139ca
mov edx, dword [ebx + 4]
mov esi, dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringW]
push edx
push 0x3ff
lea eax, [esp + 0x14bc]
push eax
push 0x4471b0
push str.User
push str.login
call esi
mov ecx, dword [ebx + 4]
push ecx
push 0x3ff
lea edx, [esp + 0x1cbc]
push edx
push 0x4471b0
push 0x448100
push str.login
call esi
lea eax, [esp + 0x14b4]
push eax
call fcn.00401380
add esp, 4
mov esi, eax
lea edi, [eax + 1]
lea ebx, [ebx]
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x40aaf0
sub eax, edi
mov ecx, esi
call fcn.004043f0
push eax
mov dword [esp + 0x1c], eax
call fcn.004013e0
add esp, 4
mov edi, eax
push edi
lea ecx, [esp + 0x2c]
call fcn.00401c70
push edi
push 0x454bb0
push 0
push 0
push 4
push 3
push ebp
mov byte [esp + 0x24e0], 4
call fcn.00412b9c
push edi
call fcn.0040bffc
mov ecx, dword [esp + 0x38]
push ecx
call fcn.0040bffc
push esi
call fcn.0040bffc
lea edx, [esp + 0x1cdc]
push edx
call fcn.00401380
add esp, 0x2c
mov dword [esp + 0x24], eax
lea esi, [eax + 1]
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x40ab64
mov ecx, dword [esp + 0x24]
sub eax, esi
call fcn.004043f0
push eax
mov dword [esp + 0x1c], eax
call fcn.004013e0
add esp, 4
mov edi, eax
push edi
lea ecx, [esp + 0x34]
call fcn.00401c70
lea esi, [esp + 0x1c]
mov ecx, ebp
mov byte [esp + 0x24c4], 5
call fcn.00409310
push edi
push str._b_v_v_v_v_b
push 0
push 0
push 4
push 0xba
push eax
mov byte [esp + 0x24e0], 6
call fcn.00414405
add esp, 0x1c
mov ecx, esi
mov byte [esp + 0x24c4], 5
call fcn.004139ca
mov eax, dword [esp + 0x24]
push eax
call fcn.0040bffc
mov ecx, dword [esp + 0x1c]
push ecx
call fcn.0040bffc
push edi
call fcn.0040bffc
mov edx, dword [ebx + 4]
add esp, 0xc
push edx
push 0
push str.LogonWay
push str.application
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileIntW]
mov esi, eax
push esi
push str.LogonWay
push 0x4474e0
mov ecx, 0x457880
call fcn.00413687
cmp esi, 1
jne 0x40ac70
lea esi, [esp + 0x28]
call fcn.00404800
add eax, 1
push eax
lea eax, [esp + 0x18]
push eax
mov ecx, esi
call fcn.004072b0
lea ecx, [esp + 0x30]
push ecx
lea edx, [esp + 0x18]
push edx
mov byte [esp + 0x24cc], 7
call fcn.00406470
add esp, 8
test al, al
lea ecx, [esp + 0x14]
je 0x40b280
mov byte [esp + 0x24c4], 5
call fcn.00401730
lea esi, [esp + 0x1c]
mov ecx, ebp
call fcn.00409310
mov ecx, eax
mov eax, dword [esp + 0x2c]
mov byte [esp + 0x24c4], 8
mov eax, dword [eax + 0xd8]
call fcn.00409350
mov ecx, esi
mov byte [esp + 0x24c4], 5
call fcn.004139ca
mov ecx, dword [ebx + 4]
mov edi, dword [sym.imp.KERNEL32.dll_GetPrivateProfileIntW]
push ecx
push 1
push str.DiskMap
push str.application
call edi
lea esi, [esp + 0x1c]
mov ecx, ebp
mov dword [esp + 0x14], eax
call fcn.00409310
mov ecx, eax
mov byte [esp + 0x24c4], 9
mov eax, dword [esp + 0x14]
call fcn.00409370
mov ecx, esi
mov byte [esp + 0x24c4], 5
call fcn.004139ca
mov edx, dword [ebx + 4]
push edx
push 0
push str.SerialPort
push str.application
call edi
lea esi, [esp + 0x1c]
mov ecx, ebp
mov dword [esp + 0x14], eax
call fcn.00409310
mov ecx, eax
mov byte [esp + 0x24c4], 0xa
mov eax, dword [esp + 0x14]
call fcn.004093b0
mov ecx, esi
mov byte [esp + 0x24c4], 5
call fcn.004139ca
mov eax, dword [ebx + 4]
push eax
push 1
push str.Printer
push str.application
call edi
lea esi, [esp + 0x1c]
mov ecx, ebp
mov dword [esp + 0x14], eax
call fcn.00409310
mov ecx, eax
mov byte [esp + 0x24c4], 0xb
mov eax, dword [esp + 0x14]
call fcn.00409390
mov ecx, esi
mov byte [esp + 0x24c4], 5
call fcn.004139ca
lea esi, [esp + 0x1c]
mov ecx, ebp
call fcn.00409310
mov byte [esp + 0x24c4], 0xc
call fcn.004093d0
mov ecx, esi
mov byte [esp + 0x24c4], 5
call fcn.004139ca
mov ecx, dword [ebx + 4]
push ecx
push 0x10
push str.ColorDept
push str.application
call edi
mov ecx, ebp
call fcn.004092f0
mov ecx, ebp
call fcn.00409290
test eax, eax
je 0x40b151
mov edx, dword [ebx + 4]
mov esi, dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringW]
push edx
push 0x103
lea eax, [esp + 0xab4]
push eax
push 0x4471b0
push str.AppPath
push str.application
call esi
lea ecx, [esp + 0xaac]
push ecx
call fcn.00401380
mov ecx, eax
lea edx, [eax + 1]
add esp, 4
mov dword [esp + 0x4c], ecx
mov dword [esp + 0x18], edx
mov dl, byte [eax]
add eax, 1
test dl, dl
jne 0x40ae06
sub eax, dword [esp + 0x18]
call fcn.004043f0
push eax
mov dword [esp + 0x4c], eax
call fcn.004013e0
add esp, 4
mov dword [esp + 0x14], eax
mov eax, dword [ebx + 4]
push eax
push 0x103
lea ecx, [esp + 0x8c]
push ecx
push 0x4471b0
push str.AppParam
push str.application
call esi
mov edx, dword [ebx + 4]
push edx
push 0x103
lea eax, [esp + 0x8ac]
push eax
push 0x4471b0
push str.Root
push 0x448958
call esi
lea ecx, [esp + 0x8a4]
push ecx
call fcn.00401380
mov esi, eax
add esp, 4
mov dword [esp + 0x3c], esi
lea ecx, [eax + 1]
mov dl, byte [eax]
add eax, 1
test dl, dl
jne 0x40ae86
sub eax, ecx
mov ecx, esi
call fcn.004043f0
push eax
mov dword [esp + 0x3c], eax
call fcn.004013e0
mov edx, dword [ebx + 4]
add esp, 4
push edx
push 1
push str.StartThimless
mov esi, eax
push str.application
mov dword [esp + 0x2c], esi
call edi
test eax, eax
mov ecx, dword [esp + 0x2c]
mov dword [ecx + 0xe0], eax
lea edx, [esp + 0x28c]
je 0x40af93
mov eax, esi
sub edx, esi
lea ebx, [ebx]
movzx ecx, word [eax]
mov word [edx + eax], cx
add eax, 2
test cx, cx
jne 0x40aee0
lea edi, [esp + 0x28c]
add edi, 0xfffffffe
lea esp, [esp]
mov ax, word [edi + 2]
add edi, 2
test ax, ax
jne 0x40af00
mov ecx, 0xa
mov esi, str.TSServerClipper.exe
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
lea edi, [esp + 0x28c]
add edi, 0xfffffffe
mov ax, word [edi + 2]
add edi, 2
test ax, ax
jne 0x40af24
mov edx, dword [0x448220]
mov eax, dword [esp + 0x14]
mov dword [edi], edx
mov edx, eax
mov edi, edi
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x40af40
lea edi, [esp + 0x28c]
sub eax, edx
add edi, 0xfffffffe
jmp 0x40af60
mov cx, word [edi + 2]
add edi, 2
test cx, cx
jne 0x40af60
mov ecx, eax
shr ecx, 2
mov esi, edx
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
push 0
and ecx, 3
push 0x80
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0x34]
push 0x40000
call fcn.00412a5a
jmp 0x40afaf
mov eax, dword [esp + 0x14]
sub edx, eax
lea esp, [esp]
movzx ecx, word [eax]
mov word [edx + eax], cx
add eax, 2
test cx, cx
jne 0x40afa0
xor edi, edi
mov dword [esp + 0x18], edi
mov dword [esp + 0x24], edi
mov ecx, 0x4471b0
lea eax, [esp + 0x84]
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x40afeb
test dx, dx
je 0x40afe7
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x40afeb
add eax, 4
add ecx, 4
test dx, dx
jne 0x40afc5
xor eax, eax
jmp 0x40aff0
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x40b0a0
lea eax, [esp + 0x84]
push eax
call fcn.00401380
mov ecx, eax
add esp, 4
mov dword [esp + 0x40], ecx
lea esi, [eax + 1]
mov dl, byte [eax]
add eax, 1
test dl, dl
jne 0x40b011
sub eax, esi
call fcn.004043f0
push eax
mov dword [esp + 0x1c], eax
call fcn.004013e0
lea edi, [esp + 0x290]
add esp, 4
mov dword [esp + 0x24], eax
add edi, 0xfffffffe
lea esp, [esp]
mov ax, word [edi + 2]
add edi, 2
test ax, ax
jne 0x40b040
mov ecx, dword [0x448220]
mov eax, dword [esp + 0x24]
mov dword [edi], ecx
mov edx, eax
lea ebx, [ebx]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x40b060
lea edi, [esp + 0x28c]
sub eax, edx
add edi, 0xfffffffe
jmp 0x40b080
mov cx, word [edi + 2]
add edi, 2
test cx, cx
jne 0x40b080
mov ecx, eax
shr ecx, 2
mov esi, edx
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, dword [esp + 0x40]
lea esi, [esp + 0x40]
mov ecx, ebp
call fcn.004092b0
lea edx, [esp + 0x28c]
push edx
push 0x454bd4
push 0
push 0
push 4
push 1
push eax
mov byte [esp + 0x24e0], 0xd
call fcn.00414405
add esp, 0x1c
mov ecx, esi
mov byte [esp + 0x24c4], 5
call fcn.004139ca
mov eax, dword [esp + 0x4c]
push eax
call fcn.0040bffc
mov ecx, dword [esp + 0x4c]
push ecx
call fcn.0040bffc
mov edx, dword [esp + 0x1c]
push edx
call fcn.0040bffc
add esp, 0xc
test edi, edi
je 0x40b10e
push edi
call fcn.0040bffc
add esp, 4
mov eax, dword [esp + 0x18]
test eax, eax
je 0x40b11f
push eax
call fcn.0040bffc
add esp, 4
mov eax, dword [esp + 0x24]
test eax, eax
je 0x40b130
push eax
call fcn.0040bffc
add esp, 4
mov eax, dword [esp + 0x3c]
push eax
call fcn.0040bffc
mov ecx, dword [esp + 0x3c]
push ecx
call fcn.0040bffc
mov edx, dword [esp + 0x24]
push edx
call fcn.0040bffc
add esp, 0xc
mov eax, dword [ebx + 4]
push eax
lea ecx, [esp + 0x38]
call fcn.00401c70
mov byte [esp + 0x24c4], 0xe
mov eax, dword [esp + 0x34]
cmp dword [eax - 0xc], 0
jl 0x40b18d
push str.Temporary_Internet_Files
push eax
call fcn.0042826a
add esp, 8
test eax, eax
je 0x40b18d
sub eax, dword [esp + 0x34]
sar eax, 1
cmp eax, 0xffffffff
jne 0x40b19f
mov ecx, dword [ebx + 4]
push ecx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
je 0x40b24d
push 0xd0
call fcn.0040bfd1
add esp, 4
mov dword [esp + 0x1c], eax
test eax, eax
mov byte [esp + 0x24c4], 0xf
je 0x40b1c4
push eax
call fcn.00401fb0
jmp 0x40b1c6
xor eax, eax
mov esi, dword [esp + 0x2c]
mov byte [esp + 0x24c4], 0xe
mov dword [esi + 0xec], eax
mov edx, dword [eax]
push esi
mov ecx, eax
mov eax, dword [edx + 0x134]
push 0x87
call eax
mov ecx, dword [esi + 0xec]
push 5
call fcn.00412b1e
mov ecx, dword [esi + 0xec]
mov edx, dword [ecx + 0x20]
push 0
push 1
push 0x466
push edx
call dword [sym.imp.USER32.dll_SendMessageW]
push 0
push 0
push 0
push 1
push 0x1e
push ebp
mov dword [esi + 0xf0], 1
call fcn.00412b9c
add esp, 0x18
lea ecx, [esp + 0x34]
call fcn.00401730
lea ecx, [esp + 0x30]
call fcn.00401730
lea ecx, [esp + 0x28]
call fcn.00401730
jmp 0x40b2f2
lea eax, [esp + 0x1c]
push eax
mov ecx, 0x2968
call fcn.0040b4c0
add esp, 4
push 0
mov byte [esp + 0x24c8], 0x10
mov eax, dword [eax]
push 0
push eax
call fcn.00416dca
lea ecx, [esp + 0x1c]
call fcn.00401730
lea ecx, [esp + 0x34]
call fcn.00401730
lea ecx, [esp + 0x30]
call fcn.00401730
lea ecx, [esp + 0x28]
jmp 0x40a9ea
lea ecx, [esp + 0x38]
push ecx
mov ecx, 0x2763
call fcn.0040b4c0
add esp, 4
push 0
mov byte [esp + 0x24c8], 0x11
mov eax, dword [eax]
push 0
push eax
call fcn.00416dca
mov byte [esp + 0x24c4], 0
mov eax, dword [esp + 0x38]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40b2e5
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov edx, dword [ebp]
mov eax, dword [edx + 0x154]
mov ecx, ebp
call eax
push ebx
call dword [sym.imp.KERNEL32.dll_GlobalFree]
mov ecx, dword [esp + 0x54]
mov byte [ecx], 1
lea ecx, [esp + 0x58]
mov dword [esp + 0x24c4], 0xffffffff
call fcn.0041a44d
jmp 0x40b319
mov byte [esi], 0
mov al, 1
mov ecx, dword [esp + 0x24bc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x24a0]
xor ecx, esp
call fcn.0042769e
add esp, 0x24b4
ret 4