Function at 0x4040f0
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x244c
call fcn.00410620
mov eax, dword [0x417004]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
mov dword [ebp - 0x2448], eax
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x242c], eax
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x2440], eax
mov eax, dword [ebp + 0x14]
push ebx
push esi
mov dword [ebp - 0x2434], eax
mov eax, dword [ebp + 0x18]
push edi
mov dword [ebp - 0x243c], eax
mov eax, dword [ebp + 0x1c]
mov esi, 0x1ff
push esi
mov dword [ebp - 0x2430], eax
xor edi, edi
lea eax, [ebp - 0x1427]
push edi
push eax
mov ebx, ecx
mov byte [ebp - 0x1428], 0
call fcn.0040fd90
add esp, 0xc
push esi
lea eax, [ebp - 0xa27]
push edi
push eax
mov byte [ebp - 0xa28], 0
call fcn.0040fd90
add esp, 0xc
xor eax, eax
mov esi, 0x7fe
push esi
mov word [ebp - 0x1228], ax
lea eax, [ebp - 0x1226]
push edi
push eax
call fcn.0040fd90
add esp, 0xc
xor eax, eax
push esi
mov word [ebp - 0x828], ax
lea eax, [ebp - 0x826]
push edi
push eax
call fcn.0040fd90
add esp, 0xc
xor eax, eax
push esi
mov word [ebp - 0x2428], ax
lea eax, [ebp - 0x2426]
push edi
push eax
call fcn.0040fd90
add esp, 0xc
xor eax, eax
push esi
mov word [ebp - 0x1c28], ax
lea eax, [ebp - 0x1c26]
push edi
push eax
call fcn.0040fd90
add esp, 0xc
push 0x400
lea eax, [ebp - 0x2428]
push eax
push edi
call dword [sym.imp.KERNEL32.DLL_GetModuleFileNameW]
test eax, eax
jne 0x404220
mov edx, dword [ebp - 0x2430]
mov eax, 0x4145e0
push 2
sub edx, eax
pop ebx
movzx ecx, word [eax]
mov word [edx + eax], cx
add eax, ebx
cmp cx, di
jne 0x40420d
jmp 0x4047da
lea eax, [ebp - 0x2428]
push eax
lea esi, [ebp - 0x1c28]
call fcn.00401c9d
pop ecx
test eax, eax
jne 0x40425a
mov edx, dword [ebp - 0x2430]
mov eax, str.getFileDir
push 2
sub edx, eax
pop ebx
movzx ecx, word [eax]
mov word [edx + eax], cx
add eax, ebx
cmp cx, di
jne 0x404247
jmp 0x4047da
push 5
lea eax, [ebx + 0x40]
mov edx, dword [eax + 0x100]
pop ecx
push 0x40
lea esi, [edx + eax + 0x104]
lea edi, [ebp - 0x18]
rep movsd dword es:[edi], dword [esi]
pop ecx
lea esi, [edx + eax + 0x118]
lea edi, [ebp - 0x1428]
rep movsd dword es:[edi], dword [esi]
lea ecx, [ebp - 0x1428]
push ecx
lea ecx, [ebp - 0x18]
mov dword [ebp - 0x2438], edx
push ecx
add edx, 0x104
push edx
push eax
call fcn.00401499
add esp, 0x10
test eax, eax
jne 0x4042cc
mov edx, dword [ebp - 0x2430]
mov eax, str.verifyHashAndSignature
push 2
sub edx, eax
pop ebx
movzx ecx, word [eax]
mov word [edx + eax], cx
add eax, ebx
test cx, cx
jne 0x4042b9
jmp 0x4047da
push 0x40
pop ecx
lea eax, [ebp - 0x2444]
push eax
lea eax, [ebp - 0xa28]
lea esi, [ebx + 0x40]
lea edi, [ebp - 0xa28]
push eax
rep movsd dword es:[edi], dword [esi]
mov dword [ebp - 0x2444], 0x100
call fcn.004013e7
pop ecx
pop ecx
test eax, eax
jne 0x404320
mov edx, dword [ebp - 0x2430]
mov eax, str.rsaDecrypt
push 2
sub edx, eax
pop ebx
movzx ecx, word [eax]
mov word [edx + eax], cx
add eax, ebx
test cx, cx
jne 0x40430d
jmp 0x4047da
cmp dword [ebp - 0x2444], 0x20
je 0x40434c
mov edx, dword [ebp - 0x2430]
mov eax, str.KeyIvLen
push 2
sub edx, eax
pop ebx
movzx ecx, word [eax]
mov word [edx + eax], cx
add eax, ebx
test cx, cx
jne 0x404339
jmp 0x4047da
push 8
pop ecx
push dword [ebp - 0x2438]
lea esi, [ebp - 0xa28]
lea edi, [ebp - 0x24]
rep movsd dword es:[edi], dword [esi]
lea esi, [ebx + 0x144]
lea eax, [ebp - 0x14]
push esi
push eax
lea edx, [ebp - 0x24]
call fcn.00401292
mov al, byte [esi]
mov ecx, dword [ebp - 0x2448]
add esp, 0xc
push 2
mov byte [ecx], al
lea ecx, [esi + 1]
pop ebx
test al, al
jne 0x40448f
lea edi, [ebp - 0x1228]
mov eax, ecx
sub edi, ecx
movzx edx, word [eax]
mov word [edi + eax], dx
add eax, ebx
test dx, dx
jne 0x404398
lea eax, [ebp - 0x1228]
lea edi, [eax + 2]
mov dx, word [eax]
add eax, ebx
test dx, dx
jne 0x4043af
sub eax, edi
sar eax, 1
lea edi, [ecx + eax*2 + 2]
push 0x3fe
lea eax, [ebp - 0x828]
push eax
lea eax, [ebp - 0x1228]
push eax
call dword [sym.imp.KERNEL32.DLL_ExpandEnvironmentStringsW]
test eax, eax
jne 0x4043f5
movzx ecx, word [ebp + eax - 0x1228]
mov word [ebp + eax - 0x828], cx
add eax, ebx
test cx, cx
jne 0x4043de
lea eax, [ebp - 0x828]
push 0x5c
push eax
call fcn.0040ad57
pop ecx
test eax, eax
pop ecx
lea eax, [ebp - 0x828]
jne 0x40442c
push eax
lea eax, [ebp - 0x1c28]
push eax
push str._s_s
push dword [ebp - 0x242c]
call fcn.0040af2c
add esp, 0x10
jmp 0x404448
mov edx, dword [ebp - 0x242c]
lea ecx, [ebp - 0x828]
sub edx, ecx
movzx ecx, word [eax]
mov word [edx + eax], cx
add eax, ebx
test cx, cx
jne 0x40443a
lea eax, [ebp - 0x244c]
push eax
sub esi, edi
add esi, dword [ebp - 0x2438]
push esi
push edi
push dword [ebp - 0x242c]
call fcn.004019ed
add esp, 0x10
test eax, eax
jne 0x404518
mov edx, dword [ebp - 0x2430]
mov eax, str.overwriteData
sub edx, eax
movzx ecx, word [eax]
mov word [eax + edx], cx
add eax, ebx
test cx, cx
jne 0x40447c
jmp 0x4047da
cmp al, 1
jne 0x40453e
lea edx, [ebp - 0x1228]
mov eax, ecx
sub edx, ecx
movzx ecx, word [eax]
mov word [eax + edx], cx
add eax, ebx
test cx, cx
jne 0x4044a1
push 0x3fe
lea eax, [ebp - 0x828]
push eax
lea eax, [ebp - 0x1228]
push eax
call dword [sym.imp.KERNEL32.DLL_ExpandEnvironmentStringsW]
test eax, eax
jne 0x4044e3
movzx ecx, word [ebp + eax - 0x1228]
mov word [ebp + eax - 0x828], cx
add eax, ebx
test cx, cx
jne 0x4044cc
lea eax, [ebp - 0x828]
push 0x5c
push eax
call fcn.0040ad57
pop ecx
test eax, eax
pop ecx
lea eax, [ebp - 0x828]
jne 0x404520
push eax
lea eax, [ebp - 0x1c28]
push eax
push str._s_s
push dword [ebp - 0x242c]
call fcn.0040af2c
add esp, 0x10
xor eax, eax
inc eax
jmp 0x4047dc
mov edx, dword [ebp - 0x242c]
lea ecx, [ebp - 0x828]
sub edx, ecx
movzx ecx, word [eax]
mov word [eax + edx], cx
add eax, ebx
test cx, cx
jne 0x40452e
jmp 0x404518
cmp al, bl
jne 0x404635
lea esi, [ebp - 0x1228]
mov eax, ecx
sub esi, ecx
movzx edx, word [eax]
mov word [eax + esi], dx
add eax, ebx
test dx, dx
jne 0x404550
lea eax, [ebp - 0x1228]
lea esi, [eax + 2]
mov dx, word [eax]
add eax, ebx
test dx, dx
jne 0x404567
sub eax, esi
sar eax, 1
lea esi, [ecx + eax*2 + 2]
push 0x3fe
lea eax, [ebp - 0x828]
push eax
lea eax, [ebp - 0x1228]
push eax
call dword [sym.imp.KERNEL32.DLL_ExpandEnvironmentStringsW]
test eax, eax
jne 0x4045ad
movzx ecx, word [ebp + eax - 0x1228]
mov word [ebp + eax - 0x828], cx
add eax, ebx
test cx, cx
jne 0x404596
lea eax, [ebp - 0x828]
push 0x5c
push eax
call fcn.0040ad57
pop ecx
test eax, eax
pop ecx
lea eax, [ebp - 0x828]
jne 0x4045e4
push eax
lea eax, [ebp - 0x1c28]
push eax
push str._s_s
push dword [ebp - 0x242c]
call fcn.0040af2c
add esp, 0x10
jmp 0x404600
mov edx, dword [ebp - 0x242c]
lea ecx, [ebp - 0x828]
sub edx, ecx
movzx ecx, word [eax]
mov word [eax + edx], cx
add eax, ebx
test cx, cx
jne 0x4045f2
mov edx, dword [ebp - 0x2434]
mov eax, esi
sub edx, esi
movzx ecx, word [eax]
mov word [edx + eax], cx
add eax, ebx
test cx, cx
jne 0x40460a
mov eax, dword [ebp - 0x2434]
lea edx, [eax + 2]
mov cx, word [eax]
add eax, ebx
test cx, cx
jne 0x404621
sub eax, edx
sar eax, 1
mov eax, dword [esi + eax*2 + 2]
jmp 0x40466c
cmp al, 3
jne 0x404679
mov esi, dword [ebp - 0x2440]
mov eax, ecx
sub esi, ecx
movzx edx, word [eax]
mov word [eax + esi], dx
add eax, ebx
test dx, dx
jne 0x404643
mov eax, dword [ebp - 0x2440]
lea esi, [eax + 2]
mov dx, word [eax]
add eax, ebx
test dx, dx
jne 0x40465a
sub eax, esi
sar eax, 1
mov eax, dword [ecx + eax*2 + 2]
mov ecx, dword [ebp - 0x243c]
mov dword [ecx], eax
jmp 0x404518
cmp al, 4
jne 0x4047bf
lea edi, [ebp - 0x1228]
mov eax, ecx
sub edi, ecx
movzx edx, word [eax]
mov word [eax + edi], dx
add eax, ebx
test dx, dx
jne 0x40468b
lea eax, [ebp - 0x1228]
lea edi, [eax + 2]
mov dx, word [eax]
add eax, ebx
test dx, dx
jne 0x4046a2
sub eax, edi
sar eax, 1
lea edi, [ecx + eax*2 + 2]
push 0x3fe
lea eax, [ebp - 0x828]
push eax
lea eax, [ebp - 0x1228]
push eax
call dword [sym.imp.KERNEL32.DLL_ExpandEnvironmentStringsW]
test eax, eax
jne 0x4046e8
movzx ecx, word [ebp + eax - 0x1228]
mov word [ebp + eax - 0x828], cx
add eax, ebx
test cx, cx
jne 0x4046d1
lea eax, [ebp - 0x828]
push 0x5c
push eax
call fcn.0040ad57
pop ecx
test eax, eax
pop ecx
lea eax, [ebp - 0x828]
jne 0x40471f
push eax
lea eax, [ebp - 0x1c28]
push eax
push str._s_s
push dword [ebp - 0x242c]
call fcn.0040af2c
add esp, 0x10
jmp 0x40473b
mov edx, dword [ebp - 0x242c]
lea ecx, [ebp - 0x828]
sub edx, ecx
movzx ecx, word [eax]
mov word [eax + edx], cx
add eax, ebx
test cx, cx
jne 0x40472d
mov edx, dword [ebp - 0x2434]
mov eax, edi
sub edx, edi
movzx ecx, word [eax]
mov word [eax + edx], cx
add eax, ebx
test cx, cx
jne 0x404745
mov eax, dword [ebp - 0x2434]
lea edx, [eax + 2]
mov cx, word [eax]
add eax, ebx
test cx, cx
jne 0x40475c
sub eax, edx
mov edx, dword [ebp - 0x243c]
sar eax, 1
lea eax, [edi + eax*2 + 2]
mov ecx, dword [eax]
add eax, 4
mov dword [edx], ecx
sub esi, eax
add esi, dword [ebp - 0x2438]
lea ecx, [ebp - 0x244c]
push ecx
push esi
push eax
push dword [ebp - 0x242c]
call fcn.004019ed
add esp, 0x10
test eax, eax
jne 0x404518
mov edx, dword [ebp - 0x2430]
mov eax, str.overwriteData
sub edx, eax
movzx ecx, word [eax]
mov word [eax + edx], cx
add eax, ebx
test cx, cx
jne 0x4047af
jmp 0x4047da
mov edx, dword [ebp - 0x2430]
mov eax, str.bOperation_value_wrong
sub edx, eax
movzx ecx, word [eax]
mov word [edx + eax], cx
add eax, ebx
test cx, cx
jne 0x4047cc
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0040ad48
leave
ret