joyce8/EMBER2024-capa huggingface dataset:
Function at 0x405d3d
Capabilities:
Delete directory
Delete file
Enumerate files on windows
Enumerate files recursively
Set file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x144
push esi
push edi
mov edi, dword [ebp + 8]
push edi
call fcn.00406022
test byte [ebp + 0xc], 8
mov dword [ebp - 4], eax
je 0x405d71
push edi
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
neg eax
sbb eax, eax
inc eax
add dword [0x44bae8], eax
jmp 0x405f3a
push ebx
mov ebx, dword [ebp + 0xc]
and ebx, 1
mov dword [ebp + 8], ebx
je 0x405d8f
test eax, eax
je 0x405ebe
test byte [ebp + 0xc], 2
je 0x405ebe
mov esi, 0x436430
push edi
push esi
call fcn.0040643b
test ebx, ebx
je 0x405dac
push str..
push esi
call fcn.00406459
jmp 0x405db2
push edi
call fcn.00405f87
push 0x40a23c
push edi
call fcn.00406459
push edi
call fcn.0040644c
mov ebx, eax
lea eax, [ebp - 0x144]
push eax
push esi
add ebx, edi
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov esi, eax
cmp esi, 0xffffffff
je 0x405eb4
cmp byte [ebp - 0x118], 0x2e
jne 0x405e03
cmp byte [ebp - 0x117], 0x2e
je 0x405e97
cmp byte [ebp - 0x117], 0
je 0x405e97
lea eax, [ebp - 0x118]
push eax
push ebx
call fcn.0040643b
test byte [ebp - 0x144], 0x10
je 0x405e2e
mov eax, dword [ebp + 0xc]
and eax, 3
cmp al, 3
jne 0x405e97
push dword [ebp + 0xc]
push edi
call fcn.00405d3d
jmp 0x405e97
push edi
push str.Delete:_DeleteFile___s__
call fcn.004067e1
mov eax, dword [ebp - 0x144]
pop ecx
pop ecx
and al, 0xfe
push eax
push edi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
push edi
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
test eax, eax
jne 0x405e8f
test byte [ebp + 0xc], 4
push edi
je 0x405e7b
push str.Delete:_DeleteFile_on_Reboot___s__
call fcn.004067e1
pop ecx
pop ecx
push edi
push 0xfffffffffffffff1
call fcn.00405724
push 0
push edi
call fcn.00406184
jmp 0x405e97
push str.Delete:_DeleteFile_failed___s__
call fcn.004067e1
inc dword [0x44bae8]
pop ecx
pop ecx
jmp 0x405e97
push edi
push 0xfffffffffffffff2
call fcn.00405724
lea eax, [ebp - 0x144]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x405de0
push esi
call dword [sym.imp.KERNEL32.dll_FindClose]
cmp dword [ebp + 8], 0
je 0x405ebe
and byte [ebx - 1], 0
xor esi, esi
pop ebx
cmp dword [ebp + 8], esi
je 0x405f3a
cmp dword [ebp - 4], esi
push edi
jne 0x405ee0
push str.RMDir:_RemoveDirectory_invalid_input___s__
call fcn.004067e1
inc dword [0x44bae8]
pop ecx
pop ecx
jmp 0x405f3a
call fcn.004067fd
test eax, eax
je 0x405f3a
push edi
call fcn.00405f40
push edi
push str.RMDir:_RemoveDirectory___s__
call fcn.004067e1
pop ecx
pop ecx
push edi
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
test eax, eax
jne 0x405f32
test byte [ebp + 0xc], 4
push edi
je 0x405f2b
push str.RMDir:_RemoveDirectory_on_Reboot___s__
call fcn.004067e1
pop ecx
pop ecx
push edi
push 0xfffffffffffffff1
call fcn.00405724
push esi
push edi
call fcn.00406184
jmp 0x405f3a
push str.RMDir:_RemoveDirectory_failed___s__
jmp 0x405ed1
push edi
push 0xffffffffffffffe5
call fcn.00405724
pop edi
pop esi
leave
ret 8
Function at 0x406022
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push esi
push edi
push dword [esp + 0xc]
mov esi, 0x438430
push esi
call fcn.0040643b
push esi
call fcn.00405fd3
mov edi, eax
test edi, edi
jne 0x406043
xor eax, eax
jmp 0x406095
push edi
call fcn.004066ab
test byte [0x44ba70], 0x80
je 0x40605c
mov al, byte [edi]
test al, al
je 0x40603f
cmp al, 0x5c
je 0x40603f
sub edi, esi
push esi
call fcn.0040644c
cmp eax, edi
push esi
jle 0x40607f
call fcn.004067fd
test eax, eax
je 0x406077
test byte [eax], 0x10
je 0x40603f
push esi
call fcn.00405f87
jmp 0x40605e
call fcn.00405f40
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
xor ecx, ecx
cmp eax, 0xffffffff
setne cl
mov eax, ecx
pop edi
pop esi
ret 4

