joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4efcd0
Capabilities:
Get socket status

Disassembly:
sub esp, 0x118
mov eax, dword [0x8a3940]
xor eax, esp
mov dword [esp + 0x114], eax
push ebx
mov ebx, dword [esp + 0x124]
push ebp
mov ebp, dword [esp + 0x12c]
push esi
push edi
push ebp
push ebx
call fcn.0057b720
mov edi, dword [esp + 0x134]
add esp, 8
mov dword [esp + 0x18], eax
mov dword [esp + 0x1c], edx
lea esi, [edi + 1]
test ebp, ebp
jg 0x4efd2e
jl 0x4efd1c
test ebx, ebx
jae 0x4efd2e
mov dword [esp + 0x10], 1
mov dword [esp + 0x14], 0
jmp 0x4efd54
push 0
push 0x3e8
push ebp
push ebx
call fcn.0059c060
mov dword [esp + 0x10], eax
mov ecx, ebx
imul eax, eax, 0x3e8
sub ecx, eax
imul eax, ecx, 0x3e8
mov dword [esp + 0x14], eax
lea eax, [esp + 0x10]
mov dword [esp + 0x24], edi
push eax
push 0
lea eax, [esp + 0x28]
mov dword [esp + 0x28], 1
push eax
push 0
push esi
call dword [sym.imp.WSOCK32.dll_select]
mov esi, eax
test esi, esi
js 0x4efda5
push 0
call fcn.004eff60
add esp, 4
test esi, esi
je 0x4efdca
js 0x4efdf5
test esi, esi
jle 0x4efdf1
lea eax, [esp + 0x20]
push eax
push edi
call sub.WSOCK32.dll___WSAFDIsSet
test eax, eax
je 0x4efdf1
mov eax, 1
jmp 0x4efdf8
call dword [sym.imp.WSOCK32.dll_WSAGetLastError]
mov edi, eax
push edi
call fcn.004eff60
add esp, 4
cmp esi, 0xffffffff
jne 0x4efdf5
cmp edi, 0x2714
jne 0x4efdf5
mov edi, dword [esp + 0x12c]
lea eax, [esp + 0x18]
push eax
push ebp
push ebx
call fcn.0057b770
mov ebx, eax
mov ebp, edx
mov ecx, ebx
add esp, 0xc
or ecx, ebp
je 0x4efdf1
call fcn.004a5c50
test ax, ax
je 0x4efd0f
xor eax, eax
jmp 0x4efdf8
or eax, 0xffffffff
mov ecx, dword [esp + 0x124]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.0059bb21
add esp, 0x118
ret

Function at 0x4efe50
Capabilities:
Send data
Send data on socket

Disassembly:
push ebp
push esi
call fcn.0047d480
mov eax, dword [esp + 0x20]
mov ebp, dword [esp + 0xc]
test eax, eax
jl 0x4efea0
mov ecx, dword [esp + 0x1c]
jg 0x4efe6d
test ecx, ecx
jb 0x4efea0
push eax
push ecx
push ebp
call fcn.004efcd0
mov esi, eax
add esp, 0xc
test esi, esi
jne 0x4efe9a
call fcn.00498b60
mov dword [eax + 0x10], esi
or esi, 0xffffffff
mov dword [eax + 0xc], 2
call fcn.0047d480
mov eax, esi
pop esi
pop ebp
ret
js 0x4eff27
push ebx
mov ebx, dword [esp + 0x1c]
push edi
xor edi, edi
test ebx, ebx
je 0x4efed1
mov ecx, ebx
mov eax, ebx
and ecx, 1
mov edx, ecx
or edx, 2
and al, 2
mov eax, ebx
cmove edx, ecx
mov edi, edx
or edi, 4
and al, 4
cmove edi, edx
test bl, 8
je 0x4efed1
or edi, 8
push edi
push dword [esp + 0x20]
push dword [esp + 0x20]
push ebp
call dword [sym.imp.WSOCK32.dll_send]
mov esi, eax
test esi, esi
jg 0x4eff1b
call dword [sym.imp.WSOCK32.dll_WSAGetLastError]
mov ebx, eax
push ebx
call fcn.004eff60
add esp, 4
cmp esi, 0xffffffff
jne 0x4eff25
cmp ebx, 0x2714
jne 0x4eff25
call fcn.004a5c50
test ax, ax
je 0x4efed1
pop edi
pop ebx
call fcn.0047d480
mov eax, esi
pop esi
pop ebp
ret
push 0
call fcn.004eff60
add esp, 4
pop edi
pop ebx
call fcn.0047d480
mov eax, esi
pop esi
pop ebp
ret
Function at 0x4fd500
Capabilities:
Get common file path

