joyce8/EMBER2024-capa huggingface dataset:
Function at 0x59db80
Capabilities:
Read file via mapping

Disassembly:
push ebx
mov ebx, dword [esp + 0xc]
push ebp
mov ebp, dword [esp + 0x14]
push esi
push edi
mov edi, ecx
mov ecx, dword [esp + 0x14]
mov eax, dword [ecx]
mov edx, dword [eax + 0xc]
lea esi, [ebx + ebp]
call edx
cmp esi, eax
ja 0x59dbf1
mov ecx, dword [esp + 0x14]
call fcn.0059f0f0
push 0
push esi
push 0
push 2
push 0
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileMappingW]
mov dword [edi + 0x24], eax
test eax, eax
jne 0x59dbfa
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [esp + 0x14]
push eax
call fcn.0059f1e0
push eax
push str.CREATE_FILE_MAPPING_ERROR_diskFile_s__errno_lu_
push str.EL_MappedFile::Map
push 0x4f
push str..MappedFile.cpp
push 0xffffffffffffffff
push 0x200
call fcn.0059efe0
add esp, 0x20
pop edi
pop esi
pop ebp
xor al, al
pop ebx
ret 0xc
mov ecx, dword [0x6b4000]
call fcn.0055edc0
mov ecx, dword [edi + 0x24]
mov esi, eax
dec esi
and esi, ebx
lea eax, [esi + ebp]
push eax
sub ebx, esi
push ebx
push 0
push 4
push ecx
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov dword [edi + 8], eax
test eax, eax
jne 0x59dc60
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [esp + 0x14]
push eax
call fcn.0059f1e0
push eax
push str.MAP_VIEW_OF_FILE_ERROR_diskFile_s__errno_lu_
push str.EL_MappedFile::Map
push 0x60
push str..MappedFile.cpp
push 0xffffffffffffffff
push 0x200
call fcn.0059efe0
add esp, 0x20
pop edi
pop esi
pop ebp
xor al, al
pop ebx
ret 0xc
add eax, esi
mov dword [edi + 0x18], ebp
mov dword [edi + 4], eax
mov dword [edi + 0x14], 0
pop edi
pop esi
pop ebp
mov al, 1
pop ebx
ret 0xc
Function at 0x59e080
Capabilities:
Encode data using add xor sub operations
Encode data using xor
Hash data with crc32

Disassembly:
mov edx, dword [esp + 8]
mov ecx, dword [esp + 4]
or eax, 0xffffffff
push esi
cmp edx, 0x10
jb 0x59e203
movzx esi, byte [ecx]
xor esi, eax
and esi, 0xff
shr eax, 8
xor eax, dword [esi*4 + 0x681430]
movzx esi, byte [ecx + 1]
xor esi, eax
and esi, 0xff
shr eax, 8
xor eax, dword [esi*4 + 0x681430]
movzx esi, byte [ecx + 2]
xor esi, eax
and esi, 0xff
shr eax, 8
xor eax, dword [esi*4 + 0x681430]
movzx esi, byte [ecx + 3]
xor esi, eax
and esi, 0xff
shr eax, 8
xor eax, dword [esi*4 + 0x681430]
movzx esi, byte [ecx + 4]
xor esi, eax
and esi, 0xff
shr eax, 8
xor eax, dword [esi*4 + 0x681430]
movzx esi, byte [ecx + 5]
xor esi, eax
and esi, 0xff
shr eax, 8
xor eax, dword [esi*4 + 0x681430]
movzx esi, byte [ecx + 6]
xor esi, eax
and esi, 0xff
shr eax, 8
xor eax, dword [esi*4 + 0x681430]
movzx esi, byte [ecx + 7]
xor esi, eax
and esi, 0xff
shr eax, 8
xor eax, dword [esi*4 + 0x681430]
movzx esi, byte [ecx + 8]
xor esi, eax
and esi, 0xff
shr eax, 8
xor eax, dword [esi*4 + 0x681430]
movzx esi, byte [ecx + 9]
xor esi, eax
and esi, 0xff
shr eax, 8
xor eax, dword [esi*4 + 0x681430]
movzx esi, byte [ecx + 0xa]
xor esi, eax
and esi, 0xff
shr eax, 8
xor eax, dword [esi*4 + 0x681430]
movzx esi, byte [ecx + 0xb]
xor esi, eax
and esi, 0xff
shr eax, 8
xor eax, dword [esi*4 + 0x681430]
movzx esi, byte [ecx + 0xc]
xor esi, eax
and esi, 0xff
shr eax, 8
xor eax, dword [esi*4 + 0x681430]
movzx esi, byte [ecx + 0xd]
xor esi, eax
and esi, 0xff
shr eax, 8
xor eax, dword [esi*4 + 0x681430]
movzx esi, byte [ecx + 0xe]
xor esi, eax
and esi, 0xff
shr eax, 8
xor eax, dword [esi*4 + 0x681430]
movzx esi, byte [ecx + 0xf]
xor esi, eax
and esi, 0xff
shr eax, 8
xor eax, dword [esi*4 + 0x681430]
add ecx, 0x10
sub edx, 0x10
cmp edx, 0x10
jae 0x59e095
test edx, edx
je 0x59e22b
jmp 0x59e210
movzx esi, byte [ecx]
xor esi, eax
and esi, 0xff
shr eax, 8
xor eax, dword [esi*4 + 0x681430]
inc ecx
sub edx, 1
jne 0x59e210
not eax
pop esi
ret
Function at 0x59ec30
Capabilities:
Delete directory
Delete file
Enumerate files on windows
Enumerate files recursively

