joyce8/EMBER2024-capa huggingface dataset:
Function at 0x565d20
Capabilities:
Allocate thread local storage

Disassembly:
sub esp, 0xc
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
mov dword [0x56d1b4], eax
cmp eax, 0xffffffff
je 0x56bcb8
add esp, 0xc
ret

Function at 0x566300
Capabilities:
Print debug messages

Disassembly:
test eax, eax
je 0x566330
push edi
push esi
push ebx
mov ebx, eax
add esp, 0xffffff80
mov dword [esp], eax
call fcn.005693f0
cmp eax, 1
je 0x566331
mov dword [ebx], 0xffffffff
sub esp, 0xffffff80
pop ebx
pop esi
pop edi
ret
ret
lea ebx, [esp + 0x15]
xor eax, eax
mov esi, str.Error_cleaning_up_spin_keys_for_thread
mov ecx, 0xa
mov edi, ebx
rep movsd dword es:[edi], dword [esi]
lea edi, [esp + 0x3d]
mov ecx, 0x43
rep stosb byte es:[edi], al
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
lea edx, [esp + 0x3c]
mov dword [esp + 8], 0xa
mov dword [esp + 4], edx
mov dword [esp], eax
call dword [sym.imp.msvcrt.dll__ultoa]
cmp byte [esp + 0x3c], 0
mov eax, 0x27
jne 0x566385
jmp 0x566393
cmp eax, 0x6a
je 0x56639d
add eax, 1
cmp byte [ebx + eax], 0
jne 0x566380
cmp eax, 0x6a
je 0x56639d
mov byte [esp + eax + 0x15], 0xa
mov byte [esp + eax + 0x16], 0
mov dword [esp], ebx
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
push eax
call sub.msvcrt.dll_abort
lea esi, [esi]

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

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x2c
cmp dword [0x59218c], 1
je 0x5663c5
call fcn.00566270
mov eax, dword [0x56d1b4]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
sub esp, 4
mov ebx, eax
test eax, eax
je 0x5663f0
add esp, 0x2c
mov eax, ebx
pop ebx
pop esi
pop edi
pop ebp
ret
call fcn.005661b0
mov esi, eax
mov eax, dword [entry4]
test eax, eax
je 0x5663dc
test esi, esi
je 0x5663dc
mov dword [esi + 0x24], 1
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov dword [esi + 0x3c], eax
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 1
mov dword [esp], 0
call dword [sym.imp.KERNEL32.dll_CreateEventA]
mov dword [esi + 0x1c], 0xffffffff
mov dword [esi + 0x18], eax
sub esp, 0x10
lea eax, [esi + 0x38]
call fcn.00566300
mov ebp, dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov dword [esi + 0x64], 0
mov dword [esi + 0x14], 0
call ebp
mov edi, eax
call dword [sym.imp.KERNEL32.dll_GetCurrentThread]
mov ebx, eax
call ebp
lea edx, [esi + 0x14]
mov dword [esp + 8], edi
mov dword [esp + 0x18], 2
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], edx
mov dword [esp + 4], ebx
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_DuplicateHandle]
sub esp, 0x1c
test eax, eax
je 0x56bcbd
mov eax, dword [esi + 0x14]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_GetThreadPriority]
mov dword [esi + 0x68], 0
mov dword [esi + 0x6c], eax
movzx eax, byte [esi + 0x20]
sub esp, 4
and eax, 0xffffffcf
or eax, 0x10
mov byte [esi + 0x20], al
mov eax, dword [0x56d1b4]
mov dword [esp + 4], esi
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
sub esp, 8
test eax, eax
je 0x56bcbd
add esp, 0x2c
mov ebx, esi
mov eax, ebx
pop ebx
pop esi
pop edi
pop ebp
ret
call sub.msvcrt.dll_abort
mov eax, dword [pe_dos_header]
ud2
Function at 0x566640
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push edi
push esi
push ebx
sub esp, 0x10
mov eax, dword [esp + 0x24]
test eax, eax
jne 0x566670
mov ecx, dword [esp + 0x28]
test ecx, ecx
je 0x566720
add esp, 0x10
mov eax, 1
pop ebx
pop esi
pop edi
ret 0xc
cmp eax, 1
je 0x566750
cmp eax, 3
jne 0x56665a
mov eax, dword [0x56d1b4]
cmp eax, 0xffffffff
je 0x56665a
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
sub esp, 4
mov ebx, eax
test eax, eax
je 0x56665a
test byte [eax + 0x20], 0x30
je 0x566780
mov eax, dword [eax + 0xb4]
test eax, eax
je 0x5666b3
call fcn.00566540
mov eax, dword [ebx + 0x14]
test eax, eax
je 0x5666e5
mov dword [esp], eax
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
mov eax, dword [ebx + 0x18]
sub esp, 4
test eax, eax
je 0x5666d7
mov dword [esp], eax
call esi
sub esp, 4
mov dword [ebx + 0x18], 0
mov dword [ebx + 0x14], 0
lea eax, [ebx + 0x1c]
mov dword [esp], eax
call fcn.00565aa0
lea eax, [ebx + 0x38]
call fcn.00566300
mov eax, ebx
call fcn.00565f30
mov eax, dword [0x56d1b4]
mov dword [esp + 4], 0
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
sub esp, 8
jmp 0x56665a
mov eax, dword [0x592168]
test eax, eax
je 0x56665a
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_RemoveVectoredExceptionHandler]
mov dword [0x592168], 0
sub esp, 4
jmp 0x56665a
mov dword [esp + 4], 0x565c50
mov dword [esp], 1
call dword [sym.imp.KERNEL32.dll_AddVectoredExceptionHandler]
sub esp, 8
mov dword [0x592168], eax
mov eax, 1
add esp, 0x10
pop ebx
pop esi
pop edi
ret 0xc
mov edx, dword [ebx + 0x68]
mov eax, dword [eax + 0x18]
test edx, edx
jne 0x5667f8
test eax, eax
je 0x56679a
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
sub esp, 4
mov eax, dword [ebx + 0xb4]
mov dword [ebx + 0x18], 0
mov dword [ebx + 0x68], 1
test eax, eax
je 0x5667b7
call fcn.00566540
lea edi, [ebx + 0x1c]
lea esi, [ebx + 0x38]
test byte [ebx + 0x24], 4
je 0x566830
mov eax, dword [ebx + 0x14]
mov dword [ebx], 0xdeadbeef
test eax, eax
je 0x5667dc
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
sub esp, 4
mov dword [ebx + 0x14], 0
mov dword [esp], edi
call fcn.00565aa0
mov eax, esi
jmp 0x5666f3
test eax, eax
je 0x566808
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
sub esp, 4
lea eax, [ebx + 0x1c]
mov dword [ebx + 0x18], 0
mov dword [esp], eax
call fcn.00565aa0
lea eax, [ebx + 0x38]
call fcn.00566300
jmp 0x56665a
mov dword [esp], edi
call fcn.00565aa0
mov eax, esi
call fcn.00566300
jmp 0x56665a
Function at 0x567190
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push esi
push ebx
sub esp, 0x14
mov esi, dword [esp + 0x20]
call fcn.005663b0
mov dword [eax + 4], esi
mov ebx, eax
mov eax, dword [eax + 0xb4]
test eax, eax
je 0x5671b2
call fcn.00566540
test byte [ebx + 0x20], 0x30
jne 0x5671cc
add ebx, 0x70
mov dword [esp + 4], 1
mov dword [esp], ebx
call dword [sym.imp.msvcrt.dll_longjmp]
mov eax, dword [0x56d1b4]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ebx, eax
push edx
test eax, eax
je 0x56720f
cmp dword [ebx + 0x14], 0
mov eax, dword [eax + 0x18]
je 0x567253
mov dword [ebx + 0x68], 1
mov esi, dword [ebx + 4]
test eax, eax
je 0x567202
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push ecx
mov dword [ebx + 0x18], 0
test byte [ebx + 0x24], 4
jne 0x567218
mov dword [esp], esi
call dword [sym.imp.msvcrt.dll__endthreadex]
mov eax, dword [ebx + 0x14]
mov dword [ebx], 0xdeadbeef
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edx
mov dword [ebx + 0x14], 0
mov eax, ebx
call fcn.00565f30
mov eax, dword [0x56d1b4]
mov dword [esp + 4], 0
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
push eax
push eax
jmp 0x56720f
mov dword [ebx], 0xdeadbeef
test eax, eax
je 0x567267
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push esi
mov dword [ebx + 0x18], 0
mov esi, dword [ebx + 4]
jmp 0x567232

