joyce8/EMBER2024-capa huggingface dataset:
Function at 0x412157
Capabilities:
Get file size
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
push esi
xor ebx, ebx
push edi
push ebx
push 0x80
push 3
push ebx
push 1
push accept
push dword [ebp + 8]
mov esi, ecx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
cmp edi, 0xffffffff
jne 0x4121ad
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0xc]
push dword [ebp + 8]
push str.CRLStream::ReadFromFile___Couldnt_open_file__s_error_d
push eax
call fcn.004109c8
add esp, 0x10
lea eax, [ebp - 0xc]
push 0x465b58
push eax
call sub.MSVCRT.dll__CxxThrowException
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x4121ec
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0xc]
push dword [ebp + 8]
push str.CRLStream::ReadFromFile___Couldnt_get_the_size_of_file__s_error_d
push eax
call fcn.004109c8
add esp, 0x10
lea eax, [ebp - 0xc]
push 0x465b58
push eax
call sub.MSVCRT.dll__CxxThrowException
mov eax, dword [esi]
push ebx
mov ecx, esi
call dword [eax + 4]
lea eax, [ebp - 4]
push 0
push eax
push ebx
push dword [esi + 4]
push edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x412251
cmp dword [ebp - 4], ebx
jne 0x412251
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test eax, eax
jne 0x412242
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0xc]
push dword [ebp + 8]
push str.CRLStream::ReadFromFile___Couldnt_close_file__s_error_d
push eax
call fcn.004109c8
add esp, 0x10
lea eax, [ebp - 0xc]
push 0x465b58
push eax
call sub.MSVCRT.dll__CxxThrowException
mov eax, dword [esi]
push ebx
mov ecx, esi
call dword [eax + 0x1c]
pop edi
pop esi
pop ebx
leave
ret 4
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0xc]
push dword [ebp + 8]
push str.CRLStream::ReadFromFile___Couldnt_read_file__s_error_d
push eax
call fcn.004109c8
add esp, 0x10
lea eax, [ebp - 0xc]
push 0x465b58
push eax
call sub.MSVCRT.dll__CxxThrowException
Function at 0x412281
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
push esi
push 0
push 0x80
push 2
push 0
push 0
push 0x40000000
push dword [ebp + 8]
mov esi, ecx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x4122d6
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0xc]
push dword [ebp + 8]
push str.CRLStream::WriteToFile___Couldnt_create_file__s_error_d
push eax
call fcn.004109c8
add esp, 0x10
lea eax, [ebp - 0xc]
push 0x465b58
push eax
call sub.MSVCRT.dll__CxxThrowException
lea eax, [ebp - 4]
push 0
push eax
push dword [esi + 0xc]
push dword [esi + 4]
push ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x412329
mov eax, dword [ebp - 4]
cmp eax, dword [esi + 0xc]
jne 0x412329
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test eax, eax
jne 0x412359
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0xc]
push dword [ebp + 8]
push str.CRLStream::WriteToFile___Couldnt_close_file__s_error_d
push eax
call fcn.004109c8
add esp, 0x10
lea eax, [ebp - 0xc]
push 0x465b58
push eax
call sub.MSVCRT.dll__CxxThrowException
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0xc]
push dword [ebp + 8]
push str.CRLStream::WriteToFile___Couldnt_write_to_file__s_error_d
push eax
call fcn.004109c8
add esp, 0x10
lea eax, [ebp - 0xc]
push 0x465b58
push eax
call sub.MSVCRT.dll__CxxThrowException
pop esi
pop ebx
leave
ret 4

Function at 0x412580
Capabilities:
Get graphical window text

