joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4581e0
Capabilities:
Get file size

Disassembly:
mov eax, dword [esp + 8]
push esi
push edi
push 0
push 0x20
push 3
push 0
push 3
push SysReAllocString
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
jne 0x458208
pop edi
or eax, eax
pop esi
ret
lea ecx, [esp + 0x10]
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
push esi
mov edi, eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [esp + 0x10], 0xffffffff
jne 0x45822a
pop edi
or eax, 0xffffffff
pop esi
ret
mov eax, edi
pop edi
pop esi
ret

Function at 0x458230
Capabilities:
Enumerate files on windows

Disassembly:
sub esp, 0x144
push ebx
mov ebx, dword [esp + 0x14c]
push ebp
mov ebp, dword [esp + 0x15c]
push esi
push edi
mov esi, dword [ebp]
mov dword [esp + 0x10], 0
test ebx, ebx
je 0x4582bb
mov edi, ebx
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
je 0x4582bb
test esi, esi
je 0x458275
cmp esi, 0xffffffff
je 0x458275
push esi
call dword [sym.imp.KERNEL32.dll_FindClose]
lea eax, [esp + 0x14]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov esi, eax
cmp esi, 0xffffffff
mov dword [ebp], esi
je 0x458301
mov eax, dword [esp + 0x160]
test eax, eax
je 0x4582a4
mov ecx, dword [esp + 0x14]
and ecx, 0x10
cmp cl, 0x10
je 0x4582bb
jmp 0x4582b3
mov edx, dword [esp + 0x15c]
mov eax, dword [esp + 0x14]
test edx, eax
je 0x4582bb
mov dword [esp + 0x10], 1
test esi, esi
je 0x458301
cmp esi, 0xffffffff
je 0x458301
mov eax, dword [esp + 0x10]
test eax, eax
jne 0x458338
mov eax, dword [esp + 0x160]
mov edi, dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
lea eax, [esp + 0x14]
push eax
push esi
je 0x45830e
call edi
test eax, eax
je 0x458301
mov ecx, dword [esp + 0x14]
and ecx, 0x10
cmp cl, 0x10
jne 0x458338
lea edx, [esp + 0x14]
push edx
push esi
call edi
test eax, eax
jne 0x4582e9
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x144
ret
call edi
test eax, eax
je 0x458301
mov ebx, dword [esp + 0x15c]
test dword [esp + 0x14], ebx
jne 0x458338
lea ecx, [esp + 0x14]
push ecx
push esi
call edi
test eax, eax
jne 0x45831b
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x144
ret
lea edi, [esp + 0x40]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
push ecx
call fcn.00457030
mov edx, eax
lea edi, [esp + 0x44]
or ecx, 0xffffffff
xor eax, eax
add esp, 4
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
mov eax, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x144
ret

Function at 0x4583a0
Capabilities:
Set file attributes

Disassembly:
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 8]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
ret
Function at 0x458610
Capabilities:
Delete directory

Disassembly:
push esi
mov esi, dword [esp + 0xc]
test esi, esi
jne 0x45861d
xor eax, eax
pop esi
ret
push edi
mov edi, esi
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
pop edi
jne 0x45862f
pop esi
ret
cmp ecx, 1
jne 0x45863d
cmp byte [esi], 0x5c
jne 0x45863d
xor eax, eax
pop esi
ret
push esi
call fcn.004583c0
add esp, 4
test eax, eax
je 0x458651
push esi
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
pop esi
ret

Function at 0x458660
Capabilities:
Get file size
Read file on windows

Disassembly:
mov eax, dword [esp + 8]
push edi
push 0
push 0x20
push 3
push 0
push 3
push SysReAllocString
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
xor eax, eax
cmp edi, 0xffffffff
je 0x4586c9
push ebx
lea ecx, [esp + 0x10]
push esi
push ecx
push edi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ebx, eax
lea edx, [ebx + 8]
push edx
call fcn.00457030
add esp, 4
mov esi, eax
lea eax, [esp + 0x14]
push 0
push eax
lea ecx, [esi + 8]
push ebx
push ecx
push edi
mov dword [esi], 1
mov dword [esi + 4], ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, esi
pop esi
pop ebx
pop edi
ret

