joyce8/EMBER2024-capa huggingface dataset:
Function at 0x406bc4
Capabilities:
Enumerate files on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x264
mov eax, dword [0x437118]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
mov edi, ecx
push dword [edi + 0x3c]
mov byte [ebp - 0x255], 1
call dword [sym.imp.KERNEL32.dll_lstrlenW]
mov esi, eax
add esi, 7
xor ecx, ecx
push 2
pop edx
mov eax, esi
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.00407eaa
mov ebx, eax
xor ecx, ecx
push 2
pop edx
mov eax, esi
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.00407eaa
and dword [ebp - 0x264], 0
pop ecx
pop ecx
mov dword [ebp - 0x25c], eax
lea eax, [ebp - 0x264]
push eax
push ebx
push esi
push dword [edi + 0x3c]
call dword [sym.imp.KERNEL32.dll_GetFullPathNameW]
test eax, eax
jne 0x406c59
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [edi + 0x10], eax
mov byte [ebp - 0x255], 0
jmp 0x406d34
mov eax, dword [ebp - 0x264]
test eax, eax
je 0x406c68
xor ecx, ecx
mov word [eax], cx
push ebx
push esi
push dword [ebp - 0x25c]
call fcn.0040472b
push 0x430ad0
push esi
push ebx
call fcn.004047a6
lea eax, [ebp - 0x254]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov dword [ebp - 0x260], eax
cmp eax, 0xffffffff
je 0x406d34
lea eax, [ebp - 0x228]
push eax
push dword [ebp - 0x25c]
mov ecx, edi
call fcn.00406107
test al, al
jne 0x406cca
lea eax, [ebp - 0x228]
push eax
push dword [ebp - 0x25c]
mov ecx, edi
call fcn.0040499a
mov esi, dword [sym.imp.KERNEL32.dll_FindNextFileW]
jmp 0x406cfe
lea eax, [ebp - 0x228]
push eax
push dword [ebp - 0x25c]
mov ecx, edi
call fcn.00406107
test al, al
jne 0x406cfe
lea eax, [ebp - 0x228]
push eax
push dword [ebp - 0x25c]
mov ecx, edi
call fcn.0040499a
lea eax, [ebp - 0x254]
push eax
push dword [ebp - 0x260]
call esi
test eax, eax
jne 0x406cd2
mov edi, dword [edi + 0x40]
test edi, edi
je 0x406d28
push 0x430adc
push 0x7d00
push edi
call fcn.004047a6
push dword [ebp - 0x260]
call dword [sym.imp.KERNEL32.dll_FindClose]
push ebx
call fcn.00407eb5
push dword [ebp - 0x25c]
call fcn.00407eb5
mov al, byte [ebp - 0x255]
pop ecx
pop ecx
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004076ca
leave
ret
Function at 0x406d5c
Capabilities:
Identify system language via api

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
and dword [eax], 0
sub esp, 0x30
push edi
mov edi, ecx
test byte [edi + 0x50], 1
jne 0x406ef0
cmp dword [edi + 0x5c], 1
jle 0x406ef0
push ebx
push esi
push 0xa0
call fcn.00407eaa
pop ecx
mov dword [ebp - 0x20], eax
call dword [sym.imp.KERNEL32.dll_GetUserDefaultLangID]
movzx esi, ax
call dword [sym.imp.KERNEL32.dll_GetSystemDefaultLangID]
movzx eax, ax
movzx eax, ax
movzx ebx, si
mov esi, 0x3ff
mov dword [ebp - 0x2c], eax
and eax, esi
xor ecx, ecx
mov dword [ebp - 0x24], ebx
mov dword [ebp - 0x30], eax
or eax, 0xffffffff
and ebx, esi
cmp dword [edi + 0x5c], ecx
mov dword [ebp - 0x10], eax
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x18], eax
mov dword [ebp - 0x1c], eax
mov dword [ebp - 8], eax
mov dword [ebp - 4], ecx
jle 0x406e47
push dword [ebp - 4]
mov ecx, edi
call fcn.00404150
push dword [ebp - 0x20]
mov dword [ebp - 0xc], eax
push dword [ebp - 0xc]
and eax, esi
mov ecx, edi
mov dword [ebp - 0x28], eax
call fcn.0040559d
push dword [ebp - 0x20]
mov ecx, edi
push 0x430ae0
call fcn.00404380
mov edx, dword [ebp - 0xc]
mov eax, dword [ebp - 4]
cmp edx, dword [ebp - 0x24]
jne 0x406e11
mov dword [ebp - 0x10], eax
mov ecx, dword [ebp - 0x28]
cmp ecx, ebx
jne 0x406e1b
mov dword [ebp - 0x14], eax
cmp edx, dword [ebp - 0x2c]
jne 0x406e23
mov dword [ebp - 0x18], eax
cmp ecx, dword [ebp - 0x30]
jne 0x406e2b
mov dword [ebp - 0x1c], eax
mov ecx, dword [edi + 0x58]
test ecx, ecx
je 0x406e39
cmp edx, ecx
jne 0x406e39
mov dword [ebp - 8], eax
inc eax
cmp eax, dword [edi + 0x5c]
mov dword [ebp - 4], eax
jl 0x406dd5
xor ecx, ecx
or eax, 0xffffffff
pop esi
pop ebx
cmp dword [edi + 0x58], ecx
je 0x406e65
cmp dword [ebp - 8], eax
jne 0x406e6a
push ecx
push str.Warning:_Language_chosen_with_parameter__lang_not_found._r_n
mov ecx, edi
call fcn.00404380
xor ecx, ecx
or eax, 0xffffffff
cmp dword [ebp - 8], eax
je 0x406e7c
push ecx
push str.Info:_Found_language_chosen_with_parameter__lang._r_n
mov ecx, edi
call fcn.00404380
push dword [ebp - 8]
jmp 0x406edb
push ecx
mov ecx, edi
cmp dword [ebp - 0x10], eax
je 0x406e93
push str.Info:_Found_user_default_language._r_n
call fcn.00404380
push dword [ebp - 0x10]
jmp 0x406edb
cmp dword [ebp - 0x14], eax
je 0x406ea7
push str.Info:_Found_user_default_primary_language._r_n
call fcn.00404380
push dword [ebp - 0x14]
jmp 0x406edb
cmp dword [ebp - 0x18], eax
je 0x406ebb
push str.Info:_Found_system_default_language._r_n
call fcn.00404380
push dword [ebp - 0x18]
jmp 0x406edb
cmp dword [ebp - 0x1c], eax
je 0x406ecf
push str.Info:_Found_system_default_primary_language._r_n
call fcn.00404380
push dword [ebp - 0x1c]
jmp 0x406edb
push str.Info:_Use_default_language_from_ini_file._r_n
call fcn.00404380
push 0
mov ecx, edi
call fcn.00404150
mov ecx, dword [ebp + 8]
push dword [ebp - 0x20]
mov dword [ecx], eax
call fcn.00407eb5
pop ecx
mov al, 1
pop edi
leave
ret 4

