joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4021ed
Capabilities:
Create process on windows
Query environment variable
Self delete

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x208
push esi
mov esi, 0x104
push esi
lea eax, [ebp - 0x104]
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
je 0x402288
push esi
lea eax, [ebp - 0x104]
push eax
push eax
call dword [sym.imp.KERNEL32.dll_GetShortPathNameA]
test eax, eax
je 0x402288
lea eax, [ebp - 0x104]
push eax
lea eax, [ebp - 0x208]
push 0x4011fc
push eax
call fcn.00403e87
add esp, 0xc
push esi
lea eax, [ebp - 0x104]
push eax
push 0x4011f4
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableA]
test eax, eax
je 0x402288
mov esi, dword [sym.imp.KERNEL32.dll_lstrcatA]
push 0x4011f0
lea eax, [ebp - 0x104]
push eax
call esi
lea eax, [ebp - 0x208]
push eax
lea eax, [ebp - 0x104]
push eax
call esi
push 0
lea eax, [ebp - 0x104]
push eax
call dword [sym.imp.KERNEL32.dll_WinExec]
pop esi
leave
ret

Function at 0x402308
Capabilities:
Accept command line arguments
Check os version

Disassembly:
push ebp
lea ebp, [esp - 0x64]
sub esp, 0xa0
call dword [sym.imp.KERNEL32.dll_GetTickCount]
push eax
call fcn.00402001
mov eax, dword [ebp + 0x6c]
mov dword [0x405a00], eax
call fcn.004022dc
test eax, eax
je 0x402337
xor eax, eax
jmp 0x40247a
push esi
mov esi, 0x9c
push esi
lea eax, [ebp - 0x3c]
push 0
push eax
call fcn.00403510
add esp, 0xc
lea eax, [ebp - 0x3c]
mov dword [ebp - 0x3c], esi
mov esi, dword [sym.imp.KERNEL32.dll_GetVersionExA]
push eax
call esi
test eax, eax
jne 0x402370
lea eax, [ebp - 0x3c]
push eax
mov dword [ebp - 0x3c], 0x94
call esi
test eax, eax
je 0x402382
cmp dword [ebp - 0x38], 5
jne 0x40237c
cmp dword [ebp - 0x34], 1
jae 0x402389
cmp dword [ebp - 0x38], 6
jae 0x402389
xor eax, eax
jmp 0x402479
and dword [ebp + 0x60], 0
push ebx
lea eax, [ebp + 0x60]
push eax
call dword [sym.imp.KERNEL32.dll_GetCommandLineW]
push eax
call dword [sym.imp.SHELL32.dll_CommandLineToArgvW]
mov ebx, eax
test ebx, ebx
je 0x402439
push edi
xor edi, edi
inc edi
cmp dword [ebp + 0x60], edi
jle 0x402431
lea esi, [ebx + edi*4]
push 0x401278
push dword [esi]
call fcn.00403a11
pop ecx
pop ecx
test eax, eax
jne 0x4023d3
mov dword [0x405a04], 1
jmp 0x40242b
push 0x401264
push dword [esi]
call fcn.00403a11
pop ecx
pop ecx
test eax, eax
jne 0x4023f1
mov dword [0x405a08], 1
jmp 0x40242b
push 0x401258
push dword [esi]
call fcn.00403a11
pop ecx
pop ecx
test eax, eax
jne 0x40240f
mov dword [0x405a0c], 1
jmp 0x40242b
push 0x401240
push dword [esi]
call fcn.00403a11
pop ecx
pop ecx
test eax, eax
jne 0x40242b
mov dword [0x405a10], 1
inc edi
cmp edi, dword [ebp + 0x60]
jl 0x4023b2
push ebx
call dword [sym.imp.KERNEL32.dll_LocalFree]
pop edi
mov eax, dword [ebp + 0x70]
pop ebx
test eax, eax
je 0x402449
mov ecx, dword [0x405a04]
mov dword [eax], ecx
mov eax, dword [ebp + 0x74]
test eax, eax
je 0x402458
mov ecx, dword [0x405a08]
mov dword [eax], ecx
mov eax, dword [ebp + 0x78]
test eax, eax
je 0x402467
mov ecx, dword [0x405a0c]
mov dword [eax], ecx
mov eax, dword [ebp + 0x7c]
test eax, eax
je 0x402476
mov ecx, dword [0x405a10]
mov dword [eax], ecx
xor eax, eax
inc eax
pop esi
add ebp, 0x64
leave
ret 0x14
Function at 0x4024aa
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push esi
push edi
xor esi, esi
push esi
push esi
push 2
push esi
push esi
push 0x40000000
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
cmp edi, 0xffffffff
je 0x4024fe
push esi
lea eax, [ebp + 8]
push eax
push dword [ebp + 0x10]
mov dword [ebp + 8], esi
push dword [ebp + 0xc]
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x4024e8
inc esi
jmp 0x4024ee
call dword [sym.imp.KERNEL32.dll_GetLastError]
push edi
call dword [sym.imp.KERNEL32.dll_FlushFileBuffers]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x402504
call dword [sym.imp.KERNEL32.dll_GetLastError]
pop edi
mov eax, esi
pop esi
pop ebp
ret 0xc

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

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push edi
xor edi, edi
push edi
push edi
push 3
push edi
push 1
push 0x80000000
push dword [ebp + 8]
mov dword [ebp - 4], edi
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x40258c
push esi
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, dword [ebp + 0x10]
push eax
push 0x40
mov dword [esi], eax
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov ecx, dword [ebp + 0xc]
mov dword [ecx], eax
cmp eax, edi
je 0x40257a
push edi
lea ecx, [ebp + 8]
push ecx
push dword [esi]
mov dword [ebp + 8], edi
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x402572
mov dword [ebp - 4], 1
jmp 0x402582
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x402582
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [esi], edi
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop esi
jmp 0x402592
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov eax, dword [ebp - 4]
pop edi
pop ebx
leave
ret 0xc

