joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4a5081
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 8]
push edi
mov eax, dword [esi + 8]
mov edi, eax
mov edx, eax
and edi, 7
je 0x4a50af
cmp eax, edi
jge 0x4a50a3
push esi
call fcn.004a06f3
mov eax, dword [esi + 8]
pop ecx
mov ecx, edi
shr dword [esi + 0xc], cl
sub eax, edi
mov dword [esi + 8], eax
mov edx, eax
xor ecx, ecx
test eax, eax
jle 0x4a50d2
mov edi, dword [esi + 0xc]
mov al, byte [esi + 0xc]
sub edx, 8
mov byte [ebp + ecx + 8], al
inc ecx
shr edi, 8
mov dword [esi + 0xc], edi
test edx, edx
jg 0x4a50b8
mov dword [esi + 8], edx
jmp 0x4a50e7
mov eax, dword [esi]
cmp eax, dword [esi + 4]
jb 0x4a50dd
xor dl, dl
jmp 0x4a50e2
mov dl, byte [eax]
inc eax
mov dword [esi], eax
mov byte [ebp + ecx + 8], dl
inc ecx
cmp ecx, 4
jl 0x4a50d2
mov eax, dword [ebp + 8]
movzx ecx, byte [ebp + 0xb]
movzx edi, ah
movzx eax, al
shl edi, 8
add edi, eax
shl ecx, 8
movzx eax, byte [ebp + 0xa]
add ecx, eax
mov eax, edi
xor eax, 0xffff
cmp ecx, eax
je 0x4a511f
push str.zlib_corrupt
call fcn.004a0618
pop ecx
jmp 0x4a515f
mov eax, dword [esi]
add eax, edi
cmp eax, dword [esi + 4]
jbe 0x4a512f
push str.read_past_buffer
jmp 0x4a5117
mov ecx, dword [esi + 0x10]
lea eax, [ecx + edi]
cmp eax, dword [esi + 0x18]
jbe 0x4a5149
push edi
push ecx
push esi
call fcn.004a8352
add esp, 0xc
test eax, eax
je 0x4a515f
push edi
push dword [esi]
push dword [esi + 0x10]
call fcn.004c5e60
add dword [esi], edi
xor eax, eax
add dword [esi + 0x10], edi
add esp, 0xc
inc eax
pop edi
pop esi
pop ebp
ret

Function at 0x4a866e
Capabilities:
Check if file exists
Create directory
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x414
mov eax, dword [0x56b114]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 0xc]
push edi
mov edi, dword [ebp + 8]
test edi, edi
je 0x4a86a2
push edi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x4a86a2
push 0
push edi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
movzx eax, word [ebx]
test ax, ax
je 0x4a8758
push esi
mov esi, ebx
mov ecx, ebx
mov edx, eax
cmp dx, 0x2f
je 0x4a86c1
cmp dx, 0x5c
jne 0x4a86c3
mov esi, ecx
add ecx, 2
movzx eax, word [ecx]
mov edx, eax
test ax, ax
jne 0x4a86b5
cmp esi, ebx
je 0x4a870b
sub esi, ebx
lea eax, [ebp - 0x414]
and esi, 0xfffffffe
push esi
push ebx
push eax
call fcn.004c5e60
add esp, 0xc
cmp esi, 0x208
jae 0x4a8766
xor eax, eax
mov word [ebp + esi - 0x414], ax
lea eax, [ebp - 0x414]
push eax
push edi
call fcn.004a866e
pop ecx
pop ecx
xor eax, eax
mov word [ebp - 0x20c], ax
pop esi
test edi, edi
je 0x4a8728
lea eax, [ebp - 0x20c]
push edi
push eax
call fcn.004ce600
pop ecx
pop ecx
lea eax, [ebp - 0x20c]
push ebx
push eax
call fcn.004ce5cf
pop ecx
pop ecx
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x4a8758
push 0
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop ebx
call fcn.004c360c
leave
ret
call fcn.004c3e58
int3
Function at 0x4a8dd3
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
mov esi, ecx
cmp dword [esi], 0
jne 0x4a8e7f
cmp dword [esi + 4], 0xffffffff
jne 0x4a8e7f
push edi
lea edi, [esi + 0x244]
push edi
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
push edi
call fcn.004ce744
pop ecx
movzx eax, word [esi + eax*2 + 0x242]
cmp eax, 0x5c
je 0x4a8e26
cmp eax, 0x2f
je 0x4a8e26
push 0x51db98
push edi
call fcn.004ce5cf
pop ecx
pop ecx
cmp dword [ebp + 0x10], 1
pop edi
jne 0x4a8e48
push 1
push 0
push 0
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp eax, 0xffffffff
jne 0x4a8e48
mov eax, 0x2000000
jmp 0x4a8e84
lea eax, [ebp - 4]
push eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.004ab57c
add esp, 0x10
test eax, eax
jne 0x4a8e66
mov eax, dword [ebp - 4]
jmp 0x4a8e84
push eax
call fcn.004abc59
pop ecx
xor ecx, ecx
mov dword [esi], eax
test eax, eax
mov edx, 0x200
cmove ecx, edx
mov eax, ecx
jmp 0x4a8e84
mov eax, 0x1000000
pop esi
leave
ret 0xc
Function at 0x4a934d
Capabilities:
Generate random numbers using the delphi lcg
Hash data with crc32