Function at 0x4076ca
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x437118]
jne 0x4076d4
repz ret
jmp fcn.0040dc1c
Function at 0x4195af
Capabilities:
Check if file exists
Get file attributes

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
xor esi, esi
cmp dword [ebp + 8], esi
jne 0x4195e0
call fcn.0040f64b
mov dword [eax], esi
call fcn.0040f638
push esi
push esi
push esi
push esi
push esi
mov dword [eax], 0x16
call fcn.0040e9d4
add esp, 0x14
push 0x16
pop eax
jmp 0x419635
test dword [ebp + 0xc], 0xfffffff9
jne 0x4195bc
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x41960d
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.0040f65e
pop ecx
call fcn.0040f638
mov eax, dword [eax]
jmp 0x419635
test al, 0x10
jne 0x419633
test al, 1
je 0x419633
test byte [ebp + 0xc], 2
je 0x419633
call fcn.0040f64b
mov dword [eax], 5
call fcn.0040f638
mov dword [eax], 0xd
jmp 0x419604
xor eax, eax
pop esi
pop ebp
ret

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

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
xor esi, esi
cmp dword [ebp + 8], esi
jne 0x41c9bf
call fcn.0040f64b
mov dword [eax], esi
call fcn.0040f638
push esi
push esi
push esi
push esi
push esi
mov dword [eax], 0x16
call fcn.0040e9d4
add esp, 0x14
push 0x16
pop eax
jmp 0x41ca14
test dword [ebp + 0xc], 0xfffffff9
jne 0x41c99b
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x41c9ec
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.0040f65e
pop ecx
call fcn.0040f638
mov eax, dword [eax]
jmp 0x41ca14
test al, 0x10
jne 0x41ca12
test al, 1
je 0x41ca12
test byte [ebp + 0xc], 2
je 0x41ca12
call fcn.0040f64b
mov dword [eax], 5
call fcn.0040f638
mov dword [eax], 0xd
jmp 0x41c9e3
xor eax, eax
pop esi
pop ebp
ret
Function at 0x423705
Capabilities:
Link many functions at runtime

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
push esi
push edi
call fcn.0040d54e
and dword [ebp - 4], 0
cmp dword [0x438c7c], 0
mov ebx, eax
jne 0x4237b6
push str.USER32.DLL
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
test edi, edi
je 0x423867
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 0x434960
push edi
call esi
test eax, eax
je 0x423867
push eax
call fcn.0040d4dc
mov dword [esp], str.GetActiveWindow
push edi
mov dword [0x438c7c], eax
call esi
push eax
call fcn.0040d4dc
mov dword [esp], str.GetLastActivePopup
push edi
mov dword [0x438c80], eax
call esi
push eax
call fcn.0040d4dc
mov dword [esp], str.GetUserObjectInformationA
push edi
mov dword [0x438c84], eax
call esi
push eax
call fcn.0040d4dc
pop ecx
mov dword [0x438c8c], eax
test eax, eax
je 0x4237b6
push str.GetProcessWindowStation
push edi
call esi
push eax
call fcn.0040d4dc
pop ecx
mov dword [0x438c88], eax
mov eax, dword [0x438c88]
cmp eax, ebx
je 0x42380e
cmp dword [0x438c8c], ebx
je 0x42380e
push eax
call fcn.0040d557
push dword [0x438c8c]
mov esi, eax
call fcn.0040d557
pop ecx
pop ecx
mov edi, eax
test esi, esi
je 0x42380e
test edi, edi
je 0x42380e
call esi
test eax, eax
je 0x423805
lea ecx, [ebp - 8]
push ecx
push 0xc
lea ecx, [ebp - 0x14]
push ecx
push 1
push eax
call edi
test eax, eax
je 0x423805
test byte [ebp - 0xc], 1
jne 0x42380e
or dword [ebp + 0x10], 0x200000
jmp 0x423847
mov eax, dword [0x438c80]
cmp eax, ebx
je 0x423847
push eax
call fcn.0040d557
pop ecx
test eax, eax
je 0x423847
call eax
mov dword [ebp - 4], eax
test eax, eax
je 0x423847
mov eax, dword [0x438c84]
cmp eax, ebx
je 0x423847
push eax
call fcn.0040d557
pop ecx
test eax, eax
je 0x423847
push dword [ebp - 4]
call eax
mov dword [ebp - 4], eax
push dword [0x438c7c]
call fcn.0040d557
pop ecx
test eax, eax
je 0x423867
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
push dword [ebp - 4]
call eax
jmp 0x423869
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret
Function at 0x4eef30
Capabilities:
Packed with generic packer