Function at 0x4586d0
Capabilities:
Read file on windows

Disassembly:
push ebx
mov ebx, dword [esp + 0xc]
push ebp
push esi
test ebx, ebx
push edi
jne 0x4586e3
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
ret
push ebx
call fcn.0045c5b0
add esp, 4
test eax, eax
jne 0x4586f5
pop edi
pop esi
pop ebp
pop ebx
ret
mov edi, dword [esp + 0x24]
test edi, edi
jg 0x458704
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
ret
mov eax, dword [ebx]
xor esi, esi
cmp eax, 1
jne 0x45875b
mov ebx, dword [ebx + 4]
push edi
call fcn.00469ce2
add esp, 4
mov ebp, eax
lea eax, [esp + 0x18]
push esi
push eax
push edi
push ebp
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x45873e
push ebp
call fcn.00469d0b
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
ret
mov ecx, dword [esp + 0x18]
push ecx
push ebp
call fcn.0045bf20
push ebp
mov esi, eax
call fcn.00469d0b
add esp, 0xc
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
ret
cmp eax, 2
jne 0x45879d
mov ebx, dword [ebx + 4]
lea edx, [edi + 8]
push edx
call fcn.00457030
mov esi, eax
add esp, 4
lea ecx, [esi + 8]
mov dword [esi], 1
mov dword [esi + 4], edi
mov eax, dword [ebx]
push edi
push ecx
mov ecx, ebx
call dword [eax + 0x20]
test eax, eax
jne 0x45879a
push esi
call fcn.004570c0
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
ret
mov dword [esi + 4], eax
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
ret
Function at 0x458810
Capabilities:
Write file on windows

Disassembly:
sub esp, 8
push esi
mov esi, dword [esp + 0x14]
test esi, esi
jne 0x458823
xor eax, eax
pop esi
add esp, 8
ret
push esi
call fcn.0045c5b0
add esp, 4
test eax, eax
jne 0x458835
pop esi
add esp, 8
ret
mov eax, dword [esi]
push ebx
mov ebx, 1
push ebp
cmp eax, ebx
push edi
mov dword [esp + 0x10], 0
jne 0x4588ac
mov eax, dword [esp + 0x1c]
mov edi, dword [esi + 4]
cmp eax, ebx
mov dword [esp + 0x10], ebx
jle 0x4588de
mov ebp, dword [sym.imp.KERNEL32.dll_WriteFile]
lea esi, [esp + 0x2c]
mov eax, dword [esi]
lea edx, [esp + 0x14]
push 0
push edx
lea ecx, [eax + 8]
mov eax, dword [eax + 4]
push eax
push ecx
push edi
call ebp
test eax, eax
je 0x458898
mov eax, dword [esp + 0x1c]
inc ebx
add esi, 0xc
cmp ebx, eax
jl 0x458868
mov eax, dword [esp + 0x10]
pop edi
pop ebp
pop ebx
pop esi
add esp, 8
ret
pop edi
mov dword [esp + 0xc], 0
mov eax, dword [esp + 0xc]
pop ebp
pop ebx
pop esi
add esp, 8
ret
cmp eax, 2
jne 0x4588de
mov eax, dword [esp + 0x1c]
mov esi, dword [esi + 4]
cmp eax, ebx
mov dword [esp + 0x10], ebx
jle 0x4588de
lea edi, [esp + 0x2c]
lea ebx, [eax - 1]
mov eax, dword [edi]
mov edx, dword [esi]
mov ecx, dword [eax + 4]
add eax, 8
push ecx
push eax
mov ecx, esi
call dword [edx + 0x24]
add edi, 0xc
dec ebx
jne 0x4588c7
mov eax, dword [esp + 0x10]
pop edi
pop ebp
pop ebx
pop esi
add esp, 8
ret

Function at 0x4588f0
Capabilities:
Copy file
Delete file
Move file

Disassembly:
push esi
mov esi, dword [esp + 0xc]
push edi
mov edi, dword [esp + 0x1c]
push edi
push esi
call dword [sym.imp.KERNEL32.dll_MoveFileA]
test eax, eax
jne 0x45891a
push eax
push edi
push esi
call dword [sym.imp.KERNEL32.dll_CopyFileA]
test eax, eax
je 0x45891a
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
pop edi
pop esi
ret