Function at 0x56adf0
Capabilities:
Write file on windows

Disassembly:
push ebx
sub esp, 0x18
mov dword [esp], 2
lea ebx, [esp + 0x24]
call fcn.0056ab50
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 sub.msvcrt.dll_fwrite
mov dword [esp], 2
call fcn.0056ab50
mov edx, dword [esp + 0x20]
mov dword [esp + 8], ebx
mov dword [esp], eax
mov dword [esp + 4], edx
call sub.msvcrt.dll_vfprintf
call sub.msvcrt.dll_abort
lea esi, [esi]
Function at 0x56ae50
Capabilities:
Allocate or change rwx memory

Disassembly:
push edi
push esi
push ebx
mov ebx, eax
sub esp, 0x30
mov esi, dword [0x5921d4]
test esi, esi
jle 0x56af70
mov eax, dword [0x5921d8]
xor ecx, ecx
add eax, 0xc
mov edx, dword [eax]
cmp edx, ebx
ja 0x56ae84
mov edi, dword [eax + 4]
add edx, dword [edi + 8]
cmp ebx, edx
jb 0x56af07
add ecx, 1
add eax, 0x14
cmp ecx, esi
jne 0x56ae70
mov dword [esp], ebx
call fcn.0056b7e0
mov edi, eax
test eax, eax
je 0x56af97
mov eax, dword [0x5921d8]
lea ebx, [esi + esi*4]
shl ebx, 2
add eax, ebx
mov dword [eax + 0x10], edi
mov dword [eax], 0
call fcn.0056b8f0
mov edx, dword [0x5921d8]
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 0x56af77
mov eax, dword [esp + 0x28]
lea edx, [eax - 0x40]
and edx, 0xffffffbf
je 0x56af00
lea edx, [eax - 4]
and edx, 0xfffffffb
jne 0x56af10
add dword [0x5921d4], 1
add esp, 0x30
pop ebx
pop esi
pop edi
ret
cmp eax, 2
mov edx, 0x40
mov eax, 4
mov ecx, dword [esp + 0x20]
cmovne eax, edx
mov edx, dword [esp + 0x14]
add ebx, dword [0x5921d8]
mov dword [ebx + 8], ecx
mov dword [ebx + 4], edx
mov dword [esp + 0xc], ebx
mov dword [esp + 8], eax
mov dword [esp + 4], ecx
mov dword [esp], edx
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
sub esp, 0x10
test eax, eax
jne 0x56af00
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [esp], str.__VirtualProtect_failed_with_code_0x_x
mov dword [esp + 4], eax
call fcn.0056adf0
lea esi, [esi]
lea esi, [esi]
xor esi, esi
jmp 0x56ae8e
mov eax, dword [0x5921d8]
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 fcn.0056adf0
mov dword [esp + 4], ebx
mov dword [esp], str.Address__p_has_no_image_section
call fcn.0056adf0
lea esi, [esi]
nop