Disassembly:
push ebp
mov ebp, esp
mov edx, dword [ebp + 8]
movsx eax, byte [ebp + 0xc]
mov ecx, dword [edx]
xor eax, ecx
movzx eax, al
shr ecx, 8
mov eax, dword [eax*4 + 0x507158]
xor eax, ecx
mov ecx, dword [edx + 8]
mov dword [edx], eax
movzx eax, al
add eax, dword [edx + 4]
imul eax, eax, 0x8088405
inc eax
mov dword [edx + 4], eax
shr eax, 0x18
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x507158]
mov dword [edx + 8], ecx
pop ebp
ret

Function at 0x4ab679
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
mov ecx, dword [ebp + 0xc]
imul ecx, dword [ebp + 0x10]
push edi
mov edi, dword [ebp + 0x14]
cmp byte [edi], 0
je 0x4ab6ac
push 0
lea eax, [ebp + 0x10]
push eax
push ecx
push dword [ebp + 8]
push dword [edi + 4]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x4ab6a7
mov byte [edi + 8], 1
mov eax, dword [ebp + 0x10]
jmp 0x4ab6d6
mov edx, dword [edi + 0x1c]
push esi
mov esi, dword [edi + 0x18]
sub esi, edx
lea eax, [edx + ecx]
cmp eax, dword [edi + 0x18]
cmovbe esi, ecx
mov ecx, dword [edi + 0x14]
push esi
add ecx, edx
push ecx
push dword [ebp + 8]
call fcn.004c5e60
add esp, 0xc
mov eax, esi
add dword [edi + 0x1c], esi
pop esi
xor edx, edx
div dword [ebp + 0xc]
pop edi
pop ebp
ret

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

Disassembly:
push ebp
mov ebp, esp
mov edx, dword [ebp + 0xc]
test edx, edx
jne 0x4ab814
xor eax, eax
pop ebp
ret
mov ecx, dword [ebp + 8]
push esi
mov esi, dword [ebp + 0x10]
not ecx
cmp esi, 8
jb 0x4ab8d3
push edi
mov edi, esi
shr edi, 3
movzx eax, byte [edx]
sub esi, 8
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x507158]
movzx eax, byte [edx + 1]
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x507158]
movzx eax, byte [edx + 2]
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x507158]
movzx eax, byte [edx + 3]
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x507158]
movzx eax, byte [edx + 4]
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x507158]
movzx eax, byte [edx + 5]
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x507158]
movzx eax, byte [edx + 6]
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x507158]
movzx eax, byte [edx + 7]
add edx, 8
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x507158]
sub edi, 1
jne 0x4ab82c
pop edi
test esi, esi
je 0x4ab8ef
movzx eax, byte [edx]
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x507158]
inc edx
sub esi, 1
jne 0x4ab8d7
not ecx
mov eax, ecx
pop esi
pop ebp
ret

Function at 0x4e2503
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.004e2379
Function at 0x10001020
Capabilities:
Encode data using add xor sub operations
Encode data using xor
Hash data with crc32