Function at 0x459cc0
Capabilities:
Read .ini file

Disassembly:
push ebx
push ebp
push esi
push edi
push 0x400
call fcn.00469ce2
mov ebx, dword [esp + 0x1c]
mov ebp, dword [esp + 0x40]
mov ecx, dword [esp + 0x28]
add esp, 4
mov esi, eax
mov eax, dword [esp + 0x30]
push ebx
push 0x400
push esi
push ebp
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
cmp eax, 0x3ff
jl 0x459d2a
push esi
lea edi, [eax + 0x400]
call fcn.00469d0b
push edi
call fcn.00469ce2
mov edx, dword [esp + 0x38]
add esp, 8
mov esi, eax
mov eax, dword [esp + 0x24]
push ebx
push edi
push esi
push ebp
push edx
push eax
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
dec edi
cmp eax, edi
jge 0x459cfa
mov edi, esi
or ecx, 0xffffffff
xor eax, eax
xor ebx, ebx
repne scasb al, byte es:[edi]
not ecx
dec ecx
je 0x459d46
push ecx
push esi
call fcn.0045bd20
add esp, 8
mov ebx, eax
push esi
call fcn.00469d0b
add esp, 4
mov eax, ebx
pop edi
pop esi
pop ebp
pop ebx
ret
Function at 0x45b310
Capabilities:
Write file on windows

Disassembly:
sub esp, 8
mov eax, dword [esp + 0x10]
push edi
push 0
push 0x20
push 2
push 0
push 0
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
xor eax, eax
cmp edi, 0xffffffff
je 0x45b3a2
mov eax, dword [esp + 0x10]
push ebx
mov ebx, 1
push ebp
cmp eax, ebx
push esi
mov dword [esp + 0x10], ebx
jle 0x45b394
mov ebp, dword [sym.imp.KERNEL32.dll_WriteFile]
lea esi, [esp + 0x2c]
mov eax, dword [esi]
lea edx, [esp + 0x14]
push 0
push edx
lea ecx, [eax + 8]
mov eax, dword [eax + 4]
push eax
push ecx
push edi
call ebp
test eax, eax
je 0x45b38c
mov eax, dword [esp + 0x1c]
inc ebx
add esi, 0xc
cmp ebx, eax
jl 0x45b355
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esp + 0x10]
pop esi
pop ebp
pop ebx
pop edi
add esp, 8
ret
mov dword [esp + 0x10], 0
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esp + 0x10]
pop esi
pop ebp
pop ebx
pop edi
add esp, 8
ret