Function at 0x40610c
Capabilities:
Get file attributes

Disassembly:
push dword [esp + 4]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
mov ecx, eax
push 0
inc ecx
neg ecx
sbb ecx, ecx
and ecx, eax
push ecx
push dword [esp + 0x14]
push 0
push 1
push dword [esp + 0x1c]
push dword [esp + 0x1c]
call dword [sym.imp.KERNEL32.dll_CreateFileA]
ret 0xc

Function at 0x40613b
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 8]
push edi
push 0x63
pop edi
mov dword [ebp + 8], 0x61736e
call dword [sym.imp.KERNEL32.dll_GetTickCount]
push 0x1a
xor edx, edx
pop ecx
div ecx
push esi
lea eax, [ebp + 8]
push 0
push eax
push dword [ebp + 0xc]
add byte [ebp + 0xa], dl
call dword [sym.imp.KERNEL32.dll_GetTempFileNameA]
test eax, eax
jne 0x406180
mov eax, edi
dec edi
test eax, eax
jne 0x406146
and byte [esi], al
pop edi
pop esi
pop ebp
ret 8
mov eax, esi
jmp 0x40617a
Function at 0x406184
Capabilities:
Get common file path
Get file size

Disassembly:
push ebx
push ebp
push esi
push edi
push str.MoveFileExA
push str.KERNEL32.dll
call fcn.0040683b
test eax, eax
mov esi, dword [esp + 0x18]
je 0x4061b0
push 5
push esi
push dword [esp + 0x1c]
call eax
test eax, eax
jne 0x4062f4
mov ebx, dword [sym.imp.KERNEL32.dll_GetShortPathNameA]
mov dword [0x43adb8], 0x4c554e
test esi, esi
mov edi, 0x400
mov ebp, 0x43adb8
je 0x4061f4
push 1
push 0
push esi
call fcn.0040610c
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
push ebp
push esi
call ebx
test eax, eax
je 0x4062fa
cmp eax, edi
jg 0x4062fa
mov esi, 0x43a830
push edi
push esi
push dword [esp + 0x1c]
call ebx
test eax, eax
je 0x4062fa
cmp eax, edi
jg 0x4062fa
push esi
push ebp
push str._s_s_r_n
push 0x43a430
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x10
mov ebp, eax
push 0x3f0
push esi
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
push str.wininit.ini
push esi
call fcn.00406459
xor edi, edi
push edi
push 0x8000080
push 4
push edi
push edi
push 0xc0000000
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x4062f4
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
push edi
lea eax, [esi + ebp + 0xa]
push eax
push edi
push 4
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_CreateFileMappingA]
cmp eax, edi
mov dword [esp + 0x14], eax
je 0x4062dc
push edi
push edi
push edi
push 2
push eax
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov edi, eax
test edi, edi
je 0x4062d0
push str._Rename__r_n
push edi
call fcn.0040609a
test eax, eax
jne 0x406301
lea eax, [edi + esi]
push str._Rename__r_n
push eax
call fcn.0040643b
add esi, 0xa
mov eax, esi
push ebp
add eax, edi
push 0x43a430
push eax
call fcn.004060e6
push edi
add esi, ebp
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
push dword [esp + 0x14]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor edi, edi
push edi
push edi
push esi
push ebx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push ebx
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
inc dword [0x44baf0]
pop edi
pop esi
pop ebp
pop ebx
ret 8
add eax, 0xa
push 0x40a9ec
push eax
call fcn.0040609a
test eax, eax
je 0x4062b7
inc eax
lea edx, [edi + esi]
cmp eax, edx
mov ecx, eax
jae 0x40632a
mov dl, byte [ecx]
mov byte [ecx + ebp], dl
inc ecx
lea edx, [edi + esi]
cmp ecx, edx
jb 0x40631d
sub eax, edi
jmp 0x4062b9
Function at 0x40632e
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push ebx
lea eax, [ebp + 0xc]
push esi
mov esi, dword [ebp + 0x14]
xor ebx, ebx
push eax
push 0x20019
push ebx
push dword [ebp + 0xc]
mov byte [esi], bl
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x406392
lea eax, [ebp + 8]
mov dword [ebp + 8], 0x2000
push eax
lea eax, [ebp + 0x14]
push esi
push eax
push ebx
push dword [ebp + 0x10]
push dword [ebp + 0xc]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x406381
cmp dword [ebp + 0x14], 1
je 0x406383
cmp dword [ebp + 0x14], 2
je 0x406383
mov byte [esi], bl
push dword [ebp + 0xc]
mov byte [esi + 0x1fff], bl
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop esi
pop ebx
pop ebp
ret 0x10
Function at 0x406744
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ebx
xor ebx, ebx
cmp dword [ebp + 8], ebx
je 0x406769
mov eax, dword [0x40a8e8]
cmp eax, 0xffffffff
je 0x406760
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
or dword [0x40a8e8], 0xffffffff
jmp 0x4067dc
cmp dword [0x43b9c0], ebx
je 0x4067dc
cmp byte [0x43b5c0], bl
je 0x4067a8
cmp dword [0x40a8e8], 0xffffffff
jne 0x4067b1
push 4
push 0x40000000
push 0x43b5c0
call fcn.0040610c
cmp eax, 0xffffffff
mov dword [0x40a8e8], eax
je 0x4067dc
push 2
push ebx
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp dword [0x40a8e8], 0xffffffff
je 0x4067dc
push esi
mov esi, 0x43fa00
push 0x40aab8
push esi
call fcn.00406459
lea eax, [ebp + 8]
push ebx
push eax
push esi
call fcn.0040644c
push eax
push esi
push dword [0x40a8e8]
call dword [sym.imp.KERNEL32.dll_WriteFile]
pop esi
pop ebx
pop ebp
ret 4