Disassembly:
sub esp, 0x668
mov eax, dword [0x67ff88]
xor eax, esp
mov dword [esp + 0x664], eax
mov eax, dword [esp + 0x66c]
push ebx
push ebp
push edi
mov edi, dword [esp + 0x67c]
push eax
push 0x61dd3c
mov dword [esp + 0x18], eax
lea eax, [esp + 0x278]
push 0x200
push eax
call fcn.0041ee90
mov ebp, 0x200
add esp, 0x10
sub ebp, eax
lea ebx, [esp + eax*2 + 0x270]
push 0x62ee84
mov edx, ebp
mov ecx, ebx
call fcn.0041edf0
lea ecx, [esp + 0x20]
push ecx
lea edx, [esp + 0x274]
push edx
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov dword [esp + 0xc], eax
cmp eax, 0xffffffff
jne 0x59ecec
test edi, edi
je 0x59ecd2
mov dword [esp + 0x18], eax
lea eax, [esp + 0x14]
push eax
push 0x45
mov ecx, edi
mov dword [esp + 0x1c], str.NO_FILES
mov dword [esp + 0x24], 0
call fcn.0059ead0
pop edi
pop ebp
xor al, al
pop ebx
mov ecx, dword [esp + 0x664]
xor ecx, esp
call fcn.0057ac48
add esp, 0x668
ret
push esi
lea ecx, [ecx]
cmp word [esp + 0x50], 0
lea esi, [esp + 0x50]
jne 0x59ed03
lea esi, [esp + 0x258]
push 1
push 0x62ee74
push esi
call fcn.0041ec90
add esp, 0xc
test eax, eax
jne 0x59ed3b
push 0x62ee74
push esi
call fcn.0041ec10
add esp, 8
test eax, eax
je 0x59ed94
push 0x62ee6c
push esi
call fcn.0041ec10
add esp, 8
test eax, eax
je 0x59ed94
push esi
mov edx, ebp
mov ecx, ebx
call fcn.0041edf0
test byte [esp + 0x24], 0x10
je 0x59ed5f
lea ecx, [esp + 0x274]
push edi
push ecx
call fcn.0059ec30
add esp, 8
jmp 0x59ed94
lea edx, [esp + 0x274]
push edx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
jne 0x59ed94
test edi, edi
je 0x59ed94
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [esp + 0x278]
push eax
push str.DELETE_FILE_ERROR_filePath_s__errorCode_d_
push 0x45
push edi
call fcn.0059ebb0
add esp, 0x14
mov edx, dword [esp + 0x10]
lea ecx, [esp + 0x24]
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x59ecf0
mov eax, dword [esp + 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_FindClose]
mov esi, dword [esp + 0x14]
push esi
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
test eax, eax
jne 0x59ede2
test edi, edi
je 0x59ede2
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push esi
push str.REMOVE_DIRECTORY_ERROR_dir_s__errorCode_d_
push 0x45
push edi
call fcn.0059ebb0
add esp, 0x14
mov ecx, dword [esp + 0x674]
pop esi
pop edi
pop ebp
pop ebx
xor ecx, esp
mov al, 1
call fcn.0057ac48
add esp, 0x668
ret