Function at 0x46c6b0
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebx
push esi
push edi
xor edi, edi
cmp dword [esp + 0x10], edi
mov ebx, ecx
je 0x46c6f2
call fcn.0046f9fa
mov esi, dword [eax + 0xc]
push 0xf0
push dword [esp + 0x14]
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
cmp eax, edi
je 0x46c6f2
push eax
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
cmp eax, edi
jne 0x46c6e9
xor eax, eax
jmp 0x46c6fa
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov edi, eax
push edi
mov ecx, ebx
call fcn.0046c700
pop edi
pop esi
pop ebx
ret 4
Function at 0x46d68b
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov eax, 0x4712c4
call fcn.0045f5bc
sub esp, 0x18
push ebx
push esi
mov esi, ecx
push edi
mov dword [ebp - 0x10], esp
mov dword [ebp - 0x1c], esi
mov eax, dword [esi + 0x48]
mov edi, dword [esi + 0x44]
mov dword [ebp - 0x18], eax
call fcn.0046f9fa
cmp dword [esi + 0x40], 0
mov ebx, dword [eax + 0xc]
je 0x46d6ca
call fcn.0046f9fa
mov ebx, dword [eax + 0xc]
push 5
push dword [esi + 0x40]
push ebx
call dword [sym.imp.KERNEL32.dll_FindResourceA]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov edi, eax
test edi, edi
je 0x46d6d8
push edi
call dword [sym.imp.KERNEL32.dll_LockResource]
mov dword [ebp - 0x18], eax
cmp dword [ebp - 0x18], 0
jne 0x46d6e6
or eax, 0xffffffff
jmp 0x46d7ce
mov ecx, esi
call fcn.0046d601
mov dword [ebp - 0x14], eax
call fcn.0046acf8
xor edi, edi
cmp dword [ebp - 0x14], edi
mov dword [ebp - 0x20], edi
je 0x46d71d
push dword [ebp - 0x14]
call dword [sym.imp.USER32.dll_IsWindowEnabled]
test eax, eax
je 0x46d71d
push edi
push dword [ebp - 0x14]
call dword [sym.imp.USER32.dll_EnableWindow]
mov dword [ebp - 0x20], 1
push esi
mov dword [ebp - 4], edi
call fcn.0046acac
push dword [ebp - 0x14]
call fcn.0046a7dd
push ebx
push eax
push dword [ebp - 0x18]
mov ecx, esi
call fcn.0046d399
cmp eax, edi
je 0x46d790
test byte [esi + 0x24], 0x10
je 0x46d75e
push 4
mov ecx, esi
pop ebx
call fcn.0046a1dd
test ah, 1
je 0x46d756
push 5
pop ebx
push ebx
mov ecx, esi
call fcn.0046c802
cmp dword [esi + 0x1c], edi
je 0x46d790
push 0x97
push edi
push edi
push edi
push edi
push edi
mov ecx, esi
call fcn.0046a211
jmp 0x46d790
or dword [ebp - 4], 0xffffffff
cmp dword [ebp - 0x20], edi
je 0x46d7a4
push 1
push dword [ebp - 0x14]
call dword [sym.imp.USER32.dll_EnableWindow]
cmp dword [ebp - 0x14], edi
je 0x46d7bd
call dword [sym.imp.USER32.dll_GetActiveWindow]
cmp eax, dword [esi + 0x1c]
jne 0x46d7bd
push dword [ebp - 0x14]
call dword [sym.imp.USER32.dll_SetActiveWindow]
mov eax, dword [esi]
mov ecx, esi
call dword [eax + 0x58]
mov ecx, esi
call fcn.0046d63b
mov eax, dword [esi + 0x2c]
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
leave
ret

Function at 0x46f571
Capabilities:
Get thread local storage value

Disassembly:
push ebx
push esi
mov esi, ecx
lea ebx, [esi + 0x1c]
push ebx
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
cmp dword [esp + 0x10], 0
jne 0x46f59f
push dword [esi]
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x46f5bd
push dword [esp + 0xc]
mov ecx, esi
push eax
call fcn.0046f4d7
jmp 0x46f5bd
mov eax, dword [esi + 0x14]
test eax, eax
je 0x46f5bd
push edi
push dword [esp + 0x10]
mov edi, dword [eax + 4]
mov ecx, esi
push eax
call fcn.0046f4d7
test edi, edi
mov eax, edi
jne 0x46f5a7
pop edi
push ebx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop esi
pop ebx
ret 8
Function at 0x408d90
Capabilities:
Access peb ldr_data
Check for peb ntglobalflag flag