Disassembly:
push ebp
mov ebp, esp
push esi
push ecx
push edx
mov esi, dword [ebp + 0xc]
xor edx, edx
or eax, 0xffffffff
mov ecx, dword [ebp + 8]
lea esp, [esp]
lea esp, [esp]
nop
mov dl, byte [esi]
xor dl, al
shr eax, 8
xor eax, dword [edx*4 + 0x10001060]
add esi, 1
sub ecx, 1
jne 0x10001040
not eax
pop edx
pop ecx
pop esi
leave
ret 8

Function at 0x1000149b
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffffc
pushal
mov dword [ebp - 4], 0
push 0xa
push dword [ebp + 0xc]
push dword [ebp + 8]
call sub.kernel32.dll_FindResourceA
or eax, eax
jne 0x100014bc
jmp 0x100014de
push eax
push eax
push dword [ebp + 8]
call sub.kernel32.dll_SizeofResource
mov dword [0x1000d880], eax
pop eax
push eax
push dword [ebp + 8]
call sub.kernel32.dll_LoadResource
or eax, eax
jne 0x100014db
jmp 0x100014de
mov dword [ebp - 4], eax
popal
mov eax, dword [ebp - 4]
leave
ret 8

Function at 0x10001545
Capabilities:
Set environment variable

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffbfc
mov byte [ebp - 0x401], 0
pushal
mov esi, dword [ebp + 0xc]
lea ebx, [ebp - 0x400]
push esi
push ebx
call sub.kernel32.dll_lstrcpyA
xor ecx, ecx
jmp 0x1000156b
inc ecx
cmp byte [ecx + ebx], 0x5c
jne 0x1000156a
mov byte [ecx + ebx], 0
lea esi, [ecx + esi + 1]
push ebx
call fcn.10001657
or eax, eax
je 0x100015d2
mov byte [ebx], 0
test dword [ebp + 0x14], 8
je 0x10001596
mov edx, 1
jmp 0x10001598
xor edx, edx
push edx
push dword [ebp + 0x10]
push esi
push eax
push ebx
call sym.dup2patcher.dll_GetRegString
push section..data
push ebx
call fcn.10001607
test dword [ebp + 0x14], 1
je 0x100015be
push ebx
call fcn.100015de
cmp byte [ebx], 0
je 0x100015d2
push ebx
push dword [ebp + 8]
call sub.kernel32.dll_SetEnvironmentVariableA
mov byte [ebp - 0x401], al
popal
movzx eax, byte [ebp - 0x401]
leave
ret 0x10
Function at 0x100016e0
Capabilities:
Hide graphical window

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffff98
push ebx
push esi
push edi
mov ebx, dword [ebp + 8]
push dword [ebp + 0x10]
push ebx
call sub.user32.dll_LoadBitmapA
test eax, eax
je 0x1000189f
mov dword [ebp - 8], eax
push dword [ebp + 0x14]
push ebx
call sub.user32.dll_LoadBitmapA
or eax, eax
jne 0x10001710
mov eax, dword [ebp - 8]
mov dword [ebp - 0xc], eax
push dword [ebp + 0x18]
push ebx
call sub.user32.dll_LoadBitmapA
or eax, eax
jne 0x10001723
mov eax, dword [ebp - 8]
mov dword [ebp - 0x10], eax
push dword [ebp + 0x1c]
push dword [ebp + 0xc]
call sub.user32.dll_GetDlgItem
test eax, eax
je 0x1000189f
mov esi, eax
push ebx
lea ebx, [ebp - 0x38]
push ebx
push esi
call sub.user32.dll_GetWindowRect
lea edi, [ebp - 0x28]
push edi
push dword [ebp + 0xc]
call sub.user32.dll_GetWindowRect
mov eax, dword [ebx]
sub eax, dword [edi]
mov dword [ebp - 0x14], eax
mov eax, dword [ebx + 4]
sub eax, dword [edi + 4]
mov dword [ebp - 0x18], eax
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x14]
push eax
push dword [ebp + 0xc]
call fcn.100018b0
pop ebx
push 0
push esi
call sub.user32.dll_ShowWindow
jmp 0x1000178e
lea esi, [ebp - 0x68]
mov dword [esi], 0x30
mov dword [esi + 4], 0x2000
mov dword [esi + 8], 0x10001980
mov dword [esi + 0xc], 0
mov dword [esi + 0x10], 0x14
mov dword [esi + 0x14], ebx
mov dword [esi + 0x20], 0x10
mov dword [esi + 0x24], 0
mov dword [esi + 0x28], 0x1000177d
mov dword [esi + 0x18], 0
push 0x7f00
push 0
call sub.user32.dll_LoadCursorA
mov dword [esi + 0x1c], eax
mov dword [esi + 0x2c], 0
push esi
call sub.user32.dll_RegisterClassExA
push 0
push ebx
push dword [ebp + 0x1c]
push dword [ebp + 0xc]
push 0
push 0
push dword [ebp - 0x18]
push dword [ebp - 0x14]
push 0x50000000
push 0
push 0x1000177d
push 0x20
call sub.user32.dll_CreateWindowExA
mov ebx, eax
push dword [ebp - 8]
push 0
push ebx
call sub.user32.dll_SetWindowLongA
push dword [ebp - 0xc]
push 4
push ebx
call sub.user32.dll_SetWindowLongA
push dword [ebp - 0x10]
push 8
push ebx
call sub.user32.dll_SetWindowLongA
push 0
push dword [ebp + 8]
push dword [ebp + 0x1c]
push ebx
push 0
push 0
push 0
push 0
push 0x5000000e
push 0
push str.STATIC
push 0
call sub.user32.dll_CreateWindowExA
mov dword [ebp - 4], eax
push dword [ebp - 8]
push 0
push 0x172
push eax
call sub.user32.dll_SendMessageA
push edi
push dword [ebp - 4]
call sub.user32.dll_GetWindowRect
push dword [ebp - 4]
push 0xc
push ebx
call sub.user32.dll_SetWindowLongA
mov ecx, dword [edi + 0xc]
sub ecx, dword [edi + 4]
mov eax, dword [edi + 8]
sub eax, dword [edi]
push 2
push ecx
push eax
push 0
push 0
push 0
push ebx
call sub.user32.dll_SetWindowPos
mov eax, ebx
pop edi
pop esi
pop ebx
leave
ret 0x18

