joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4106e0
Capabilities:
Accept command line arguments

Disassembly:
mov eax, dword fs:[0]
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x43ff60
push 0x416f30
push eax
mov dword fs:[0], esp
sub esp, 0x60
push ebx
push esi
push edi
mov dword [ebp - 0x18], esp
call dword [sym.imp.KERNEL32.dll_GetVersion]
mov dword [0x4488cc], eax
xor eax, eax
mov al, byte [0x4488cd]
mov dword [0x4488d8], eax
mov eax, dword [0x4488cc]
shr dword [0x4488cc], 0x10
and eax, 0xff
mov dword [0x4488d4], eax
shl eax, 8
add eax, dword [0x4488d8]
mov dword [0x4488d0], eax
call fcn.00416f10
call fcn.00414110
test eax, eax
jne 0x410759
push 0x10
call fcn.00410880
add esp, 4
mov dword [ebp - 4], 0
call fcn.00415160
call fcn.00411970
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
mov dword [0x44bb48], eax
call fcn.00416d70
mov dword [0x448318], eax
test eax, eax
je 0x41078c
cmp dword [0x44bb48], 0
jne 0x410796
push 0xffffffffffffffff
call fcn.004130d0
add esp, 4
call fcn.00416af0
call fcn.00416a10
call fcn.004130a0
mov esi, dword [0x44bb48]
mov al, byte [esi]
cmp al, 0x22
je 0x4107bd
cmp al, 0x20
jbe 0x4107ea
inc esi
cmp byte [esi], 0x20
ja 0x4107b5
jmp 0x4107ea
inc esi
cmp byte [esi], 0x22
je 0x4107e9
mov bl, byte [ebp - 0x28]
mov bl, byte [esi]
test bl, bl
je 0x4107e4
xor eax, eax
mov al, bl
push eax
call fcn.004169b0
add esp, 4
test eax, eax
je 0x4107de
inc esi
inc esi
cmp byte [esi], 0x22
jne 0x4107c6
cmp byte [esi], 0x22
jne 0x4107ea
inc esi
cmp byte [esi], 0
je 0x4107fa
cmp byte [esi], 0x20
ja 0x4107fa
inc esi
cmp byte [esi], 0
jne 0x4107ef
mov dword [ebp - 0x44], 0
lea eax, [ebp - 0x70]
push eax
call dword [sym.imp.KERNEL32.dll_GetStartupInfoA]
test byte [ebp - 0x44], 1
mov eax, 0xa
je 0x41081e
mov eax, dword [ebp - 0x40]
and eax, 0xffff
push eax
push esi
push 0
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call main
push eax
call fcn.004130d0
jmp 0x41085f
add esp, 4
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x10]
pop edi
mov dword fs:[0], eax
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x413110
Capabilities:
Terminate process

Disassembly:
push ebx
push esi
call fcn.004131a0
mov dword [0x448904], 1
cmp dword [esp + 0x10], 0
mov ebx, dword [esp + 0x14]
mov byte [0x448900], bl
jne 0x413171
cmp dword [0x44bb44], 0
je 0x41315f
mov esi, dword [0x44bb40]
sub esi, 4
cmp esi, dword [0x44bb44]
jb 0x41315f
mov eax, dword [esi]
test eax, eax
je 0x413154
call eax
sub esi, 4
cmp esi, dword [0x44bb44]
jae 0x41314c
push 0x44617c
push 0x446174
call fcn.004131c0
add esp, 8
push 0x446184
push 0x446180
call fcn.004131c0
add esp, 8
test ebx, ebx
je 0x41318f
call fcn.004131b0
pop esi
pop ebx
ret
mov eax, dword [esp + 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_ExitProcess]
Function at 0x414110
Capabilities:
Allocate thread local storage
Set thread local storage value

Disassembly:
push esi
call fcn.00414ee0
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
mov dword [0x44890c], eax
cmp eax, 0xffffffff
jne 0x41412a
xor eax, eax
pop esi
ret
push 0x74
push 1
call fcn.00413430
add esp, 8
mov esi, eax
test esi, esi
je 0x41416c
push esi
mov eax, dword [0x44890c]
push eax
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
test eax, eax
je 0x41416c
push esi
call fcn.00414170
add esp, 4
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov dword [esi], eax
mov eax, 1
mov dword [esi + 4], 0xffffffff
pop esi
ret
xor eax, eax
pop esi
ret