Disassembly:
push 0xffffffffffffffff
push 0x4189ae
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
push ecx
push ebx
push ebp
push esi
mov esi, ecx
push edi
mov dword [esp + 0x10], esi
call fcn.00410250
xor edi, edi
mov eax, 0x41c21c
mov dword [esp + 0x1c], edi
mov dword [esi + 0x24], edi
mov dword [esi + 0x20], eax
mov dword [esi + 0x2c], edi
mov dword [esi + 0x28], eax
mov dword [esi + 0x34], edi
mov dword [esi + 0x30], eax
lea ecx, [esi + 0x6c]
mov byte [esp + 0x1c], 3
call fcn.00416d72
lea ecx, [esi + 0x70]
mov byte [esp + 0x1c], 4
call fcn.00416d72
lea ecx, [esi + 0x74]
mov byte [esp + 0x1c], 5
call fcn.00416d72
lea ebp, [esi + 0x78]
mov byte [esp + 0x1c], 6
mov ecx, ebp
call fcn.00416d72
lea ebx, [esi + 0x7c]
mov byte [esp + 0x1c], 7
mov ecx, ebx
call fcn.00416d72
lea ecx, [esi + 0x80]
mov byte [esp + 0x1c], 8
call fcn.00416d72
lea edx, [esi + 0x10]
mov eax, 0xa
mov ecx, eax
push str.Arial
mov dword [edx], eax
mov byte [esp + 0x20], 9
mov dword [esi], fcn.00410390
mov dword [esi + 0x50], edi
mov dword [edx + 4], ecx
xor ecx, ecx
mov dword [esi + 0x5c], 1
mov dword [esi + 0x60], edi
mov dword [edx + 8], eax
mov dword [esi + 0x68], edi
mov dword [esi + 0x54], edi
mov dword [esi + 0x58], edi
mov dword [edx + 0xc], eax
xor eax, eax
mov dword [esi + 0x48], eax
mov dword [esi + 0x40], eax
mov dword [esi + 0x38], eax
mov dword [esi + 0x4c], ecx
mov dword [esi + 0x44], ecx
mov dword [esi + 0x3c], ecx
mov dword [esi + 0x90], eax
mov ecx, ebp
mov dword [esi + 0x94], edi
mov dword [esi + 0x64], edi
call fcn.00416d6c
push str.Times_New_Roman
mov ecx, ebx
call fcn.00416d6c
push str.Arial
lea ecx, [esi + 0x80]
call fcn.00416d6c
mov ecx, dword [esp + 0x14]
mov dword [esi + 0x84], 0xc
mov dword [esi + 0x88], 6
mov dword [esi + 0x8c], 0xa
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x10
ret
Function at 0x408f00
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x418a46
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 8
push esi
mov esi, ecx
push edi
mov dword [esp + 8], esi
mov dword [esi], fcn.00410390
mov eax, dword [esi + 0x60]
mov dword [esp + 0x18], 9
test eax, eax
je 0x408f8c
mov eax, dword [esi + 0x50]
test eax, eax
je 0x408f45
push eax
call sub.MFC42.DLL_operatordelete
add esp, 4
mov eax, dword [esi + 0x54]
test eax, eax
je 0x408f55
push eax
call sub.MFC42.DLL_operatordelete
add esp, 4
mov eax, dword [esi + 0x58]
test eax, eax
je 0x408f8c
mov eax, dword [esi + 0x60]
xor edi, edi
test eax, eax
jle 0x408f80
mov eax, dword [esi + 0x58]
mov eax, dword [eax + edi*4]
test eax, eax
je 0x408f78
push eax
call sub.MFC42.DLL_operatordelete
add esp, 4
mov eax, dword [esi + 0x60]
inc edi
cmp edi, eax
jl 0x408f65
mov eax, dword [esi + 0x58]
push eax
call sub.MFC42.DLL_operatordelete
add esp, 4
lea ecx, [esi + 0x80]
mov byte [esp + 0x18], 8
call sub.MFC42.DLL_CString::CString
lea ecx, [esi + 0x7c]
mov byte [esp + 0x18], 7
call sub.MFC42.DLL_CString::CString
lea ecx, [esi + 0x78]
mov byte [esp + 0x18], 6
call sub.MFC42.DLL_CString::CString
lea ecx, [esi + 0x74]
mov byte [esp + 0x18], 5
call sub.MFC42.DLL_CString::CString
lea ecx, [esi + 0x70]
mov byte [esp + 0x18], 4
call sub.MFC42.DLL_CString::CString
lea ecx, [esi + 0x6c]
mov byte [esp + 0x18], 3
call sub.MFC42.DLL_CString::CString
lea edi, [esi + 0x30]
mov dword [esp + 0xc], edi
mov dword [edi], 0x41c1dc
mov ecx, edi
mov byte [esp + 0x18], 0xa
call sub.MFC42.DLL_CGdiObject::DeleteObject
mov dword [edi], 0x41c1f0
lea edi, [esi + 0x28]
mov dword [esp + 0xc], edi
mov dword [edi], 0x41c1dc
mov ecx, edi
mov byte [esp + 0x18], 0xb
call sub.MFC42.DLL_CGdiObject::DeleteObject
mov dword [edi], 0x41c1f0
lea edi, [esi + 0x20]
mov dword [esp + 0xc], edi
mov dword [edi], 0x41c1dc
mov ecx, edi
mov byte [esp + 0x18], 0xc
call sub.MFC42.DLL_CGdiObject::DeleteObject
mov ecx, esi
mov dword [edi], 0x41c1f0
mov dword [esp + 0x18], 0xffffffff
call fcn.004102d0
mov ecx, dword [esp + 0x10]
pop edi
pop esi
mov dword fs:[0], ecx
add esp, 0x14
ret
Function at 0x409ea0
Capabilities:
Start service