Disassembly:
mov eax, 0x45f42b
call fcn.0045d320
push ecx
push ecx
push ebx
push esi
push edi
mov edi, ecx
xor esi, esi
lea ecx, [ebp - 0x10]
mov dword [ebp - 0x14], esi
call fcn.00412af0
push esi
push esi
mov esi, dword [sym.imp.USER32.dll_SendMessageA]
push 0xe
push dword [edi + 4]
mov dword [ebp - 4], 1
call esi
mov ebx, eax
test ebx, ebx
jbe 0x4125d6
inc ebx
lea ecx, [ebp - 0x10]
push ebx
call fcn.004131b3
push eax
push ebx
push 0xd
push dword [edi + 4]
call esi
push eax
lea ecx, [ebp - 0x10]
call fcn.00413289
mov ecx, dword [ebp + 8]
lea eax, [ebp - 0x10]
push eax
call fcn.00412afc
mov dword [ebp - 0x14], 1
and byte [ebp - 4], 0
lea ecx, [ebp - 0x10]
call fcn.00412d67
mov ecx, dword [ebp - 0xc]
mov eax, dword [ebp + 8]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret 4
Function at 0x412609
Capabilities:
Get graphical window text

Disassembly:
mov eax, 0x45f457
call fcn.0045d320
push ecx
push ecx
push ebx
push esi
push edi
mov esi, ecx
xor edi, edi
lea ecx, [ebp - 0x10]
mov dword [ebp - 0x14], edi
call fcn.00413ce7
push 1
pop ebx
push edi
push edi
push 0xe
mov dword [ebp - 4], ebx
push dword [esi + 4]
call dword [sym.imp.USER32.dll_SendMessageA]
mov edi, eax
test edi, edi
jbe 0x412660
inc edi
lea ecx, [ebp - 0x10]
push edi
call fcn.0041424e
push eax
push edi
push 0xd
push dword [esi + 4]
call dword [sym.imp.USER32.dll_SendMessageW]
push eax
lea ecx, [ebp - 0x10]
call fcn.00414324
mov ecx, dword [ebp + 8]
lea eax, [ebp - 0x10]
push eax
call fcn.00413cf3
mov dword [ebp - 0x14], ebx
and byte [ebp - 4], 0
lea ecx, [ebp - 0x10]
call fcn.00413ff7
mov ecx, dword [ebp - 0xc]
mov eax, dword [ebp + 8]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret 4
Function at 0x416909
Capabilities:
Terminate process

Disassembly:
push ecx
push ecx
push esi
mov esi, ecx
mov eax, dword [esi + 4]
test eax, eax
je 0x416949
push 0
push eax
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
push dword [esi + 4]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test eax, eax
jne 0x416945
push 0x4d0
push str.C:projectsAmmyy_sources_viewer_vrClient.cpp
lea ecx, [esp + 0xc]
call fcn.00410522
mov ecx, eax
call fcn.0041062e
and dword [esi + 4], 0
pop esi
pop ecx
pop ecx
ret

Function at 0x418c90
Capabilities:
Open clipboard
Read clipboard data

Disassembly:
mov eax, 0x45f924
call fcn.0045d320
sub esp, 0x18
push esi
mov esi, ecx
call dword [sym.imp.USER32.dll_GetClipboardOwner]
cmp eax, dword [esi + 0x64]
je 0x418d7d
cmp byte [esi + 0x3ab0], 0
lea eax, [esi + 0x3ab0]
jne 0x418cc6
mov byte [eax], 1
jmp 0x418d7d
cmp byte [esi + 0x3a08], 0
jne 0x418d7d
lea ecx, [esi + 0xf4]
push edi
mov dword [ebp - 0x10], ecx
call fcn.0043789c
push dword [esi + 0x64]
and dword [ebp - 4], 0
call dword [sym.imp.USER32.dll_OpenClipboard]
test eax, eax
je 0x418d70
push 0xd
call dword [sym.imp.USER32.dll_GetClipboardData]
mov edi, eax
test edi, edi
jne 0x418d09
call dword [sym.imp.USER32.dll_CloseClipboard]
jmp 0x418d70
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_GlobalLock]
lea ecx, [ebp - 0x24]
mov ebx, eax
call fcn.00411c60
mov ecx, dword [esi + 0x3ac0]
lea edx, [ebp - 0x24]
push edx
push ebx
mov eax, dword [ecx]
mov byte [ebp - 4], 1
call dword [eax + 0x1c]
push edi
call dword [sym.imp.KERNEL32.dll_GlobalUnlock]
call dword [sym.imp.USER32.dll_CloseClipboard]
lea ecx, [ebp - 0x24]
call fcn.00412465
mov edi, eax
mov ecx, eax
pop ebx
mov dl, byte [edi]
inc edi
cmp dl, 0xd
je 0x418d49
mov byte [ecx], dl
inc ecx
test dl, dl
jne 0x418d49
sub ecx, eax
dec ecx
push ecx
push eax
mov ecx, esi
call fcn.00417aab
and byte [ebp - 4], 0
lea ecx, [ebp - 0x24]
call fcn.00411cb9
mov ecx, dword [ebp - 0x10]
or dword [ebp - 4], 0xffffffff
call fcn.004378a4
pop edi
mov ecx, dword [ebp - 0xc]
pop esi
mov dword fs:[0], ecx
leave
ret
Function at 0x418d8a
Capabilities:
Open clipboard
Write clipboard data