Function at 0x414190
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push esi
push edi
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
mov eax, dword [0x44890c]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov edi, eax
test edi, edi
jne 0x4141f3
push 0x74
push 1
call fcn.00413430
add esp, 8
mov edi, eax
test edi, edi
je 0x4141e9
push edi
mov eax, dword [0x44890c]
push eax
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
test eax, eax
je 0x4141e9
push edi
call fcn.00414170
add esp, 4
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov dword [edi], eax
mov dword [edi + 4], 0xffffffff
jmp 0x4141f3
push 0x10
call fcn.00410880
add esp, 4
push esi
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov eax, edi
pop edi
pop esi
ret
Function at 0x4159b0
Capabilities:
Write file on windows

Disassembly:
sub esp, 0x418
push ebx
push esi
push edi
push ebp
xor edi, edi
mov ebp, dword [esp + 0x434]
mov dword [esp + 0x20], edi
cmp ebp, edi
jne 0x4159d8
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x418
ret
mov edx, dword [esp + 0x42c]
mov eax, edx
and eax, 0xffffffe7
sar eax, 3
add eax, 0x44ba40
mov dword [esp + 0x18], eax
mov eax, edx
and eax, 0x1f
mov ebx, dword [esp + 0x18]
shl eax, 2
lea ecx, [eax + eax*8]
mov eax, dword [ebx]
mov dword [esp + 0x1c], ecx
test byte [eax + ecx + 4], 0x20
je 0x415a19
push 2
push 0
push edx
call fcn.004155a0
add esp, 0xc
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x1c]
add ecx, dword [eax]
test byte [ecx + 4], 0x80
je 0x415ab5
mov dword [esp + 0x10], 0
mov ebx, dword [esp + 0x430]
mov eax, ebx
sub eax, dword [esp + 0x430]
cmp eax, ebp
jae 0x415aee
lea esi, [esp + 0x24]
mov eax, ebx
sub eax, dword [esp + 0x430]
cmp eax, ebp
jae 0x415a7c
mov al, byte [ebx]
inc ebx
cmp al, 0xa
jne 0x415a6a
mov byte [esi], 0xd
inc edi
inc esi
mov byte [esi], al
inc esi
mov eax, esi
lea ecx, [esp + 0x24]
sub eax, ecx
cmp eax, 0x400
jl 0x415a51
lea eax, [esp + 0x24]
push 0
sub esi, eax
lea ecx, [esp + 0x28]
lea eax, [esp + 0x18]
mov edx, dword [esp + 0x1c]
push eax
push esi
push ecx
mov eax, dword [edx]
mov ecx, dword [esp + 0x2c]
mov edx, dword [eax + ecx]
push edx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x415ae4
mov eax, dword [esp + 0x14]
add dword [esp + 0x20], eax
cmp eax, esi
jge 0x415a3c
jmp 0x415aee
lea eax, [esp + 0x14]
push 0
mov edx, dword [esp + 0x434]
push eax
push ebp
mov ecx, dword [ecx]
push edx
push ecx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x415ae4
mov dword [esp + 0x10], 0
mov eax, dword [esp + 0x14]
mov dword [esp + 0x20], eax
jmp 0x415aee
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [esp + 0x10], eax
cmp dword [esp + 0x20], 0
jne 0x415b9a
cmp dword [esp + 0x10], 0
je 0x415b4a
cmp dword [esp + 0x10], 5
jne 0x415b2d
call fcn.004128e0
mov dword [eax], 9
call fcn.004128f0
mov ecx, dword [esp + 0x10]
pop ebp
pop edi
mov dword [eax], ecx
mov eax, 0xffffffff
pop esi
pop ebx
add esp, 0x418
ret
mov ecx, dword [esp + 0x10]
push ecx
call fcn.00412860
add esp, 4
mov eax, 0xffffffff
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x418
ret
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x1c]
mov edx, dword [eax]
test byte [edx + ecx + 4], 0x40
je 0x415b74
mov eax, dword [esp + 0x430]
cmp byte [eax], 0x1a
jne 0x415b74
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x418
ret
call fcn.004128e0
mov dword [eax], 0x1c
call fcn.004128f0
pop ebp
mov dword [eax], 0
mov eax, 0xffffffff
pop edi
pop esi
pop ebx
add esp, 0x418
ret
mov eax, dword [esp + 0x20]
pop ebp
sub eax, edi
pop edi
pop esi
pop ebx
add esp, 0x418
ret
Function at 0x416d70
Capabilities:
Query environment variable

