joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4021f2
Capabilities:
Accept command line arguments
Parse pe header
Terminate process

Disassembly:
push 0x60
push 0x408750
call fcn.00404928
mov edi, 0x94
mov eax, edi
call fcn.00401ed0
mov dword [ebp - 0x18], esp
mov esi, esp
mov dword [esi], edi
push esi
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
mov ecx, dword [esi + 0x10]
mov dword [0x40a6ec], ecx
mov eax, dword [esi + 4]
mov dword [0x40a6f8], eax
mov edx, dword [esi + 8]
mov dword [0x40a6fc], edx
mov esi, dword [esi + 0xc]
and esi, 0x7fff
mov dword [0x40a6f0], esi
cmp ecx, 2
je 0x402252
or esi, 0x8000
mov dword [0x40a6f0], esi
shl eax, 8
add eax, edx
mov dword [0x40a6f4], eax
xor esi, esi
push esi
mov edi, dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
call edi
cmp word [eax], 0x5a4d
jne 0x40228d
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x40228d
movzx eax, word [ecx + 0x18]
cmp eax, 0x10b
je 0x4022a5
cmp eax, 0x20b
je 0x402292
mov dword [ebp - 0x1c], esi
jmp 0x4022b9
cmp dword [ecx + 0x84], 0xe
jbe 0x40228d
xor eax, eax
cmp dword [ecx + 0xf8], esi
jmp 0x4022b3
cmp dword [ecx + 0x74], 0xe
jbe 0x40228d
xor eax, eax
cmp dword [ecx + 0xe8], esi
setne al
mov dword [ebp - 0x1c], eax
push esi
call fcn.004023e8
pop ecx
test eax, eax
jne 0x4022e5
cmp dword [0x40a6d4], 1
jne 0x4022d2
call fcn.004040f5
push 0x1c
call fcn.00403f7d
push 0xff
call fcn.00403bbe
pop ecx
pop ecx
call fcn.0040489e
mov dword [ebp - 4], esi
call fcn.004046f3
test eax, eax
jge 0x4022fe
push 0x1b
call fcn.004021cd
pop ecx
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
mov dword [0x40bc98], eax
call fcn.004045d1
mov dword [0x40a6cc], eax
call fcn.0040452f
test eax, eax
jge 0x402324
push 8
call fcn.004021cd
pop ecx
call fcn.004042fc
test eax, eax
jge 0x402335
push 9
call fcn.004021cd
pop ecx
push 1
call fcn.00403bee
pop ecx
mov dword [ebp - 0x28], eax
cmp eax, esi
je 0x40234b
push eax
call fcn.004021cd
pop ecx
mov dword [ebp - 0x44], esi
lea eax, [ebp - 0x70]
push eax
call dword [sym.imp.KERNEL32.dll_GetStartupInfoA]
call fcn.0040429f
mov dword [ebp - 0x20], eax
test byte [ebp - 0x44], 1
je 0x40236c
movzx eax, word [ebp - 0x40]
jmp 0x40236f
push 0xa
pop eax
push eax
push dword [ebp - 0x20]
push esi
push esi
call edi
push eax
call fcn.00401000
mov edi, eax
mov dword [ebp - 0x2c], edi
cmp dword [ebp - 0x1c], esi
jne 0x40238d
push edi
call fcn.00403d19
call fcn.00403d3b
jmp 0x4023bf
or dword [ebp - 4], 0xffffffff
mov eax, edi
lea esp, [ebp - 0x7c]
call fcn.00404963
ret
Function at 0x403c58
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
push esi
xor esi, esi
inc esi
cmp dword [0x40a72c], esi
push edi
jne 0x403c78
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
cmp dword [ebp + 0xc], 0
mov al, byte [ebp + 0x10]
mov dword [0x40a728], esi
mov byte [0x40a724], al
jne 0x403cde
mov ecx, dword [0x40bc68]
test ecx, ecx
je 0x403cbf
mov eax, dword [0x40bc64]
sub eax, 4
cmp eax, ecx
jmp 0x403cb8
mov eax, dword [eax]
test eax, eax
je 0x403caa
call eax
mov eax, dword [0x40bc64]
sub eax, 4
cmp eax, dword [0x40bc68]
mov dword [0x40bc64], eax
jae 0x403ca2
mov eax, 0x40a020
mov esi, 0x40a028
cmp eax, esi
mov edi, eax
jae 0x403cde
mov eax, dword [edi]
test eax, eax
je 0x403cd7
call eax
add edi, 4
cmp edi, esi
jb 0x403ccf
mov eax, 0x40a02c
mov esi, 0x40a030
cmp eax, esi
mov edi, eax
jae 0x403cfd
mov eax, dword [edi]
test eax, eax
je 0x403cf6
call eax
add edi, 4
cmp edi, esi
jb 0x403cee
cmp dword [ebp + 0x10], 0
pop edi
pop esi
jne 0x403d17
push dword [ebp + 8]
mov dword [0x40a72c], 1
call fcn.00403bbe
pop ebp
ret