Disassembly:
mov eax, 0x45f948
call fcn.0045d320
sub esp, 0x30
push esi
mov esi, ecx
push edi
cmp byte [esi + 0x3a08], 0
jne 0x418ef3
mov eax, dword [ebp + 0xc]
lea ecx, [ebp - 0x3c]
lea eax, [eax + eax + 1]
push eax
call fcn.00411c93
and dword [ebp - 4], 0
lea ecx, [ebp - 0x28]
call fcn.00411c60
lea ecx, [ebp - 0x3c]
mov byte [ebp - 4], 1
call fcn.00412465
mov edx, dword [ebp + 8]
mov edi, eax
mov ecx, edi
mov al, byte [edx]
inc edx
cmp al, 0xa
jne 0x418de2
mov byte [ecx], 0xd
inc ecx
mov byte [ecx], al
inc ecx
test al, al
jne 0x418dd7
mov ecx, dword [esi + 0x3ac0]
lea edx, [ebp - 0x28]
push edx
push edi
mov eax, dword [ecx]
call dword [eax + 0x20]
lea edi, [esi + 0xf4]
mov ecx, edi
mov dword [ebp + 8], edi
call fcn.0043789c
push dword [esi + 0x64]
mov byte [ebp - 4], 2
call dword [sym.imp.USER32.dll_OpenClipboard]
test eax, eax
jne 0x418e38
lea eax, [ebp - 0x14]
push str.Failed_to_open_clipboard
push eax
call fcn.004109c8
pop ecx
lea eax, [ebp - 0x14]
pop ecx
push 0x465b58
push eax
call sub.MSVCRT.dll__CxxThrowException
call dword [sym.imp.USER32.dll_EmptyClipboard]
test eax, eax
jne 0x418e60
lea eax, [ebp - 0x14]
push str.Failed_to_empty_clipboard
push eax
call fcn.004109c8
pop ecx
lea eax, [ebp - 0x14]
pop ecx
push 0x465b58
push eax
call sub.MSVCRT.dll__CxxThrowException
mov eax, dword [ebp - 0x1c]
push eax
push 0x2000
mov dword [ebp + 0xc], eax
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov esi, eax
test esi, esi
je 0x418ea8
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_GlobalLock]
push dword [ebp + 0xc]
lea ecx, [ebp - 0x28]
mov ebx, eax
call fcn.00412465
push eax
push ebx
call sub.MSVCRT.dll_memcpy
add esp, 0xc
push esi
call dword [sym.imp.KERNEL32.dll_GlobalUnlock]
push esi
push 0xd
call dword [sym.imp.USER32.dll_SetClipboardData]
pop ebx
call dword [sym.imp.USER32.dll_CloseClipboard]
test eax, eax
jne 0x418ed0
lea eax, [ebp - 0x14]
push str.Failed_to_close_clipboard
push eax
call fcn.004109c8
pop ecx
lea eax, [ebp - 0x14]
pop ecx
push 0x465b58
push eax
call sub.MSVCRT.dll__CxxThrowException
mov ecx, edi
mov byte [ebp - 4], 1
call fcn.004378a4
and byte [ebp - 4], 0
lea ecx, [ebp - 0x28]
call fcn.00411cb9
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x3c]
call fcn.00411cb9
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
leave
ret 8
Function at 0x420712
Capabilities:
Hide graphical window