Function at 0x59f150
Capabilities:
Get file size
Write file on windows

Disassembly:
mov edx, dword [esp + 4]
push esi
push 0
mov esi, ecx
mov ecx, dword [esp + 0x10]
lea eax, [esp + 0x10]
push eax
mov eax, dword [esi + 0x28]
push ecx
push edx
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x59f178
xor al, al
pop esi
ret 0xc
mov eax, dword [esp + 0x10]
test eax, eax
je 0x59f186
mov ecx, dword [esp + 0xc]
mov dword [eax], ecx
mov edx, dword [esi + 0x28]
push 0
push edx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov dword [esi + 8], eax
mov al, 1
pop esi
ret 0xc
Function at 0x59f1a0
Capabilities:
Read file on windows

Disassembly:
mov edx, dword [esp + 8]
mov ecx, dword [ecx + 0x28]
push 0
lea eax, [esp + 0xc]
push eax
mov eax, dword [esp + 0xc]
push edx
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x59f1c4
xor al, al
ret 0xc
mov eax, dword [esp + 0xc]
test eax, eax
je 0x59f1d2
mov edx, dword [esp + 8]
mov dword [eax], edx
mov al, 1
ret 0xc

Function at 0x59f290
Capabilities:
Get file size

Disassembly:
push ebx
push esi
push edi
mov edi, dword [esp + 0x10]
mov eax, edi
mov esi, ecx
lea edx, [eax + 2]
mov edi, edi
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x59f2a0
sub eax, edx
sar eax, 1
push eax
push edi
lea ecx, [esi + 0xc]
call fcn.0040240d
mov ebx, dword [esp + 0x14]
movsx eax, bl
and eax, 2
or eax, 0xfffffffc
xor ecx, ecx
shl eax, 0x1d
cmp ebx, 1
setne cl
push 0
push 0x80
add ecx, 3
push ecx
push 0
push 1
push eax
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [esi + 0x28], eax
cmp eax, 0xffffffff
jne 0x59f2ff
pop edi
mov dword [esi + 0x28], 0
pop esi
xor al, al
pop ebx
ret 8
push 0
push eax
mov dword [esi + 4], ebx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
pop edi
mov dword [esi + 8], eax
pop esi
mov al, 1
pop ebx
ret 8

Function at 0x59fe50
Capabilities:
Access peb ldr_data
Get kernel32 base address

Disassembly:
push 0xffffffffffffffff
push 0x5d1453
mov eax, dword fs:[0]
push eax
push ecx
push ebx
push esi
mov eax, dword [0x67ff88]
xor eax, esp
push eax
lea eax, [esp + 0x10]
mov dword fs:[0], eax
mov esi, ecx
mov dword [esp + 0xc], esi
xor ebx, ebx
push ebx
call fcn.0059fb30
lea ecx, [esi + 0x34]
mov dword [esi], vtable.TiXmlDocument.0
mov dword [esp + 0x18], ebx
mov dword [ecx], 0x6b393c
or eax, 0xffffffff
mov dword [esi + 0x40], eax
mov dword [esi + 0x3c], eax
push ebx
push 0x62b83c
mov byte [esp + 0x20], 1
mov dword [esi + 0x38], 4
mov byte [esi + 0x44], bl
mov byte [esi + 0x2c], bl
mov dword [esi + 0x30], ebx
call fcn.005a0d00
mov dword [esi + 0x40], ebx
mov dword [esi + 0x3c], ebx
mov eax, esi
mov ecx, dword [esp + 0x10]
mov dword fs:[0], ecx
pop ecx
pop esi
pop ebx
add esp, 0x10
ret
Function at 0x5a4d40
Capabilities:
Check if file exists
Get file attributes