Function at 0x56b450
Capabilities:
Get thread local storage value

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x1c
mov dword [esp], 0x5921f0
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov ebx, dword [0x5921e8]
sub esp, 4
test ebx, ebx
je 0x56b4a5
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 0x56b49e
test esi, esi
je 0x56b49e
mov eax, dword [ebx + 4]
mov dword [esp], esi
call eax
mov ebx, dword [ebx + 8]
test ebx, ebx
jne 0x56b480
mov dword [esp], 0x5921f0
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
sub esp, 4
add esp, 0x1c
pop ebx
pop esi
pop edi
pop ebp
ret
Function at 0x42a550
Capabilities:
Packed with generic packer

Disassembly:
pushal
mov esi, section.UPX1
lea edi, [esi - 0x25000]
push edi
or ebp, 0xffffffff
jmp 0x42a572
mov al, byte [esi]
inc esi
mov byte [edi], al
inc edi
add ebx, ebx
jne 0x42a579
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x42a568
mov eax, 1
add ebx, ebx
jne 0x42a58b
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc eax, eax
add ebx, ebx
jae 0x42a580
jne 0x42a59c
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jae 0x42a580
xor ecx, ecx
sub eax, 3
jb 0x42a5b0
shl eax, 8
mov al, byte [esi]
inc esi
xor eax, 0xffffffff
je 0x42a622
mov ebp, eax
add ebx, ebx
jne 0x42a5bb
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
add ebx, ebx
jne 0x42a5c8
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
jne 0x42a5ec
inc ecx
add ebx, ebx
jne 0x42a5d8
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
add ebx, ebx
jae 0x42a5cd
jne 0x42a5e9
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jae 0x42a5cd
add ecx, 2
cmp ebp, 0xfffff300
adc ecx, 1
lea edx, [edi + ebp]
cmp ebp, 0xfffffffc
jbe 0x42a60c
mov al, byte [edx]
inc edx
mov byte [edi], al
inc edi
dec ecx
jne 0x42a5fd
jmp 0x42a56e
mov eax, dword [edx]
add edx, 4
mov dword [edi], eax
add edi, 4
sub ecx, 4
ja 0x42a60c
add edi, ecx
jmp 0x42a56e
pop esi
lea edi, [esi + 0x27000]
mov eax, dword [edi]
or eax, eax
je 0x42a674
mov ebx, dword [edi + 4]
lea eax, [eax + esi + 0x2a1dc]
add ebx, esi
push eax
add edi, 8
call dword [esi + 0x2a254]
xchg ebp, eax
mov al, byte [edi]
inc edi
or al, al
je 0x42a629
mov ecx, edi
jns 0x42a658
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 + 0x2a25c]
or eax, eax
je 0x42a66e
mov dword [ebx], eax
add ebx, 4
jmp 0x42a646
call dword [esi + 0x2a258]
add edi, 4
lea ebx, [esi - 4]
xor eax, eax
mov al, byte [edi]
inc edi
or eax, eax
je 0x42a6a5
cmp al, 0xef
ja 0x42a698
add ebx, eax
mov eax, dword [ebx]
xchg ah, al
rol eax, 0x10
xchg ah, al
add eax, esi
mov dword [ebx], eax
jmp 0x42a67a
and al, 0xf
shl eax, 0x10
mov ax, word [edi]
add edi, 2
jmp 0x42a687
mov ebp, dword [esi + 0x2a260]
lea edi, [esi - 0x1000]
mov ebx, 0x1000
push eax
push esp
push 4
push ebx
push edi
call ebp
lea eax, [edi + 0x207]
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 0x42a6d9
sub esp, 0xffffff80
jmp 0x41102d
Function at 0x10004770
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20c
cmp eax, 0xffffffcb
inc eax
cmp eax, 0xba6abe71
mov eax, 0x9167589b
mov eax, ecx
nop
cmp eax, 0x3bd6aac7
cmp eax, 0x5f200b78
mov eax, ebx
mov eax, ebx
cmp eax, 0xffffff87
mov eax, ebx
mov eax, ecx
mov eax, ecx
nop
nop
push 3
push 2
push 1
call fcn.1000c1f0
add esp, 0xc
mov eax, ecx
mov eax, ebx
cmp eax, 0xd0276bb9
mov eax, ebx
nop
mov eax, ebx
mov eax, ebx
mov eax, ebx
cmp eax, 0x49e83926
cmp eax, 0xd4fee8e7
mov eax, ecx
nop
mov eax, ecx
inc eax
mov eax, ebx
mov eax, 0xcd17c76b
inc eax
push 3
push 2
push 1
call fcn.1000c1f0
add esp, 0xc
push 0x104
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
cmp eax, 0xf4ac83c3
cmp eax, 0x4c
cmp eax, 0x7d83fef4
cmp eax, 0xdb09f0e2
mov eax, ebx
nop
inc eax
cmp eax, 0xffffffd8
mov eax, 0x92a9ec36
mov eax, ecx
inc eax
cmp eax, 0xffffff8a
mov eax, 0x87d543d5
nop
push 3
push 2
push 1
call fcn.1000c1f0
add esp, 0xc
push 0x1002beb4
lea ecx, [ebp - 0x20c]
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcatW]
nop
nop
mov eax, 0xfce2bf1d
nop
cmp eax, 0x7a
cmp eax, 0xffffffef
mov eax, 0x7a39a33d
mov eax, 0xca382961
mov eax, ebx
nop
inc eax
cmp eax, 0xffffffa4
cmp eax, 0xbe3fa46d
cmp eax, 0x8d4149a1
inc eax
push 3
push 2
push 1
call fcn.1000c1f0
add esp, 0xc
lea edx, [ebp - 0x20c]
push edx
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov dword [0x1003e22c], eax
mov eax, ecx
mov eax, ecx
mov eax, 0xe6b09e49
inc eax
mov eax, ecx
cmp eax, 0x50
mov eax, ecx
inc eax
mov eax, ebx
cmp eax, 0x4a
inc eax
inc eax
mov eax, 0x5520f856
mov eax, ebx
mov eax, ebx
mov eax, ecx
mov eax, 0x5ee2a3f3
inc eax
push 3
push 2
push 1
call fcn.1000c1f0
add esp, 0xc
cmp dword [0x1003e22c], 0
jne 0x1000491f
push 0x41030
push str.DllWrap
push str.miss
push 0
call dword [sym.imp.USER32.dll_MessageBoxW]
mov eax, ecx
mov eax, ebx
cmp eax, 0xf54111f6
mov eax, ebx
cmp eax, 0xa3eace65
mov eax, ecx
mov eax, ecx
cmp eax, 0xb1f14596
mov eax, 0xe9feb08d
nop
cmp eax, 0x4b70e690
mov eax, 0xf631cb02
nop
push 3
push 2
push 1
call fcn.1000c1f0
add esp, 0xc
cmp dword [0x1003e22c], 0
je 0x10004931
mov dword [ebp - 4], 1
jmp 0x10004938
mov dword [ebp - 4], 0
mov eax, dword [ebp - 4]
mov esp, ebp
pop ebp
ret
Function at 0x401143
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
push edi
mov edi, 0x104
push edi
call fcn.004055d9
mov esi, eax
pop ecx
test esi, esi
jne 0x40115f
push 5
jmp 0x40117a
and byte [esi + 1], 0
push edi
push esi
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
cmp byte [esi + 1], 0x3a
je 0x40117d
push esi
call fcn.004054f0
pop ecx
push 1
pop eax
jmp 0x401196
mov al, byte [esi]
push esi
mov byte [ebp - 4], al
call fcn.004054f0
push dword [ebp + 8]
push dword [ebp - 4]
call fcn.00401357
add esp, 0xc
pop edi
pop esi
leave
ret