Disassembly:
pushal
mov esi, 0x7ab000
lea edi, [esi - 0x9a000]
push edi
jmp 0x4eef4a
mov al, byte [esi]
inc esi
mov byte [edi], al
inc edi
add ebx, ebx
jne 0x4eef51
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x4eef40
mov eax, 1
add ebx, ebx
jne 0x4eef63
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc eax, eax
add ebx, ebx
jae 0x4eef74
jne 0x4eef93
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x4eef93
dec eax
add ebx, ebx
jne 0x4eef80
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc eax, eax
jmp 0x4eef58
add ebx, ebx
jne 0x4eef8f
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
jmp 0x4eefe5
xor ecx, ecx
sub eax, 3
jb 0x4eefab
shl eax, 8
mov al, byte [esi]
inc esi
xor eax, 0xffffffff
je 0x4ef01a
sar eax, 1
mov ebp, eax
jmp 0x4eefb6
add ebx, ebx
jne 0x4eefb6
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x4eef84
inc ecx
add ebx, ebx
jne 0x4eefc4
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x4eef84
add ebx, ebx
jne 0x4eefd1
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
add ebx, ebx
jae 0x4eefc6
jne 0x4eefe2
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jae 0x4eefc6
add ecx, 2
cmp ebp, 0xfffffb00
adc ecx, 2
lea edx, [edi + ebp]
cmp ebp, 0xfffffffc
jbe 0x4ef004
mov al, byte [edx]
inc edx
mov byte [edi], al
inc edi
dec ecx
jne 0x4eeff6
jmp 0x4eef46
mov eax, dword [edx]
add edx, 4
mov dword [edi], eax
add edi, 4
sub ecx, 4
ja 0x4ef004
add edi, ecx
jmp 0x4eef46
pop esi
mov edi, esi
mov ecx, 0x3ed9
mov al, byte [edi]
inc edi
sub al, 0xe8
cmp al, 1
ja 0x4ef022
cmp byte [edi], 0x11
jne 0x4ef022
mov eax, dword [edi]
mov bl, byte [edi + 4]
shr ax, 8
rol eax, 0x10
xchg ah, al
sub eax, edi
sub bl, 0xe8
add eax, esi
mov dword [edi], eax
add edi, 5
mov al, bl
loop 0x4ef027
lea edi, [esi + 0xe7000]
mov eax, dword [edi]
or eax, eax
je 0x4ef09f
mov ebx, dword [edi + 4]
lea eax, [eax + esi + 0x105420]
add ebx, esi
push eax
add edi, 8
call dword [esi + 0x10559c]
xchg ebp, eax
mov al, byte [edi]
inc edi
or al, al
je 0x4ef054
mov ecx, edi
jns 0x4ef083
movzx eax, word [edi]
inc edi
push eax
inc edi
mov ecx, 0xaef24857
push edi
dec eax
repne scasb al, byte es:[edi]
push ebp
call dword [esi + 0x1055a0]
or eax, eax
je 0x4ef099
mov dword [ebx], eax
add ebx, 4
jmp 0x4ef071
call dword [esi + 0x1055b0]
add edi, 4
lea ebx, [esi - 4]
xor eax, eax
mov al, byte [edi]
inc edi
or eax, eax
je 0x4ef0d0
cmp al, 0xef
ja 0x4ef0c3
add ebx, eax
mov eax, dword [ebx]
xchg ah, al
rol eax, 0x10
xchg ah, al
add eax, esi
mov dword [ebx], eax
jmp 0x4ef0a5
and al, 0xf
shl eax, 0x10
mov ax, word [edi]
add edi, 2
jmp 0x4ef0b2
mov ebp, dword [esi + 0x1055a4]
lea edi, [esi - 0x1000]
mov ebx, 0x1000
push eax
push esp
push 4
push ebx
push edi
call ebp
lea eax, [edi + 0x227]
and byte [eax], 0x7f
and byte [eax + 0x28], 0x7f
pop eax
push eax
push esp
push eax
push ebx
push edi
call ebp
pop eax
popal
lea eax, [esp - 0x80]
push 0
cmp esp, eax
jne 0x4ef104
sub esp, 0xffffff80
jmp 0x425f74
Function at 0x795e80
Capabilities:
Packed with generic packer