Disassembly:
push esi
mov esi, ecx
cmp byte [esi + 0x8a0], 0
lea eax, [esi + 0x8a0]
je 0x420732
push dword [esi + 0x814]
call dword [sym.imp.USER32.dll_SetForegroundWindow]
pop esi
ret
push esi
push 0x4208c1
push 0
push 0xdb
mov byte [eax], 1
push dword [0x47a620]
call dword [sym.imp.USER32.dll_CreateDialogParamA]
add esi, 0x814
push 5
push eax
mov dword [esi], eax
call dword [sym.imp.USER32.dll_ShowWindow]
push dword [esi]
call dword [sym.imp.USER32.dll_UpdateWindow]
pop esi
ret
Function at 0x42137a
Capabilities:
Delete file

Disassembly:
push esi
mov esi, ecx
push edi
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [esi + 0x840], 0
lea eax, [esi + 0x840]
je 0x42139e
push dword [esi + 0x85c]
and dword [eax], 0
call edi
cmp dword [esi + 0x844], 0
lea eax, [esi + 0x844]
je 0x4213dd
push dword [esi + 0x858]
and dword [eax], 0
or dword [esi + 0x80c], 0xffffffff
or dword [esi + 0x808], 0xffffffff
mov dword [esi + 0x854], 1
call edi
add esi, 0x6f9
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
pop edi
pop esi
ret
Function at 0x423521
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
lea eax, [ebp + 8]
push eax
xor eax, eax
push eax
push dword [ebp + 8]
push 0x42330b
push eax
push eax
call dword [sym.imp.KERNEL32.dll_CreateThread]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop ebp
ret

Function at 0x4236f2
Capabilities:
Enumerate pe sections

Disassembly:
push ebx
mov eax, ecx
mov ecx, dword [esp + 8]
push esi
push edi
push 0xffffffffffffffca
mov edi, ecx
pop ebx
sub edi, eax
lea esi, [eax + 0x36]
sub ebx, eax
mov dl, byte [edi + esi]
mov byte [esi], dl
inc esi
lea edx, [ebx + esi]
cmp edx, 8
jle 0x423707
mov dl, byte [ecx + 6]
pop edi
mov byte [eax + 6], dl
mov dl, byte [ecx + 7]
mov byte [eax + 7], dl
mov dl, byte [ecx + 8]
mov byte [eax + 8], dl
mov edx, dword [ecx + 0xc]
mov dword [eax + 0xc], edx
mov dl, byte [ecx + 0x10]
mov byte [eax + 0x10], dl
mov dl, byte [ecx + 0x18]
mov byte [eax + 0x18], dl
mov dl, byte [ecx + 0x19]
mov byte [eax + 0x19], dl
mov edx, dword [ecx + 0x1c]
mov dword [eax + 0x1c], edx
mov edx, dword [ecx + 0x20]
mov dword [eax + 0x20], edx
mov edx, dword [ecx + 0x14]
mov dword [eax + 0x14], edx
mov dl, byte [ecx + 4]
mov byte [eax + 4], dl
mov edx, dword [ecx + 0x44]
mov dword [eax + 0x44], edx
mov dl, byte [ecx + 5]
mov byte [eax + 5], dl
mov dl, byte [ecx + 0x24]
mov byte [eax + 0x24], dl
mov edx, dword [ecx + 0x28]
mov dword [eax + 0x28], edx
mov dl, byte [ecx + 0x2c]
mov byte [eax + 0x2c], dl
mov edx, dword [ecx + 0x30]
mov dword [eax + 0x30], edx
mov dl, byte [ecx + 0x34]
mov byte [eax + 0x34], dl
mov cl, byte [ecx + 0x35]
pop esi
mov byte [eax + 0x35], cl
pop ebx
ret 4
Function at 0x4276b2
Capabilities:
Write file on windows