Disassembly:
sub esp, 0x430
mov eax, dword [0x8a3940]
xor eax, esp
mov dword [esp + 0x42c], eax
mov eax, dword [esp + 0x440]
push ebx
mov ebx, dword [esp + 0x43c]
push ebp
mov ebp, dword [esp + 0x43c]
push esi
push edi
mov dword [esp + 0x18], ebx
mov dword [esp + 0x10], eax
mov dword [esp + 0x14], 0x3e6
nop dword [eax]
mov byte [eax], 0
call fcn.0047d480
xor esi, esi
xor edi, edi
test ebx, ebx
je 0x4fd55b
push ebx
call fcn.004e00f0
add esp, 4
mov esi, eax
test ebp, ebp
je 0x4fd574
cmp byte [ebp], 0
je 0x4fd574
push ebp
call fcn.004e00f0
mov edi, eax
add esp, 4
mov ecx, edi
jmp 0x4fd59a
lea eax, [esp + 0x1c]
push eax
push 0x108
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
test eax, eax
je 0x4fd634
xor eax, eax
lea ecx, [esp + 0x1c]
mov word [esp + 0x22a], ax
lea eax, [esp + 0x22c]
test esi, esi
push eax
push 0
mov eax, 0x76d810
cmovne eax, esi
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_GetTempFileNameW]
mov ebx, eax
test ebx, ebx
je 0x4fd5d5
push 0x107
push dword [esp + 0x14]
lea eax, [esp + 0x234]
push eax
call fcn.00493bf0
add esp, 0xc
test esi, esi
je 0x4fd5e2
push esi
call fcn.004a6790
add esp, 4
test edi, edi
je 0x4fd5ef
push edi
call fcn.004a6790
add esp, 4
push 0
push ebx
call fcn.004edd70
add esp, 8
call fcn.0047d480
test ebx, ebx
je 0x4fd640
push 0x210
push dword [esp + 0x450]
push dword [esp + 0x18]
call fcn.004df060
add esp, 0xc
cmp eax, 0xffffffff
jne 0x4fd643
sub dword [esp + 0x14], 1
je 0x4fd640
mov eax, dword [esp + 0x10]
mov ebx, dword [esp + 0x18]
jmp 0x4fd540
push 0
push 0
call fcn.004edd70
add esp, 8
or eax, 0xffffffff
mov ecx, dword [esp + 0x43c]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.0059bb21
add esp, 0x430
ret

Function at 0x4fd7c0
Capabilities:
Get common file path

Disassembly:
sub esp, 0x214
mov eax, dword [0x8a3940]
xor eax, esp
mov dword [esp + 0x210], eax
push esi
mov esi, dword [esp + 0x21c]
lea eax, [esp + 4]
push edi
push eax
push 0x108
or edi, 0xffffffff
mov byte [esi], 0
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
test eax, eax
je 0x4fd857
xor eax, eax
xor edi, edi
push 0x107
mov word [esp + 0x21a], ax
lea eax, [esp + 0xc]
push esi
push eax
call fcn.00493bf0
add esp, 0xc
cmp byte [esi], 0
je 0x4fd857
mov ecx, esi
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x4fd820
sub ecx, edx
cmp byte [esi + ecx - 1], 0x5c
je 0x4fd860
mov eax, edi
cmp ecx, 0x107
jge 0x4fd862
pop edi
mov word [esi + ecx], 0x5c
pop esi
mov ecx, dword [esp + 0x210]
xor ecx, esp
call fcn.0059bb21
add esp, 0x214
ret
mov word [esi], 0x5c2e
mov byte [esi + 2], 0
mov eax, edi
mov ecx, dword [esp + 0x218]
pop edi
pop esi
xor ecx, esp
call fcn.0059bb21
add esp, 0x214
ret
Function at 0x4fdfe0
Capabilities:
Check if file exists
Get file attributes