Function at 0x403f7d
Capabilities:
Write file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x90]
sub esp, 0x110
mov eax, dword [0x40a590]
mov ecx, dword [ebp + 0x98]
push ebx
xor eax, ebp
push esi
mov dword [ebp + 0x8c], eax
xor edx, edx
push edi
xor eax, eax
cmp ecx, dword [eax*8 + 0x40a058]
je 0x403fb4
inc eax
cmp eax, 0x13
jb 0x403fa5
mov esi, eax
shl esi, 3
cmp ecx, dword [esi + 0x40a058]
jne 0x4040d7
mov eax, dword [0x40a6d4]
cmp eax, 1
je 0x4040b2
cmp eax, edx
jne 0x403fe4
cmp dword [0x40a044], 1
je 0x4040b2
cmp ecx, 0xfc
je 0x4040d7
push 0x104
lea eax, [ebp - 0x7c]
push eax
push edx
mov byte [ebp + 0x88], dl
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x40401a
lea eax, [ebp - 0x7c]
push str._program_name_unknown_
push eax
call fcn.00405cc0
pop ecx
pop ecx
lea edi, [ebp - 0x7c]
mov eax, edi
push eax
call fcn.004052f0
inc eax
cmp eax, 0x3c
pop ecx
jbe 0x40404e
mov eax, edi
push eax
call fcn.004052f0
mov edi, eax
lea eax, [ebp - 0x7c]
sub eax, 0x3b
push 3
add edi, eax
push 0x408be0
push edi
call fcn.00405dc0
add esp, 0x10
push edi
call fcn.004052f0
push dword [esi + 0x40a05c]
mov ebx, eax
call fcn.004052f0
lea eax, [ebx + eax + 0x1c]
pop ecx
add eax, 3
pop ecx
and eax, 0xfffffffc
call fcn.00401ed0
mov ebx, esp
push str.Runtime_Error__n_nProgram:
push ebx
call fcn.00405cc0
push edi
push ebx
call fcn.00405cd0
push 0x408bc0
push ebx
call fcn.00405cd0
push dword [esi + 0x40a05c]
push ebx
call fcn.00405cd0
push 0x12010
push str.Microsoft_Visual_C_Runtime_Library
push ebx
call fcn.00405bc4
add esp, 0x2c
jmp 0x4040d7
push edx
lea eax, [ebp - 0x80]
push eax
lea esi, [esi + 0x40a05c]
push dword [esi]
call fcn.004052f0
pop ecx
push eax
push dword [esi]
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
lea esp, [ebp - 0x8c]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0x8c]
xor ecx, ebp
call fcn.00405412
add ebp, 0x90
leave
ret
Function at 0x404fe6
Capabilities:
Write file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x3a4]
sub esp, 0x424
mov eax, dword [0x40a590]
mov ecx, dword [ebp + 0x3ac]
push ebx
push esi
xor eax, ebp
cmp ecx, dword [0x40bb44]
push edi
mov edi, dword [ebp + 0x3b0]
mov dword [ebp + 0x3a0], eax
mov dword [ebp - 0x78], edi
jae 0x405188
mov eax, ecx
sar eax, 5
lea ebx, [eax*4 + 0x40bb60]
mov eax, dword [ebx]
mov esi, ecx
and esi, 0x1f
shl esi, 3
mov al, byte [eax + esi + 4]
test al, 1
mov dword [ebp - 0x80], ebx
je 0x405188
and dword [ebp - 0x70], 0
and dword [ebp - 0x7c], 0
cmp dword [ebp + 0x3b4], 0
jne 0x40505c
xor eax, eax
jmp 0x40519c
test al, 0x20
je 0x40506f
push 2
push 0
push 0
push ecx
call fcn.00406987
add esp, 0x10
mov eax, dword [ebx]
add eax, esi
test byte [eax + 4], 0x80
je 0x405104
and dword [ebp - 0x68], 0
cmp dword [ebp + 0x3b4], 0
mov dword [ebp - 0x6c], edi
jbe 0x405165
mov ecx, dword [ebp - 0x6c]
xor edi, edi
sub ecx, dword [ebp - 0x78]
lea eax, [ebp - 0x64]
cmp ecx, dword [ebp + 0x3b4]
jae 0x4050c9
mov edx, dword [ebp - 0x6c]
inc dword [ebp - 0x6c]
mov dl, byte [edx]
inc ecx
cmp dl, 0xa
jne 0x4050ba
inc dword [ebp - 0x7c]
mov byte [eax], 0xd
inc eax
inc edi
mov ebx, dword [ebp - 0x80]
mov byte [eax], dl
inc eax
inc edi
cmp edi, 0x400
jl 0x40509c
mov edi, eax
lea eax, [ebp - 0x64]
sub edi, eax
push 0
lea eax, [ebp - 0x74]
push eax
push edi
lea eax, [ebp - 0x64]
push eax
mov eax, dword [ebx]
push dword [eax + esi]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x405129
mov eax, dword [ebp - 0x74]
add dword [ebp - 0x70], eax
cmp eax, edi
jl 0x405132
mov eax, dword [ebp - 0x6c]
sub eax, dword [ebp - 0x78]
cmp eax, dword [ebp + 0x3b4]
jb 0x405091
jmp 0x405132
push 0
lea ecx, [ebp - 0x74]
push ecx
push dword [ebp + 0x3b4]
push edi
push dword [eax]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x405129
mov eax, dword [ebp - 0x74]
and dword [ebp - 0x68], 0
mov dword [ebp - 0x70], eax
jmp 0x405132
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x68], eax
mov eax, dword [ebp - 0x70]
test eax, eax
jne 0x405183
cmp dword [ebp - 0x68], eax
je 0x405162
push 5
pop eax
cmp dword [ebp - 0x68], eax
jne 0x405157
mov dword [0x40a6e0], 9
mov dword [0x40a6e4], eax
jmp 0x405199
push dword [ebp - 0x68]
call fcn.00404dbd
pop ecx
jmp 0x405199
mov edi, dword [ebp - 0x78]
mov eax, dword [ebx]
test byte [eax + esi + 4], 0x40
je 0x405177
cmp byte [edi], 0x1a
je 0x405055
mov dword [0x40a6e0], 0x1c
jmp 0x405192
sub eax, dword [ebp - 0x7c]
jmp 0x40519c
mov dword [0x40a6e0], 9
and dword [0x40a6e4], 0
or eax, 0xffffffff
mov ecx, dword [ebp + 0x3a0]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00405412
add ebp, 0x3a4
leave
ret
Function at 0x405bc4
Capabilities:
Link many functions at runtime

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
xor ebx, ebx
cmp dword [0x40a878], ebx
push esi
push edi
jne 0x405c44
push str.user32.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
cmp edi, ebx
je 0x405c7f
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x4091a8
push edi
call esi
test eax, eax
mov dword [0x40a878], eax
je 0x405c7f
push str.GetActiveWindow
push edi
call esi
push str.GetLastActivePopup
push edi
mov dword [0x40a87c], eax
call esi
cmp dword [0x40a6ec], 2
mov dword [0x40a880], eax
jne 0x405c44
push str.GetUserObjectInformationA
push edi
call esi
test eax, eax
mov dword [0x40a888], eax
je 0x405c44
push str.GetProcessWindowStation
push edi
call esi
mov dword [0x40a884], eax
mov eax, dword [0x40a884]
test eax, eax
je 0x405c89
call eax
test eax, eax
je 0x405c70
lea ecx, [ebp - 4]
push ecx
push 0xc
lea ecx, [ebp - 0x10]
push ecx
push 1
push eax
call dword [0x40a888]
test eax, eax
je 0x405c70
test byte [ebp - 8], 1
jne 0x405c89
cmp dword [0x40a6f8], 4
jb 0x405c83
or byte [ebp + 0x12], 0x20
jmp 0x405ca8
xor eax, eax
jmp 0x405cb8
or byte [ebp + 0x12], 4
jmp 0x405ca8
mov eax, dword [0x40a87c]
test eax, eax
je 0x405ca8
call eax
mov ebx, eax
test ebx, ebx
je 0x405ca8
mov eax, dword [0x40a880]
test eax, eax
je 0x405ca8
push ebx
call eax
mov ebx, eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
push ebx
call dword [0x40a878]
pop edi
pop esi
pop ebx
leave
ret
Function at 0x40675e
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
push ebx
push esi
mov esi, dword [ebp + 8]
mov ebx, dword [esi + 8]
test bl, 3
jne 0x40678c
mov eax, dword fs:[0x18]
mov dword [ebp + 8], eax
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 8]
cmp ebx, ecx
mov dword [ebp - 4], ecx
jb 0x406793
cmp ebx, dword [eax + 4]
jae 0x406793
xor eax, eax
jmp 0x406983
push edi
mov edi, dword [esi + 0xc]
cmp edi, 0xffffffff
jne 0x4067a4
xor eax, eax
inc eax
jmp 0x406982
xor edx, edx
mov dword [ebp + 8], edx
mov eax, ebx
mov ecx, dword [eax]
cmp ecx, 0xffffffff
je 0x4067ba
cmp ecx, edx
jae 0x4068ff
cmp dword [eax + 4], 0
je 0x4067c3
inc dword [ebp + 8]
inc edx
add eax, 0xc
cmp edx, edi
jbe 0x4067ab
cmp dword [ebp + 8], 0
je 0x4067e5
mov eax, dword [esi - 8]
cmp eax, dword [ebp - 4]
jb 0x4068ff
cmp eax, esi
jae 0x4068ff
mov eax, dword [0x40a890]
mov edi, ebx
and edi, 0xfffff000
xor esi, esi
test eax, eax
jle 0x40680a
cmp dword [esi*4 + 0x40a898], edi
je 0x406903
inc esi
cmp esi, eax
jl 0x4067f8
push 0x1c
lea eax, [ebp - 0x20]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x40697f
cmp dword [ebp - 8], 0x1000000
jne 0x40697f
test byte [ebp - 0xc], 0xcc
je 0x406888
mov ecx, dword [ebp - 0x1c]
cmp word [ecx], 0x5a4d
jne 0x40697f
mov eax, dword [ecx + 0x3c]
add eax, ecx
cmp dword [eax], 0x4550
jne 0x40697f
cmp word [eax + 0x18], 0x10b
jne 0x40697f
sub ebx, ecx
cmp word [eax + 6], 0
movzx ecx, word [eax + 0x14]
lea ecx, [ecx + eax + 0x18]
jbe 0x40697f
mov eax, dword [ecx + 0xc]
cmp ebx, eax
jb 0x406888
mov edx, dword [ecx + 8]
add edx, eax
cmp ebx, edx
jae 0x406888
test byte [ecx + 0x27], 0x80
jne 0x4068ff
push 1
push 0x40a8d8
call dword [sym.imp.KERNEL32.dll_InterlockedExchange]
test eax, eax
jne 0x40679c
mov ecx, dword [0x40a890]
test ecx, ecx
mov edx, ecx
jle 0x4068bc
lea eax, [ecx*4 + 0x40a894]
cmp dword [eax], edi
je 0x4068bc
dec edx
sub eax, 4
test edx, edx
jg 0x4068b0
test edx, edx
jne 0x4068ed
push 0xf
pop ebx
cmp ecx, ebx
jg 0x4068c9
mov ebx, ecx
xor edx, edx
test ebx, ebx
jl 0x4068e1
lea eax, [edx*4 + 0x40a898]
mov esi, dword [eax]
inc edx
cmp edx, ebx
mov dword [eax], edi
mov edi, esi
jle 0x4068cf
cmp ecx, 0x10
jge 0x4068ed
inc ecx
mov dword [0x40a890], ecx
push 0
push 0x40a8d8
call dword [sym.imp.KERNEL32.dll_InterlockedExchange]
jmp 0x40679c
xor eax, eax
jmp 0x406982
test esi, esi
jle 0x40679c
mov ebx, dword [sym.imp.KERNEL32.dll_InterlockedExchange]
push 1
push 0x40a8d8
call ebx
test eax, eax
jne 0x40679c
cmp dword [esi*4 + 0x40a898], edi
je 0x406959
mov eax, dword [0x40a890]
lea esi, [eax - 1]
test esi, esi
jl 0x406947
cmp dword [esi*4 + 0x40a898], edi
je 0x406943
dec esi
jns 0x406937
test esi, esi
jge 0x406957
cmp eax, 0x10
jge 0x406952
inc eax
mov dword [0x40a890], eax
lea esi, [eax - 1]
jmp 0x406959
je 0x406971
xor ecx, ecx
test esi, esi
jl 0x406971
lea eax, [ecx*4 + 0x40a898]
mov edx, dword [eax]
inc ecx
cmp ecx, esi
mov dword [eax], edi
mov edi, edx
jle 0x40695f
push 0
push 0x40a8d8
call ebx
jmp 0x40679c
or eax, 0xffffffff
pop edi
pop esi
pop ebx
leave
ret
Function at 0x406cc9
Capabilities:
Clear file content

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x100c
call fcn.00401ed0
mov eax, dword [0x40a590]
push ebx
mov ebx, dword [ebp + 8]
xor eax, ebp
push esi
xor esi, esi
cmp ebx, dword [0x40bb44]
mov dword [ebp - 4], eax
jae 0x406e14
mov eax, ebx
sar eax, 5
mov eax, dword [eax*4 + 0x40bb60]
mov ecx, ebx
and ecx, 0x1f
test byte [eax + ecx*8 + 4], 1
je 0x406e14
push 1
push esi
push ebx
call fcn.00405841
add esp, 0xc
cmp eax, 0xffffffff
mov dword [ebp - 0x1008], eax
je 0x406e1e
push 2
push esi
push ebx
call fcn.00405841
add esp, 0xc
cmp eax, 0xffffffff
je 0x406e1e
push edi
mov edi, dword [ebp + 0xc]
sub edi, eax
test edi, edi
jle 0x406dbe
push 0x1000
lea eax, [ebp - 0x1004]
push esi
push eax
call fcn.00407c80
push 0x8000
push ebx
call fcn.00407ce0
add esp, 0x14
mov dword [ebp - 0x100c], eax
mov eax, 0x1000
cmp edi, eax
jge 0x406d7a
mov eax, edi
push eax
lea eax, [ebp - 0x1004]
push eax
push ebx
call fcn.00404fe6
add esp, 0xc
cmp eax, 0xffffffff
je 0x406d98
sub edi, eax
test edi, edi
jg 0x406d6f
jmp 0x406dae
cmp dword [0x40a6e4], 5
jne 0x406dab
mov dword [0x40a6e0], 0xd
or esi, 0xffffffff
push dword [ebp - 0x100c]
push ebx
call fcn.00407ce0
pop ecx
pop ecx
jmp 0x406dfe
jge 0x406dfe
push 0
push dword [ebp + 0xc]
push ebx
call fcn.00405841
push ebx
call fcn.00404faa
add esp, 0x10
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
mov esi, eax
neg esi
sbb esi, esi
neg esi
dec esi
cmp esi, 0xffffffff
jne 0x406dfe
mov dword [0x40a6e0], 0xd
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [0x40a6e4], eax
push 0
push dword [ebp - 0x1008]
push ebx
call fcn.00405841
add esp, 0xc
mov eax, esi
pop edi
jmp 0x406e21
mov dword [0x40a6e0], 9
or eax, 0xffffffff
mov ecx, dword [ebp - 4]
pop esi
xor ecx, ebp
pop ebx
call fcn.00405412
leave
ret
Function at 0x406e2f
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
push esi
mov esi, dword [ebp + 8]
cmp esi, dword [0x40bb44]
push edi
jae 0x407006
mov eax, esi
sar eax, 5
lea edi, [eax*4 + 0x40bb60]
mov eax, dword [edi]
and esi, 0x1f
shl esi, 3
add eax, esi
mov dl, byte [eax + 4]
test dl, 1
je 0x407006
and dword [ebp - 0xc], 0
cmp dword [ebp + 0x10], 0
mov ebx, dword [ebp + 0xc]
mov ecx, ebx
je 0x406eda
test dl, 2
jne 0x406eda
test dl, 0x48
je 0x406ea4
cmp byte [eax + 5], 0xa
je 0x406ea4
mov eax, dword [edi]
mov al, byte [eax + esi + 5]
dec dword [ebp + 0x10]
mov byte [ebx], al
mov eax, dword [edi]
lea ecx, [ebx + 1]
mov dword [ebp - 0xc], 1
mov byte [eax + esi + 5], 0xa
push 0
lea eax, [ebp - 0x10]
push eax
push dword [ebp + 0x10]
mov eax, dword [edi]
push ecx
push dword [eax + esi]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x406eed
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 5
pop ecx
cmp eax, ecx
jne 0x406ed5
mov dword [0x40a6e4], ecx
jmp 0x40700d
cmp eax, 0x6d
jne 0x406ee1
xor eax, eax
jmp 0x40701a
push eax
call fcn.00404dbd
pop ecx
jmp 0x407017
mov eax, dword [ebp - 0x10]
mov ecx, dword [edi]
add dword [ebp - 0xc], eax
test byte [ecx + esi + 4], 0x80
je 0x407001
test eax, eax
je 0x406f14
cmp byte [ebx], 0xa
jne 0x406f14
mov eax, ecx
lea eax, [eax + esi + 4]
or byte [eax], 4
jmp 0x406f1d
mov eax, dword [edi]
lea eax, [eax + esi + 4]
and byte [eax], 0xfb
mov eax, dword [ebp + 0xc]
mov ecx, dword [ebp - 0xc]
add ecx, eax
cmp eax, ecx
mov dword [ebp - 8], eax
mov dword [ebp - 0xc], ecx
jae 0x406ffb
mov eax, dword [ebp - 8]
mov al, byte [eax]
cmp al, 0x1a
je 0x406feb
cmp al, 0xd
je 0x406f4f
mov byte [ebx], al
inc ebx
inc dword [ebp - 8]
jmp 0x406fdd
dec ecx
cmp dword [ebp - 8], ecx
jae 0x406f69
mov eax, dword [ebp - 8]
inc eax
cmp byte [eax], 0xa
jne 0x406f64
add dword [ebp - 8], 2
jmp 0x406fbd
mov dword [ebp - 8], eax
jmp 0x406fd9
inc dword [ebp - 8]
push 0
lea eax, [ebp - 0x10]
push eax
push 1
lea eax, [ebp - 1]
push eax
mov eax, dword [edi]
push dword [eax + esi]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x406f91
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x406fd9
cmp dword [ebp - 0x10], 0
je 0x406fd9
mov eax, dword [edi]
test byte [eax + esi + 4], 0x48
je 0x406fb2
mov al, byte [ebp - 1]
cmp al, 0xa
je 0x406fbd
mov byte [ebx], 0xd
mov ecx, dword [edi]
mov byte [ecx + esi + 5], al
jmp 0x406fdc
cmp ebx, dword [ebp + 0xc]
jne 0x406fc2
cmp byte [ebp - 1], 0xa
jne 0x406fc2
mov byte [ebx], 0xa
jmp 0x406fdc
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.00406987
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x406fdd
mov byte [ebx], 0xd
inc ebx
mov ecx, dword [ebp - 0xc]
cmp dword [ebp - 8], ecx
jb 0x406f33
jmp 0x406ffb
mov eax, dword [edi]
test byte [eax + esi + 4], 0x40
jne 0x406ffb
lea esi, [eax + esi + 4]
or byte [esi], 2
sub ebx, dword [ebp + 0xc]
mov dword [ebp - 0xc], ebx
mov eax, dword [ebp - 0xc]
jmp 0x40701a
and dword [0x40a6e4], 0
mov dword [0x40a6e0], 9
or eax, 0xffffffff
pop edi
pop esi
pop ebx
leave
ret
Function at 0x4071bf
Capabilities:
Get system information on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x4c
push ebx
push esi
push edi
push 4
pop eax
call fcn.00401ed0
mov esi, esp
push 0x1c
lea eax, [ebp - 0x28]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x40725a
mov ebx, dword [ebp - 0x24]
lea eax, [ebp - 0x4c]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemInfo]
mov ecx, dword [ebp - 0x48]
mov eax, dword [0x40a6ec]
lea edi, [ecx - 1]
not edi
and edi, esi
sub edi, ecx
mov esi, eax
dec esi
neg esi
sbb esi, esi
and esi, 0xfffffff1
add esi, 0x11
imul esi, ecx
add esi, ebx
cmp edi, esi
mov dword [ebp - 8], ecx
jb 0x40725a
cmp eax, 1
je 0x40727b
mov dword [ebp - 4], ebx
mov ebx, 0x1000
push 0x1c
lea eax, [ebp - 0x28]
push eax
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x40725a
mov eax, dword [ebp - 0x1c]
add dword [ebp - 4], eax
test dword [ebp - 0x18], ebx
je 0x407227
test byte [ebp - 0x13], 1
mov eax, dword [ebp - 0x28]
mov dword [ebp - 4], eax
je 0x407256
xor eax, eax
inc eax
jmp 0x40729a
cmp edi, eax
jae 0x40725e
xor eax, eax
jmp 0x40729a
cmp eax, esi
jae 0x407265
mov dword [ebp - 4], esi
push 4
push ebx
push dword [ebp - 8]
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov eax, dword [0x40a6ec]
jmp 0x40727e
mov dword [ebp - 4], edi
dec eax
neg eax
sbb eax, eax
and eax, 0x103
lea ecx, [ebp - 0xc]
push ecx
inc eax
push eax
push dword [ebp - 8]
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
lea esp, [ebp - 0x58]
pop edi
pop esi
pop ebx
leave
ret
Function at 0x4037c1
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ecx + 0x10]
push edi
cmp esi, 0x40
jb 0x40381f
mov ecx, dword [ebp + 8]
mov eax, 0x5a4d
cmp word [ecx], ax
jne 0x40381f
mov edx, dword [ecx + 0x3c]
lea eax, [edx + 0xf8]
cmp esi, eax
jb 0x40381f
cmp dword [edx + ecx], 0x4550
jne 0x40381f
movzx eax, word [edx + ecx + 4]
mov edi, 0x14c
cmp ax, di
je 0x40380a
mov edi, 0x8664
cmp ax, di
je 0x40381f
lea eax, [ecx + 0x98]
add eax, edx
mov ecx, dword [eax]
test ecx, ecx
je 0x40381f
add ecx, 0xc
cmp esi, ecx
jae 0x403821
xor eax, eax
pop edi
pop esi
pop ebp
ret 4