Disassembly:
mov eax, 0x45ffb0
call fcn.0045d320
sub esp, 0x40
push ebx
push esi
push edi
lea eax, [ebp - 0xf]
push 2
mov ebx, ecx
push eax
call fcn.004278b0
xor esi, esi
cmp word [ebp - 0xf], si
jne 0x427766
lea eax, [ebp - 0x14]
push 4
push eax
mov ecx, ebx
call fcn.004278b0
cmp dword [ebx + 8], esi
je 0x4277f5
lea eax, [ebp - 0x20]
mov ecx, ebx
push eax
push dword [ebp - 0x14]
call fcn.004284c2
lea eax, [ebp - 0x20]
push eax
lea eax, [ebp - 0x20]
push eax
lea eax, [ebp - 0x20]
push eax
push dword [ebx + 0x94]
call dword [sym.imp.KERNEL32.dll_SetFileTime]
test eax, eax
mov edi, str.C:projectsAmmyy_sources_target_trClient.cpp
mov esi, 0x47a230
jne 0x427736
push str.SetFileTime___failed
push edi
push 2
push esi
call fcn.0040e807
add esp, 0x10
push dword [ebx + 0x94]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
and dword [ebx + 0x84], 0
add ebx, 0x98
push ebx
push str.file_upload_complete:__s_
push edi
push 2
push esi
call fcn.0040e807
add esp, 0x14
jmp 0x4277f5
movzx eax, word [ebp - 0xf]
push eax
lea ecx, [ebp - 0x34]
call fcn.00411c93
lea ecx, [ebp - 0x34]
mov dword [ebp - 4], esi
call fcn.00412465
mov edi, eax
mov ecx, ebx
movzx eax, word [ebp - 0xf]
push eax
push edi
call fcn.004278b0
mov ecx, dword [ebx + 0x1c]
mov byte [ebp - 0xd], 0x8b
push 1
lea edx, [ebp - 0xd]
mov eax, dword [ecx]
push 1
push edx
call dword [eax + 4]
cmp dword [ebx + 8], esi
je 0x4277e9
lea eax, [ebp - 0x18]
push esi
push eax
movzx eax, word [ebp - 0xf]
push eax
push edi
push dword [ebx + 0x94]
call dword [sym.imp.KERNEL32.dll_WriteFile]
movzx ecx, word [ebp - 0xf]
cmp dword [ebp - 0x18], ecx
jne 0x4277ca
cmp eax, esi
jne 0x4277e9
push 6
mov esi, str.Error_writing_file_data
pop ecx
lea edi, [ebp - 0x4c]
rep movsd dword es:[edi], dword [esi]
lea eax, [ebp - 0x4c]
mov ecx, ebx
push eax
call fcn.0042843a
mov ecx, ebx
call fcn.0042877a
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x34]
call fcn.00411cb9
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret

Function at 0x42786e
Capabilities:
Create directory

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
push edi
lea eax, [ebp - 3]
push 2
mov esi, ecx
push eax
call fcn.004278b0
movzx eax, word [ebp - 3]
push eax
mov ecx, esi
call fcn.004278c3
cmp dword [esi + 8], 0
mov edi, eax
je 0x4278a5
push edi
call fcn.004283e6
pop ecx
push 0
push edi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
push edi
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
pop ecx
pop edi
pop esi
leave
ret
Function at 0x4285ef
Capabilities:
Read file on windows

