Function at 0x100043b0
Capabilities:
Check if file exists
Get file attributes
Query environment variable
Query or enumerate registry value
Read .ini file
Set environment variable

Disassembly:
sub esp, 0x82c
mov eax, dword [esp + 0x834]
push ebx
push ebp
push esi
test eax, eax
push edi
mov dword [esp + 0x18], ecx
je case.0x100046f6.31
mov edi, str.SCVSys.ini
or ecx, 0xffffffff
xor eax, eax
mov ebp, 0x103
repne scasb al, byte es:[edi]
not ecx
dec ecx
lea eax, [esp + 0x2c]
sub ebp, ecx
test eax, eax
je 0x1000470e
test ebp, ebp
je 0x1000470e
mov ebx, dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableA]
lea ecx, [esp + 0x2c]
push ebp
push ecx
push str.SKYSEA_INSTDIR
call ebx
test eax, eax
jne 0x1000466b
lea edx, [esp + 0x530]
push 0x104
push edx
push eax
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x1000445b
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, 0x100a2820
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x530]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
jmp 0x10004476
lea ecx, [esp + 0x530]
push 0x5c
push ecx
call dword [sym.imp.MSVCRT.dll__mbsrchr]
add esp, 8
test eax, eax
je 0x10004476
mov byte [eax + 1], 0
lea edx, [esp + 0x530]
push edx
call dword [sym.imp.SHLWAPI.dll_PathIsNetworkPathA]
test eax, eax
jne 0x1000454c
lea edi, [esp + 0x530]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea edx, [esp + 0x738]
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x738]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, str.SCVSys.ini
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edi, edx
mov edx, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
lea eax, [esp + 0x738]
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x1000454c
lea edi, [esp + 0x530]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
cmp ecx, ebp
jg 0x1000470e
lea edi, [esp + 0x530]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea edx, [esp + 0x2c]
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x2c]
push ecx
push str.SKYSEA_INSTDIR
call dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableA]
jmp 0x1000466b
mov dl, byte [0x100aba18]
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0x635]
mov byte [esp + 0x634], dl
lea edx, [esp + 0x634]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
or ecx, 0xffffffff
mov edi, str.SOFTWARESky_ProductSKYSEAClientView
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
shr ecx, 2
mov edi, edx
lea edx, [esp + 0x634]
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
mov dword [esp + 0x10], eax
rep movsb byte es:[edi], byte [esi]
mov edi, 0x100a27e8
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edi, edx
mov edx, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
lea edx, [esp + 0x634]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, str.ScvInst
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edi, edx
mov edx, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
lea eax, [esp + 0x10]
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
push 1
lea ecx, [esp + 0x63c]
push 0
push ecx
push reloc.WS2_32.dll_bind
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
mov esi, eax
test esi, esi
jne 0x10004654
mov ecx, dword [esp + 0x10]
lea edx, [esp + 0x14]
lea eax, [esp + 0x2c]
push edx
push eax
push esi
push esi
push str.SCVDIR
push ecx
mov dword [esp + 0x2c], ebp
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov esi, eax
test esi, esi
jne 0x10004654
lea edi, [esp + 0x2c]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
dec ecx
jne 0x10004654
mov esi, 0xd
mov eax, dword [esp + 0x10]
test eax, eax
je 0x10004663
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test esi, esi
jne 0x1000470e
lea edx, [esp + 0x2c]
push 0x5c
push edx
call dword [sym.imp.MSVCRT.dll__mbsrchr]
add esp, 8
test eax, eax
je 0x1000470e
mov cl, byte [eax + 1]
test cl, cl
je 0x100046b8
mov edi, 0x100a27e8
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x2c]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebp, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebp
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebp
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, str.SCVSys.ini
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x2c]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebp, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebp
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov eax, dword [esp + 0x840]
mov ecx, ebp
and ecx, 3
cmp eax, 0x3c
rep movsb byte es:[edi], byte [esi]
ja case.0x100046f6.31
jmp dword [eax*4 + 0x10004ed4]
lea edx, [esp + 0x130]
mov edi, str.MasterSvr
jmp 0x10004a96
pop edi
pop esi
pop ebp
mov eax, 3
pop ebx
add esp, 0x82c
ret 8
lea edx, [esp + 0x130]
mov edi, str.CabMgrSvr
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.LogSvr
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.HSSSvr
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.CommMgTCP
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.CommMgUDP
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.RecSvr
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.RecTCP
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.RCV2TCP
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.RCV2UDP
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.RCV2UDPMulticast
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.RCV2UDPUnicast
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.KMToolScreen
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.KMToolControl
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.WakeOnLan
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.AstExSvr
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.LogAgrtSvr
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.AstExSvrLink
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.EventLogSvr
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.LogCollector
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.SwtCRSet
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.C2dmSender
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.UsbDeviceLog
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.AstXmlExportSvr
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.FileTrackingDataSvr
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.SkyschoolDataSvr
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.AggregateDataSvr
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.LogWebMailRelaySvc
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.SwtDtlSvr
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.SubsystemLogSvr
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.CommonIceSvr
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.SactMonSvr
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.UnvSvr
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.UnvSes
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.UnvCall
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.UnvRCV2TCP
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.UnvRCV2UDP
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.UnvRCV2UDPMulticast
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.UnvRCV2UDPUnicast
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.UnvTeacher
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.UruGraphSvr
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.DiskMntImageSvr
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.LogFilterSvr
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.ReceiveBlockNotify
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.OvertimeWorkSvr
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.PPSMngSvr
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.InstantMessengerSvrTCP
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.InstantMsgFileSvrTCP
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.InstantMsgClientTCP
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.OvernightBatchSvc
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.LogAttachSvc
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.MalwareInfomationFileSvr
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.MasterSvrCloudAgent
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.CabMgrSvrCloudAgent
jmp 0x10004a96
lea edx, [esp + 0x130]
mov edi, str.DataSyncSvc
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0x18]
cmp dword [ecx], 2
jne 0x10004dfa
push 0
call fcn.10004fd0
test eax, eax
je 0x10004dfa
mov edi, str.UserSet
or ecx, 0xffffffff
xor eax, eax
mov ebp, 0x102
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov edi, str.VisitMs.ini
sub ebp, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
dec ecx
sub ebp, ecx
je 0x10004dfa
lea edx, [esp + 0x2c]
push ebp
push edx
push str.SKYSEA_INSTDIR
call ebx
test eax, eax
jne 0x10004d69
lea eax, [esp + 0x530]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x10004b59
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, 0x100a2820
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x530]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
jmp 0x10004b74
lea ecx, [esp + 0x530]
push 0x5c
push ecx
call dword [sym.imp.MSVCRT.dll__mbsrchr]
add esp, 8
test eax, eax
je 0x10004b74
mov byte [eax + 1], 0
lea edx, [esp + 0x530]
push edx
call dword [sym.imp.SHLWAPI.dll_PathIsNetworkPathA]
test eax, eax
jne 0x10004c4a
lea edi, [esp + 0x530]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea edx, [esp + 0x738]
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x738]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, str.SCVSys.ini
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
lea eax, [esp + 0x738]
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x10004c4a
lea edi, [esp + 0x530]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
cmp ecx, ebp
jg 0x10004dfa
lea edi, [esp + 0x530]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea edx, [esp + 0x2c]
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x2c]
push ecx
push str.SKYSEA_INSTDIR
call dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableA]
jmp 0x10004d69
mov dl, byte [0x100aba18]
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0x635]
mov byte [esp + 0x634], dl
lea edx, [esp + 0x634]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
or ecx, 0xffffffff
mov edi, str.SOFTWARESky_ProductSKYSEAClientView
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
shr ecx, 2
mov edi, edx
lea edx, [esp + 0x634]
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
mov dword [esp + 0x10], eax
rep movsb byte es:[edi], byte [esi]
mov edi, 0x100a27e8
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
lea edx, [esp + 0x634]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, str.ScvInst
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
lea eax, [esp + 0x10]
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
push 1
lea ecx, [esp + 0x63c]
push 0
push ecx
push reloc.WS2_32.dll_bind
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
mov esi, eax
test esi, esi
jne 0x10004d52
mov ecx, dword [esp + 0x10]
lea edx, [esp + 0x14]
lea eax, [esp + 0x2c]
push edx
push eax
push esi
push esi
push str.SCVDIR
push ecx
mov dword [esp + 0x2c], ebp
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov esi, eax
test esi, esi
jne 0x10004d52
lea edi, [esp + 0x2c]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
dec ecx
jne 0x10004d52
mov esi, 0xd
mov eax, dword [esp + 0x10]
test eax, eax
je 0x10004d61
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test esi, esi
jne 0x10004dfa
lea edx, [esp + 0x2c]
push edx
call dword [sym.imp.SHLWAPI.dll_PathRemoveBackslashA]
or ecx, 0xffffffff
mov edi, 0x100a3364
xor eax, eax
lea edx, [esp + 0x2c]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov ebx, ecx
mov esi, edi
or ecx, 0xffffffff
mov edi, edx
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
lea edx, [esp + 0x2c]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, 0x100a27e8
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
lea edx, [esp + 0x2c]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, str.VisitMs.ini
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov esi, dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
lea eax, [esp + 0x2c]
push eax
lea ecx, [esp + 0x20]
push 8
push ecx
lea edx, [esp + 0x13c]
push 0x100aba18
push edx
push str.PORT
call esi
test eax, eax
ja 0x10004e99
lea eax, [esp + 0x2c]
lea ecx, [esp + 0x24]
push eax
push 8
push ecx
push 0x100aba18
push str.MasterSvr
push str.PORT
call esi
test eax, eax
ja 0x10004e6a
mov edx, dword [esp + 0x840]
mov eax, dword [esp + 0x844]
add edx, 0xcc4c
pop edi
pop esi
mov dword [eax], edx
pop ebp
xor eax, eax
pop ebx
add esp, 0x82c
ret 8
lea ecx, [esp + 0x24]
push ecx
call dword [sym.imp.MSVCRT.dll_atoi]
mov ecx, dword [esp + 0x844]
mov edx, dword [esp + 0x848]
add esp, 4
add eax, ecx
mov dword [edx], eax
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x82c
ret 8
lea eax, [esp + 0x1c]
push eax
call dword [sym.imp.MSVCRT.dll_atoi]
mov ecx, dword [esp + 0x848]
add esp, 4
pop edi
pop esi
mov dword [ecx], eax
pop ebp
xor eax, eax
pop ebx
add esp, 0x82c
ret 8
pop edi
pop esi
pop ebp
mov eax, 0x57
pop ebx
add esp, 0x82c
ret 8