Function at 0x10001b8b
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffffc
lea eax, [ebp - 4]
push eax
push 0
push dword [ebp + 8]
push 0x10001bcc
push 0
push 0
call sub.kernel32.dll_CreateThread
push eax
call sub.kernel32.dll_CloseHandle
leave
ret 4
Function at 0x10001fe3
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffc00
push esi
push edi
push ebx
push ecx
push edx
lea eax, [ebp - 0x400]
push eax
push 0x400
call sub.kernel32.dll_GetTempPathA
push 0x1000d0ef
lea eax, [ebp - 0x400]
push eax
call sub.kernel32.dll_lstrcatA
xor edi, edi
lea eax, [ebp - 0x400]
push eax
call sub.kernel32.dll_LoadLibraryA
or eax, eax
je 0x100020b2
mov dword [0x1000d89e], eax
mov esi, str.BASSMOD_Init
mov ebx, 0x1000d88a
jmp 0x10002071
push esi
push dword [0x1000d89e]
call sub.kernel32.dll_GetProcAddress
or eax, eax
je 0x1000205a
mov dword [ebx], eax
add ebx, 4
jmp 0x10002052
inc esi
cmp byte [esi], 0
jne 0x10002051
inc esi
jmp 0x10002071
push dword [0x1000d89e]
call sub.kernel32.dll_FreeLibrary
mov dword [0x1000d89e], 0
jmp 0x100020b2
cmp byte [esi], 0
jne 0x1000203a
push 0
push 0xac44
push 0xffffffffffffffff
call dword [0x1000d88a]
cmp eax, 1
jne 0x100020b2
call dword [0x1000d88e]
mov eax, dword [ebp + 8]
mov ecx, dword [eax]
add eax, 4
push 6
push ecx
push 0
push eax
push 1
call dword [0x1000d892]
cmp eax, 1
jne 0x100020b2
call dword [0x1000d896]
inc edi
mov eax, edi
pop edx
pop ecx
pop ebx
pop edi
pop esi
leave
ret 4

Function at 0x10002244
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffffc
pushal
lea eax, [ebp - 4]
push eax
push 0
push 0
push dword [ebp + 8]
push 0
push 0
call sub.kernel32.dll_CreateThread
push eax
call sub.kernel32.dll_CloseHandle
popal
leave
ret 4

Function at 0x10002313
Capabilities:
Check if file exists
Copy file
Get file attributes