Disassembly:
mov eax, 0x460158
call fcn.0045d320
sub esp, 0x18
push ebx
push esi
push edi
mov esi, ecx
xor edi, edi
cmp dword [esi + 0x88], edi
je 0x4286df
cmp dword [esi + 0x8c], 0x14
jge 0x4286c7
mov eax, 0x2000
lea ecx, [ebp - 0x24]
push eax
mov dword [ebp - 0x10], edi
mov dword [esi + 0x2a4], eax
call fcn.00411c93
lea ecx, [ebp - 0x24]
mov dword [ebp - 4], edi
call fcn.00412465
mov ebx, eax
lea eax, [ebp - 0x10]
push edi
push eax
push dword [esi + 0x2a4]
push ebx
push dword [esi + 0x90]
call dword [sym.imp.KERNEL32.dll_ReadFile]
cmp eax, edi
je 0x42867a
cmp dword [ebp - 0x10], edi
je 0x42867a
push dword [ebp - 0x10]
mov ecx, esi
push ebx
call fcn.004286ee
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x24]
call fcn.00411cb9
jmp 0x4286cf
push dword [esi + 0x2a0]
mov ecx, esi
call fcn.00428576
lea eax, [esi + 0x19c]
push eax
push str.file_download_complete:__s
push str.C:projectsAmmyy_sources_target_trClient.cpp
push 2
push 0x47a230
call fcn.0040e807
add esp, 0x14
push dword [esi + 0x90]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x24]
mov dword [esi + 0x88], edi
call fcn.00411cb9
jmp 0x4286df
push 1
call dword [sym.imp.KERNEL32.dll_Sleep]
mov ecx, dword [esi + 0x18]
push edi
push esi
push dword [0x47ab00]
call fcn.00433b23
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret
Function at 0x429f7b
Capabilities:
Open clipboard
Write clipboard data

Disassembly:
mov eax, 0x460324
call fcn.0045d320
sub esp, 0x28
push esi
mov esi, dword [ebp + 8]
push edi
mov edi, ecx
push esi
call sub.MSVCRT.dll_strlen
pop ecx
lea eax, [eax + eax + 1]
push eax
lea ecx, [ebp - 0x34]
call fcn.00411c93
and dword [ebp - 4], 0
lea ecx, [ebp - 0x20]
call fcn.00411c60
lea ecx, [ebp - 0x34]
mov byte [ebp - 4], 1
call fcn.00412465
mov ecx, eax
mov dl, byte [esi]
inc esi
cmp dl, 0xa
jne 0x429fc9
mov byte [ecx], 0xd
inc ecx
mov byte [ecx], dl
inc ecx
test dl, dl
jne 0x429fbd
mov ecx, dword [0x47aaf0]
lea esi, [ebp - 0x20]
push esi
push eax
mov edx, dword [ecx]
call dword [edx + 0x20]
push dword [edi + 0x6c]
call dword [sym.imp.USER32.dll_OpenClipboard]
test eax, eax
je 0x42a040
push ebx
call dword [sym.imp.USER32.dll_EmptyClipboard]
test eax, eax
je 0x42a039
mov ebx, dword [ebp - 0x14]
push ebx
push 0x2000
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov esi, eax
test esi, esi
je 0x42a039
push esi
call dword [sym.imp.KERNEL32.dll_GlobalLock]
push ebx
lea ecx, [ebp - 0x20]
mov edi, eax
call fcn.00412465
push eax
push edi
call sub.MSVCRT.dll_memcpy
add esp, 0xc
push esi
call dword [sym.imp.KERNEL32.dll_GlobalUnlock]
push esi
push 0xd
call dword [sym.imp.USER32.dll_SetClipboardData]
call dword [sym.imp.USER32.dll_CloseClipboard]
pop ebx
and byte [ebp - 4], 0
lea ecx, [ebp - 0x20]
call fcn.00411cb9
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x34]
call fcn.00411cb9
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
leave
ret 4

Function at 0x42a3da
Capabilities:
Open clipboard
Read clipboard data