Disassembly:
pushal
mov esi, section.UPX1
lea edi, [esi - 0x323000]
push edi
jmp 0x795e9a
mov al, byte [esi]
inc esi
mov byte [edi], al
inc edi
add ebx, ebx
jne 0x795ea1
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x795e90
mov eax, 1
add ebx, ebx
jne 0x795eb3
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc eax, eax
add ebx, ebx
jae 0x795ec4
jne 0x795ee3
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x795ee3
dec eax
add ebx, ebx
jne 0x795ed0
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc eax, eax
jmp 0x795ea8
add ebx, ebx
jne 0x795edf
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
jmp 0x795f35
xor ecx, ecx
sub eax, 3
jb 0x795efb
shl eax, 8
mov al, byte [esi]
inc esi
xor eax, 0xffffffff
je 0x795f6a
sar eax, 1
mov ebp, eax
jmp 0x795f06
add ebx, ebx
jne 0x795f06
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x795ed4
inc ecx
add ebx, ebx
jne 0x795f14
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x795ed4
add ebx, ebx
jne 0x795f21
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
add ebx, ebx
jae 0x795f16
jne 0x795f32
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jae 0x795f16
add ecx, 2
cmp ebp, 0xfffffb00
adc ecx, 2
lea edx, [edi + ebp]
cmp ebp, 0xfffffffc
jbe 0x795f54
mov al, byte [edx]
inc edx
mov byte [edi], al
inc edi
dec ecx
jne 0x795f46
jmp 0x795e96
mov eax, dword [edx]
add edx, 4
mov dword [edi], eax
add edi, 4
sub ecx, 4
ja 0x795f54
add edi, ecx
jmp 0x795e96
pop esi
mov edi, esi
mov ecx, 0x5015
mov al, byte [edi]
inc edi
sub al, 0xe8
cmp al, 1
ja 0x795f72
cmp byte [edi], 0x13
jne 0x795f72
mov eax, dword [edi]
mov bl, byte [edi + 4]
shr ax, 8
rol eax, 0x10
xchg ah, al
sub eax, edi
sub bl, 0xe8
add eax, esi
mov dword [edi], eax
add edi, 5
mov al, bl
loop 0x795f77
lea edi, [esi + 0x391000]
mov eax, dword [edi]
or eax, eax
je 0x795fe6
mov ebx, dword [edi + 4]
lea eax, [eax + esi + 0x3a6bf4]
add ebx, esi
push eax
add edi, 8
call dword [esi + 0x3a6ca8]
xchg ebp, eax
mov al, byte [edi]
inc edi
or al, al
je 0x795fa4
mov ecx, edi
push edi
dec eax
repne scasb al, byte es:[edi]
push ebp
call dword [esi + 0x3a6cac]
or eax, eax
je 0x795fe0
mov dword [ebx], eax
add ebx, 4
jmp 0x795fc1
call dword [esi + 0x3a6cbc]
mov ebp, dword [esi + 0x3a6cb0]
lea edi, [esi - 0x1000]
mov ebx, 0x1000
push eax
push esp
push 4
push ebx
push edi
call ebp
lea eax, [edi + 0x227]
and byte [eax], 0x7f
and byte [eax + 0x28], 0x7f
pop eax
push eax
push esp
push eax
push ebx
push edi
call ebp
pop eax
popal
lea eax, [esp - 0x80]
push 0
cmp esp, eax
jne 0x79601a
sub esp, 0xffffff80
jmp 0x4affb6
Function at 0x401990
Capabilities:
Write file on windows