Disassembly:
push ebp
mov ebp, esp
pushal
push 0x6b
push dword [0x1000d8a6]
call sub.user32.dll_IsDlgButtonChecked
cmp eax, 1
jne 0x10002363
mov esi, 0x1000dd11
push dword [ebp + 8]
push esi
call sub.kernel32.dll_lstrcpyA
push str..BAK
push esi
call sub.kernel32.dll_lstrcatA
push esi
call sub.kernel32.dll_GetFileAttributesA
cmp eax, 0xffffffff
jne 0x1000235c
push 0
push esi
push dword [ebp + 8]
call sub.kernel32.dll_CopyFileA
mov al, 0
jmp 0x1000235e
mov al, 1
mov byte [0x1000e52d], al
popal
leave
ret 4

Function at 0x10002368
Capabilities:
Copy file
Delete file
Set file attributes

Disassembly:
push ebp
mov ebp, esp
pushal
push 0x6b
push dword [0x1000d8a6]
call sub.user32.dll_IsDlgButtonChecked
cmp eax, 1
jne 0x1000240c
mov esi, 0x1000dd11
cmp dword [ebp + 8], 0
jne 0x100023b4
cmp byte [0x1000e52d], 0
jne 0x100023a3
push 0
push 0x1000d911
push esi
call sub.kernel32.dll_CopyFileA
cmp byte [0x1000e52d], 0
jne 0x1000240c
push esi
call sub.kernel32.dll_DeleteFileA
jmp 0x1000240c
mov eax, 1
cmp byte [0x1000e95c], 1
jne 0x100023d0
cmp byte [0x1000e95d], 0
jne 0x100023d0
mov eax, 0
cmp eax, 1
jne 0x1000240a
push 0x400
push 0x10012e3d
push 0xd
push dword [0x1000d8a2]
call sub.user32.dll_LoadStringA
push 0x10012e3d
call sym.dup2patcher.dll_AddMsg
push esi
call sym.dup2patcher.dll_AddMsg
push dword [0x1000e511]
push esi
call sub.kernel32.dll_SetFileAttributesA
jmp 0x1000240c
jmp 0x100023a3
popal
leave
ret 4
Function at 0x10002411
Capabilities:
Copy file
Delete file
Move file

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffc00
push esi
lea esi, [ebp - 0x400]
push dword [ebp + 8]
push esi
call sub.kernel32.dll_lstrcpyA
push str..tmp
push esi
call sub.kernel32.dll_lstrcatA
push esi
call sub.kernel32.dll_DeleteFileA
push esi
push dword [ebp + 8]
call sub.kernel32.dll_MoveFileA
cmp eax, 1
jne 0x1000245e
push 1
push dword [ebp + 8]
push esi
call sub.kernel32.dll_CopyFileA
cmp eax, 1
jne 0x1000245e
mov eax, 1
pop esi
leave
ret 4
Function at 0x100028d8
Capabilities:
Set file attributes

Disassembly:
push ebp
mov ebp, esp
pushal
mov esi, dword [0x1000e515]
or esi, esi
je 0x100029bd
test dword [ebp + 0xc], 0x20
je 0x10002912
call fcn.100029ef
or eax, eax
je 0x10002908
push str.PE_CheckSum_Fix_:_OK
call sym.dup2patcher.dll_AddMsg
jmp 0x10002912
push str.PE_CheckSum_Fix_:_Failed
call sym.dup2patcher.dll_AddMsg
push dword [0x1000e521]
call sub.kernel32.dll_UnmapViewOfFile
push dword [0x1000e525]
call sub.kernel32.dll_CloseHandle
push 0
push 0x1000e51d
push dword [0x1000e529]
push esi
call sub.kernel32.dll_SetFilePointer
push esi
call sub.kernel32.dll_SetEndOfFile
push esi
call sub.kernel32.dll_CloseHandle
push dword [ebp + 8]
call fcn.10002368
push dword [0x1000e511]
push 0x1000d911
call sub.kernel32.dll_SetFileAttributesA
test dword [ebp + 0xc], 0x10
je 0x100029bd
push 0
push 0x82
push 3
push 0
push 0
push 0xc0000000
push 0x1000d911
call sub.kernel32.dll_CreateFileA
mov dword [0x1000e515], eax
cmp eax, 0xffffffff
je 0x100029bd
push 0x1000f191
push 0x1000f189
push 0x1000f181
push dword [0x1000e515]
call sub.kernel32.dll_SetFileTime
push dword [0x1000e515]
call sub.kernel32.dll_CloseHandle
push str.Restore_original_file_time_:_OK
call sym.dup2patcher.dll_AddMsg
popal
leave
ret 8