Disassembly:
sub esp, 4
cmp dword [0x448d44], 0
push ebx
push esi
push edi
push ebp
jne 0x416dc0
mov esi, dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
call esi
mov edi, eax
test edi, edi
je 0x416d9e
mov dword [0x448d44], 1
mov ebx, dword [esp + 0x10]
jmp 0x416dce
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStrings]
mov ebx, eax
test ebx, ebx
je 0x416db6
mov dword [0x448d44], 2
jmp 0x416dce
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret
mov edi, dword [esp + 0x10]
mov ebx, dword [esp + 0x10]
mov esi, dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
cmp dword [0x448d44], 1
jne 0x416e7d
test edi, edi
jne 0x416df1
call esi
mov edi, eax
test edi, edi
jne 0x416df1
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret
cmp word [edi], 0
mov esi, edi
je 0x416e0b
add esi, 2
cmp word [esi], 0
jne 0x416df9
add esi, 2
cmp word [esi], 0
jne 0x416df9
sub esi, edi
push 0
sar esi, 1
push 0
inc esi
push 0
push 0
push esi
push edi
push 0
push 0
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
mov ebp, eax
test ebp, ebp
je 0x416e6c
push ebp
call fcn.00410bc0
add esp, 4
mov ebx, eax
test ebx, ebx
je 0x416e6c
push 0
push 0
push ebp
push ebx
push esi
push edi
push 0
push 0
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
test eax, eax
jne 0x416e5b
push ebx
call fcn.00410c40
add esp, 4
xor ebx, ebx
push edi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov eax, ebx
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret
push edi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret
cmp dword [0x448d44], 2
jne 0x416f01
test ebx, ebx
jne 0x416ea0
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStrings]
mov ebx, eax
test ebx, ebx
jne 0x416ea0
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret
mov ebp, ebx
cmp byte [ebx], 0
je 0x416eb5
inc ebp
cmp byte [ebp], 0
jne 0x416ea7
inc ebp
cmp byte [ebp], 0
jne 0x416ea7
sub ebp, ebx
inc ebp
push ebp
call fcn.00410bc0
mov dword [esp + 0x14], eax
add esp, 4
test eax, eax
jne 0x416eda
push ebx
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsA]
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret
mov edi, dword [esp + 0x10]
mov esi, ebx
mov ecx, ebp
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebp
push ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsA]
mov eax, dword [esp + 0x10]
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret
Function at 0x417050
Capabilities:
Write file on windows