Disassembly:
mov eax, dword [esp + 8]
cmp dword [eax + 0x18], 8
jb 0x5a4d4f
mov eax, dword [eax + 4]
jmp 0x5a4d52
add eax, 4
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x5a4de4
push esi
mov esi, dword [0x6b3958]
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [esp + 0x10]
mov dword [ecx + 4], esi
mov dword [ecx], eax
pop esi
cmp eax, 2
je 0x5a4dc9
cmp eax, 3
je 0x5a4dc9
cmp eax, 0x7b
je 0x5a4dc9
cmp eax, 0xf
je 0x5a4dc9
cmp eax, 0x57
je 0x5a4dc9
cmp eax, 0xa1
je 0x5a4dc9
cmp eax, 0x35
je 0x5a4dc9
cmp eax, 0x20
jne 0x5a4dbe
mov eax, dword [0x6b395c]
mov dword [ecx], eax
mov edx, dword [0x6b3960]
mov eax, dword [esp + 4]
mov dword [ecx + 4], edx
mov dword [eax], 9
ret
mov eax, dword [esp + 4]
mov dword [eax], 0
ret
mov eax, dword [0x6b395c]
mov dword [ecx], eax
mov edx, dword [0x6b3960]
mov eax, dword [esp + 4]
mov dword [ecx + 4], edx
mov dword [eax], 1
ret
mov edx, dword [0x6b395c]
mov ecx, dword [esp + 0xc]
mov dword [ecx], edx
mov edx, dword [0x6b3960]
test al, 0x10
mov dword [ecx + 4], edx
lea eax, [esp + 8]
mov dword [esp + 8], 3
jne 0x5a4e11
mov dword [esp + 8], 2
mov ecx, dword [eax]
mov eax, dword [esp + 4]
mov dword [eax], ecx
ret

Function at 0x5a4f00
Capabilities:
Delete directory

Disassembly:
mov eax, dword [esp + 4]
cmp dword [eax + 0x18], 8
jb 0x5a4f1b
mov eax, dword [eax + 4]
push eax
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
neg eax
sbb eax, eax
neg eax
ret
add eax, 4
push eax
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
neg eax
sbb eax, eax
neg eax
ret

Function at 0x5a4f30
Capabilities:
Delete file

Disassembly:
mov eax, dword [esp + 4]
cmp dword [eax + 0x18], 8
jb 0x5a4f4b
mov eax, dword [eax + 4]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
neg eax
sbb eax, eax
neg eax
ret
add eax, 4
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
neg eax
sbb eax, eax
neg eax
ret

Function at 0x5a4f80
Capabilities:
Move file

Disassembly:
mov eax, dword [esp + 0xc]
mov edx, 8
cmp dword [eax + 0x18], edx
jb 0x5a4f93
mov ecx, dword [eax + 4]
jmp 0x5a4f96
lea ecx, [eax + 4]
mov eax, dword [esp + 8]
cmp dword [eax + 0x18], edx
jb 0x5a4fa4
mov eax, dword [eax + 4]
jmp 0x5a4fa7
add eax, 4
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_MoveFileW]
test eax, eax
je 0x5a4fc5
mov eax, dword [esp + 4]
xor ecx, ecx
mov dword [eax], ecx
mov ecx, dword [0x6b3958]
mov dword [eax + 4], ecx
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, eax
mov eax, dword [esp + 4]
mov dword [eax], ecx
mov ecx, dword [0x6b3958]
mov dword [eax + 4], ecx
ret
Function at 0x5a4fe0
Capabilities:
Copy file