Function at 0x10002a7d
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffffc
pushal
mov byte [ebp - 1], 0
push 1
push 8
push dword [0x1000d8a2]
call fcn.10001460
or eax, eax
je 0x10002ad1
mov esi, eax
push 0x1000e111
push 0x400
call sub.kernel32.dll_GetTempPathA
push str._bassmod.dll
push 0x1000e111
call sub.kernel32.dll_lstrcatA
mov ecx, dword [esi + 1]
lea eax, [esi + 5]
push ecx
push eax
push 0x1000e111
call sym.dup2patcher.dll_write_disk_file
mov byte [ebp - 1], 1
popal
movzx eax, byte [ebp - 1]
leave
ret
Function at 0x100038cc
Capabilities:
Get common file path
Hide graphical window

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffba0
push esi
push edi
push ebx
push 0x70
push dword [0x1000d8a6]
call sub.user32.dll_GetDlgItem
or eax, eax
je 0x10003a8a
mov dword [ebp - 0x404], eax
push 0
push dword [ebp - 0x404]
call sub.user32.dll_ShowWindow
mov esi, 0x1000f15f
push 9
push dword [0x1000d8aa]
call fcn.10002a53
mov dword [esi + 4], eax
push eax
call fcn.10006c90
or eax, eax
je 0x10003a8a
push dword [0x1000d8a6]
pop dword [esi]
lea ebx, [ebp - 0x414]
push ebx
push dword [ebp - 0x404]
call sub.user32.dll_GetWindowRect
lea edi, [ebp - 0x424]
push edi
push dword [0x1000d8a6]
call sub.user32.dll_GetWindowRect
mov eax, dword [ebx]
sub eax, dword [edi]
mov dword [esi + 8], eax
mov eax, dword [ebx + 8]
sub eax, dword [ebx]
mov dword [esi + 0x10], eax
mov eax, dword [ebx + 4]
sub eax, dword [edi + 4]
mov dword [esi + 0xc], eax
lea eax, [esi + 8]
lea ecx, [esi + 0xc]
push ecx
push eax
push dword [0x1000d8a6]
call fcn.100018b0
push 1
push 0x12
push dword [0x1000d8a2]
call fcn.10001460
or eax, eax
je 0x10003990
mov eax, dword [eax + 1]
mov dword [esi + 0x1d], eax
push 1
push 0xb
push dword [0x1000d8a2]
call fcn.10001460
or eax, eax
je 0x100039ab
mov eax, dword [eax + 1]
jmp 0x100039bd
cmp dword [esi + 0x1d], 0
je 0x100039b8
mov eax, 0xfe
jmp 0x100039bd
mov eax, 0xff
mov byte [esi + 0x1c], al
lea ebx, [ebp - 0x460]
push 0x3c
push ebx
call sub.kernel32.dll_RtlZeroMemory
mov dword [ebx], 7
mov byte [ebx + 0x17], 1
mov byte [ebx + 0x1a], 4
push str.MS_SANS_SERIF
lea eax, [ebx + 0x1c]
push eax
call sub.kernel32.dll_lstrcpyA
push 1
push 0x13
push dword [0x1000d8a2]
call fcn.10001460
or eax, eax
je 0x10003a7b
mov edi, eax
push dword [edi + 0x11]
pop dword [esi + 0x18]
push dword [edi + 5]
pop dword [ebx]
test dword [edi + 9], 1
je 0x10003a1a
mov dword [ebx + 0x10], 0x2bc
lea eax, [ebp - 0x400]
push eax
push 0x400
call sub.kernel32.dll_GetTempPathA
lea edx, [edi + 0x15]
push edx
lea eax, [ebp - 0x400]
push eax
call sub.kernel32.dll_lstrcatA
lea edx, [edi + 0x95]
push edx
lea eax, [ebp - 0x400]
push eax
call sub.kernel32.dll_lstrcatA
lea edx, [edi + 0x9b]
mov ecx, dword [edi + 0xd]
lea eax, [ebp - 0x400]
push eax
push ecx
push edx
call fcn.10003a8f
lea edx, [edi + 0x15]
cmp byte [edx], 0
jne 0x10003a71
xor ebx, ebx
jmp 0x10003a7b
push edx
lea eax, [ebx + 0x1c]
push eax
call sub.kernel32.dll_lstrcpyA
push ebx
call sub.gdi32.dll_CreateFontIndirectA
mov dword [esi + 0x14], eax
push esi
call fcn.10001b8b
pop ebx
pop edi
pop esi
leave
ret
Function at 0x10004616
Capabilities:
Get file size
Get system information on windows

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffa4
push esi
push edi
push ebx
mov dword [ebp - 4], 0
lea eax, [ebp - 0x2c]
push eax
call sub.kernel32.dll_GetSystemInfo
mov ecx, dword [ebp - 0x10]
mov dword [ebp - 0x54], ecx
add ecx, ecx
mov dword [ebp - 0x58], ecx
add ecx, dword [ebp - 0x10]
mov dword [ebp - 0x5c], ecx
mov esi, dword [ebp + 8]
push 0
push 0x82
push 3
push 0
push 2
push 0xc0000000
push 0x1000d911
call sub.kernel32.dll_CreateFileA
cmp eax, 0xffffffff
je 0x10004787
mov dword [ebp - 0x30], eax
lea eax, [ebp - 0x40]
push eax
push dword [ebp - 0x30]
call sub.kernel32.dll_GetFileSize
mov dword [ebp - 0x3c], eax
push 0
push 0
push 0
push 4
push 0
push dword [ebp - 0x30]
call sub.kernel32.dll_CreateFileMappingA
or eax, eax
je 0x1000477d
mov dword [ebp - 0x34], eax
push str.trying_large_file_patchmode
call sym.dup2patcher.dll_AddMsg
mov dword [ebp - 0x44], 0
mov dword [ebp - 0x48], 0
mov eax, dword [esi + 0x16]
lea esi, [eax + esi]
push dword [ebp - 0x5c]
pop dword [ebp - 0x4c]
mov dword [ebp - 8], 0
push dword [ebp - 0x4c]
push dword [ebp - 0x44]
push dword [ebp - 0x48]
push 2
push dword [ebp - 0x34]
call sub.kernel32.dll_MapViewOfFile
or eax, eax
je 0x10004737
mov dword [ebp - 0x38], eax
mov ecx, dword [esi]
mov edx, dword [esi + 4]
cmp edx, 0xffffffff
je 0x100046e9
sub edx, dword [ebp - 8]
push edx
cmp dword [ebp - 0x4c], 0
je 0x100046fa
mov edx, dword [ebp - 0x58]
add edx, ecx
sub edx, 1
jmp 0x10004700
mov edx, dword [ebp - 0x3c]
sub edx, dword [ebp - 0x44]
push edx
push ecx
lea eax, [esi + ecx*2 + 8]
add eax, ecx
push eax
lea eax, [esi + ecx*2 + 8]
push eax
lea eax, [ecx + esi + 8]
push eax
lea eax, [esi + 8]
push eax
push dword [ebp - 0x38]
call sym.dup2patcher.dll_SearchAndReplace
add dword [ebp - 8], eax
or dword [ebp - 4], eax
push dword [ebp - 0x38]
call sub.kernel32.dll_UnmapViewOfFile
cmp dword [ebp - 0x4c], 0
jne 0x10004739
jmp 0x10004766
jmp 0x10004775
mov eax, dword [ebp - 0x58]
mov edx, 0
add dword [ebp - 0x44], eax
adc dword [ebp - 0x48], edx
mov ecx, dword [ebp - 0x40]
cmp dword [ebp - 0x48], ecx
jne 0x10004761
mov ecx, dword [ebp - 0x44]
add ecx, dword [ebp - 0x4c]
cmp ecx, dword [ebp - 0x3c]
jb 0x10004761
mov dword [ebp - 0x4c], 0
jmp 0x100046c2
mov ecx, dword [esi]
lea esi, [esi + ecx*4 + 8]
cmp dword [esi], 0
jne 0x100046a1
push dword [ebp - 0x34]
call sub.kernel32.dll_CloseHandle
push dword [ebp - 0x30]
call sub.kernel32.dll_CloseHandle
jmp 0x10004787
mov eax, dword [ebp - 4]
pop ebx
pop edi
pop esi
leave
ret 4