Disassembly:
sub esp, 0x1a8
xor eax, eax
mov ecx, 0x448fb0
push ebx
mov edx, dword [esp + 0x1b0]
push esi
push edi
push ebp
cmp dword [ecx], edx
je 0x417078
add ecx, 8
inc eax
cmp ecx, 0x449038
jb 0x417068
cmp dword [eax*8 + 0x448fb0], edx
lea ebx, [eax*8]
jne 0x417233
cmp dword [0x448324], 1
je 0x4171f8
cmp dword [0x448324], 0
jne 0x4170af
cmp dword [0x448328], 1
je 0x4171f8
cmp edx, 0xfc
je 0x417233
lea eax, [esp + 0xb4]
push 0x104
push eax
mov ebp, dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
push 0
call ebp
test eax, eax
jne 0x4170ec
mov esi, str._program_name_unknown_
lea edi, [esp + 0xb4]
mov ecx, 5
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
movsb byte es:[edi], byte [esi]
lea ebp, [esp + 0xb4]
lea edi, [esp + 0xb4]
mov ecx, 0xffffffff
sub eax, eax
repne scasb al, byte es:[edi]
not ecx
cmp ecx, 0x3c
jbe 0x417130
lea edi, [esp + 0xb4]
mov ecx, 0xffffffff
sub eax, eax
push 3
repne scasb al, byte es:[edi]
not ecx
lea ebp, [esp + ecx + 0x7c]
push 0x449084
push ebp
call fcn.0040f820
add esp, 0xc
mov esi, str.Runtime_Error__n_nProgram:
lea edi, [esp + 0x14]
mov ecx, 6
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
mov edi, ebp
mov ecx, 0xffffffff
sub eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov edx, ecx
mov esi, edi
mov ecx, 0xffffffff
lea edi, [esp + 0x14]
sub eax, eax
repne scasb al, byte es:[edi]
dec edi
mov ecx, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, 0x449064
mov ecx, 0xffffffff
sub eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov edx, ecx
mov esi, edi
mov ecx, 0xffffffff
lea edi, [esp + 0x14]
sub eax, eax
repne scasb al, byte es:[edi]
dec edi
mov ecx, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, dword [ebx + 0x448fb4]
mov ecx, 0xffffffff
sub eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edx, ecx
lea edi, [esp + 0x14]
mov ecx, 0xffffffff
sub eax, eax
repne scasb al, byte es:[edi]
dec edi
mov ecx, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
push 0x12010
and ecx, 3
push str.Microsoft_Visual_C_Runtime_Library
rep movsb byte es:[edi], byte [esi]
lea eax, [esp + 0x1c]
push eax
call fcn.00418f80
add esp, 0xc
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x1a8
ret
mov eax, dword [0x44ba40]
mov esi, dword [eax + 0x48]
cmp esi, 0xffffffff
jne 0x41720f
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
mov esi, eax
mov edx, dword [ebx + 0x448fb4]
push 0
lea eax, [esp + 0x14]
mov edi, edx
push eax
mov ecx, 0xffffffff
sub eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push edx
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x1a8
ret
Function at 0x419a90
Capabilities:
Clear file content

Disassembly:
mov eax, 0x1008
call fcn.00410c60
push ebx
push esi
push edi
xor ebx, ebx
mov esi, dword [esp + 0x1018]
push ebp
push 1
push ebx
push esi
call fcn.004155a0
mov dword [esp + 0x1c], eax
add esp, 0xc
cmp eax, 0xffffffff
je 0x419bb2
push 2
push ebx
push esi
call fcn.004155a0
add esp, 0xc
cmp eax, 0xffffffff
je 0x419bb2
mov ecx, dword [esp + 0x1020]
mov ebp, ecx
sub ebp, eax
test ebp, ebp
jle 0x419b53
lea edi, [esp + 0x18]
xor eax, eax
mov ecx, 0x400
push 0x8000
rep stosd dword es:[edi], eax
push esi
call fcn.0041a7e0
mov dword [esp + 0x1c], eax
add esp, 8
mov eax, 0x1000
cmp ebp, eax
jge 0x419b0e
mov eax, ebp
push eax
lea eax, [esp + 0x1c]
push eax
push esi
call fcn.004159b0
add esp, 0xc
mov edi, eax
cmp edi, 0xffffffff
je 0x419b2c
sub ebp, edi
test ebp, ebp
jg 0x419b03
jmp 0x419b43
call fcn.004128f0
cmp dword [eax], 5
jne 0x419b41
call fcn.004128e0
mov dword [eax], 0xd
mov ebx, edi
mov eax, dword [esp + 0x14]
push eax
push esi
call fcn.0041a7e0
add esp, 8
jmp 0x419b95
jge 0x419b95
push 0
push ecx
push esi
call fcn.004155a0
add esp, 0xc
push esi
call fcn.004126b0
add esp, 4
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
cmp eax, 1
sbb ebx, ebx
cmp ebx, 0xffffffff
jne 0x419b95
call fcn.004128e0
mov dword [eax], 0xd
call fcn.004128f0
mov edi, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [edi], eax
mov eax, dword [esp + 0x10]
push 0
push eax
push esi
call fcn.004155a0
add esp, 0xc
mov eax, ebx
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x1008
ret
mov eax, 0xffffffff
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x1008
ret
Function at 0x41ab70
Capabilities:
Set environment variable