Function at 0x4068a2
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
push esi
xor esi, esi
cmp dword [0x43b1bc], esi
push edi
jne 0x4068dc
mov ecx, 0x43b1b8
push 8
mov eax, esi
pop edi
mov edx, eax
and dl, 1
neg dl
sbb edx, edx
and edx, 0xedb88320
shr eax, 1
xor eax, edx
dec edi
jne 0x4068b8
mov dword [ecx], eax
add ecx, 4
inc esi
cmp ecx, 0x43b5b8
jl 0x4068b3
mov ecx, dword [esp + 0x14]
mov eax, dword [esp + 0xc]
mov edx, ecx
dec ecx
test edx, edx
not eax
jbe 0x406911
lea edx, [ecx + 1]
mov ecx, dword [esp + 0x10]
movzx edi, byte [ecx]
mov esi, eax
and esi, 0xff
xor esi, edi
shr eax, 8
mov esi, dword [esi*4 + 0x43b1b8]
xor eax, esi
inc ecx
dec edx
jne 0x4068f4
pop edi
pop esi
not eax
ret 0xc
Function at 0x407180
Capabilities:
Enumerate pe sections

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
xor edx, edx
push ebx
push esi
push edi
mov ecx, dword [eax + 0x3c]
add ecx, eax
movzx eax, word [ecx + 0x14]
movzx ebx, word [ecx + 6]
add eax, 0x18
add eax, ecx
test ebx, ebx
je 0x4071be
mov edi, dword [ebp + 0xc]
mov esi, dword [eax + 0xc]
cmp edi, esi
jb 0x4071b6
mov ecx, dword [eax + 8]
add ecx, esi
cmp edi, ecx
jb 0x4071c0
inc edx
add eax, 0x28
cmp edx, ebx
jb 0x4071a6
xor eax, eax
pop edi
pop esi
pop ebx
pop ebp
ret