Disassembly:
mov eax, dword [esp + 0xc]
mov edx, 8
cmp dword [eax + 0x18], edx
jb 0x5a4ff3
mov ecx, dword [eax + 4]
jmp 0x5a4ff6
lea ecx, [eax + 4]
mov eax, dword [esp + 8]
cmp dword [eax + 0x18], edx
jb 0x5a5004
mov eax, dword [eax + 4]
jmp 0x5a5007
add eax, 4
movzx edx, byte [esp + 0x10]
push edx
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileW]
test eax, eax
je 0x5a502b
mov eax, dword [esp + 4]
xor ecx, ecx
mov dword [eax], ecx
mov ecx, dword [0x6b3958]
mov dword [eax + 4], ecx
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, eax
mov eax, dword [esp + 4]
mov dword [eax], ecx
mov ecx, dword [0x6b3958]
mov dword [eax + 4], ecx
ret

Function at 0x5a5170
Capabilities:
Create directory

Disassembly:
sub esp, 8
push ebp
push esi
push edi
xor esi, esi
call fcn.005a5950
mov ebp, eax
mov dword [esp + 0xc], esi
call fcn.005a5950
mov edi, dword [esp + 0x1c]
cmp dword [edi + 0x18], 8
mov dword [esp + 0x10], eax
jb 0x5a519b
mov eax, dword [edi + 4]
jmp 0x5a519e
lea eax, [edi + 4]
push 0
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
je 0x5a51bf
mov eax, dword [esp + 0x18]
pop edi
mov dword [eax], esi
pop esi
mov dword [eax + 4], ebp
mov byte [eax + 8], 1
pop ebp
add esp, 8
ret
mov ebp, dword [0x6b3958]
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
cmp esi, 0xb7
jne 0x5a520f
lea eax, [esp + 0xc]
push eax
lea ecx, [esp + 0x20]
push edi
push ecx
call fcn.005a4d40
add esp, 0xc
cmp dword [esp + 0x1c], 3
jne 0x5a520f
mov eax, dword [esp + 0x18]
mov edx, dword [0x6b395c]
mov ecx, dword [0x6b3960]
pop edi
pop esi
mov dword [eax], edx
mov dword [eax + 4], ecx
mov byte [eax + 8], 0
pop ebp
add esp, 8
ret
mov eax, dword [esp + 0x18]
pop edi
mov dword [eax], esi
pop esi
mov dword [eax + 4], ebp
mov byte [eax + 8], 0
pop ebp
add esp, 8
ret

Function at 0x5a5500
Capabilities:
Get common file path

Disassembly:
push 0xffffffffffffffff
push 0x5d1778
mov eax, dword fs:[0]
push eax
push ecx
push ebx
push esi
push edi
mov eax, dword [0x67ff88]
xor eax, esp
push eax
lea eax, [esp + 0x14]
mov dword fs:[0], eax
mov ebx, dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
push 0
push 0
call ebx
mov edi, eax
test edi, edi
jne 0x5a553b
mov edi, 1
push edi
call fcn.0057365e
mov esi, eax
add esp, 4
mov dword [esp + 0x10], esi
push esi
push edi
mov dword [esp + 0x24], 0
call ebx
test eax, eax
jne 0x5a556f
mov ebx, dword [0x6b3958]
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, dword [esp + 0x24]
mov dword [edi + 4], ebx
jmp 0x5a559a
mov eax, esi
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x5a5574
mov ecx, dword [esp + 0x28]
sub eax, edx
push eax
push esi
call fcn.00402a71
mov edi, dword [esp + 0x24]
mov ecx, dword [0x6b3960]
mov eax, dword [0x6b395c]
mov dword [edi + 4], ecx
push esi
mov dword [edi], eax
call fcn.0057403d
mov eax, edi
add esp, 4
mov ecx, dword [esp + 0x14]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
add esp, 0x10
ret
Function at 0x5a55e0
Capabilities:
Check if file exists

