Function at 0x402490
Capabilities:
Create process on windows
Query environment variable
Set current directory

Disassembly:
sub esp, 0x5c
cmp byte [0x413f84], 0
push ebx
push ebp
push esi
push edi
jne 0x402724
mov eax, dword [0x413f78]
push eax
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
push 0x44
lea ecx, [esp + 0x24]
push 0
push ecx
call fcn.00408e60
mov edi, dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
add esp, 0xc
xor edx, edx
push edx
push edx
push str.Temp
mov dword [esp + 0x2c], 0x44
mov dword [esp + 0x58], 1
mov word [esp + 0x5c], dx
call edi
xor ecx, ecx
mov esi, eax
mov edx, 2
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0040352b
add esp, 4
push esi
mov ebp, eax
push ebp
push str.Temp
call edi
mov eax, dword [0x413f74]
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x402515
sub eax, edx
sar eax, 1
mov ecx, eax
mov eax, ebp
lea esi, [eax + 2]
jmp 0x402530
mov dx, word [eax]
add eax, 2
test dx, dx
jne 0x402530
add ecx, 0x11
sub eax, esi
sar eax, 1
lea eax, [eax + ecx*2]
add eax, ecx
xor ecx, ecx
mov edx, 2
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0040352b
mov ebx, eax
mov eax, 0x41029c
mov edx, ebx
add esp, 4
sub edx, eax
jmp 0x402570
movzx ecx, word [eax]
mov word [edx + eax], cx
add eax, 2
test cx, cx
jne 0x402570
mov eax, dword [0x413f74]
mov edx, eax
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x402586
sub eax, edx
lea edi, [ebx - 2]
mov cx, word [edi + 2]
add edi, 2
test cx, cx
jne 0x402596
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]
lea edi, [ebx - 2]
mov ax, word [edi + 2]
add edi, 2
test ax, ax
jne 0x4025b5
mov ecx, 0xb
mov esi, str.StartRemoveDir.bat_
mov eax, ebp
rep movsd dword es:[edi], dword [esi]
mov edx, eax
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x4025d1
sub eax, edx
lea edi, [ebx - 2]
mov cx, word [edi + 2]
add edi, 2
test cx, cx
jne 0x4025e1
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]
lea eax, [ebx - 2]
mov cx, word [eax + 2]
add eax, 2
test cx, cx
jne 0x402600
mov ecx, dword [0x410324]
mov dword [eax], ecx
mov dx, word [0x410328]
mov word [eax + 4], dx
mov eax, dword [0x413f74]
mov edx, eax
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x402626
sub eax, edx
lea edi, [ebx - 2]
mov cx, word [edi + 2]
add edi, 2
test cx, cx
jne 0x402636
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]
lea eax, [ebx - 2]
mov cx, word [eax + 2]
add eax, 2
test cx, cx
jne 0x402655
mov ecx, dword [0x41047c]
mov dword [eax], ecx
mov edx, dword [0x410480]
mov dword [eax + 4], edx
mov eax, dword [0x413f74]
mov edx, eax
lea esp, [esp]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x402680
sub eax, edx
lea edi, [ebx - 2]
mov cx, word [edi + 2]
add edi, 2
test cx, cx
jne 0x402690
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]
lea eax, [ebx - 2]
nop
mov cx, word [eax + 2]
add eax, 2
test cx, cx
jne 0x4026b0
mov ecx, dword [0x4103fc]
mov dword [eax], ecx
mov dx, word [0x410400]
mov word [eax + 4], dx
test ebp, ebp
je 0x4026dc
push ebp
call fcn.00403545
add esp, 4
lea eax, [esp + 0x10]
push eax
lea ecx, [esp + 0x24]
push ecx
push 0
push 0
push 0x200
push 1
push 0
push 0
push ebx
push 0
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
cmp eax, 1
jne 0x402717
mov edx, dword [esp + 0x14]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
push edx
call esi
mov eax, dword [esp + 0x10]
push eax
call esi
test ebx, ebx
je 0x402724
push ebx
call fcn.00403545
add esp, 4
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x5c
ret