Disassembly:
sub esp, 0x214
mov eax, dword [0x8a3940]
xor eax, esp
mov dword [esp + 0x210], eax
push esi
mov esi, dword [esp + 0x21c]
push edi
xor edi, edi
test esi, esi
je 0x4fe115
call fcn.0047d480
cmp dword [0x8a89a0], edi
jne 0x4fe053
push str.kernel32.dll
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
je 0x4fe036
push str.GetFinalPathNameByHandleW
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [0x8a89a0], eax
jmp 0x4fe03b
mov eax, dword [0x8a89a0]
test eax, eax
jne 0x4fe053
push 1
call fcn.004edd50
add esp, 4
call fcn.0047d480
jmp 0x4fe11f
push esi
call fcn.004e00f0
add esp, 4
mov esi, eax
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x4fe075
test al, 0x10
je 0x4fe075
mov ecx, 1
jmp 0x4fe077
xor ecx, ecx
push 0
test ecx, ecx
mov edx, 0x2000010
mov eax, 0x80
cmovne eax, edx
push eax
push 3
push 0
push 1
push SysReAllocStringLen
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
push 0
cmp eax, 0xffffffff
jne 0x4fe0ae
push 0
call fcn.004edd70
add esp, 8
jmp 0x4fe101
push 0x108
lea ecx, [esp + 0x10]
push ecx
push eax
call dword [0x8a89a0]
cmp eax, 0x108
jae 0x4fe0f7
test eax, eax
je 0x4fe0e9
add eax, eax
cmp eax, 0x210
jae 0x4fe138
xor ecx, ecx
mov word [esp + eax + 8], cx
lea eax, [esp + 8]
push eax
call fcn.00493b80
add esp, 4
mov edi, eax
push 0
push 1
call fcn.004edd70
add esp, 8
jmp 0x4fe101
push 9
call fcn.004edd50
add esp, 4
test esi, esi
je 0x4fe10e
push esi
call fcn.004a6790
add esp, 4
call fcn.0047d480
jmp 0x4fe11f
push 2
call fcn.004edd50
add esp, 4
mov ecx, dword [esp + 0x218]
mov eax, edi
pop edi
pop esi
xor ecx, esp
call fcn.0059bb21
add esp, 0x214
ret
call fcn.0059bc52
int3

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

Disassembly:
push esi
mov esi, dword [esp + 8]
push edi
test esi, esi
je 0x4fe215
mov edi, dword [esp + 0x10]
test edi, edi
je 0x4fe215
call fcn.0047d480
cmp dword [0x8a899c], 0
jne 0x4fe1a9
push str.kernel32.dll
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
je 0x4fe18a
push str.CreateSymbolicLinkW
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [0x8a899c], eax
jmp 0x4fe18f
mov eax, dword [0x8a899c]
test eax, eax
jne 0x4fe1a9
push 1
call fcn.004edd50
add esp, 4
xor esi, esi
call fcn.0047d480
pop edi
mov eax, esi
pop esi
ret
push ebx
push edi
call fcn.004e00f0
push esi
mov ebx, eax
call fcn.004e00f0
add esp, 8
mov edi, eax
push edi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x4fe1d4
test al, 0x10
je 0x4fe1d4
mov eax, 1
jmp 0x4fe1d6
xor eax, eax
push eax
push edi
push ebx
call dword [0x8a899c]
neg eax
push 0
sbb esi, esi
neg esi
push esi
call fcn.004edd70
add esp, 8
test ebx, ebx
je 0x4fe1fd
push ebx
call fcn.004a6790
add esp, 4
pop ebx
test edi, edi
je 0x4fe20b
push edi
call fcn.004a6790
add esp, 4
call fcn.0047d480
pop edi
mov eax, esi
pop esi
ret
push 2
call fcn.004edd50
add esp, 4
xor eax, eax
pop edi
pop esi
ret
Function at 0x4fe310
Capabilities:
Open clipboard
Read clipboard data