Disassembly:
push 0xffffffffffffffff
push 0x5d17ab
mov eax, dword fs:[0]
push eax
sub esp, 0x27c
mov eax, dword [0x67ff88]
xor eax, esp
mov dword [esp + 0x278], eax
push ebp
push esi
push edi
mov eax, dword [0x67ff88]
xor eax, esp
push eax
lea eax, [esp + 0x28c]
mov dword fs:[0], eax
mov ecx, dword [esp + 0x2ac]
mov eax, dword [esp + 0x29c]
mov edx, dword [esp + 0x2b0]
mov edi, dword [esp + 0x2a0]
mov ebp, dword [esp + 0x2a8]
mov dword [esp + 0x14], ecx
xor ecx, ecx
push 0xffffffffffffffff
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0x2a8]
push ecx
mov word [esp + 0x28], cx
push eax
lea ecx, [esp + 0x28]
mov dword [esp + 0x24], edx
mov dword [esp + 0x40], 7
mov dword [esp + 0x3c], 0
call fcn.00403a5a
mov eax, dword [esp + 0x30]
mov dword [esp + 0x294], 0
test eax, eax
je 0x5a56ae
lea esi, [eax - 1]
cmp esi, eax
jbe 0x5a5693
call fcn.005749cd
cmp dword [esp + 0x34], 8
mov eax, dword [esp + 0x20]
jae 0x5a56a2
lea eax, [esp + 0x20]
cmp word [eax + esi*2], 0x5c
mov edx, 0x62ee84
je 0x5a56b3
mov edx, 0x62ee7c
mov eax, edx
lea esi, [eax + 2]
jmp 0x5a56c0
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x5a56c0
sub eax, esi
sar eax, 1
push eax
push edx
lea ecx, [esp + 0x24]
call fcn.00402253
mov eax, dword [esp + 0x20]
mov esi, 8
cmp dword [esp + 0x34], esi
jae 0x5a56ed
lea eax, [esp + 0x20]
lea edx, [esp + 0x38]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov dword [edi], eax
cmp eax, 0xffffffff
jne 0x5a573f
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [edi], 0
call esi
cmp eax, 2
jne 0x5a5717
xor eax, eax
jmp 0x5a5719
call esi
cmp dword [esp + 0x34], 8
mov esi, dword [esp + 0x10]
mov dword [esi], eax
mov eax, dword [0x6b3958]
mov dword [esi + 4], eax
jb 0x5a573b
mov ecx, dword [esp + 0x20]
push ecx
call fcn.00574048
add esp, 4
mov eax, esi
jmp 0x5a57bd
lea eax, [esp + 0x64]
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x5a5746
sub eax, edx
sar eax, 1
push eax
lea edx, [esp + 0x68]
push edx
mov ecx, ebp
call fcn.0040240d
test byte [esp + 0x38], 0x10
je 0x5a577f
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x18]
mov dword [eax], 3
mov dword [ecx], 3
jmp 0x5a5793
mov edx, dword [esp + 0x14]
mov eax, dword [esp + 0x18]
mov dword [edx], 2
mov dword [eax], 2
mov ecx, dword [0x6b395c]
mov edi, dword [esp + 0x10]
mov dword [edi], ecx
mov edx, dword [0x6b3960]
mov dword [edi + 4], edx
cmp dword [esp + 0x34], esi
jb 0x5a57bb
mov eax, dword [esp + 0x20]
push eax
call fcn.00574048
add esp, 4
mov eax, edi
mov ecx, dword [esp + 0x28c]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
mov ecx, dword [esp + 0x278]
xor ecx, esp
call fcn.0057ac48
add esp, 0x288
ret
Function at 0x5a6700
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push 0xffffffffffffffff
push 0x5d1918
mov eax, dword fs:[0]
push eax
push ecx
push ebx
push ebp
push esi
push edi
mov eax, dword [0x67ff88]
xor eax, esp
push eax
lea eax, [esp + 0x18]
mov dword fs:[0], eax
mov eax, dword [0x6b39b8]
test eax, eax
jne 0x5a6732
xor esi, esi
jmp 0x5a673b
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov esi, eax
mov dword [esp + 0x14], esi
mov ebp, dword [sym.imp.KERNEL32.dll_HeapFree]
mov dword [esp + 0x20], 0
test esi, esi
je 0x5a677d
cmp dword [esi + 0x14], 0
jne 0x5a67bf
cmp dword [esi + 0x10], 0
jne 0x5a67c5
push 0x5a6420
push 0x6b39bc
call fcn.005a6510
mov eax, dword [0x6b39b8]
add esp, 8
push 0
push eax
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
mov dword [esp + 0x20], 0xffffffff
test esi, esi
je 0x5a67ab
lea ecx, [esi + 4]
or edx, 0xffffffff
lock xadd dword [ecx], edx
jne 0x5a67ab
mov eax, dword [esi]
mov edx, dword [eax]
push 0
mov ecx, esi
call edx
push esi
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call ebp
mov ecx, dword [esp + 0x18]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x10
ret
cmp dword [esi + 0x10], 0
je 0x5a6805
mov ebx, dword [esi + 0x10]
mov eax, dword [ebx + 4]
mov dword [esi + 0x10], eax
mov ecx, dword [ebx]
test ecx, ecx
je 0x5a67f3
mov edx, dword [ecx]
mov eax, dword [edx + 4]
call eax
mov edi, dword [ebx]
mov edx, dword [edi]
mov eax, dword [edx]
push 0
mov ecx, edi
call eax
push edi
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call ebp
push ebx
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call ebp
cmp dword [esi + 0x10], 0
jne 0x5a67c5
cmp dword [esi + 0x14], 0
je 0x5a6757
mov edi, dword [esi + 0x14]
mov ecx, dword [edi + 0x10]
mov dword [esi + 0x14], ecx
mov ecx, dword [edi + 4]
test ecx, ecx
je 0x5a682a
mov edx, dword [ecx]
mov eax, dword [edi + 0xc]
mov edx, dword [edx + 4]
push eax
call edx
mov ebx, dword [edi + 8]
test ebx, ebx
je 0x5a685b
lea eax, [ebx + 4]
or ecx, 0xffffffff
lock xadd dword [eax], ecx
jne 0x5a685b
mov edx, dword [ebx]
mov eax, dword [edx + 4]
mov ecx, ebx
call eax
lea ecx, [ebx + 8]
or edx, 0xffffffff
lock xadd dword [ecx], edx
jne 0x5a685b
mov eax, dword [ebx]
mov edx, dword [eax + 8]
mov ecx, ebx
call edx
push edi
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call ebp
cmp dword [esi + 0x14], 0
jne 0x5a680f
jmp 0x5a6751
Function at 0x5a6910
Capabilities:
Create thread
Resume thread