Disassembly:
push ebx
sub esp, 0x18
mov dword [esp], 2
lea ebx, [esp + 0x24]
call dbg.__acrt_iob_func
mov dword [esp + 8], 0x1b
mov dword [esp + 0xc], eax
mov dword [esp + 4], 1
mov dword [esp], str.Mingw_w64_runtime_failure:_n
call sym._fwrite
mov dword [esp], 2
call dbg.__acrt_iob_func
mov edx, dword [esp + 0x20]
mov dword [esp + 8], ebx
mov dword [esp], eax
mov dword [esp + 4], edx
call sym._vfprintf
call sym._abort
lea esi, [esi]

Function at 0x4019f0
Capabilities:
Allocate or change rwx memory

Disassembly:
push edi
push esi
push ebx
mov ebx, eax
sub esp, 0x30
mov esi, dword [0x40539c]
test esi, esi
jle 0x401af0
mov eax, dword [0x4053a0]
xor ecx, ecx
add eax, 0xc
mov edx, dword [eax]
cmp edx, ebx
ja 0x401a20
mov edi, dword [eax + 4]
add edx, dword [edi + 8]
cmp ebx, edx
jb 0x401a9f
add ecx, 1
add eax, 0x14
cmp ecx, esi
jne 0x401a10
mov dword [esp], ebx
call dbg.__mingw_GetSectionForAddress
mov edi, eax
test eax, eax
je 0x401b17
mov eax, dword [0x4053a0]
lea ebx, [esi + esi*4]
shl ebx, 2
add eax, ebx
mov dword [eax + 0x10], edi
mov dword [eax], 0
call dbg._GetPEImageBase
mov edx, dword [0x4053a0]
add eax, dword [edi + 0xc]
mov dword [edx + ebx + 0xc], eax
lea edx, [esp + 0x14]
mov dword [esp + 8], 0x1c
mov dword [esp + 4], edx
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
sub esp, 0xc
test eax, eax
je 0x401af7
mov eax, dword [esp + 0x28]
lea edx, [eax - 0x40]
and edx, 0xffffffbf
je 0x401a98
sub eax, 4
and eax, 0xfffffffb
jne 0x401aa6
add dword [0x40539c], 1
add esp, 0x30
pop ebx
pop esi
pop edi
ret
mov eax, dword [esp + 0x14]
mov edx, dword [esp + 0x20]
add ebx, dword [0x4053a0]
mov dword [ebx + 4], eax
mov dword [ebx + 8], edx
mov dword [esp + 0xc], ebx
mov dword [esp + 8], 0x40
mov dword [esp + 4], edx
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
sub esp, 0x10
test eax, eax
jne 0x401a98
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [esp], str.__VirtualProtect_failed_with_code_0x_x
mov dword [esp + 4], eax
call dbg.__report_error
xor esi, esi
jmp 0x401a2a
mov eax, dword [0x4053a0]
mov eax, dword [eax + ebx + 0xc]
mov dword [esp + 8], eax
mov eax, dword [edi + 8]
mov dword [esp], str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov dword [esp + 4], eax
call dbg.__report_error
mov dword [esp + 4], ebx
mov dword [esp], str.Address__p_has_no_image_section
call dbg.__report_error
lea esi, [esi]
nop
Function at 0x401fd0
Capabilities:
Get thread local storage value

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x1c
mov dword [esp], 0x4053b8
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov ebx, dword [0x4053b0]
sub esp, 4
test ebx, ebx
je 0x402025
mov ebp, dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
lea esi, [esi]
mov eax, dword [ebx]
mov dword [esp], eax
call ebp
sub esp, 4
mov esi, eax
call edi
test eax, eax
jne 0x40201e
test esi, esi
je 0x40201e
mov eax, dword [ebx + 4]
mov dword [esp], esi
call eax
mov ebx, dword [ebx + 8]
test ebx, ebx
jne 0x402000
mov dword [esp], 0x4053b8
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
sub esp, 4
add esp, 0x1c
pop ebx
pop esi
pop edi
pop ebp
ret
Function at 0x42e000
Capabilities:
Encode data using xor