Disassembly:
push ebx
push ebp
push esi
push edi
push 0xf003f
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov edi, eax
test edi, edi
jne 0x409ee9
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 5
jne 0x409ee9
mov esi, dword [sym.imp.MSVCRT.dll_printf]
push str.IsaAdSys:_You_do_not_have_rights_to_access_the_Service_Control_Manager_and_n
call esi
push str.IsaAdSys:_the_IsaAdSys_driver_is_not_installed_or_started._Please_ask__n
call esi
push str.IsaAdSys:_your_administrator_to_install_the_driver_on_your_behalf._n
call esi
add esp, 0xc
xor al, al
pop edi
pop esi
pop ebp
pop ebx
ret
mov ebx, dword [sym.imp.MSVCRT.dll_printf]
mov ebp, dword [sym.imp.ADVAPI32.dll_OpenServiceA]
push 0xf01ff
push str.IsaAdSys
push edi
call ebp
mov esi, eax
test esi, esi
jne 0x409f59
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 5
je 0x409f48
cmp eax, 0x7b
je 0x409f37
cmp eax, 0x424
jne 0x409ef5
push str.IsaAdSys:_The_IsaAdSys_driver_does_not_exist._Installing_driver._n
call ebx
push str.IsaAdSys:_This_can_take_up_to_30_seconds_on_some_machines_._._n
call ebx
add esp, 8
call fcn.00409fc0
jmp 0x409ef5
push str.IsaAdSys:_The_specified_service_name_is_invalid._n
call ebx
add esp, 4
xor al, al
pop edi
pop esi
pop ebp
pop ebx
ret
push str.IsaAdSys:_You_do_not_have_rights_to_the_IsaAdSys_service_database_n
call ebx
add esp, 4
xor al, al
pop edi
pop esi
pop ebp
pop ebx
ret
push 0
push 0
push esi
call dword [sym.imp.ADVAPI32.dll_StartServiceA]
test eax, eax
je 0x409f80
push str.IsaAdSys:_The_IsaAdSys_driver_has_been_successfully_started._n
call ebx
add esp, 4
push esi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
pop edi
pop esi
pop ebp
mov al, 1
pop ebx
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x420
jne 0x409fa5
push str.IsaAdSys:_The_IsaAdSys_driver_is_already_running._n
call ebx
add esp, 4
push esi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
pop edi
pop esi
pop ebp
mov al, 1
pop ebx
ret
push str.IsaAdSys:_Unknown_error_while_starting_IsaAdSys_driver_service._n
call ebx
push str.IsaAdSys:_Does_IsaAdSys.SYS_exist_in_your_System32Drivers_Directory__n
call ebx
add esp, 8
xor al, al
pop edi
pop esi
pop ebp
pop ebx
ret
Function at 0x409fc0
Capabilities:
Copy file
Create service
Get common file path