Disassembly:
push 0xffffffffffffffff
push 0x5d1968
mov eax, dword fs:[0]
push eax
sub esp, 0x10
push ebx
push esi
push edi
mov eax, dword [0x67ff88]
xor eax, esp
push eax
lea eax, [esp + 0x20]
mov dword fs:[0], eax
mov edi, ecx
mov eax, dword [edi + 8]
lea ecx, [eax + 0x1c]
push ecx
push 4
push eax
push 0x5a6880
push 0
push 0
call fcn.0057b419
mov ebx, eax
add esp, 0x18
test ebx, ebx
jne 0x5a697c
lea ecx, [esp + 0x10]
call fcn.00574135
mov dword [esp + 0x1c], ebx
mov dword [esp + 0x10], vtable.boost::thread_resource_error.0
lea edx, [esp + 0x10]
push edx
mov dword [esp + 0x2c], ebx
call fcn.0042ade5
mov eax, dword [edi + 8]
add eax, 4
mov ecx, 1
lock xadd dword [eax], ecx
mov esi, dword [edi + 8]
mov eax, dword [esi + 8]
add esi, 8
test eax, eax
je 0x5a69a4
cmp eax, 0xffffffff
je 0x5a69a4
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [esi], ebx
mov edx, dword [edi + 8]
mov eax, dword [edx + 8]
push eax
call dword [sym.imp.KERNEL32.dll_ResumeThread]
mov ecx, dword [esp + 0x20]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
add esp, 0x1c
ret
Function at 0x5aa780
Capabilities:
Encode data using xor