Disassembly:
pushal
nop
nop
nop
nop
nop
mov eax, section..text
nop
mov ebx, 0x407ef8
nop
nop
mov ecx, 0x7fc51f70
nop
test eax, eax
nop
nop
nop
nop
je 0x42e04e
nop
nop
nop
nop
nop
nop
xor dword [eax], ecx
nop
nop
nop
nop
inc eax
nop
nop
nop
inc eax
nop
nop
nop
nop
nop
nop
nop
nop
nop
inc eax
nop
inc eax
nop
nop
nop
nop
cmp eax, ebx
nop
nop
nop
nop
nop
nop
jne 0x42e024
nop
nop
mov eax, section..data
nop
mov ebx, 0x42cd70
nop
nop
mov ecx, 0x24194d4b
nop
test eax, eax
nop
nop
nop
nop
nop
nop
je 0x42e084
nop
nop
nop
xor dword [eax], ecx
nop
nop
nop
nop
nop
add eax, 4
nop
nop
cmp eax, ebx
nop
nop
nop
nop
nop
nop
jne 0x42e06c
nop
nop
nop
nop
popal
nop
jmp 0x401219
Function at 0x403680
Capabilities:
Terminate thread

Disassembly:
mov al, byte [0x615bb4]
push ebx
xor ebx, ebx
push ebp
push esi
cmp al, bl
push edi
je 0x403697
push 1
call dword [sym.imp.WINMM.dll_timeEndPeriod]
mov eax, dword [0x615bbc]
mov edi, dword [sym.imp.KERNEL32.dll_Sleep]
mov ebp, dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp eax, ebx
mov byte [0x615bb4], bl
je 0x4036f5
mov eax, dword [0x615bc0]
xor esi, esi
cmp eax, ebx
jne 0x4036d5
cmp esi, 0xbb8
jge 0x4036d5
push 0xa
call edi
mov eax, dword [0x615bc0]
add esi, 0xa
cmp eax, ebx
je 0x4036bd
push 0xa
call edi
mov eax, dword [0x615bbc]
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_TerminateThread]
mov ecx, dword [0x615bbc]
push ecx
call ebp
mov dword [0x615bbc], ebx
mov eax, dword [0x615b9c]
cmp eax, ebx
je 0x403729
mov edx, dword [eax]
push 0xffffd8f0
push eax
call dword [edx + 0x3c]
push 1
call edi
mov eax, dword [0x615b9c]
push eax
mov ecx, dword [eax]
call dword [ecx + 0x48]
mov eax, dword [0x615b9c]
push eax
mov edx, dword [eax]
call dword [edx + 8]
mov dword [0x615b9c], ebx
mov ecx, 0xd2
xor eax, eax
mov edi, 0x4a3838
mov dword [0x615bac], ebx
rep stosd dword es:[edi], eax
mov eax, dword [0x615ba4]
cmp eax, ebx
je 0x40374f
push eax
call ebp
mov dword [0x615ba4], ebx
push ebx
call fcn.004035d0
mov eax, dword [0x615bcc]
add esp, 4
pop edi
pop esi
pop ebp
pop ebx
ret
Function at 0x404a30
Capabilities:
Query or enumerate registry value
Set current directory