Function at 0x4027dd
Capabilities:
Check os version

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x94
lea eax, [ebp - 0x94]
push eax
mov dword [ebp - 0x94], 0x94
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
test eax, eax
je 0x402818
xor eax, eax
cmp dword [ebp - 0x84], 2
jne 0x402820
cmp dword [ebp - 0x90], 6
sete al
leave
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
xor eax, eax
leave
ret

Function at 0x402822
Capabilities:
Enumerate processes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x128
push esi
push edi
xor edi, edi
push edi
push 2
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov esi, eax
cmp esi, 0xffffffff
je 0x40288e
lea eax, [ebp - 0x128]
push eax
push esi
mov dword [ebp - 0x128], 0x128
call sub.KERNEL32.dll_Process32First
test eax, eax
je 0x40287f
mov eax, dword [ebp - 0x120]
cmp eax, dword [ebp + 8]
je 0x402877
lea eax, [ebp - 0x128]
push eax
push esi
call sub.KERNEL32.dll_Process32Next
test eax, eax
jne 0x402859
jmp 0x402885
mov edi, dword [ebp - 0x110]
jmp 0x402885
call dword [sym.imp.KERNEL32.dll_GetLastError]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x402894
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov eax, edi
pop edi
pop esi
leave
ret 4
Function at 0x40289c
Capabilities:
Check os version