Function at 0x4072a0
Capabilities:
Parse pe header

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
mov ecx, 0x5a4d
cmp word [eax], cx
je 0x4072b6
xor eax, eax
pop ebp
ret
mov ecx, dword [eax + 0x3c]
add ecx, eax
xor eax, eax
cmp dword [ecx], 0x4550
jne 0x4072d1
mov edx, 0x10b
cmp word [ecx + 0x18], dx
sete al
pop ebp
ret

Function at 0x433005
Capabilities:
Encode data using xor

Disassembly:
pushal
nop
mov eax, section..pdata
mov ebx, 0x40de38
nop
nop
mov ecx, 0x2b546c54
nop
nop
nop
test eax, eax
nop
nop
nop
je 0x43304e
nop
nop
nop
xor dword [eax], ecx
nop
nop
nop
nop
nop
nop
inc eax
nop
nop
nop
nop
inc eax
nop
nop
nop
nop
nop
nop
inc eax
nop
nop
nop
nop
nop
nop
inc eax
nop
nop
nop
cmp eax, ebx
nop
nop
jne 0x433024
nop
nop
nop
nop
nop
mov eax, section..data
nop
mov ebx, 0x4304d8
mov ecx, 0x11047447
nop
nop
nop
nop
nop
test eax, eax
nop
nop
nop
je 0x433084
nop
nop
nop
xor dword [eax], ecx
nop
nop
nop
add eax, 4
nop
nop
nop
nop
nop
nop
cmp eax, ebx
nop
nop
jne 0x43306c
nop
nop
nop
nop
nop
nop
popal
nop
jmp 0x431219
Function at 0x404b6c
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [ebp + 0x10]
push ebx
mov ebx, ecx
push edi
mov edi, dword [ebp + 0xc]
test eax, eax
jg 0x404b8d
jl 0x404b84
test edi, edi
jne 0x404b8d
xor eax, eax
xor edx, edx
jmp 0x404c4e
cmp dword [ebx + 0x38], 0
je 0x404ba2
push eax
push edi
push dword [ebp + 8]
call fcn.00404c54
jmp 0x404c4e
mov eax, dword [ebx + 0x1c]
push esi
mov esi, edi
mov ecx, dword [eax]
test ecx, ecx
je 0x404be9
mov eax, dword [ebx + 0x2c]
mov eax, dword [eax]
mov dword [ebp - 4], eax
test eax, eax
je 0x404be9
cmp eax, edi
jb 0x404bc3
mov eax, edi
mov dword [ebp - 4], edi
push eax
push ecx
push dword [ebp + 8]
call fcn.00406f10
mov ecx, dword [ebp - 4]
add esp, 0xc
mov eax, dword [ebp + 8]
sub esi, ecx
add eax, ecx
mov dword [ebp - 4], eax
mov eax, dword [ebx + 0x2c]
sub dword [eax], ecx
mov eax, dword [ebx + 0x1c]
add dword [eax], ecx
jmp 0x404bef
mov eax, dword [ebp + 8]
mov dword [ebp - 4], eax
cmp dword [ebx + 0x4c], 0
je 0x404c43
mov ecx, ebx
call fcn.00404233
mov ecx, dword [ebp - 4]
mov edx, esi
mov eax, 0xfff
cmp esi, eax
jbe 0x404c2e
push dword [ebx + 0x4c]
push eax
push 1
push ecx
call fcn.0040b4ad
mov ecx, dword [ebp - 4]
sub esi, eax
add ecx, eax
add esp, 0x10
mov dword [ebp - 4], ecx
mov edx, esi
cmp eax, 0xfff
jne 0x404c43
jmp 0x404c01
test edx, edx
je 0x404c43
push dword [ebx + 0x4c]
push esi
push 1
push ecx
call fcn.0040b4ad
add esp, 0x10
sub esi, eax
mov edx, dword [ebp + 0x10]
sub edi, esi
mov eax, edi
sbb edx, 0
pop esi
pop edi
pop ebx
leave
ret 0xc

Function at 0x406525
Capabilities:
Parse pe header

Disassembly:
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
je 0x406564
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x406564
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x406564
mov eax, 0x10b
cmp word [ecx + 0x18], ax
jne 0x406564
cmp dword [ecx + 0x74], 0xe
jbe 0x406564
cmp dword [ecx + 0xe8], 0
setne al
ret
xor al, al
ret