Disassembly:
sub esp, 8
lea eax, [esp]
mov dword [esp], 0
push eax
push 0x20019
push 0
push str.SoftwareDisney_InteractiveHercules1.00
push 0x80000002
mov dword [esp + 0x18], 0x400
call dword [0xba5624]
test eax, eax
je 0x404a69
xor eax, eax
add esp, 8
ret
mov edx, dword [esp]
lea ecx, [esp + 4]
push ecx
push 0xb9e458
push 0
push 0
push 0x43617c
push edx
call dword [0xba5628]
test eax, eax
je 0x404a91
xor eax, eax
add esp, 8
ret
mov eax, dword [esp]
push eax
call dword [0xba5618]
push 0xb9e458
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
neg eax
sbb eax, eax
neg eax
add esp, 8
ret

Function at 0x404ce0
Capabilities:
Query or enumerate registry value

Disassembly:
sub esp, 8
lea eax, [esp]
push edi
push eax
push 0x20019
push 0
push str.SoftwareDisney_InteractiveHercules1.00
push 0x80000002
mov dword [esp + 0x18], 0
call dword [0xba5624]
mov eax, dword [esp + 4]
mov edi, dword [0xba5618]
test eax, eax
je 0x404d7a
lea ecx, [esp + 8]
mov dword [esp + 8], 0x48
push ecx
push 0xb9e858
push 0
push 0
push str.Config
push eax
call dword [0xba5628]
test eax, eax
jne 0x404d76
cmp dword [esp + 8], 0x48
jne 0x404d76
mov edx, dword [esp + 4]
push edx
call edi
call fcn.00404cc0
mov ecx, dword [0xb9e858]
cmp ecx, eax
je 0x404d5e
cmp ecx, 0xffffffff
jne 0x404d76
mov eax, dword [0xb9e870]
cmp eax, 2
jl 0x404d76
cmp eax, 4
jg 0x404d76
cmp byte [0xb9e864], 2
jbe 0x404d86
mov eax, dword [esp + 4]
test eax, eax
je 0x404d81
push eax
call edi
call fcn.00404be0
call fcn.00407aa0
call fcn.00404ac0
pop edi
add esp, 8
ret