Disassembly:
mov eax, 0x46034c
call fcn.0045d320
sub esp, 0x14
push esi
push edi
mov edi, ecx
call dword [sym.imp.USER32.dll_GetClipboardOwner]
mov ecx, dword [edi + 0x6c]
cmp eax, ecx
je 0x42a49a
cmp byte [edi + 0x40], 0
jne 0x42a40b
mov byte [edi + 0x40], 1
jmp 0x42a49a
cmp dword [edi + 0x74], 0
je 0x42a49a
push ecx
call dword [sym.imp.USER32.dll_OpenClipboard]
test eax, eax
je 0x42a49a
push 0xd
call dword [sym.imp.USER32.dll_GetClipboardData]
mov esi, eax
test esi, esi
jne 0x42a436
call dword [sym.imp.USER32.dll_CloseClipboard]
jmp 0x42a49a
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_GlobalLock]
lea ecx, [ebp - 0x20]
mov ebx, eax
call fcn.00411c60
mov ecx, dword [0x47aaf0]
and dword [ebp - 4], 0
lea edx, [ebp - 0x20]
mov eax, dword [ecx]
push edx
push ebx
call dword [eax + 0x1c]
push esi
call dword [sym.imp.KERNEL32.dll_GlobalUnlock]
call dword [sym.imp.USER32.dll_CloseClipboard]
lea ecx, [ebp - 0x20]
call fcn.00412465
mov esi, eax
mov edx, eax
pop ebx
mov cl, byte [esi]
inc esi
cmp cl, 0xd
je 0x42a476
mov byte [edx], cl
inc edx
test cl, cl
jne 0x42a476
mov ecx, dword [edi + 0x64]
push eax
call fcn.00427e18
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x20]
call fcn.00411cb9
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
leave
ret
Function at 0x42d653
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
push esi
push edi
mov edi, str.C:projectsAmmyy_sources_target_trEncoder.cpp
push str.remote_palette_data_requested
push edi
mov ebx, 0x47a230
push 2
mov esi, ecx
push ebx
call fcn.0040e807
add esp, 0x10
cmp byte [esi + 0x12], 0
jne 0x42d68e
mov ecx, esi
call fcn.0042d7e9
test eax, eax
je 0x42d779
cmp byte [esi + 0x1e], 0
jne 0x42d779
cmp byte [esi + 0x12], 0
je 0x42d77d
push str.generating_BGR233_palette_data
push edi
push 2
push ebx
call fcn.0040e807
mov cl, byte [esi + 0x28]
mov eax, dword [esi + 0xc]
add esp, 0x10
lea edi, [esi + 0xc]
push 1
pop ebx
shl ebx, cl
test eax, eax
je 0x42d6cd
push eax
call dword [sym.imp.MSVCRT.dll_free]
pop ecx
mov eax, ebx
shl eax, 2
push eax
call dword [sym.imp.MSVCRT.dll_malloc]
test eax, eax
pop ecx
mov dword [edi], eax
je 0x42d75a
and dword [ebp - 4], 0
test ebx, ebx
jle 0x42d75a
inc eax
mov dword [ebp - 8], eax
mov eax, dword [ebp - 4]
mov cl, byte [esi + 0x33]
movzx edx, word [esi + 0x2f]
sar eax, cl
movzx ecx, word [esi + 0x2f]
and eax, edx
imul eax, eax, 0xff
cdq
idiv ecx
mov ecx, dword [ebp - 8]
mov byte [ecx - 1], al
mov eax, dword [ebp - 4]
mov cl, byte [esi + 0x31]
movzx edx, word [esi + 0x2b]
sar eax, cl
movzx ecx, word [esi + 0x2b]
and eax, edx
imul eax, eax, 0xff
cdq
idiv ecx
mov ecx, dword [ebp - 8]
mov byte [ecx + 1], al
mov eax, dword [ebp - 4]
mov cl, byte [esi + 0x32]
movzx edx, word [esi + 0x2d]
sar eax, cl
movzx ecx, word [esi + 0x2d]
and eax, edx
imul eax, eax, 0xff
cdq
idiv ecx
mov ecx, dword [ebp - 8]
inc dword [ebp - 4]
add dword [ebp - 8], 4
cmp dword [ebp - 4], ebx
mov byte [ecx], al
jl 0x42d6ec
mov ebx, 0x47a230
mov edi, dword [edi]
test edi, edi
jne 0x42d7cc
push str.failed_to_obtain_colour_map_data_
push str.C:projectsAmmyy_sources_target_trEncoder.cpp
push edi
push ebx
call fcn.0040e807
add esp, 0x10
xor eax, eax
jmp 0x42d7e2
push str.generating_8_bit_palette_data
push edi
push 2
push ebx
call fcn.0040e807
and byte [ebp - 9], 0
lea edi, [esi + 0xc]
lea eax, [ebp - 0x14]
add esi, 0x10
push eax
push esi
push edi
mov byte [ebp - 0x12], 1
mov byte [ebp - 0x14], 0x20
mov byte [ebp - 0x13], 0x18
mov word [ebp - 0xd], 0xff
mov word [ebp - 0xf], 0xff
mov word [ebp - 0x11], 0xff
mov byte [ebp - 0xb], 0x10
mov byte [ebp - 0xa], 8
call dword [0x471abc]
add esp, 0x1c
jmp 0x42d75f
mov eax, dword [ebp + 0xc]
shl eax, 2
push eax
push edi
push dword [ebp + 8]
call sub.MSVCRT.dll_memcpy
add esp, 0xc
push 1
pop eax
pop edi
pop esi
pop ebx
leave
ret 8
Function at 0x42e105
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 0x10]
push ebx
push esi
xor ebx, ebx
xor esi, esi
cmp eax, 8
je 0x42e14f
cmp eax, 0x10
jne 0x42e123
mov eax, dword [ebp + 8]
movzx eax, word [eax]
jmp 0x42e190
cmp eax, 0x20
jne 0x42e12f
mov eax, dword [ebp + 8]
mov eax, dword [eax]
jmp 0x42e190
push eax
mov eax, dword [sym.imp.MSVCRT.dll__iob]
add eax, 0x40
push str.getBgColour:_bpp__d__n
push eax
call dword [sym.imp.MSVCRT.dll_fprintf]
add esp, 0xc
push 1
call dword [sym.imp.MSVCRT.dll_exit]
push edi
mov ecx, 0x100
xor eax, eax
mov edi, 0x47a65c
rep stosd dword es:[edi], eax
xor edx, edx
cmp dword [ebp + 0xc], ebx
pop edi
jle 0x42e18d
mov eax, dword [ebp + 8]
mov cl, byte [edx + eax]
movzx eax, cl
inc dword [eax*4 + 0x47a65c]
lea eax, [eax*4 + 0x47a65c]
mov eax, dword [eax]
cmp eax, esi
jle 0x42e187
mov esi, eax
mov bl, cl
inc edx
cmp edx, dword [ebp + 0xc]
jl 0x42e166
movzx eax, bl
pop esi
pop ebx
pop ebp
ret