Function at 0x40c5b1
Capabilities:
Encode data using add xor sub operations
Encode data using xor

Disassembly:
xchg byte [ecx + 0x42], bl
add edi, dword fs:[ecx + 0x69]
xor esi, dword [edx + 0x2aee138e]
out dx, al
sub dh, byte [ebx + edi*2]
out dx, al
sub dh, byte [ebx + edi*2]
xor dword [ecx - 0x49], ebx
pushal
xchg dword [eax + 3], ebp
mov ch, 0xd9
adc al, 0xc0
push cs
or dh, bh
cmc
sbb al, 0xe4
sar dword [0x22826c2b], 0xab
sbb al, 0x2d
sub bh, byte [esp + ebx*8 + 0x4a]
or eax, eax
sahf
jecxz 0x40c5a6
sub esp, ecx
mov esi, 0xceaba6e7
shl dword [esi], 0xe3
sbb ah, byte [ecx]
scasd eax, dword es:[edi]
invalid
Function at 0x401850
Capabilities:
Read file on windows
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push esi
push edi
mov edi, eax
push edi
call fcn.00462e12
mov ecx, dword [ebp + 8]
add esp, 4
push 0
mov esi, eax
lea eax, [ebp - 4]
push eax
push edi
push esi
push ecx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x4018a7
mov eax, dword [ebp - 4]
cmp eax, edi
jne 0x4018a7
push 0
lea edx, [ebp - 8]
push edx
push eax
mov eax, dword [ebp + 0xc]
push esi
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
push esi
mov edi, eax
call fcn.004629cd
add esp, 4
mov eax, edi
pop edi
pop esi
mov esp, ebp
pop ebp
ret
push esi
xor edi, edi
call fcn.004629cd
add esp, 4
mov eax, edi
pop edi
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x419d00
Capabilities:
Copy file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x479aa1
mov eax, dword fs:[0]
push eax
sub esp, 0x1ac
mov eax, dword [0x51484c]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, dword [ebp + 8]
mov edi, dword [ebp + 0xc]
lea ecx, [ebp - 0x130]
call fcn.00408110
lea ecx, [ebp - 0x1b8]
mov dword [ebp - 4], 0
call fcn.00408110
push esi
lea ecx, [ebp - 0x130]
mov byte [ebp - 4], 1
call fcn.00409370
push edi
lea ecx, [ebp - 0x1b8]
call fcn.00409370
push 0x5c
push 0x2f
lea ecx, [ebp - 0x130]
call fcn.00408f60
push 0x5c
push 0x2f
lea ecx, [ebp - 0x1b8]
call fcn.00408f60
lea ecx, [ebp - 0xa8]
call fcn.00422e30
lea ecx, [ebp - 0xa8]
mov byte [ebp - 4], 2
call fcn.00422e60
test al, al
je 0x419dd2
xor eax, eax
cmp byte [ebp + 0x10], al
lea ecx, [ebp - 0x1b8]
setne al
push eax
call fcn.00408920
push eax
lea ecx, [ebp - 0x130]
call fcn.00408920
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileA]
jmp 0x419df9
xor ecx, ecx
cmp byte [ebp + 0x10], cl
setne cl
push ecx
lea ecx, [ebp - 0x1b8]
call fcn.004091d0
push eax
lea ecx, [ebp - 0x130]
call fcn.004091d0
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileW]
test eax, eax
lea ecx, [ebp - 0xa8]
setne bl
mov byte [ebp - 4], 1
call fcn.00422e50
lea ecx, [ebp - 0x1b8]
mov byte [ebp - 4], 0
call fcn.004081c0
lea ecx, [ebp - 0x130]
mov dword [ebp - 4], 0xffffffff
call fcn.004081c0
mov al, bl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00462878
mov esp, ebp
pop ebp
ret