Function at 0x404da0
Capabilities:
Set registry value

Disassembly:
sub esp, 8
mov dword [esp], 0
call fcn.00404b00
call fcn.00404cc0
mov dword [0xb9e858], eax
lea eax, [esp + 4]
lea ecx, [esp]
push eax
push ecx
push 0
push 0x20006
push 0
push 0
push 0
push str.SoftwareDisney_InteractiveHercules1.00
push 0x80000002
call dword [0xba561c]
mov eax, dword [esp]
test eax, eax
je 0x404e0b
push 0x48
push 0xb9e858
push 3
push 0
push str.Config
push eax
call dword [0xba5620]
mov edx, dword [esp]
push edx
call dword [0xba5618]
add esp, 8
ret

Function at 0x407bb0
Capabilities:
Log keystrokes via polling

Disassembly:
sub esp, 0x10
mov ecx, 0x650
xor eax, eax
push ebx
mov ebx, dword [sym.imp.WINMM.dll_joyGetPos]
push ebp
mov ebp, dword [sym.imp.WINMM.dll_joyGetDevCapsA]
push esi
push edi
mov edi, 0xb9e8b0
xor esi, esi
rep stosd dword es:[edi], eax
mov dword [0xba0218], esi
mov edi, 0xb9e8b0
lea eax, [esp + 0x10]
mov byte [esi + 0xb9e8a0], 0
push eax
push esi
call ebx
test eax, eax
jne 0x407c10
push 0x194
push edi
push esi
call ebp
test eax, eax
jne 0x407c10
mov eax, dword [0xba0218]
mov byte [esi + 0xb9e8a0], 1
inc eax
mov dword [0xba0218], eax
add edi, 0x194
inc esi
cmp edi, 0xba01f0
jl 0x407bde
mov edi, dword [sym.imp.USER32.dll_GetAsyncKeyState]
xor ebx, ebx
xor esi, esi
push esi
call edi
inc esi
cmp esi, 0x100
jl 0x407c29
pop edi
pop esi
mov dword [0x96e5d0], ebx
mov dword [0x96e5d4], ebx
pop ebp
pop ebx
add esp, 0x10
ret