Disassembly:
sub esp, 0x50
lea eax, [esp]
push esi
push edi
push 0x37
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
mov esi, dword [sym.imp.MSVCRT.dll_printf]
test eax, eax
jne 0x409fed
push str.IsaAdSys:_Failed_to_get_System_Directory._Is_System_Directory_Path___55_Characters__n
call esi
push str.IsaAdSys:_Please_manually_copy_driver_to_your_system32_driver_directory._n
call esi
add esp, 8
lea ecx, [esp + 8]
push str.DriversIsaAdSys.sys
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcatA]
lea edx, [esp + 8]
push edx
push str.IsaAdSys:_Copying_driver_to__s_n
call esi
add esp, 8
lea eax, [esp + 8]
push 0
push eax
push str.IsaAdSys.sys
call dword [sym.imp.KERNEL32.dll_CopyFileA]
test eax, eax
jne 0x40a038
lea ecx, [esp + 8]
push ecx
push str.IsaAdSys:_Failed_to_copy_driver_to__s_n
call esi
push str.IsaAdSys:_Please_manually_copy_driver_to_your_system32_driver_directory._n
call esi
add esp, 0xc
push 0xf003f
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
push 0
push 0
push 0
push 0
push 0
push str.System32DriversIsaAdSys.sys
push 1
push 3
push 1
push 0xf01ff
push str.IsaAdSys
push str.IsaAdSys
push eax
call dword [sym.imp.ADVAPI32.dll_CreateServiceA]
mov edi, eax
test edi, edi
jne 0x40a0b3
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x431
jne 0x40a09c
push str.IsaAdSys:_Driver_already_exists._No_action_taken._n
call esi
add esp, 4
push edi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
pop edi
pop esi
add esp, 0x50
ret
push str.IsaAdSys:_Unknown_error_while_creating_Service._n
call esi
add esp, 4
push edi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
pop edi
pop esi
add esp, 0x50
ret
push str.IsaAdSys:_Driver_successfully_installed._n
call esi
add esp, 4
push edi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
pop edi
pop esi
add esp, 0x50
ret
Function at 0x40af20
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x14
push ebx
push esi
xor esi, esi
push edi
mov edi, ecx
mov dword [esp + 0x14], 0x10
mov dword [esp + 0x18], esi
mov dword [esp + 0x1c], 0x20
mov byte [esp + 0x10], 0
mov bl, byte [esp + esi*4 + 0x14]
push ebx
push 0x330
call fcn.00409d70
mov cl, byte [esp + 0x18]
add esp, 8
xor cl, bl
test esi, esi
mov byte [esp + 0x10], cl
jne 0x40af71
fld dword [0x41c658]
jmp 0x40af77
fld dword [0x41c654]
sub esp, 8
mov ecx, edi
fstp qword [esp]
call fcn.0040b270
inc esi
cmp esi, 3
jl 0x40af49
mov eax, dword [esp + 0x10]
push eax
push 0x330
call fcn.00409d70
add esp, 8
mov ecx, edi
push 0x40440000
push 0
call fcn.0040b270
xor bl, bl
xor esi, esi
push 0x330
call fcn.00409dc0
add esp, 4
and eax, 0xff
mov dl, al
mov ecx, edi
push 0x40340000
push 0
mov dword [esi + 0x424670], eax
xor bl, dl
call fcn.0040b270
push 0x330
call fcn.00409dc0
and eax, 0xff
add esp, 4
mov cl, al
mov dword [esi + 0x4245d0], eax
xor bl, cl
push 0x40340000
push 0
mov ecx, edi
call fcn.0040b270
add esi, 4
cmp esi, 0x40
jl 0x40afae
push 0x330
call fcn.00409dc0
add esp, 4
and eax, 0xff
xor bl, al
mov ecx, edi
push 0x40340000
push 0
mov dword [0x4246ec], eax
mov byte [esp + 0x18], bl
call fcn.0040b270
push 0x330
call fcn.00409dc0
mov ecx, dword [0x4246ec]
add esp, 4
and eax, 0xff
cmp ecx, 0xa5
mov dword [0x42464c], eax
jne 0x40b0b3
mov ecx, dword [esp + 0x10]
and ecx, 0xff
cmp eax, ecx
jne 0x40b0a6
mov ecx, 0x425d84
xor eax, eax
mov dx, word [eax + 0x424670]
add ecx, 2
shl dx, 8
add dx, word [eax + 0x4245d0]
add eax, 4
cmp ecx, 0x425da4
mov word [ecx - 2], dx
jl 0x40b06f
mov eax, dword [ebp + 8]
and eax, 0xffff
mov dword [eax*4 + 0x4244b8], 0
mov ax, 1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
mov ecx, dword [ebp + 8]
and ecx, 0xffff
lea esi, [ecx*4 + 0x4244b8]
mov ecx, dword [ecx*4 + 0x4244b8]
inc ecx
mov dword [esi], ecx
mov eax, dword [0x4244b8]
cmp eax, 0x1e
jle 0x40b0fd
push 0xf1
push 0x330
call fcn.00409d70
add esp, 8
mov ecx, 8
xor eax, eax
mov edi, 0x425d84
mov dword [esi], 0
rep stosd dword es:[edi], eax
pop edi
pop esi
xor ax, ax
pop ebx
mov esp, ebp
pop ebp
ret 4