Function at 0x401357
Capabilities:
Check os version

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x94
lea eax, [ebp - 0x94]
mov dword [ebp - 0x94], 0x94
push eax
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
test eax, eax
je 0x4013ad
cmp dword [ebp - 0x84], 2
jne 0x4013ad
push dword [ebp + 0xc]
cmp dword [ebp - 0x90], 5
push dword [ebp + 8]
jae 0x40139a
call 0x403440
jmp 0x40139f
call fcn.004034cd
pop ecx
pop ecx
xor ecx, ecx
test ax, ax
sete cl
mov eax, ecx
leave
ret
push 1
pop eax
leave
ret

Function at 0x4013b2
Capabilities:
Read file on windows
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [ebp + 0x10]
push ebx
mov ebx, dword [ebp + 0xc]
push esi
push edi
xor edi, edi
dec eax
push edi
mul ebx
mov esi, eax
lea eax, [ebp + 0x10]
push eax
push esi
push dword [ebp + 8]
mov dword [ebp - 4], edi
mov dword [ebp + 0x10], edx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp eax, esi
je 0x4013e3
push 0xd
jmp 0x401402
lea eax, [ebp - 4]
push edi
push eax
push ebx
push dword [ebp + 0x14]
xor esi, esi
cmp dword [ebp + 0x18], edi
push dword [ebp + 8]
je 0x401405
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x401413
push 9
pop esi
jmp 0x401425
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x401413
push 8
jmp 0x401402
cmp dword [ebp - 4], ebx
je 0x401425
xor eax, eax
cmp dword [ebp + 0x18], edi
setne al
add eax, 8
mov esi, eax
mov eax, esi
pop edi
pop esi
pop ebx
leave
ret
Function at 0x403da4
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x16c
push ebx
push esi
mov esi, dword [ebp + 8]
push 0x4111c8
push 0x411310
push str.SOFTWARE_sLicenses_s
lea eax, [ebp - 0x16c]
xor ebx, ebx
push 0x100
push eax
mov dword [esi], ebx
mov dword [ebp + 8], ebx
call fcn.00405db0
add esp, 0x14
lea eax, [ebp + 8]
push eax
push 0x20019
lea eax, [ebp - 0x16c]
push ebx
push eax
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x403e89
push edi
push 0x60
pop edi
lea eax, [ebp - 0x6c]
push edi
push ebx
push eax
call fcn.00405b10
add esp, 0xc
lea eax, [ebp - 0xc]
mov dword [ebp - 8], 3
mov dword [ebp - 0xc], edi
push eax
lea eax, [ebp - 0x6c]
push eax
lea eax, [ebp - 8]
push eax
push ebx
push 0x414648
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
push dword [ebp + 8]
mov edi, eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
cmp edi, ebx
pop edi
jne 0x403e89
cmp dword [ebp - 8], 3
jne 0x403e89
cmp dword [ebp - 0xc], 8
jb 0x403e89
cmp esi, ebx
je 0x403e83
lea eax, [ebp - 0x6c]
push 4
push eax
lea eax, [ebp - 4]
push eax
mov dword [ebp - 4], ebx
call fcn.00405720
lea eax, [ebp - 0x68]
push 4
push eax
push esi
call fcn.00405720
push esi
call fcn.00403d0c
mov eax, dword [ebp - 4]
add esp, 0x1c
sub dword [esi], eax
mov ax, 1
jmp 0x403e8c
xor ax, ax
pop esi
pop ebx
leave
ret