Disassembly:
push ebp
lea ebp, [esp - 0x70]
sub esp, 0xa4
push ebx
mov ebx, dword [ebp + 0x7c]
push esi
push edi
xor edi, edi
mov dword [ebp + 0x68], edi
mov dword [ebp + 0x6c], edi
cmp ebx, edi
je 0x4029ba
mov esi, 0x9c
push esi
lea eax, [ebp - 0x34]
push edi
push eax
mov dword [ebx], edi
call fcn.00403510
add esp, 0xc
lea eax, [ebp - 0x34]
mov dword [ebp - 0x34], esi
mov esi, dword [sym.imp.KERNEL32.dll_GetVersionExA]
push eax
call esi
test eax, eax
jne 0x4028fa
lea eax, [ebp - 0x34]
push eax
mov dword [ebp - 0x34], 0x94
call esi
test eax, eax
je 0x4029ba
cmp dword [ebp - 0x30], 6
jb 0x4029ba
lea eax, [ebp + 0x6c]
push eax
push 0x18
push dword [ebp + 0x78]
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
je 0x4029af
lea eax, [ebp + 0x7c]
push eax
push edi
push edi
push 0x19
push dword [ebp + 0x6c]
mov dword [ebp + 0x7c], edi
mov edi, dword [sym.imp.ADVAPI32.dll_GetTokenInformation]
call edi
test eax, eax
jne 0x40299e
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
call esi
cmp eax, 0x7a
jne 0x40299a
push dword [ebp + 0x7c]
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov esi, eax
test esi, esi
je 0x40299e
lea eax, [ebp + 0x7c]
push eax
push dword [ebp + 0x7c]
push esi
push 0x19
push dword [ebp + 0x6c]
call edi
test eax, eax
je 0x40298b
push dword [esi]
call dword [sym.imp.ADVAPI32.dll_GetSidSubAuthorityCount]
mov al, byte [eax]
dec al
movzx eax, al
push eax
push dword [esi]
call dword [sym.imp.ADVAPI32.dll_GetSidSubAuthority]
mov eax, dword [eax]
mov dword [ebx], eax
mov dword [ebp + 0x68], 1
jmp 0x402991
call dword [sym.imp.KERNEL32.dll_GetLastError]
push esi
call dword [sym.imp.KERNEL32.dll_LocalFree]
jmp 0x4029a4
call esi
jmp 0x4029a4
call dword [sym.imp.KERNEL32.dll_GetLastError]
push dword [ebp + 0x6c]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x4029b5
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov eax, dword [ebp + 0x68]
jmp 0x4029bc
xor eax, eax
pop edi
pop esi
pop ebx
add ebp, 0x70
leave
ret 8
Function at 0x4029c6
Capabilities:
Check os version
Get token membership