Disassembly:
push ebx
mov ebx, dword [esp + 8]
push esi
push edi
push ebx
xor esi, esi
call dword [sym.imp.USER32.dll_IsClipboardFormatAvailable]
mov edi, dword [esp + 0x14]
test eax, eax
je 0x4fe40e
push esi
call dword [sym.imp.USER32.dll_OpenClipboard]
test eax, eax
je 0x4fe40e
push ebp
push ebx
call dword [sym.imp.USER32.dll_GetClipboardData]
mov ebp, eax
test ebp, ebp
je 0x4fe403
push ebp
call dword [sym.imp.KERNEL32.dll_GlobalLock]
mov edi, eax
test edi, edi
je 0x4fe3ff
push ebp
call dword [sym.imp.KERNEL32.dll_GlobalSize]
mov ecx, ebx
mov esi, eax
sub ecx, 1
je 0x4fe3a4
sub ecx, 6
je 0x4fe3a4
sub ecx, 6
jne 0x4fe3b0
shr esi, 1
push esi
push edi
call fcn.004a6700
mov esi, eax
add esp, 8
test esi, esi
je 0x4fe3f2
push esi
push edi
mov edi, dword [esp + 0x20]
push 0
push edi
call fcn.0048d350
add esp, 0x10
push ebp
call dword [sym.imp.KERNEL32.dll_GlobalUnlock]
jmp 0x4fe403
push esi
push edi
call fcn.00579910
add esp, 8
mov esi, eax
test esi, esi
je 0x4fe3f2
cmp ebx, 1
jne 0x4fe3d7
call fcn.00497290
push esi
push edi
mov edi, dword [esp + 0x20]
push eax
push edi
call fcn.0048d240
add esp, 0x10
push ebp
call dword [sym.imp.KERNEL32.dll_GlobalUnlock]
jmp 0x4fe403
push esi
push edi
mov edi, dword [esp + 0x20]
xor eax, eax
push eax
push edi
call fcn.0048d240
add esp, 0x10
push ebp
call dword [sym.imp.KERNEL32.dll_GlobalUnlock]
jmp 0x4fe403
mov edi, dword [esp + 0x18]
push ebp
call dword [sym.imp.KERNEL32.dll_GlobalUnlock]
jmp 0x4fe403
mov edi, dword [esp + 0x18]
call dword [sym.imp.USER32.dll_CloseClipboard]
pop ebp
test esi, esi
jne 0x4fe419
push 0
push edi
call fcn.0048c560
add esp, 8
xor eax, eax
test esi, esi
pop edi
pop esi
setne al
pop ebx
ret
Function at 0x4fe430
Capabilities:
Open clipboard
Write clipboard data