Disassembly:
sub esp, 4
cmp dword [esp + 8], 0
push ebx
push esi
push edi
push ebp
je 0x41adae
mov edx, dword [esp + 0x18]
push 0x3d
push edx
call fcn.00410a40
add esp, 8
mov ebp, eax
test ebp, ebp
je 0x41adae
cmp ebp, dword [esp + 0x18]
je 0x41adae
cmp byte [ebp + 1], 1
sbb eax, eax
mov ecx, dword [0x4488e8]
neg eax
mov dword [esp + 0x10], eax
cmp dword [0x4488ec], ecx
jne 0x41abcd
push ecx
call fcn.0041ae20
add esp, 4
mov dword [0x4488e8], eax
cmp dword [0x4488e8], 0
jne 0x41ac7d
cmp dword [esp + 0x1c], 0
je 0x41ac04
cmp dword [0x4488f0], 0
je 0x41ac04
call fcn.0041a420
test eax, eax
je 0x41ac7d
mov eax, 0xffffffff
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret
cmp dword [esp + 0x10], 0
je 0x41ac15
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret
cmp dword [0x4488e8], 0
jne 0x41ac49
push 4
call fcn.00410bc0
add esp, 4
mov dword [0x4488e8], eax
test eax, eax
jne 0x41ac3e
mov eax, 0xffffffff
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret
mov eax, dword [0x4488e8]
mov dword [eax], 0
cmp dword [0x4488f0], 0
jne 0x41ac7d
push 4
call fcn.00410bc0
add esp, 4
mov dword [0x4488f0], eax
test eax, eax
jne 0x41ac72
mov eax, 0xffffffff
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret
mov eax, dword [0x4488f0]
mov dword [eax], 0
mov esi, dword [0x4488e8]
sub ebp, dword [esp + 0x18]
mov edx, dword [esp + 0x18]
push ebp
push edx
call fcn.0041adc0
add esp, 8
mov edi, eax
test edi, edi
jl 0x41ace5
cmp dword [esi], 0
je 0x41ace5
cmp dword [esp + 0x10], 0
je 0x41acdc
lea ebx, [esi + edi*4]
mov eax, dword [ebx]
push eax
call fcn.00410c40
add esp, 4
cmp dword [ebx], 0
je 0x41acc9
mov eax, dword [ebx + 4]
add ebx, 4
inc edi
mov dword [ebx - 4], eax
cmp dword [ebx], 0
jne 0x41acba
shl edi, 2
push edi
push esi
call fcn.00410d90
add esp, 8
test eax, eax
je 0x41ad2d
jmp 0x41ad28
mov edx, dword [esp + 0x18]
mov dword [esi + edi*4], edx
jmp 0x41ad2d
cmp dword [esp + 0x10], 0
jne 0x41ada4
test edi, edi
jge 0x41acf6
neg edi
lea eax, [edi*4 + 8]
push eax
push esi
call fcn.00410d90
add esp, 8
test eax, eax
jne 0x41ad18
mov eax, 0xffffffff
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret
lea ecx, [eax + edi*4]
mov edx, dword [esp + 0x18]
mov dword [ecx], edx
mov dword [ecx + 4], 0
mov dword [0x4488e8], eax
cmp dword [esp + 0x1c], 0
je 0x41ad9a
mov edi, dword [esp + 0x18]
mov ecx, 0xffffffff
sub eax, eax
repne scasb al, byte es:[edi]
not ecx
inc ecx
push ecx
call fcn.00410bc0
add esp, 4
mov ebx, eax
test ebx, ebx
je 0x41ad9a
mov edi, dword [esp + 0x18]
mov ecx, 0xffffffff
sub eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
shr ecx, 2
mov esi, edi
mov edi, ebx
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
cmp dword [esp + 0x10], 1
sbb eax, eax
lea ecx, [ebp + ebx]
mov byte [ecx], 0
lea ecx, [ecx + 1]
and eax, ecx
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableA]
push ebx
call fcn.00410c40
add esp, 4
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret
mov eax, 0xffffffff
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret
Function at 0x41e020
Capabilities:
Get graphical window text

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push ebx
push esi
push edi
mov esi, dword [ebp + 0x10]
push 0xf00021
mov edx, dword [esi + 4]
mov ecx, dword [esi]
mov eax, dword [esi + 0xc]
sub eax, edx
push eax
mov eax, dword [esi + 8]
sub eax, ecx
push eax
push edx
push ecx
mov ecx, dword [ebp + 0xc]
push ecx
call dword [sym.imp.GDI32.dll_PatBlt]
mov edi, dword [ebp + 8]
push edi
call dword [sym.imp.USER32.dll_GetWindowTextLengthA]
mov ebx, eax
lea eax, [eax + 5]
add eax, 3
and eax, 0xfffffffc
call fcn.00410c60
mov dword [ebp - 4], esp
cmp dword [ebp - 4], 0
je 0x41e0eb
add ebx, 2
mov eax, dword [ebp - 4]
push ebx
push eax
push edi
call dword [sym.imp.USER32.dll_GetWindowTextA]
test eax, eax
je 0x41e0eb
mov bx, 0x140
mov edi, dword [ebp + 0x14]
mov eax, edi
and al, 0xf
cmp al, 0xc
je 0x41e09e
mov ebx, edi
and bx, 0xf
or bx, 0x150
test edi, 0x80
je 0x41e0a9
or bh, 8
and edi, 0x8000000
je 0x41e0c4
mov eax, dword [0x44cbbc]
mov ecx, dword [ebp + 0xc]
push eax
push ecx
call dword [sym.imp.GDI32.dll_SetTextColor]
mov dword [ebp - 8], eax
mov ecx, dword [ebp - 4]
mov edx, dword [ebp + 0xc]
movzx eax, bx
push eax
push esi
push 0xffffffffffffffff
push ecx
push edx
call dword [sym.imp.USER32.dll_DrawTextA]
test edi, edi
je 0x41e0eb
mov eax, dword [ebp - 8]
mov ecx, dword [ebp + 0xc]
push eax
push ecx
call dword [sym.imp.GDI32.dll_SetTextColor]
lea esp, [ebp - 0x14]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x41e4c0
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov eax, dword [esp + 8]
sub esp, 4
push ebx
push esi
mov esi, dword [esp + 0x10]
push edi
push ebp
push 2
push eax
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
mov edi, eax
test edi, edi
jne 0x41e4eb
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret 0x20
push edi
push esi
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov ebx, eax
push edi
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov esi, eax
test esi, esi
jne 0x41e50f
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret 0x20
push ebx
push 0x40
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov ebp, eax
test ebp, ebp
jne 0x41e52a
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret 0x20
mov edi, ebp
mov ecx, ebx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov eax, dword [esp + 0x20]
xor ecx, ecx
mov cl, ah
mov edx, eax
mov dword [esp + 0x10], 0
shl ecx, 8
shr edx, 0x10
mov byte [esp + 0x10], dl
xor edx, edx
or ecx, dword [esp + 0x10]
mov dl, al
shl edx, 0x10
mov eax, dword [esp + 0x28]
or ecx, edx
mov edx, eax
shr edx, 0x10
mov dword [ebp + 0x28], ecx
mov dword [esp + 0x10], 0
xor ecx, ecx
mov byte [esp + 0x10], dl
mov cl, ah
xor edx, edx
shl ecx, 8
mov dl, al
shl edx, 0x10
or ecx, dword [esp + 0x10]
or ecx, edx
mov eax, dword [esp + 0x24]
mov edx, eax
mov dword [ebp + 0x44], ecx
shr edx, 0x10
xor ecx, ecx
mov dword [esp + 0x10], 0
mov cl, ah
mov byte [esp + 0x10], dl
shl ecx, 8
xor edx, edx
or ecx, dword [esp + 0x10]
mov dl, al
shl edx, 0x10
mov eax, dword [esp + 0x2c]
or ecx, edx
xor edx, edx
mov dl, al
mov dword [ebp + 0x48], ecx
shl edx, 0x10
xor ecx, ecx
mov cl, ah
shl ecx, 8
shr eax, 0x10
or ecx, edx
xor edx, edx
mov dl, al
mov eax, dword [esp + 0x30]
or ecx, edx
xor edx, edx
mov dl, al
mov dword [ebp + 0x64], ecx
shl edx, 0x10
xor ecx, ecx
mov cl, ah
shl ecx, 8
shr eax, 0x10
or ecx, edx
xor edx, edx
mov dl, al
mov eax, dword [esp + 0x34]
or ecx, edx
xor edx, edx
mov dl, al
mov dword [ebp + 0x54], ecx
shl edx, 0x10
xor ecx, ecx
mov cl, ah
shl ecx, 8
push 0
shr eax, 0x10
or ecx, edx
xor edx, edx
mov dl, al
or ecx, edx
mov dword [ebp + 0x50], ecx
call dword [sym.imp.USER32.dll_GetDC]
mov edi, eax
push 0
push ebp
lea ecx, [ebp + 0x68]
push ecx
push 4
push ebp
push edi
call dword [sym.imp.GDI32.dll_CreateDIBitmap]
mov esi, eax
push edi
push 0
call dword [sym.imp.USER32.dll_ReleaseDC]
push ebp
call dword [sym.imp.KERNEL32.dll_GlobalFree]
mov eax, esi
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret 0x20