Disassembly:
push ebp
lea ebp, [esp - 0x78]
sub esp, 0xf8
push ebx
push esi
push edi
mov esi, 0x9c
push esi
xor edi, edi
lea eax, [ebp - 0x3c]
push edi
push eax
call fcn.00403510
add esp, 0xc
lea eax, [ebp - 0x3c]
push eax
mov dword [ebp - 0x3c], esi
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
test eax, eax
jne 0x402a07
call dword [sym.imp.KERNEL32.dll_GetLastError]
xor eax, eax
jmp 0x402af1
cmp dword [ebp - 0x2c], 2
jne 0x402aeb
cmp dword [ebp - 0x38], 6
jb 0x402aeb
lea eax, [ebp + 0x74]
push eax
push 8
mov dword [ebp + 0x74], edi
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
je 0x402ae1
mov esi, dword [sym.imp.ADVAPI32.dll_GetTokenInformation]
lea eax, [ebp + 0x68]
push eax
push 4
lea eax, [ebp + 0x60]
push eax
push 0x12
push dword [ebp + 0x74]
mov dword [ebp + 0x68], edi
call esi
test eax, eax
jne 0x402a68
call dword [sym.imp.KERNEL32.dll_GetLastError]
push dword [ebp + 0x74]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x402a00
cmp dword [ebp + 0x60], 3
mov ebx, dword [sym.imp.KERNEL32.dll_CloseHandle]
jne 0x402ad2
lea eax, [ebp + 0x68]
push eax
push 4
lea eax, [ebp + 0x70]
push eax
push 0x13
push dword [ebp + 0x74]
mov dword [ebp + 0x70], edi
call esi
test eax, eax
je 0x402a57
lea eax, [ebp + 0x64]
push eax
lea eax, [ebp - 0x80]
push eax
push edi
push 0x1a
mov dword [ebp + 0x64], 0x44
call dword [sym.imp.ADVAPI32.dll_CreateWellKnownSid]
test eax, eax
je 0x402ac5
lea eax, [ebp + 0x6c]
push eax
lea eax, [ebp - 0x80]
push eax
push dword [ebp + 0x70]
mov dword [ebp + 0x6c], edi
call dword [sym.imp.ADVAPI32.dll_CheckTokenMembership]
test eax, eax
je 0x402ac5
mov edi, dword [ebp + 0x6c]
jmp 0x402acb
call dword [sym.imp.KERNEL32.dll_GetLastError]
push dword [ebp + 0x70]
call ebx
jmp 0x402ada
call dword [sym.imp.SHELL32.dll_IsUserAnAdmin]
mov edi, eax
push dword [ebp + 0x74]
call ebx
jmp 0x402ae7
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov eax, edi
jmp 0x402af1
call dword [sym.imp.SHELL32.dll_IsUserAnAdmin]
pop edi
pop esi
pop ebx
add ebp, 0x78
leave
ret
Function at 0x402af9
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x58
mov eax, dword [ebp + 8]
push ebx
push esi
xor esi, esi
mov dword [ebp - 4], esi
cmp eax, esi
je 0x402b0f
mov dword [eax], esi
lea eax, [ebp + 0x10]
push eax
push dword [ebp + 0xc]
call fcn.00403e9d
pop ecx
pop ecx
add eax, 0x100
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov ebx, eax
cmp ebx, esi
jne 0x402b38
xor eax, eax
jmp 0x402bd8
push edi
lea eax, [ebp + 0x10]
push eax
push dword [ebp + 0xc]
push ebx
call fcn.00403e92
push 0x10
lea eax, [ebp - 0x14]
push esi
push eax
call fcn.00403510
push 0x44
pop edi
push edi
lea eax, [ebp - 0x58]
push esi
push eax
call fcn.00403510
add esp, 0x18
lea eax, [ebp - 0x58]
push eax
mov dword [ebp - 0x58], edi
call dword [sym.imp.KERNEL32.dll_GetStartupInfoA]
xor eax, eax
mov word [ebp - 0x28], ax
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp - 0x58]
push eax
push esi
push esi
push esi
push esi
push esi
push esi
xor edi, edi
push ebx
inc edi
push esi
mov dword [ebp - 0x2c], edi
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
test eax, eax
je 0x402bc7
push 0xffffffffffffffff
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp dword [ebp + 8], esi
je 0x402bb2
push dword [ebp + 8]
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_GetExitCodeProcess]
push dword [ebp - 0x10]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
push dword [ebp - 0x14]
call esi
mov dword [ebp - 4], edi
jmp 0x402bcd
call dword [sym.imp.KERNEL32.dll_GetLastError]
push ebx
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov eax, dword [ebp - 4]
pop edi
pop esi
pop ebx
leave
ret
Function at 0x402f02
Capabilities:
Enumerate pe sections

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
push esi
push edi
push dword [ebp + 0x10]
mov esi, 0x402f01
sub esi, 0x402e88
mov dword [ebp - 0xc], esi
call fcn.004020ec
and dword [ebp - 4], 0
lea eax, [eax + esi + 0x111]
mov dword [ebp - 8], eax
mov eax, dword [ebp + 8]
mov esi, dword [eax + 0x3c]
add esi, eax
movzx edi, word [esi + 6]
movzx eax, word [esi + 0x14]
lea ebx, [eax + esi + 0x18]
test edi, edi
je 0x40305b
push 5
push 0x4013b4
push ebx
call fcn.0040214c
test eax, eax
je 0x402f6c
add ebx, 0x28
inc dword [ebp - 4]
cmp dword [ebp - 4], edi
jb 0x402f4b
jmp 0x40305b
mov eax, dword [ebp - 8]
cmp dword [ebx + 0x10], eax
jae 0x402f7b
xor eax, eax
jmp 0x40305e
mov edi, dword [ebx + 0x14]
add edi, dword [ebp + 8]
push 0x110
push 0
push edi
call fcn.004020ce
mov eax, dword [esi + 0x28]
push 0x4013a4
push 0x40137c
mov dword [edi + 8], eax
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x40139c
push 0x40137c
mov dword [edi], eax
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp dword [ebp + 0x14], 0
mov dword [edi + 4], eax
je 0x402fd9
push dword [ebp + 0x14]
lea eax, [edi + 0xc]
push eax
call fcn.00402194
push dword [ebp + 0x10]
lea eax, [edi + 0x110]
push eax
call fcn.00402194
push dword [ebp + 0x10]
call fcn.004020ec
push dword [ebp - 0xc]
lea edi, [eax + edi + 0x111]
push 0x402e88
push edi
call fcn.004020ae
push dword [ebp + 0x10]
call fcn.004020ec
mov ecx, dword [ebx + 0xc]
lea eax, [eax + ecx + 0x111]
mov dword [esi + 0x28], eax
or dword [ebx + 0x24], 0x20000000
xor eax, eax
mov dword [esi + 0x88], eax
mov dword [esi + 0x8c], eax
mov dword [ebp - 8], eax
mov dword [ebp - 4], eax
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 8]
push eax
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.imagehlp.dll_CheckSumMappedFile]
test eax, eax
je 0x403055
mov eax, dword [ebp - 4]
mov dword [esi + 0x58], eax
jmp 0x40305b
call dword [sym.imp.KERNEL32.dll_GetLastError]
xor eax, eax
inc eax
pop edi
pop esi
pop ebx
leave
ret 0x10
Function at 0x401000
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push esi
mov esi, dword [ebp + 8]
xor ecx, ecx
cmp esi, ecx
mov dword [ebp - 8], ecx
mov byte [ebp - 1], cl
je 0x40107c
mov al, byte [esi]
mov dword [ebp - 8], 1
cmp al, cl
mov dword [ebp + 8], ecx
je 0x40107c
push ebx
push edi
mov ecx, esi
xor byte [ebp - 1], al
push 2
movsx edi, al
mov eax, edi
pop ebx
cdq
idiv ebx
mov eax, edi
push 4
pop edi
mov ebx, edx
cdq
sub eax, edx
sar eax, 1
add bl, al
movsx edx, bl
lea eax, [edx + 1]
xor eax, edx
cdq
idiv edi
movsx edx, byte [ebp - 1]
add al, bl
movsx eax, al
xor eax, edx
cdq
idiv edi
mov dl, byte [ebp + 8]
and dl, 3
add al, dl
add al, bl
inc dword [ebp + 8]
mov byte [ecx], al
mov eax, dword [ebp + 8]
lea ecx, [eax + esi]
mov al, byte [eax + esi]
test al, al
jne 0x401029
pop edi
pop ebx
mov eax, dword [ebp - 8]
pop esi
leave
ret 4
Function at 0x4010ec
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x318
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x40110a
xor eax, eax
jmp 0x401261
push ebx
push esi
xor ebx, ebx
push edi
lea eax, [ebp - 0x110]
push ebx
mov esi, 0x104
push eax
push esi
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetFullPathNameA]
mov edi, eax
cmp edi, ebx
je 0x40125c
cmp edi, esi
jb 0x401143
push 0x6f
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor edi, edi
jmp 0x40125c
lea eax, [ebp - 4]
push eax
call dword [sym.imp.SHELL32.dll_SHGetDesktopFolder]
test eax, eax
jl 0x40125c
lea eax, [ebp - 0x318]
push esi
push eax
lea eax, [ebp - 0x110]
push 0xffffffffffffffff
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_AreFileApisANSI]
neg eax
sbb eax, eax
inc eax
push eax
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
test eax, eax
jne 0x401197
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x401190
push 0x6f
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor edi, edi
jmp 0x401253
mov eax, dword [ebp - 4]
lea edx, [ebp - 8]
push ebx
push edx
mov ecx, dword [eax]
lea edx, [ebp + 8]
push edx
lea edx, [ebp - 0x318]
push edx
push ebx
push ebx
push eax
call dword [ecx + 0xc]
cmp eax, ebx
jge 0x4011d2
mov ecx, eax
and ecx, 0x1fff0000
cmp ecx, 0x70000
jne 0x4011ce
and eax, 0xffff
push eax
jmp 0x40118a
push 0xd
jmp 0x40118a
lea eax, [ebp - 0x110]
push eax
push dword [ebp - 8]
call dword [sym.imp.SHELL32.dll_SHGetPathFromIDListA]
mov edi, eax
cmp edi, ebx
jne 0x4011fa
cmp byte [ebp - 0x110], bl
je 0x4011fa
push 0xd
call dword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x401230
lea eax, [ebp - 0x110]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov edi, eax
lea esi, [edi + 1]
cmp esi, dword [ebp + 0x10]
jbe 0x40121d
push 0x7a
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov edi, esi
jmp 0x401230
push dword [ebp + 0x10]
lea eax, [ebp - 0x110]
push eax
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_lstrcpynA]
lea eax, [ebp - 0xc]
push eax
call dword [sym.imp.SHELL32.dll_SHGetMalloc]
test eax, eax
jl 0x401253
mov eax, dword [ebp - 0xc]
push dword [ebp - 8]
mov ecx, dword [eax]
push eax
call dword [ecx + 0x14]
mov eax, dword [ebp - 0xc]
push eax
mov ecx, dword [eax]
call dword [ecx + 8]
mov eax, dword [ebp - 4]
push eax
mov ecx, dword [eax]
call dword [ecx + 8]
mov eax, edi
pop edi
pop esi
pop ebx
leave
ret 0xc
Function at 0x40157f
Capabilities:
Accept command line arguments
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x518
and byte [ebp - 0x518], 0
push esi
push edi
mov ecx, 0x103
xor eax, eax
lea edi, [ebp - 0x517]
rep stosd dword es:[edi], eax
and byte [ebp - 0x108], 0
push 0x41
stosw word es:[edi], ax
stosb byte es:[edi], al
pop ecx
xor eax, eax
push dword [ebp + 8]
lea edi, [ebp - 0x107]
rep stosd dword es:[edi], eax
mov esi, 0x40f
push str._s_setup.exe
lea eax, [ebp - 0x518]
push esi
push eax
or edi, 0xffffffff
call fcn.004118f0
add esp, 0x10
lea eax, [ebp - 0x518]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x401674
push 1
lea eax, [ebp - 0x108]
push 0x104
push eax
call fcn.00402236
test eax, eax
je 0x401661
push str.__Cmd
lea eax, [ebp - 0x518]
push esi
push eax
call fcn.00411948
lea eax, [ebp - 0x108]
push eax
lea eax, [ebp - 0x518]
push esi
push eax
call fcn.00411948
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
mov edi, eax
test edi, edi
je 0x401661
push edi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
test eax, eax
je 0x401661
push 0x414220
lea eax, [ebp - 0x518]
push esi
push eax
call fcn.00411948
push edi
lea eax, [ebp - 0x518]
push esi
push eax
call fcn.00411948
push 0
lea eax, [ebp - 0x518]
push 0xffffffffffffffff
push eax
call fcn.004022e2
push 1
pop edi
mov eax, edi
pop edi
pop esi
leave
ret