Function at 0x403e90
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x168
push ebx
xor ebx, ebx
cmp dword [0x414634], ebx
je 0x403fa4
push 0x4111c8
push 0x411310
push str.SOFTWARE_sLicenses_s
lea eax, [ebp - 0x168]
push 0x100
push eax
mov dword [ebp - 8], ebx
mov dword [ebp - 4], ebx
call fcn.00405db0
add esp, 0x14
lea eax, [ebp - 8]
push ebx
push eax
push 0x414548
push 0xf003f
push ebx
push ebx
lea eax, [ebp - 0x168]
push ebx
push eax
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
test eax, eax
je 0x403f01
xor ax, ax
jmp 0x403fa8
push esi
push 0x60
lea eax, [ebp - 0x68]
push ebx
push eax
call fcn.00405b10
push ebx
call fcn.004069f3
push eax
call fcn.004069c4
call fcn.004069d1
mov esi, eax
shl esi, 0x10
call fcn.004069d1
add esi, eax
lea eax, [ebp - 4]
push 4
push eax
lea eax, [ebp - 0x68]
mov dword [ebp - 4], esi
push eax
call fcn.00405720
mov eax, dword [ebp - 4]
add esp, 0x20
add dword [ebp + 8], eax
push 4
pop esi
lea eax, [ebp + 8]
push eax
call fcn.00403cf1
lea eax, [ebp + 8]
push 4
push eax
lea eax, [ebp + esi - 0x68]
push eax
call fcn.00405720
mov eax, dword [ebp + 8]
add esi, 4
add eax, eax
add esp, 0x10
sub eax, dword [ebp - 4]
cmp esi, 0x60
mov dword [ebp + 8], eax
jb 0x403f49
lea eax, [ebp - 0x68]
push 0x60
push eax
push 3
push ebx
push 0x414648
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
push dword [ebp - 8]
mov esi, eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor eax, eax
cmp esi, ebx
sete al
pop esi
jmp 0x403fa8
mov ax, 1
pop ebx
leave
ret
Function at 0x40ba2e
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1a4
mov edx, dword [ebp + 8]
xor ecx, ecx
mov eax, 0x413bb8
cmp edx, dword [eax]
je 0x40ba50
add eax, 8
inc ecx
cmp eax, 0x413c48
jl 0x40ba41
push esi
mov esi, ecx
shl esi, 3
cmp edx, dword [esi + 0x413bb8]
jne 0x40bb7e
mov eax, dword [0x414ba8]
cmp eax, 1
je 0x40bb58
test eax, eax
jne 0x40ba81
cmp dword [0x4117d4], 1
je 0x40bb58
cmp edx, 0xfc
je 0x40bb7e
lea eax, [ebp - 0x1a4]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x40bab8
lea eax, [ebp - 0x1a4]
push str._program_name_unknown_
push eax
call fcn.00405cc0
pop ecx
pop ecx
lea eax, [ebp - 0x1a4]
push edi
push eax
lea edi, [ebp - 0x1a4]
call fcn.00405c40
inc eax
pop ecx
cmp eax, 0x3c
jbe 0x40bafb
lea eax, [ebp - 0x1a4]
push eax
call fcn.00405c40
mov edi, eax
lea eax, [ebp - 0x1a4]
sub eax, 0x3b
push 3
add edi, eax
push 0x40f69c
push edi
call fcn.00406890
add esp, 0x10
lea eax, [ebp - 0xa0]
push str.Runtime_Error__n_nProgram:
push eax
call fcn.00405cc0
lea eax, [ebp - 0xa0]
push edi
push eax
call fcn.00405cd0
lea eax, [ebp - 0xa0]
push 0x40f67c
push eax
call fcn.00405cd0
push dword [esi + 0x413bbc]
lea eax, [ebp - 0xa0]
push eax
call fcn.00405cd0
push 0x12010
lea eax, [ebp - 0xa0]
push str.Microsoft_Visual_C_Runtime_Library
push eax
call fcn.0040d16b
add esp, 0x2c
pop edi
jmp 0x40bb7e
lea eax, [ebp + 8]
lea esi, [esi + 0x413bbc]
push 0
push eax
push dword [esi]
call fcn.00405c40
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]
pop esi
leave
ret
Function at 0x78c370
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov eax, dword [esp + 4]
push ebx
push esi
push edi
push 0x1a
push eax
push 0
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov esi, eax
test esi, esi
jne 0x78c38e
pop edi
pop esi
xor al, al
pop ebx
ret
push esi
push 0
call dword [sym.imp.KERNEL32.dll_LoadResource]
push esi
push 0
mov edi, eax
call dword [sym.imp.KERNEL32.dll_SizeofResource]
push edi
mov ebx, eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov ecx, dword [esp + 0x14]
push 0x7b5074
push ecx
mov edi, eax
call fcn.007a0198
mov esi, eax
add esp, 8
test esi, esi
jne 0x78c3cb
pop edi
pop esi
xor al, al
pop ebx
ret
push esi
push ebx
push 1
push edi
call fcn.007a002e
push esi
call fcn.0079ffb1
add esp, 0x14
mov al, 1
pop edi
pop esi
pop ebx
ret