Function at 0x430fbf
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
movzx eax, word [ecx + 0x1f]
mov dword [ebp - 4], eax
push esi
movzx eax, word [ecx + 0x21]
movzx edx, byte [ecx + 0x25]
movzx esi, byte [ecx + 0x26]
mov dword [ebp - 8], eax
push edi
movzx eax, word [ecx + 0x23]
movzx edi, byte [ecx + 0x27]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp + 0x10]
mov ecx, eax
dec eax
test ecx, ecx
je 0x431062
movzx ecx, dx
mov dword [ebp - 0x10], ecx
inc eax
movzx ecx, si
mov esi, dword [ebp + 8]
mov dword [ebp - 0x14], ecx
movzx ecx, di
push ebx
mov ebx, dword [ebp + 0xc]
mov dword [ebp - 0x18], ecx
mov dword [ebp + 0x10], eax
mov ax, word [ebx]
mov ecx, dword [ebp - 0x10]
movzx edi, ax
mov eax, edi
inc ebx
shr eax, cl
mov ecx, dword [ebp - 0x14]
inc ebx
and eax, dword [ebp - 4]
imul eax, eax, 0xff
cdq
idiv dword [ebp - 4]
mov byte [esi], al
mov eax, edi
shr eax, cl
mov ecx, dword [ebp - 0x18]
inc esi
and eax, dword [ebp - 8]
imul eax, eax, 0xff
cdq
idiv dword [ebp - 8]
mov byte [esi], al
mov eax, edi
shr eax, cl
inc esi
and eax, dword [ebp - 0xc]
imul eax, eax, 0xff
cdq
idiv dword [ebp - 0xc]
mov byte [esi], al
inc esi
dec dword [ebp + 0x10]
jne 0x43100f
pop ebx
pop edi
pop esi
leave
ret 0xc