Function at 0x420bc9
Capabilities:
Read file on windows

Disassembly:
push ebp
mov eax, dword [esp + 0xc]
mov ebp, esp
sub esp, 4
test eax, eax
push esi
jne 0x420bdc
xor eax, eax
jmp 0x420c04
push 0
lea edx, [ebp - 4]
push edx
push eax
push dword [ebp + 8]
push dword [ecx + 4]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x420c01
push 0
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.00426f18
mov eax, dword [ebp - 4]
pop esi
mov esp, ebp
pop ebp
ret 8
Function at 0x420c0b
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 4
push esi
push edi
mov edi, ecx
mov esi, dword [ebp + 0xc]
test esi, esi
je 0x420c53
push 0
lea eax, [ebp - 4]
push eax
push esi
push dword [ebp + 8]
push dword [edi + 4]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x420c42
push dword [edi + 0xc]
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.00426f18
cmp esi, dword [ebp - 4]
je 0x420c53
push dword [edi + 0xc]
push 0xffffffffffffffff
push 0xd
call fcn.00426ff3
pop edi
pop esi
mov esp, ebp
pop ebp
ret 8

Function at 0x42101b
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
push esi
lea eax, [ebp - 4]
push edi
xor esi, esi
push eax
mov edi, dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
push str.CLSID
mov dword [ebp - 4], esi
push 0x80000000
call edi
test eax, eax
jne 0x4210c1
lea eax, [ebp - 8]
mov dword [ebp - 8], esi
push eax
push dword [ebp + 8]
push dword [ebp - 4]
call edi
test eax, eax
jne 0x4210b8
lea eax, [ebp - 0xc]
mov dword [ebp - 0xc], esi
push eax
push str.InProcServer32
push dword [ebp - 8]
call edi
test eax, eax
jne 0x4210af
mov edi, 0x104
mov ecx, dword [ebp + 0xc]
push edi
call fcn.0042065f
lea ecx, [ebp - 0x14]
mov dword [ebp - 0x10], edi
lea edi, [ebp - 0x10]
push edi
push eax
push ecx
push esi
push 0x4465b0
push dword [ebp - 0xc]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov esi, eax
push 0xffffffffffffffff
mov ecx, dword [ebp + 0xc]
call fcn.004206b4
push dword [ebp - 0xc]
cmp esi, 1
sbb esi, esi
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
neg esi
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, esi
pop edi
pop esi
mov esp, ebp
pop ebp
ret 8