Function at 0x40167a
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10c
and byte [ebp - 0x10c], 0
push ebx
push esi
push edi
push 0x41
xor eax, eax
and dword [ebp - 4], eax
cmp dword [ebp + 8], eax
pop ecx
lea edi, [ebp - 0x10b]
rep stosd dword es:[edi], eax
je 0x401759
push dword [ebp + 8]
mov esi, dword [sym.imp.KERNEL32.dll_lstrcpyA]
lea eax, [ebp - 0x10c]
push eax
call esi
mov ebx, 0x104
push str._syscheck.exe
lea eax, [ebp - 0x10c]
push ebx
push eax
call fcn.00411948
mov edi, dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
lea eax, [ebp - 0x10c]
push eax
call edi
cmp eax, 0xffffffff
je 0x4016f8
push 0
lea eax, [ebp - 0x10c]
push 0xffffffffffffffff
push eax
call fcn.004022e2
mov dword [ebp - 4], eax
jmp 0x401759
push dword [ebp + 8]
lea eax, [ebp - 0x10c]
push eax
call esi
push str._syscheck.dll
lea eax, [ebp - 0x10c]
push ebx
push eax
call fcn.00411948
lea eax, [ebp - 0x10c]
push eax
call edi
cmp eax, 0xffffffff
je 0x401759
lea eax, [ebp - 0x10c]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
xor esi, esi
cmp edi, esi
je 0x401759
push str.CheckSysAndDisplayErrors
push edi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp eax, esi
je 0x401752
push esi
push esi
push esi
push esi
call eax
mov dword [ebp - 4], eax
push edi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov eax, dword [ebp - 4]
pop edi
pop esi
pop ebx
leave
ret
Function at 0x401761
Capabilities:
Check if file exists
Get common file path
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x21c
push ebx
push esi
push edi
push 0x41
xor ebx, ebx
pop ecx
xor eax, eax
lea edi, [ebp - 0x21b]
mov byte [ebp - 0x21c], bl
push 0x41
rep stosd dword es:[edi], eax
pop ecx
lea edi, [ebp - 0x113]
mov byte [ebp - 0x114], bl
mov dword [ebp - 0xc], ebx
rep stosd dword es:[edi], eax
lea edi, [ebp - 8]
xor esi, esi
stosd dword es:[edi], eax
lea eax, [ebp - 0x21c]
mov dword [ebp - 4], ebx
push eax
push 0x105
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
test eax, eax
je 0x401863
lea eax, [ebp - 0x21c]
push ebx
push eax
call fcn.004026bd
mov esi, dword [sym.imp.KERNEL32.dll_GetSystemTimeAsFileTime]
lea eax, [ebp - 0xc]
push eax
call esi
push ebx
lea eax, [ebp - 0x21c]
push dword [ebp - 0xc]
mov ebx, 0x104
push eax
push str._sEAC_u__8.8x
lea eax, [ebp - 0x114]
push ebx
push eax
call fcn.004118f0
mov edi, dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
add esp, 0x18
lea eax, [ebp - 0x114]
push eax
call edi
cmp eax, 0xffffffff
je 0x401847
push 5
call dword [sym.imp.KERNEL32.dll_Sleep]
inc dword [ebp - 4]
lea eax, [ebp - 0xc]
push eax
call esi
push dword [ebp - 4]
lea eax, [ebp - 0x21c]
push dword [ebp - 0xc]
push eax
push str._sEAC_u__8.8x
lea eax, [ebp - 0x114]
push ebx
push eax
call fcn.004118f0
add esp, 0x18
lea eax, [ebp - 0x114]
push eax
jmp 0x401804
lea eax, [ebp - 0x114]
push eax
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.004118d9
push dword [ebp + 8]
call fcn.004023a5
mov esi, eax
mov eax, esi
pop edi
pop esi
pop ebx
leave
ret 8