Disassembly:
push ecx
push ebx
xor ebx, ebx
push ebx
call dword [sym.imp.USER32.dll_OpenClipboard]
test eax, eax
je 0x4fe508
push ebp
push esi
push edi
call dword [sym.imp.USER32.dll_EmptyClipboard]
mov ebp, dword [esp + 0x18]
push ebx
push ebx
cmp ebp, 0xd
jne 0x4fe464
mov esi, dword [esp + 0x24]
push ebx
push esi
call fcn.0048b800
jmp 0x4fe474
call fcn.00497290
mov esi, dword [esp + 0x24]
push eax
push esi
call fcn.0048b7a0
add esp, 0x10
test eax, eax
je 0x4fe4fa
lea ecx, [eax + 1]
xor eax, eax
cmp ebp, 0xd
mov dword [esp + 0x10], ecx
sete al
inc eax
imul eax, ecx
push eax
push 2
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov edi, eax
test edi, edi
je 0x4fe4ff
push edi
call dword [sym.imp.KERNEL32.dll_GlobalLock]
test eax, eax
je 0x4fe4e5
push dword [esp + 0x10]
push eax
cmp ebp, 0xd
jne 0x4fe4bc
push 0
push esi
call fcn.0048b800
jmp 0x4fe4c8
call fcn.00497290
push eax
push esi
call fcn.0048b7a0
add esp, 0x10
push edi
call dword [sym.imp.KERNEL32.dll_GlobalUnlock]
push edi
push ebp
call dword [sym.imp.USER32.dll_SetClipboardData]
xor ebx, ebx
test eax, eax
setne bl
test eax, eax
jne 0x4fe4ff
push edi
call dword [sym.imp.KERNEL32.dll_GlobalFree]
call dword [sym.imp.USER32.dll_CloseClipboard]
pop edi
pop esi
pop ebp
mov eax, ebx
pop ebx
pop ecx
ret
mov ebx, 1
call dword [sym.imp.USER32.dll_CloseClipboard]
pop edi
pop esi
pop ebp
mov eax, ebx
pop ebx
pop ecx
ret
Function at 0x52cbc0
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebx
mov ebx, dword [esp + 8]
push esi
push edi
push 0xffffffffffffffff
push dword [esp + 0x18]
push ebx
call fcn.00534d50
mov esi, eax
add esp, 0xc
mov ecx, dword [esi + 0x7c]
or byte [esi + 0x1b], 0x80
mov edi, dword [ecx + 0xc]
mov eax, dword [edi + 0x88]
test eax, eax
je 0x52cc21
test byte [eax + 0x24], 8
jne 0x52cc21
cmp dword [edi + 0x170], 0
jne 0x52cc21
cmp dword [edi + 0x168], 0
jne 0x52cc21
push eax
call fcn.004e3ef0
add esp, 4
mov dword [edi + 0x168], eax
test eax, eax
jne 0x52cc21
mov dword [edi + 0x170], 1
mov dword [esi + 0xc], 0
mov eax, 0x38e38e39
mov dword [esi + 0x10], 0
mov dword [esi + 0x38], 1
mov dword [esi + 0x1c], 1
mov dword [esi + 0x20], 0
mov dword [esi + 0x3c], 0
mov dword [esi + 0x40], 0
mov dword [esi + 0x24], 0
mov dword [esi + 0x2c], 0
mov dword [esi + 0x28], 0
mov dword [esi + 0x34], 0
mov dword [esi + 0x30], 0
mov dword [esi + 0x14], 0xa0043
mov byte [esi + 0x1a], 0x20
movzx ecx, word [ebx + 0x2e]
sub ecx, 0xc
mov dword [esi + 0x44], 1
imul ecx
push 0
sar edx, 2
mov eax, edx
shr eax, 0x1f
add eax, edx
push esi
mov word [esi + 0x78], ax
call fcn.00533130
add esp, 8
mov dword [ebx + 0x14], esi
pop edi
pop esi
pop ebx
ret
Function at 0x52ccc0
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebx
push ebp
mov ebp, dword [esp + 0x10]
push esi
push 0xffffffffffffffff
push dword [esp + 0x1c]
push ebp
call fcn.00534d50
add esp, 0xc
mov esi, eax
cmp dword [esp + 0x10], 0
je 0x52cce3
or byte [esi + 0x1b], 0x80
mov bl, byte [esp + 0x24]
cmp bl, 0x43
jne 0x52cd33
mov eax, dword [esi + 0x7c]
push edi
mov edi, dword [eax + 0xc]
mov eax, dword [edi + 0x88]
test eax, eax
je 0x52cd32
test byte [eax + 0x24], 8
jne 0x52cd32
cmp dword [edi + 0x170], 0
jne 0x52cd32
cmp dword [edi + 0x168], 0
jne 0x52cd32
push eax
call fcn.004e3ef0
add esp, 4
mov dword [edi + 0x168], eax
test eax, eax
jne 0x52cd32
mov dword [edi + 0x170], 1
pop edi
mov eax, dword [esp + 0x1c]
test eax, eax
je 0x52cd57
push eax
call fcn.00579580
mov dword [esi + 4], eax
push eax
mov eax, dword [esi + 0x7c]
push dword [eax + 0xc]
call fcn.0050e740
add esp, 0xc
mov word [esi + 0x18], ax
mov eax, dword [esp + 0x20]
mov dword [esi + 0xc], eax
mov eax, dword [esp + 0x2c]
test eax, eax
je 0x52cd72
push eax
call fcn.00579580
add esp, 4
mov dword [esi + 8], eax
cmp dword [esp + 0x3c], 0
mov eax, dword [esp + 0x30]
mov dword [esi + 0x10], eax
mov eax, dword [esp + 0x34]
mov dword [esi + 0x38], eax
mov dword [esi + 0x1c], eax
mov eax, dword [esp + 0x38]
mov dword [esi + 0x20], eax
mov dword [esi + 0x3c], 0
je 0x52cda4
cmp bl, 0x43
jne 0x52cda4
mov eax, 1
jmp 0x52cda6
xor eax, eax
mov cx, word [esp + 0x28]
cmp bl, 0x43
mov dword [esi + 0x40], eax
mov eax, dword [esp + 0x40]
mov dword [esi + 0x24], eax
mov dword [esi + 0x2c], eax
mov dword [esi + 0x28], eax
movzx eax, bl
mov word [esi + 0x14], ax
setne al
dec al
mov word [esi + 0x16], cx
and al, 0x20
mov dword [esi + 0x34], 0
mov byte [esi + 0x1a], al
mov dword [esi + 0x30], 0
movzx eax, word [ebp + 0x2e]
sub eax, 0xc
movzx ecx, cx
add ecx, 8
cdq
idiv ecx
push dword [esp + 0x44]
mov word [esi + 0x78], ax
push esi
mov dword [esi + 0x44], 1
call fcn.00533130
add esp, 8
mov eax, esi
pop esi
pop ebp
pop ebx
ret
Function at 0x52d0e0
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
push esi
push edi
mov edi, dword [esp + 0x10]
mov eax, dword [edi + 0x14]
test eax, eax
je 0x52d109
push eax
call fcn.00534ef0
mov eax, dword [edi + 0x14]
add esp, 4
cmp dword [eax + 0x44], 0
je 0x52d109
push eax
call fcn.005340d0
add esp, 4
mov esi, dword [edi + 0x18]
test esi, esi
je 0x52d132
push esi
call fcn.00534ef0
add esp, 4
cmp dword [esi + 0x44], 0
je 0x52d128
push esi
call fcn.005340d0
add esp, 4
mov esi, dword [esi + 0x80]
test esi, esi
jne 0x52d110
cmp dword [edi + 0x20], 0
mov esi, dword [edi + 0x3c]
je 0x52d151
push 0
push 0
push str.hb_cdxIndexFlushAvailPage_on_readonly_database.
push 0x238d
call fcn.004ecae0
add esp, 0x10
cmp dword [edi + 0x1c], 0
je 0x52d173
cmp dword [edi + 0x40], 0
jne 0x52d173
push 0
push 0
push str.hb_cdxIndexFlushAvailPage_on_not_locked_index_file.
push 0x238e
call fcn.004ecae0
add esp, 0x10
lea eax, [edi + 0x48]
push eax
push dword [edi + 8]
push dword [edi + 0xc]
call fcn.005177f0
add esp, 0xc
test eax, eax
jne 0x52d19d
push eax
push eax
push str.hb_cdxIndexLockFlush:_flush_lock_failed.
push 0x2395
call fcn.004ecae0
add esp, 0x10
mov ebp, dword [edi + 0x38]
test esi, esi
je 0x52d243
cmp dword [esi + 4], 0
je 0x52d243
movzx eax, word [edi + 0x2e]
push ebx
push eax
push 0
push eax
call fcn.004a67c0
add esp, 4
push eax
call fcn.0059d510
add esp, 0xc
mov ebx, eax
nop
mov eax, dword [esi]
mov dword [ebx], eax
cmp dword [edi + 0x28], 0
je 0x52d1e0
movzx ecx, word [edi + 0x30]
jmp 0x52d1e2
xor ecx, ecx
mov eax, ebp
xor edx, edx
call fcn.0059c200
push edx
push eax
movzx eax, word [edi + 0x2e]
push eax
push ebx
push dword [edi + 8]
call fcn.004e2a60
movzx ecx, word [edi + 0x2e]
add esp, 0x14
cmp eax, ecx
je 0x52d21c
push 0
push 0
push str.Write_in_index_page_failed.
push 0x3f3
call fcn.004ecae0
add esp, 0x10
mov dword [edi + 0x78], 1
mov ebp, dword [esi]
mov dword [esi + 4], 0
mov esi, dword [esi + 8]
test esi, esi
je 0x52d239
cmp dword [esi + 4], 0
jne 0x52d1d0
push ebx
call fcn.004a6790
add esp, 4
pop ebx
pop edi
pop esi
pop ebp
ret
Function at 0x52d5d0
Capabilities:
Resolve function by parsing pe exports

