Function at 0x40120c
Capabilities:
Read .ini file
Read file on windows
Write file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x2dc4
call fcn.00402160
mov dword [ebp - 0x2d74], 1
mov dword [ebp - 0x10c], 1
mov dword [ebp - 0x2d78], 1
mov dword [ebp - 0x2d28], 1
mov dword [ebp - 0x2d24], 0
push 0x404084
call sub.CRMEM32.dll_Ordinal_37
push eax
lea eax, [ebp - 0x100]
push eax
call sub.MSVCRT.dll_strcpy
add esp, 8
lea ecx, [ebp - 0x100]
push ecx
call dword [sym.imp.MSVCRT.dll__chdir]
add esp, 4
push 0x404088
call sub.CRMEM32.dll_Ordinal_37
push eax
push 0x80
lea edx, [ebp - 0x2914]
push edx
push 0x4044e0
push 0x404094
push 0x4040a0
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
movsx eax, byte [ebp - 0x2914]
test eax, eax
je 0x40130a
lea ecx, [ebp - 0x2914]
push ecx
call sub.MSVCRT.dll_strlen
add esp, 4
push eax
lea edx, [ebp - 0x2914]
push edx
call fcn.00401050
push 0x4040b0
call sub.CRMEM32.dll_Ordinal_37
push eax
push 0x4044e4
push str.ClearPasswd
push 0x4040c8
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringA]
push 0x4040d8
call sub.CRMEM32.dll_Ordinal_37
push eax
lea eax, [ebp - 0x2914]
push eax
push str.Password
push 0x4040f0
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringA]
push 0x404100
call sub.CRMEM32.dll_Ordinal_37
push eax
push 0x80
lea ecx, [ebp - 0x2914]
push ecx
push 0x4044e8
push str.Installed
push str.Server
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
push 0x404120
lea edx, [ebp - 0x2914]
push edx
call dword [sym.imp.MSVCRT.dll__stricmp]
add esp, 8
test eax, eax
je 0x401368
push str.True
lea eax, [ebp - 0x2914]
push eax
call dword [sym.imp.MSVCRT.dll__stricmp]
add esp, 8
test eax, eax
jne 0x401372
mov dword [ebp - 0x2d74], 0
push 0x40412c
lea ecx, [ebp - 0x100]
push ecx
call sub.MSVCRT.dll_strcat
add esp, 8
push 0x404138
lea edx, [ebp - 0x100]
push edx
call dword [sym.imp.MSVCRT.dll_fopen]
add esp, 8
mov dword [ebp - 0x2d80], eax
cmp dword [ebp - 0x2d80], 0
je 0x4013e3
mov eax, dword [ebp - 0x2d80]
push eax
push 1
push 4
lea ecx, [ebp - 0x2d24]
push ecx
call dword [sym.imp.MSVCRT.dll_fread]
add esp, 0x10
mov edx, dword [ebp - 0x2d80]
push edx
call dword [sym.imp.MSVCRT.dll_fclose]
add esp, 4
cmp dword [ebp - 0x2d24], 4
jb 0x4013e3
jmp 0x4018c2
cmp dword [ebp - 0x2d24], 3
jne 0x40151d
push 0x40413c
lea eax, [ebp - 0x100]
push eax
call dword [sym.imp.MSVCRT.dll_fopen]
add esp, 8
mov dword [ebp - 0x2d80], eax
cmp dword [ebp - 0x2d80], 0
je 0x401518
push 0
push 0
mov ecx, dword [ebp - 0x2d80]
push ecx
call dword [sym.imp.MSVCRT.dll_fseek]
add esp, 0xc
mov dword [ebp - 0x2d24], 4
mov edx, dword [ebp - 0x2d80]
push edx
push 1
push 4
lea eax, [ebp - 0x2d24]
push eax
call dword [sym.imp.MSVCRT.dll_fwrite]
add esp, 0x10
push 2
push 0
mov ecx, dword [ebp - 0x2d80]
push ecx
call dword [sym.imp.MSVCRT.dll_fseek]
add esp, 0xc
push 0x40c
push 0
lea edx, [ebp - 0x2d20]
push edx
call sub.MSVCRT.dll_memset
add esp, 0xc
push 0x404140
call sub.CRMEM32.dll_Ordinal_58
push eax
lea eax, [ebp - 0x2d20]
push eax
call sub.MSVCRT.dll_strcpy
add esp, 8
call fcn.004011b0
push eax
push 0x404150
call sub.CRMEM32.dll_Ordinal_58
push eax
lea ecx, [ebp - 0x2a18]
push ecx
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 0xc
push 0x404164
lea edx, [ebp - 0x100]
push edx
call sub.MSVCRT.dll_strcpy
add esp, 8
lea eax, [ebp - 0x100]
push eax
lea ecx, [ebp - 0x2c20]
push ecx
call sub.MSVCRT.dll_strcpy
add esp, 8
mov dword [ebp - 0x2918], 1
mov edx, dword [ebp - 0x2d80]
push edx
push 1
push 0x40c
lea eax, [ebp - 0x2d20]
push eax
call dword [sym.imp.MSVCRT.dll_fwrite]
add esp, 0x10
mov ecx, dword [ebp - 0x2d80]
push ecx
call dword [sym.imp.MSVCRT.dll_fclose]
add esp, 4
jmp 0x4018c2
push 0x404170
lea edx, [ebp - 0x100]
push edx
call dword [sym.imp.MSVCRT.dll_fopen]
add esp, 8
mov dword [ebp - 0x2d80], eax
cmp dword [ebp - 0x2d80], 0
je 0x4018c2
mov dword [ebp - 0x2d24], 4
mov eax, dword [ebp - 0x2d80]
push eax
push 1
push 4
lea ecx, [ebp - 0x2d24]
push ecx
call dword [sym.imp.MSVCRT.dll_fwrite]
add esp, 0x10
mov edx, dword [ebp - 0x2d80]
push edx
push 1
push 4
lea eax, [ebp - 0x2d78]
push eax
call dword [sym.imp.MSVCRT.dll_fwrite]
add esp, 0x10
mov ecx, dword [ebp - 0x2d80]
push ecx
push 1
push 4
lea edx, [ebp - 0x10c]
push edx
call dword [sym.imp.MSVCRT.dll_fwrite]
add esp, 0x10
mov eax, dword [ebp - 0x2d80]
push eax
push 1
push 4
lea ecx, [ebp - 0x2d28]
push ecx
call dword [sym.imp.MSVCRT.dll_fwrite]
add esp, 0x10
mov byte [ebp - 0x2d68], 0
mov byte [ebp - 0x2dc0], 0
cmp dword [ebp - 0x2d74], 0
jne 0x4015ec
push str.Administrator
call sub.CRMEM32.dll_Ordinal_58
push eax
lea edx, [ebp - 0x2d68]
push edx
call sub.MSVCRT.dll_strcpy
add esp, 8
mov eax, dword [ebp - 0x2d80]
push eax
push 0x40
push 1
lea ecx, [ebp - 0x2d68]
push ecx
call dword [sym.imp.MSVCRT.dll_fwrite]
add esp, 0x10
mov edx, dword [ebp - 0x2d80]
push edx
push 0x40
push 1
lea eax, [ebp - 0x2dc0]
push eax
call dword [sym.imp.MSVCRT.dll_fwrite]
add esp, 0x10
cmp dword [ebp - 0x2d74], 0
jne 0x4016bc
push 0x40c
push 0
lea ecx, [ebp - 0x2d20]
push ecx
call sub.MSVCRT.dll_memset
add esp, 0xc
push str.System_Server
call sub.CRMEM32.dll_Ordinal_58
push eax
lea edx, [ebp - 0x2d20]
push edx
call sub.MSVCRT.dll_strcpy
add esp, 8
call fcn.004011b0
push eax
push str._s_Management_Server
call sub.CRMEM32.dll_Ordinal_58
push eax
lea eax, [ebp - 0x2a18]
push eax
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 0xc
push str.crserv.exe
lea ecx, [ebp - 0x2c20]
push ecx
call sub.MSVCRT.dll_strcpy
add esp, 8
mov dword [ebp - 0x2918], 1
mov edx, dword [ebp - 0x2d80]
push edx
push 1
push 0x40c
lea eax, [ebp - 0x2d20]
push eax
call dword [sym.imp.MSVCRT.dll_fwrite]
add esp, 0x10
cmp dword [ebp - 0x2d74], 1
jg 0x4018b2
push 0x40c
push 0
lea ecx, [ebp - 0x2d20]
push ecx
call sub.MSVCRT.dll_memset
add esp, 0xc
push str.Polling_Agent
call sub.CRMEM32.dll_Ordinal_58
push eax
lea edx, [ebp - 0x2d20]
push edx
call sub.MSVCRT.dll_strcpy
add esp, 8
call fcn.004011b0
push eax
push str._s_AutoDiscovery_Agent
call sub.CRMEM32.dll_Ordinal_58
push eax
lea eax, [ebp - 0x2a18]
push eax
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 0xc
push str.discagt.exe
lea ecx, [ebp - 0x100]
push ecx
call sub.MSVCRT.dll_strcpy
add esp, 8
lea edx, [ebp - 0x100]
push edx
lea eax, [ebp - 0x2c20]
push eax
call sub.MSVCRT.dll_strcpy
add esp, 8
mov dword [ebp - 0x2918], 1
mov ecx, dword [ebp - 0x2d80]
push ecx
push 1
push 0x40c
lea edx, [ebp - 0x2d20]
push edx
call dword [sym.imp.MSVCRT.dll_fwrite]
add esp, 0x10
push 0x40c
push 0
lea eax, [ebp - 0x2d20]
push eax
call sub.MSVCRT.dll_memset
add esp, 0xc
push str.History_Agent
call sub.CRMEM32.dll_Ordinal_58
push eax
lea ecx, [ebp - 0x2d20]
push ecx
call sub.MSVCRT.dll_strcpy
add esp, 8
call fcn.004011b0
push eax
push str._s_History_Agent
call sub.CRMEM32.dll_Ordinal_58
push eax
lea edx, [ebp - 0x2a18]
push edx
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 0xc
push str.hist32.exe
lea eax, [ebp - 0x100]
push eax
call sub.MSVCRT.dll_strcpy
add esp, 8
lea ecx, [ebp - 0x100]
push ecx
lea edx, [ebp - 0x2c20]
push edx
call sub.MSVCRT.dll_strcpy
add esp, 8
mov dword [ebp - 0x2918], 1
mov eax, dword [ebp - 0x2d80]
push eax
push 1
push 0x40c
lea ecx, [ebp - 0x2d20]
push ecx
call dword [sym.imp.MSVCRT.dll_fwrite]
add esp, 0x10
push 0x40c
push 0
lea edx, [ebp - 0x2d20]
push edx
call sub.MSVCRT.dll_memset
add esp, 0xc
push str.Backup_Server
call sub.CRMEM32.dll_Ordinal_58
push eax
lea eax, [ebp - 0x2d20]
push eax
call sub.MSVCRT.dll_strcpy
add esp, 8
call fcn.004011b0
push eax
push str._s_Backup_Server
call sub.CRMEM32.dll_Ordinal_58
push eax
lea ecx, [ebp - 0x2a18]
push ecx
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 0xc
push str.bkserv.exe
lea edx, [ebp - 0x100]
push edx
call sub.MSVCRT.dll_strcpy
add esp, 8
lea eax, [ebp - 0x100]
push eax
lea ecx, [ebp - 0x2c20]
push ecx
call sub.MSVCRT.dll_strcpy
add esp, 8
mov dword [ebp - 0x2918], 1
mov edx, dword [ebp - 0x2d80]
push edx
push 1
push 0x40c
lea eax, [ebp - 0x2d20]
push eax
call dword [sym.imp.MSVCRT.dll_fwrite]
add esp, 0x10
mov ecx, dword [ebp - 0x2d80]
push ecx
call dword [sym.imp.MSVCRT.dll_fclose]
add esp, 4
push 0x40424c
call sub.CRMEM32.dll_Ordinal_37
push eax
push 0x2800
lea edx, [ebp - 0x2914]
push edx
push 0x404258
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileSectionA]
mov dword [ebp - 0x2d74], eax
cmp dword [ebp - 0x2d74], 0
jle 0x401bf3
movsx eax, byte [ebp - 0x2914]
test eax, eax
je 0x401bf3
lea ecx, [ebp - 0x2914]
mov dword [ebp - 0x104], ecx
mov edx, dword [ebp - 0x104]
movsx eax, byte [edx]
test eax, eax
je 0x401bf3
mov ecx, dword [ebp - 0x104]
mov dword [ebp - 0x2d70], ecx
mov edx, dword [ebp - 0x104]
push edx
call sub.MSVCRT.dll_strlen
add esp, 4
mov ecx, dword [ebp - 0x104]
lea edx, [ecx + eax + 1]
mov dword [ebp - 0x104], edx
push 0x3d
mov eax, dword [ebp - 0x2d70]
push eax
call dword [sym.imp.MSVCRT.dll_strchr]
add esp, 8
mov dword [ebp - 0x108], eax
cmp dword [ebp - 0x108], 0
je 0x401989
mov ecx, dword [ebp - 0x108]
mov byte [ecx], 0
mov edx, dword [ebp - 0x108]
add edx, 1
mov dword [ebp - 0x108], edx
jmp 0x401993
mov dword [ebp - 0x108], 0x4044ec
mov eax, dword [ebp - 0x108]
mov dword [ebp - 0x114], eax
push 0x2c
mov ecx, dword [ebp - 0x114]
push ecx
call dword [sym.imp.MSVCRT.dll_strchr]
add esp, 8
mov dword [ebp - 0x110], eax
cmp dword [ebp - 0x110], 0
je 0x4019da
mov edx, dword [ebp - 0x110]
mov byte [edx], 0
mov eax, dword [ebp - 0x110]
add eax, 1
mov dword [ebp - 0x110], eax
jmp 0x4019e4
mov dword [ebp - 0x110], 0x4044f0
push 0x2c
mov ecx, dword [ebp - 0x110]
push ecx
call dword [sym.imp.MSVCRT.dll_strchr]
add esp, 8
mov dword [ebp - 0x2dc4], eax
cmp dword [ebp - 0x2dc4], 0
je 0x401a1f
mov edx, dword [ebp - 0x2dc4]
mov byte [edx], 0
mov eax, dword [ebp - 0x2dc4]
add eax, 1
mov dword [ebp - 0x2dc4], eax
jmp 0x401a29
mov dword [ebp - 0x2dc4], 0x4044f4
push 0x2c
mov ecx, dword [ebp - 0x2dc4]
push ecx
call dword [sym.imp.MSVCRT.dll_strchr]
add esp, 8
mov dword [ebp - 0x2d6c], eax
cmp dword [ebp - 0x2d6c], 0
je 0x401a64
mov edx, dword [ebp - 0x2d6c]
mov byte [edx], 0
mov eax, dword [ebp - 0x2d6c]
add eax, 1
mov dword [ebp - 0x2d6c], eax
jmp 0x401a6e
mov dword [ebp - 0x2d6c], 0x4044f8
push 0x404260
push 0x404264
call dword [sym.imp.MSVCRT.dll_fopen]
add esp, 8
mov dword [ebp - 0x2d80], eax
cmp dword [ebp - 0x2d80], 0
je 0x401bee
push 0
push 0x90
mov ecx, dword [ebp - 0x2d80]
push ecx
call dword [sym.imp.MSVCRT.dll_fseek]
add esp, 0xc
mov dword [ebp - 0x2d7c], 0
cmp dword [ebp - 0x2d7c], 0
jne 0x401b07
mov edx, dword [ebp - 0x2d80]
push edx
push 1
push 0x40c
lea eax, [ebp - 0x2d20]
push eax
call dword [sym.imp.MSVCRT.dll_fread]
add esp, 0x10
test eax, eax
je 0x401b07
mov ecx, dword [ebp - 0x2dc4]
push ecx
lea edx, [ebp - 0x2c20]
push edx
call dword [sym.imp.MSVCRT.dll__stricmp]
add esp, 8
test eax, eax
jne 0x401b05
mov dword [ebp - 0x2d7c], 1
jmp 0x401ab5
cmp dword [ebp - 0x2d7c], 0
jne 0x401bbf
push 0x40c
push 0
lea eax, [ebp - 0x2d20]
push eax
call sub.MSVCRT.dll_memset
add esp, 0xc
mov ecx, dword [ebp - 0x114]
push ecx
lea edx, [ebp - 0x2d20]
push edx
call sub.MSVCRT.dll_strcpy
add esp, 8
mov eax, dword [ebp - 0x110]
push eax
lea ecx, [ebp - 0x2a18]
push ecx
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 8
mov edx, dword [ebp - 0x2dc4]
push edx
lea eax, [ebp - 0x2c20]
push eax
call sub.MSVCRT.dll_strcpy
add esp, 8
mov ecx, dword [ebp - 0x2d6c]
push ecx
lea edx, [ebp - 0x2b1c]
push edx
call sub.MSVCRT.dll_strcpy
add esp, 8
mov dword [ebp - 0x2918], 1
push 2
push 0
mov eax, dword [ebp - 0x2d80]
push eax
call dword [sym.imp.MSVCRT.dll_fseek]
add esp, 0xc
mov ecx, dword [ebp - 0x2d80]
push ecx
push 1
push 0x40c
lea edx, [ebp - 0x2d20]
push edx
call dword [sym.imp.MSVCRT.dll_fwrite]
add esp, 0x10
mov eax, dword [ebp - 0x2d80]
push eax
call dword [sym.imp.MSVCRT.dll_fclose]
add esp, 4
push 0x404270
call sub.CRMEM32.dll_Ordinal_37
push eax
push 0
mov ecx, dword [ebp - 0x2d70]
push ecx
push str.NewApps
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringA]
jmp 0x401912
mov esp, ebp
pop ebp
ret