Function at 0x410e06
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x421e6c
push 0x421e64
push str.FlsAlloc
push 0x1e
call fcn.00410c33
mov esi, eax
add esp, 0x10
test esi, esi
je 0x410e3a
push dword [ebp + 8]
mov ecx, esi
call dword [0x41f17c]
call esi
jmp 0x410e40
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x410e84
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x421e7c
push 0x421e74
push str.FlsGetValue
push 0x20
call fcn.00410c33
mov esi, eax
add esp, 0x10
test esi, esi
je 0x410ebb
push dword [ebp + 8]
mov ecx, esi
call dword [0x41f17c]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]
Function at 0x413090
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.00412f01

Function at 0x41348a
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x101c
call fcn.00406860
mov eax, dword [0x42c014]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0x14]
push ebx
push dword [ebp + 8]
mov dword [ebp - 0x100c], eax
call fcn.004120f6
pop ecx
mov ecx, dword [ebp + 8]
mov ebx, eax
cmp dword [ecx + 8], 0
jne 0x4134cc
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
jmp 0x413628
mov eax, dword [ecx]
sub eax, dword [ecx + 4]
push esi
push edi
push 0
cdq
push 2
push edx
push eax
call fcn.0041e610
push dword [ebp - 0x100c]
mov ecx, ebx
mov dword [ebp - 0x1008], eax
mov esi, ebx
mov dword [ebp - 0x1018], edx
and ecx, 0x3f
sar esi, 6
imul edi, ecx, 0x38
push 0
mov eax, dword [esi*4 + 0x42d908]
push dword [edi + eax + 0x24]
push dword [edi + eax + 0x20]
push ebx
call fcn.00414481
mov ecx, dword [esi*4 + 0x42d908]
add esp, 0x14
mov dword [ebp - 0x1010], eax
mov eax, edx
mov edx, dword [ebp - 0x1010]
mov dword [ebp - 0x101c], eax
cmp edx, dword [edi + ecx + 0x20]
jne 0x413621
cmp eax, dword [edi + ecx + 0x24]
jne 0x413621
push 0
lea eax, [ebp - 0x1014]
push eax
push 0x1000
lea eax, [ebp - 0x1004]
push eax
push dword [edi + ecx + 0x18]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x413621
push dword [ebp - 0x100c]
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.00414481
add esp, 0x14
test edx, edx
jl 0x413621
jg 0x413597
test eax, eax
jb 0x413621
mov ebx, dword [ebp - 0x1018]
mov eax, dword [ebp - 0x1014]
test ebx, ebx
jg 0x413621
jl 0x4135b1
cmp dword [ebp - 0x1008], eax
ja 0x413621
lea edi, [ebp - 0x1004]
xor edx, edx
add edi, eax
lea ecx, [ebp - 0x1004]
xor esi, esi
cmp dword [ebp - 0x1008], edx
jne 0x4135cf
test ebx, ebx
je 0x413608
cmp ecx, edi
jae 0x413608
mov al, byte [ecx]
cmp al, 0xd
jne 0x4135e9
lea eax, [edi - 1]
cmp ecx, eax
jae 0x4135f5
cmp byte [ecx + 1], 0xa
jne 0x4135f5
inc ecx
jmp 0x4135f5
movzx eax, al
movsx eax, byte [eax + 0x42c298]
add ecx, eax
add esi, 1
adc edx, 0
inc ecx
cmp esi, dword [ebp - 0x1008]
jne 0x4135cf
cmp edx, ebx
jne 0x4135cf
lea eax, [ebp - 0x1004]
sub ecx, eax
mov eax, ecx
cdq
add eax, dword [ebp - 0x1010]
adc edx, dword [ebp - 0x101c]
jmp 0x413626
or edx, 0xffffffff
mov eax, edx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.00405ad2
leave
ret
Function at 0x41391f
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x14
mov eax, dword [ebp + 8]
mov ecx, eax
push ebx
mov ebx, dword [ebp + 0xc]
and eax, 0x3f
sar ecx, 6
push esi
push edi
imul edi, eax, 0x38
mov eax, dword [ecx*4 + 0x42d908]
mov dword [ebp - 0x10], ecx
mov ecx, dword [eax + edi + 0x18]
mov dword [ebp - 0x14], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x41395f
cmp byte [ebx], 0xa
jne 0x41395f
or byte [eax + edi + 0x28], 4
jmp 0x413964
and byte [eax + edi + 0x28], 0xfb
add ecx, ebx
mov edx, ebx
mov dword [ebp - 0xc], ecx
mov esi, ebx
cmp ebx, ecx
jae 0x413a62
mov al, byte [edx]
cmp al, 0x1a
je 0x413a44
lea ecx, [edx + 1]
mov dword [ebp - 8], ecx
mov ecx, dword [ebp - 0xc]
cmp al, 0xd
je 0x413993
mov edx, dword [ebp - 8]
mov byte [esi], al
jmp 0x4139b8
mov eax, dword [ebp - 8]
cmp eax, ecx
jae 0x4139c2
mov cl, byte [eax]
xor eax, eax
cmp cl, 0xa
sete al
inc eax
add edx, eax
cmp cl, 0xa
sete al
dec al
and al, 3
add al, 0xa
mov byte [esi], al
mov ecx, dword [ebp - 0xc]
inc esi
cmp edx, ecx
jb 0x413975
jmp 0x413a62
push 0
lea eax, [ebp - 0xc]
push eax
push 1
lea eax, [ebp - 1]
push eax
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x413a3f
cmp dword [ebp - 0xc], 0
je 0x413a3f
mov ecx, dword [ebp - 0x10]
mov eax, dword [ecx*4 + 0x42d908]
test byte [eax + edi + 0x28], 0x48
je 0x413a19
mov dl, byte [ebp - 1]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
cmp dl, 0xa
jne 0x413a04
mov byte [esi], dl
jmp 0x413a15
mov byte [esi], 0xd
mov eax, dword [ecx*4 + 0x42d908]
mov byte [eax + edi + 0x2a], dl
mov eax, dword [ebp - 0x14]
mov esi, eax
jmp 0x413a62
cmp byte [ebp - 1], 0xa
jne 0x413a28
cmp esi, ebx
jne 0x413a28
mov byte [esi], 0xa
jmp 0x413a61
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.0041449f
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x413a62
mov byte [esi], 0xd
jmp 0x413a61
mov ecx, dword [ebp - 0x10]
mov ecx, dword [ecx*4 + 0x42d908]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x413a5e
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x413a62
mov byte [esi], 0x1a
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x413a6b
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword [ebp + 8]
push ebx
push esi
mov esi, dword [ebp + 0xc]
mov ebx, eax
and eax, 0x3f
sar ebx, 6
push edi
imul edi, eax, 0x38
push 0xa
mov eax, dword [ebx*4 + 0x42d908]
pop edx
mov dword [ebp - 0x14], edx
mov ecx, dword [edi + eax + 0x18]
mov dword [ebp - 0x18], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x413aae
cmp word [esi], dx
jne 0x413aae
or byte [edi + eax + 0x28], 4
jmp 0x413ab3
and byte [edi + eax + 0x28], 0xfb
lea edx, [esi + ecx*2]
mov eax, esi
mov dword [ebp - 8], edx
mov dword [ebp - 4], eax
cmp eax, edx
jae 0x413c06
mov dword [ebp - 0xc], 0xd
movzx ecx, word [eax]
mov edx, ecx
mov dword [ebp - 0x10], edx
push 0x1a
pop edx
cmp cx, dx
mov edx, dword [ebp - 8]
je 0x413be6
add eax, 2
cmp cx, word [ebp - 0xc]
je 0x413af5
mov dword [ebp - 4], eax
mov word [esi], cx
jmp 0x413b2b
cmp eax, edx
jae 0x413b37
movzx eax, word [eax]
xor ecx, ecx
cmp ax, word [ebp - 0x14]
mov edx, eax
push 0xa
sete cl
xor eax, eax
lea ecx, [ecx*2 + 2]
add dword [ebp - 4], ecx
pop ecx
cmp dx, cx
mov edx, dword [ebp - 8]
sete al
dec eax
and eax, 3
add eax, ecx
mov word [esi], ax
mov eax, dword [ebp - 4]
add esi, 2
cmp eax, edx
jb 0x413acd
jmp 0x413c06
push 0
lea eax, [ebp - 0x14]
push eax
push 2
lea eax, [ebp - 4]
push eax
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x413be2
cmp dword [ebp - 0x14], 0
je 0x413be2
mov eax, dword [ebx*4 + 0x42d908]
push 0xa
test byte [edi + eax + 0x28], 0x48
je 0x413bba
mov dx, word [ebp - 4]
lea eax, [esi + 2]
pop ecx
mov dword [ebp - 0x18], eax
cmp dx, cx
jne 0x413b83
mov word [esi], cx
jmp 0x413bb6
push 0xd
pop eax
mov word [esi], ax
mov eax, dword [ebx*4 + 0x42d908]
movzx ecx, dx
shr ecx, 8
push 0xa
mov byte [edi + eax + 0x2a], dl
mov eax, dword [ebx*4 + 0x42d908]
mov byte [edi + eax + 0x2b], cl
mov eax, dword [ebx*4 + 0x42d908]
pop ecx
mov byte [edi + eax + 0x2c], cl
mov eax, dword [ebp - 0x18]
mov esi, eax
jmp 0x413c06
pop ebx
cmp word [ebp - 4], bx
jne 0x413bcb
cmp esi, dword [ebp + 0xc]
jne 0x413bcb
mov word [esi], bx
jmp 0x413c03
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.0041449f
add esp, 0x10
cmp word [ebp - 4], bx
je 0x413c06
push 0xd
jmp 0x413bff
mov ecx, dword [ebx*4 + 0x42d908]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x413bfd
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x413c06
push 0x1a
pop eax
mov word [esi], ax
add esi, 2
sub esi, dword [ebp + 0xc]
and esi, 0xfffffffe
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x418bee
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
mov esi, eax
test esi, esi
je 0x418c8b
push ebx
push esi
call fcn.00418bb7
xor ebx, ebx
sub eax, esi
push ebx
push ebx
push ebx
push ebx
sar eax, 1
push eax
push esi
push ebx
push ebx
mov dword [ebp - 8], eax
call fcn.0041787b
add esp, 0x24
mov dword [ebp - 4], eax
test eax, eax
jne 0x418c38
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x418c8a
push edi
push eax
call fcn.0041467e
mov edi, eax
pop ecx
push ebx
test edi, edi
jne 0x418c58
call fcn.00410958
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x418c89
push ebx
push dword [ebp - 4]
push edi
push dword [ebp - 8]
push esi
push ebx
push ebx
call fcn.0041787b
add esp, 0x20
test eax, eax
jne 0x418c77
push edi
call fcn.00410958
jmp 0x418c7f
push ebx
call fcn.00410958
mov ebx, edi
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov eax, ebx
pop edi
pop ebx
pop esi
leave
ret
Function at 0x41e5d0
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x41e5fd
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x41e5fd
mov edx, 0x10b
xor eax, eax
cmp word [ecx + 0x18], dx
sete al
pop ebp
ret
xor eax, eax
pop ebp
ret
Function at 0x4052b0
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 8]
cmp dword [esi + 0x37], 0
jne 0x4052c3
cmp dword [esi + 0x2b], 0
je 0x4052d1
mov dword [esi + 8], 0x1002
xor esi, esi
jmp 0x40535a
mov dword [esi + 8], 0
push 0xa
push dword [ebp + 0x10]
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.DLL_FindResourceA]
or eax, eax
jne 0x4052f5
mov dword [esi + 8], 0x3001
xor esi, esi
jmp 0x40535a
push eax
push eax
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.DLL_LoadResource]
pop ecx
or eax, eax
jne 0x405310
mov dword [esi + 8], 0x3002
xor esi, esi
jmp 0x40535a
mov dword [esi + 0x13], eax
mov dword [esi + 0x1b], eax
push ecx
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.DLL_SizeofResource]
or eax, eax
jne 0x40532f
mov dword [esi + 8], 0x3002
xor esi, esi
jmp 0x40535a
mov dword [esi + 0x17], eax
mov dword [esi + 0x2b], 2
push esi
call fcn.004055e0
or eax, eax
jne 0x40534e
mov dword [esi + 0x2b], 0
xor esi, esi
jmp 0x40535a
mov dword [esi + 0x37], 1
mov esi, 1
mov eax, esi
pop esi
leave
ret 0xc

Function at 0x40724e
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x4014d4]
jne 0x407258
repz ret
jmp fcn.004080a4