Disassembly:
sub esp, 8
push ebx
push ebp
push esi
mov esi, dword [esp + 0x18]
push edi
cmp dword [esi + 0x20], 0
mov ebx, dword [esi + 8]
mov dword [esp + 0x10], ebx
je 0x52d5fe
push 0
push 0
push str.hb_cdxIndexGetAvailPage_on_readonly_database.
push 0x238d
call fcn.004ecae0
add esp, 0x10
cmp dword [esi + 0x1c], 0
je 0x52d620
cmp dword [esi + 0x40], 0
jne 0x52d620
push 0
push 0
push str.hb_cdxIndexGetAvailPage_on_not_locked_index_file.
push 0x238e
call fcn.004ecae0
add esp, 0x10
mov edi, dword [esi + 0x38]
test edi, edi
je 0x52d6ba
cmp edi, 0xffffffff
je 0x52d6ba
mov ebp, dword [esp + 0x20]
test ebp, ebp
jne 0x52d6c2
mov eax, dword [esi + 0x3c]
test eax, eax
je 0x52d665
mov ecx, dword [eax]
mov dword [esi + 0x38], ecx
mov ecx, dword [eax + 8]
push eax
mov dword [esi + 0x3c], ecx
call fcn.004a6790
add esp, 4
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
cmp dword [esi + 0x28], 0
je 0x52d671
movzx ecx, word [esi + 0x30]
jmp 0x52d673
xor ecx, ecx
mov eax, edi
xor edx, edx
call fcn.0059c200
push edx
push eax
push 4
lea eax, [esp + 0x28]
push eax
push ebx
call fcn.004e27b0
add esp, 0x14
cmp eax, 4
je 0x52d6a9
push 0
push 0
push str.hb_cdxIndexGetAvailPage:_Read_index_page_failed.
push 0x3f2
call fcn.004ecae0
add esp, 0x10
mov eax, dword [esp + 0x1c]
mov dword [esi + 0x38], eax
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
mov ebp, dword [esp + 0x20]
test ebp, ebp
je 0x52d6c8
movzx eax, word [esi + 0x2c]
jmp 0x52d6cc
movzx eax, word [esi + 0x2e]
mov edi, dword [esi + 0x34]
xor ebx, ebx
movzx eax, ax
mov edx, edi
mov dword [esp + 0x14], eax
cmp edi, 0xffffffff
jne 0x52d703
cmp dword [esi + 0x28], ebx
je 0x52d6ea
movzx edi, word [esi + 0x30]
jmp 0x52d6ec
xor edi, edi
push dword [esp + 0x10]
call fcn.004e2850
add esp, 4
mov ecx, edi
call fcn.0059c220
mov edi, eax
mov edx, eax
movzx eax, word [esi + 0x2e]
mov dword [esp + 0x1c], eax
nop dword [eax + eax]
cmp dword [esi + 0x28], 0
je 0x52d71a
xor ecx, ecx
jmp 0x52d71e
movzx ecx, word [esi + 0x30]
mov eax, 1
shl eax, cl
mov ecx, dword [esp + 0x14]
add edx, eax
mov eax, dword [esp + 0x1c]
add ebx, eax
cmp ebx, ecx
jb 0x52d710
mov dword [esi + 0x34], edx
test ebp, ebp
je 0x52d7dc
cmp ecx, eax
cmovae eax, ecx
push eax
push 0
push eax
mov dword [esp + 0x28], eax
call fcn.004a67c0
add esp, 4
push eax
call fcn.0059d510
lea ecx, [esi + 0x48]
mov ebp, eax
push ecx
push dword [esi + 8]
push dword [esi + 0xc]
call fcn.005177f0
add esp, 0x18
test eax, eax
jne 0x52d787
push eax
push eax
push str.hb_cdxIndexLockFlush:_flush_lock_failed.
push 0x2395
call fcn.004ecae0
add esp, 0x10
cmp dword [esi + 0x28], 0
je 0x52d793
movzx ecx, word [esi + 0x30]
jmp 0x52d795
xor ecx, ecx
mov eax, edi
xor edx, edx
call fcn.0059c200
mov ebx, dword [esp + 0x1c]
push edx
push eax
push ebx
push ebp
push dword [esp + 0x20]
call fcn.004e2a60
add esp, 0x14
cmp eax, ebx
je 0x52d7cc
push 0
push 0
push str.Write_in_index_page_failed.
push 0x3f3
call fcn.004ecae0
add esp, 0x10
push ebp
mov dword [esi + 0x78], 1
call fcn.004a6790
add esp, 4
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
Function at 0x530f20
Capabilities:
Enumerate pe sections