Function at 0x40186c
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x90
push ebx
push esi
push edi
push 9
xor ebx, ebx
pop ecx
xor eax, eax
lea edi, [ebp - 0x2b]
mov byte [ebp - 0x2c], bl
push 0x18
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
pop ecx
xor eax, eax
lea edi, [ebp - 0x8f]
mov byte [ebp - 0x90], bl
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
xor esi, esi
cmp dword [ebp + 8], 0xffffffff
mov dword [ebp - 4], ebx
stosb byte es:[edi], al
je 0x401918
lea eax, [ebp - 0x2c]
push str.33D55E00_1916_4656_A942_92D420609FC0
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
push 1
push ebx
push 0xffffffffffffff9c
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp eax, 0xffffffff
je 0x401918
lea eax, [ebp - 4]
push ebx
push eax
lea eax, [ebp - 0x90]
push 0x64
push eax
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x401918
lea eax, [ebp - 0x2c]
push eax
call fcn.00401000
lea eax, [ebp - 0x2c]
mov byte [ebp - 0x69], bl
push eax
lea eax, [ebp - 0x90]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpA]
test eax, eax
jne 0x401918
mov eax, dword [ebp + 0xc]
mov esi, dword [ebp - 0x30]
cmp eax, ebx
je 0x401918
mov ecx, dword [ebp - 0x34]
mov dword [eax], ecx
mov eax, esi
pop edi
pop esi
pop ebx
leave
ret