Disassembly:
mov eax, dword [esp + 8]
sub esp, 0x20
cdq
and edx, 0xf
add eax, edx
sar eax, 4
test eax, eax
jle 0x5aa831
mov ecx, dword [esp + 0x2c]
push ebx
push ebp
push esi
push edi
mov edi, dword [esp + 0x34]
sub edi, ecx
mov esi, ecx
mov dword [esp + 0x3c], edi
mov dword [esp + 0x38], eax
jmp 0x5aa7b6
mov edi, dword [esp + 0x3c]
lea ecx, [esp + 0x10]
add edi, esi
mov ebp, 4
xor eax, eax
mov ebx, dword [ecx]
xor edx, edx
mov dl, byte [edi + eax]
shl ebx, 8
xor edx, ebx
inc eax
cmp eax, 4
mov dword [ecx], edx
jl 0x5aa7c3
add ecx, 4
add edi, 4
dec ebp
jne 0x5aa7c1
mov eax, dword [esp + 0x40]
lea ecx, [esp + 0x20]
push eax
lea edx, [esp + 0x14]
push ecx
push edx
call fcn.005a95f0
add esp, 0xc
lea ebp, [esp + 0x20]
mov edx, 4
mov edi, dword [ebp]
xor eax, eax
mov ecx, 0x18
mov ebx, edi
sub ecx, eax
add eax, 8
shr ebx, cl
inc esi
cmp eax, 0x20
mov byte [esi - 1], bl
jl 0x5aa805
add ebp, 4
dec edx
jne 0x5aa800
mov eax, dword [esp + 0x38]
dec eax
mov dword [esp + 0x38], eax
jne 0x5aa7b2
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x20
ret

Function at 0x5aa840
Capabilities:
Encode data using xor

Disassembly:
sub esp, 0x40
mov eax, dword [esp + 0x48]
mov dword [esp], 0x12345678
cdq
and edx, 0xf
mov dword [esp + 4], 0x56785678
add eax, edx
mov dword [esp + 8], 0x9abc5678
sar eax, 4
test eax, eax
mov dword [esp + 0xc], 0xdeff5678
jle 0x5aa925
mov ecx, dword [esp + 0x4c]
push ebx
push ebp
push esi
mov esi, dword [esp + 0x50]
push edi
sub esi, ecx
mov edi, ecx
mov dword [esp + 0x5c], esi
mov dword [esp + 0x58], eax
jmp 0x5aa896
mov esi, dword [esp + 0x5c]
lea ecx, [esp + 0x20]
add esi, edi
mov ebp, 4
xor eax, eax
mov ebx, dword [ecx]
xor edx, edx
mov dl, byte [esi + eax]
shl ebx, 8
xor edx, ebx
inc eax
cmp eax, 4
mov dword [ecx], edx
jl 0x5aa8a3
add ecx, 4
add esi, 4
dec ebp
jne 0x5aa8a1
mov eax, dword [esp + 0x60]
lea ecx, [esp + 0x30]
push eax
lea edx, [esp + 0x24]
push ecx
push edx
call fcn.005a95f0
add esp, 0xc
xor esi, esi
mov eax, dword [esp + esi + 0x30]
mov ecx, dword [esp + esi + 0x10]
xor eax, ecx
mov ecx, dword [esp + esi + 0x20]
mov dword [esp + esi + 0x40], eax
mov ebp, eax
mov dword [esp + esi + 0x10], ecx
xor eax, eax
mov ecx, 0x18
mov edx, ebp
sub ecx, eax
add eax, 8
shr edx, cl
inc edi
cmp eax, 0x20
mov byte [edi - 1], dl
jl 0x5aa8f3
add esi, 4
cmp esi, 0x10
jl 0x5aa8d9
mov eax, dword [esp + 0x58]
dec eax
mov dword [esp + 0x58], eax
jne 0x5aa892
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x40
ret