Disassembly:
sub esp, 0x1c
push ebx
push ebp
push esi
mov esi, dword [esp + 0x2c]
push edi
test byte [esi + 0x20], 2
mov eax, dword [esi + 0x40]
mov ebx, dword [esi + 0x10]
movzx eax, word [eax + 0x16]
mov dword [esp + 0x1c], eax
lea ebp, [eax + 8]
jne 0x530f58
push 0
push 0
push str.hb_cdxPageLeafDelKey:_page_is_not_a_leaf.
push 0x23f1
call fcn.004ecae0
add esp, 0x10
test ebx, ebx
js 0x530f61
cmp ebx, dword [esi + 0xc]
jl 0x530f77
push 0
push 0
push str.hb_cdxPageLeafDelKey:_wrong_iKey_index.
push 0x23f1
call fcn.004ecae0
add esp, 0x10
mov edi, dword [esi + 0x34]
test edi, edi
jne 0x530f99
mov eax, dword [esi + 0xc]
imul eax, ebp
push eax
call fcn.004a67c0
mov edi, eax
push edi
push esi
call fcn.00530d50
add esp, 0xc
mov dword [esi + 0x34], edi
lea ecx, [ebx + 1]
imul ecx, ebp
mov dword [esp + 0x18], ecx
movzx eax, word [ecx + edi - 4]
mov dword [esp + 0x14], eax
mov eax, dword [esi + 0x40]
movzx edx, word [eax + 0x16]
movzx eax, word [ecx + edi - 2]
movzx ecx, byte [esi + 0x1f]
sub ecx, eax
mov eax, dword [esi + 0xc]
sub ecx, dword [esp + 0x14]
dec eax
add ecx, edx
mov dword [esp + 0x10], ecx
cmp ebx, eax
jge 0x531066
lea eax, [ebx + 2]
xor ecx, ecx
imul eax, ebp
sub eax, 4
mov dword [esp + 0x28], eax
movzx eax, word [edi + eax]
sub dword [esp + 0x10], eax
mov dword [esp + 0x20], eax
test ebx, ebx
jle 0x531053
mov esi, dword [esp + 0x18]
lea eax, [ebx - 1]
mov ecx, dword [esp + 0x14]
imul eax, ebp
mov dword [esp + 0x24], eax
mov eax, dword [esp + 0x1c]
add eax, edi
movzx eax, word [eax + esi + 6]
mov esi, dword [esp + 0x30]
sub edx, eax
mov eax, dword [esp + 0x20]
cmp eax, ecx
mov dword [esp + 0x1c], edx
cmovb ecx, eax
cmp ecx, edx
jle 0x53102b
mov ecx, edx
jmp 0x531053
jge 0x531053
mov esi, dword [esp + 0x24]
mov eax, dword [esp + 0x18]
lea edx, [edi + esi]
mov edi, dword [esp + 0x1c]
add edx, ecx
sub eax, esi
mov esi, eax
mov al, byte [edx]
cmp al, byte [esi + edx]
jne 0x53104f
inc ecx
inc edx
cmp ecx, edi
jl 0x531042
mov esi, dword [esp + 0x30]
mov eax, dword [esi + 0x34]
mov edx, dword [esp + 0x28]
add dword [esp + 0x10], ecx
mov word [edx + eax], cx
mov ecx, dword [esp + 0x10]
mov edi, dword [esi + 0xc]
add word [esi + 0x32], cx
dec edi
movzx eax, word [esi + 0x32]
mov dword [esi + 0xc], edi
mov dword [esp + 0x30], eax
cmp edi, ebx
jle 0x5310a5
mov eax, dword [esp + 0x18]
sub edi, ebx
add eax, dword [esi + 0x34]
imul edi, ebp
imul ebp, ebx
push edi
add ebp, dword [esi + 0x34]
push eax
push ebp
call fcn.0059ce60
movzx eax, word [esi + 0x32]
add esp, 0xc
mov edi, dword [esi + 0xc]
mov dword [esp + 0x30], eax
xor edx, edx
mov dword [esi + 0x24], 1
cmp ebx, edi
mov dword [esi + 0x28], 1
setge dl
test edi, edi
jne 0x5310c3
or edx, 4
jmp 0x5310cb
test ax, ax
jns 0x5310cb
or edx, 2
movzx ecx, byte [esi + 0x1f]
mov eax, edx
pop edi
or eax, 8
cmp word [esp + 0x2c], cx
pop esi
pop ebp
cmovl eax, edx
pop ebx
add esp, 0x1c
ret