joyce8/EMBER2024-capa huggingface dataset:
Function at 0x422e90
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x14
mov eax, dword [ebp + 8]
push ebx
mov ebx, dword [ebp + 0xc]
push esi
mov dword [esp + 0x14], 0
cmp dword [eax + 0x14], 8
push edi
mov edi, dword [ebp + 0x10]
jb 0x422eb5
mov eax, dword [eax]
push 0
push 0
push 2
push 0
push 0
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
xor ecx, ecx
mov dword [esp + 0x10], ecx
test esi, esi
je 0x422f54
lea ecx, [esp + 0x10]
call fcn.00423700
cmp esi, 0xffffffff
je 0x422f21
mov dword [esp + 0x10], esi
call fcn.00427060
mov dword [esp + 0x1c], eax
mov eax, dword [ebp + 4]
mov ecx, dword [0x4b71f8]
mov dword [esp + 0x14], eax
test ecx, ecx
jne 0x422f0e
call fcn.00427170
mov ecx, dword [0x4b71f8]
push dword [esp + 0x1c]
mov eax, dword [ecx]
lea edx, [esp + 0x14]
push dword [esp + 0x18]
push edx
push esi
call dword [eax + 4]
mov ecx, dword [esp + 0x10]
test ecx, ecx
je 0x422f54
cmp ecx, 0xffffffff
je 0x422f54
push 0
lea eax, [esp + 0x1c]
push eax
push edi
push ebx
push ecx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x422f50
mov esi, dword [esp + 0x18]
cmp esi, edi
jne 0x422f50
mov ecx, dword [esp + 0x10]
jmp 0x422f57
mov ecx, dword [esp + 0x10]
or esi, 0xffffffff
test ecx, ecx
je 0x422fb5
cmp ecx, 0xffffffff
je 0x422fb5
call fcn.00427060
mov ebx, dword [ebp + 4]
mov edi, eax
mov ecx, dword [0x4b71f8]
mov eax, dword [esp + 0x10]
mov dword [esp + 0x14], eax
test ecx, ecx
jne 0x422f87
call fcn.00427170
mov ecx, dword [0x4b71f8]
mov eax, dword [ecx]
lea edx, [esp + 0x10]
push edi
push ebx
push edx
push dword [esp + 0x20]
call dword [eax + 8]
mov ecx, dword [0x4b71f8]
mov edi, dword [esp + 0x10]
test ecx, ecx
jne 0x422fb0
call fcn.00427170
mov ecx, dword [0x4b71f8]
mov edx, dword [ecx]
push edi
call dword [edx]
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x423440
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x25c
mov eax, dword [0x4b1810]
xor eax, ebp
mov dword [ebp - 4], eax
xor eax, eax
push esi
mov word [ebp - 0x210], ax
mov esi, ecx
lea eax, [ebp - 0x210]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
test eax, eax
je 0x423539
cmp eax, 0x104
ja 0x423539
lea eax, [ebp - 0x210]
push eax
lea ecx, [ebp - 0x240]
call fcn.00418f70
lea eax, [ebp - 0x228]
push eax
lea eax, [ebp - 0x240]
push eax
lea ecx, [ebp - 0x258]
call fcn.0041d0a0
mov ecx, eax
call fcn.0041d9c0
cmp esi, eax
je 0x4234c6
push 0xffffffffffffffff
push 0
push eax
mov ecx, esi
call fcn.00419cb0
cmp dword [ebp - 0x214], 8
jb 0x4234dd
push dword [ebp - 0x228]
call fcn.0048d7cb
add esp, 4
xor eax, eax
mov dword [ebp - 0x214], 7
cmp dword [ebp - 0x244], 8
mov dword [ebp - 0x218], 0
mov word [ebp - 0x228], ax
jb 0x423511
push dword [ebp - 0x258]
call fcn.0048d7cb
add esp, 4
cmp dword [ebp - 0x22c], 8
jb 0x423528
push dword [ebp - 0x240]
call fcn.0048d7cb
add esp, 4
mov al, 1
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00491511
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 4]
xor al, al
xor ecx, ebp
pop esi
call fcn.00491511
mov esp, ebp
pop ebp
ret

Function at 0x423550
Capabilities:
Delete directory
Delete file

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2f0
mov eax, dword [0x4b1810]
xor eax, ebp
mov dword [ebp - 4], eax
xorps xmm0, xmm0
mov word [ebp - 0x40], 0
push ebx
push esi
lea edx, [ebp - 0x48]
movlpd qword [ebp - 0x48], xmm0
mov esi, ecx
movlpd qword [ebp - 0x38], xmm0
movlpd qword [ebp - 0x30], xmm0
movlpd qword [ebp - 0x28], xmm0
call fcn.00422ca0
test al, al
je 0x42368a
cmp byte [ebp - 0x40], 0
jne 0x4235be
cmp dword [esi + 0x14], 8
jb 0x4235a2
mov esi, dword [esi]
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
setne al
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00491511
mov esp, ebp
pop ebp
ret
sub esp, 8
lea ecx, [ebp - 0x2f0]
mov bl, 1
push esi
call fcn.004304d0
lea eax, [ebp - 0x1c]
push eax
lea ecx, [ebp - 0x2f0]
call fcn.00430650
cmp dword [ebp - 0xc], 0
je 0x423625
lea ecx, [ebp - 0x1c]
call fcn.00423550
and bl, al
lea ecx, [ebp - 0x2f0]
lea eax, [ebp - 0x38]
push eax
call fcn.00430650
lea ecx, [ebp - 0x1c]
cmp ecx, eax
je 0x42360e
push 0xffffffffffffffff
push 0
push eax
call fcn.00419cb0
cmp dword [ebp - 0x24], 8
jb 0x42361f
push dword [ebp - 0x38]
call fcn.0048d7cb
add esp, 4
cmp dword [ebp - 0xc], 0
jne 0x4235e4
cmp dword [ebp - 8], 8
jb 0x423636
push dword [ebp - 0x1c]
call fcn.0048d7cb
add esp, 4
xor eax, eax
mov dword [ebp - 8], 7
mov dword [ebp - 0xc], 0
mov word [ebp - 0x1c], ax
test bl, bl
je 0x42367f
cmp dword [esi + 0x14], 8
jb 0x423656
mov esi, dword [esi]
push esi
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
test eax, eax
lea ecx, [ebp - 0x2f0]
setne bl
call fcn.004305a0
mov al, bl
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00491511
mov esp, ebp
pop ebp
ret
lea ecx, [ebp - 0x2f0]
call fcn.004305a0
mov ecx, dword [ebp - 4]
xor al, al
pop esi
xor ecx, ebp
pop ebx
call fcn.00491511
mov esp, ebp
pop ebp
ret
Function at 0x424c00
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xb8
push ebx
push esi
mov esi, ecx
mov dword [ebp - 4], 0
cmp byte [esi], 0
je 0x424c21
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
jmp 0x424c24
mov eax, dword [esi + 4]
push 1
push eax
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
test eax, eax
setne bl
test bl, bl
je 0x424cab
cmp byte [ebp + 0xc], 0
je 0x424d2e
cmp byte [esi], 0
je 0x424c4d
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
jmp 0x424c50
mov eax, dword [esi + 4]
push 0xea60
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
test eax, eax
je 0x424d2e
cmp dword [0x4b7158], 2
jg 0x424ca5
push 2
push 0x89
push 0x412c58
lea ecx, [ebp - 0xb8]
mov dword [ebp - 4], 2
call fcn.0041f5a0
push 1
add eax, 8
push 0x412c9c
push eax
call fcn.0041b5a0
add esp, 8
mov ecx, eax
call fcn.0041fee0
test byte [ebp - 4], 2
jmp 0x424d21
cmp dword [0x4b7158], 2
jg 0x424d1d
push 1
push 2
lea ecx, [ebp - 0xb0]
mov dword [ebp - 4], 4
mov dword [ebp - 0xb8], 2
call fcn.0041eb80
mov dword [ebp - 0x14], 0x412c58
mov dword [ebp - 0x10], 0x90
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 0x90
push 0x412c58
lea ecx, [ebp - 0xb8]
mov dword [ebp - 0xc], eax
call fcn.0041f870
push 1
lea eax, [ebp - 0xb0]
push 0x412cc8
push eax
call fcn.0041b5a0
add esp, 8
mov ecx, eax
call fcn.0041fee0
test byte [ebp - 4], 4
je 0x424d2e
lea ecx, [ebp - 0xb8]
call fcn.0041f5f0
pop esi
mov al, bl
pop ebx
mov esp, ebp
pop ebp
ret 8
Function at 0x428430
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
push ebx
push esi
mov ebx, edx
mov esi, ecx
push edi
test ebx, ebx
je 0x428457
cmp dword [ebx + 0x14], 0x10
mov dword [ebx + 0x10], 0
jb 0x428452
mov eax, dword [ebx]
jmp 0x428454
mov eax, ebx
mov byte [eax], 0
call fcn.0041da20
test al, al
je 0x428469
xor al, al
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push 0x412de4
push esi
call fcn.00422dd0
mov edi, eax
add esp, 8
mov dword [ebp - 0xc], edi
test edi, edi
je 0x428460
push 0x10000
call fcn.0048e965
add esp, 4
mov dword [ebp - 8], 0
mov esi, eax
push edi
push 0x10000
push 1
push esi
call fcn.00493e0a
mov edi, eax
add esp, 0x10
mov dword [ebp - 0x10], edi
test edi, edi
je 0x428502
mov eax, dword [ebp + 8]
test ebx, ebx
je 0x4284d5
sub eax, dword [ebp - 8]
lea edx, [ebp - 0x10]
cmp eax, edi
mov dword [ebp - 0x14], eax
lea ecx, [ebp - 0x14]
cmovae ecx, edx
push dword [ecx]
mov ecx, ebx
push esi
call fcn.00419870
mov eax, dword [ebp + 8]
mov ecx, dword [ebp - 8]
sub eax, ecx
cmp eax, edi
jb 0x428518
push dword [ebp - 0xc]
add ecx, edi
push 0x10000
push 1
push esi
mov dword [ebp - 8], ecx
call fcn.00493e0a
mov edi, eax
add esp, 0x10
mov eax, dword [ebp + 8]
mov dword [ebp - 0x10], edi
test edi, edi
jne 0x4284b3
mov ebx, dword [ebp - 0xc]
push ebx
call fcn.00493eb6
add esp, 4
test eax, eax
jne 0x42851b
mov byte [ebp - 1], 1
jmp 0x42851f
mov ebx, dword [ebp - 0xc]
mov byte [ebp - 1], 0
push ebx
call fcn.004942d8
add esp, 4
test esi, esi
je 0x428535
push esi
call fcn.0048e960
add esp, 4
mov al, byte [ebp - 1]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x42cef0
Capabilities:
Query environment variable
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
mov eax, 0x1010
call fcn.0048e9a0
mov eax, dword [0x4b1810]
xor eax, esp
mov dword [esp + 0x100c], eax
mov eax, dword [ebp + 8]
lea edx, [esp]
push esi
push edi
mov edi, dword [ebp + 0xc]
push edx
lea edx, [esp + 0x14]
mov dword [esp + 0xc], 0
push edx
lea edx, [esp + 0x14]
mov dword [esp + 0x14], 1
push edx
push 0
push eax
push dword [ecx]
mov dword [esp + 0x20], 0x800
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
mov esi, eax
test esi, esi
jne 0x42d037
mov ecx, dword [esp + 0xc]
cmp ecx, 1
jne 0x42cfc4
cmp word [esp + 0x10], ax
jne 0x42cf88
xor ecx, ecx
lea eax, [esp + 0x10]
push ecx
push eax
mov ecx, edi
call fcn.0041a8b0
mov eax, esi
pop edi
pop esi
mov ecx, dword [esp + 0x100c]
xor ecx, esp
call fcn.00491511
mov esp, ebp
pop ebp
ret 8
lea ecx, [esp + 0x10]
lea edx, [ecx + 2]
nop
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x42cf90
sub ecx, edx
lea eax, [esp + 0x10]
sar ecx, 1
push ecx
push eax
mov ecx, edi
call fcn.0041a8b0
mov eax, esi
pop edi
pop esi
mov ecx, dword [esp + 0x100c]
xor ecx, esp
call fcn.00491511
mov esp, ebp
pop ebp
ret 8
cmp ecx, 2
jne 0x42d032
push 0x400
lea eax, [esp + 0x814]
push eax
lea eax, [esp + 0x18]
push eax
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
mov dword [esp + 8], eax
test eax, eax
je 0x42d017
cmp eax, 0x400
ja 0x42d017
lea eax, [esp + 0x810]
mov ecx, edi
push eax
call fcn.0041ded0
mov eax, esi
pop edi
pop esi
mov ecx, dword [esp + 0x100c]
xor ecx, esp
call fcn.00491511
mov esp, ebp
pop ebp
ret 8
mov eax, 0xea
pop edi
pop esi
mov ecx, dword [esp + 0x100c]
xor ecx, esp
call fcn.00491511
mov esp, ebp
pop ebp
ret 8
mov eax, 0x3f4
mov ecx, dword [esp + 0x1014]
pop edi
pop esi
xor ecx, esp
call fcn.00491511
mov esp, ebp
pop ebp
ret 8
Function at 0x42e730
Capabilities:
Inspect section memory permissions

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
xor eax, eax
mov dword [ebp - 8], 0
push ebx
mov ebx, dword [ebp + 8]
test bl, 1
push esi
mov esi, ecx
mov ecx, 3
cmovne eax, ecx
test bl, 2
mov ecx, 1
cmovne eax, ecx
mov ecx, ebx
and ecx, 4
mov dword [ebp - 8], ecx
mov ecx, 4
cmovne eax, ecx
test bl, 8
mov ecx, 2
cmovne eax, ecx
mov dword [ebp + 8], eax
push edi
test bl, 0x10
je 0x42e789
mov dword [ebp + 8], 5
jmp 0x42e791
test eax, eax
je 0x42e8ee
xor edx, edx
mov edi, 0x40000000
test bl, 0x40
mov eax, 4
cmovne edx, edi
test bl, 0x80
cmovne edx, eax
test bl, 0x20
je 0x42e7b4
or edx, 0x80000000
test ebx, 0x4000
je 0x42e7c2
or edx, 0x100
test ebx, 0x40000
je 0x42e7d0
or edx, 0x20000000
mov ecx, ebx
shr ecx, 8
not ecx
and ecx, 1
test ebx, 0x200
jne 0x42e7e5
or ecx, 2
test ebx, 0x8000
je 0x42e7ef
or ecx, eax
xor eax, eax
test ebx, 0x400
cmovne eax, edi
test ebx, 0x800
je 0x42e807
or eax, 0x100
test ebx, 0x1000
je 0x42e812
or eax, 2
test ebx, 0x2000
je 0x42e81f
or eax, 0x4000000
test ebx, 0x20000
je 0x42e82c
or eax, 0x2000000
cmp dword [esi + 0x18], 8
lea edi, [esi + 4]
jb 0x42e837
mov edi, dword [edi]
push 0
push eax
push dword [ebp + 8]
push 0
push ecx
push edx
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
cmp dword [esi], edi
je 0x42e890
mov ecx, esi
call fcn.00423700
test edi, edi
je 0x42e890
cmp edi, 0xffffffff
je 0x42e890
mov dword [esi], edi
call fcn.00427060
mov dword [ebp + 8], eax
mov eax, dword [ebp + 4]
mov ecx, dword [0x4b71f8]
mov dword [ebp - 4], eax
test ecx, ecx
jne 0x42e883
call fcn.00427170
mov ecx, dword [0x4b71f8]
push dword [ebp + 8]
mov eax, dword [ecx]
push dword [ebp - 4]
push esi
push edi
call dword [eax + 4]
mov eax, dword [esi]
test eax, eax
je 0x42e8de
cmp eax, 0xffffffff
je 0x42e8de
mov eax, ebx
mov dword [esi + 0x20], 0
shr eax, 0xa
and al, 1
cmp dword [ebp - 8], 0
mov byte [esi + 0x25], al
je 0x42e8cc
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
setne al
mov byte [esi + 0x24], al
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
test bl, 0xa
je 0x42e8ee
mov byte [esi + 0x24], 1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, eax
call fcn.0042e500
mov dword [esi + 0x20], eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
Function at 0x42f740
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push ebx
push esi
mov ebx, ecx
mov dword [ebp - 4], 0
mov esi, edx
push edi
test ebx, ebx
je 0x42f7ac
cmp dword [0x4b83e0], 0
jne 0x42f799
push 0x44
call fcn.0048d755
add esp, 4
test eax, eax
je 0x42f77a
mov ecx, eax
call fcn.004265e0
mov edx, eax
jmp 0x42f77c
xor edx, edx
mov ecx, edx
mov edi, 0x4b83e0
xor eax, eax
lock cmpxchg dword [edi], ecx
test eax, eax
je 0x42f799
test edx, edx
je 0x42f799
push ecx
mov ecx, edx
call fcn.004265a0
mov eax, dword [0x4b83e0]
cmp dword [eax], 1
jl 0x42f7ac
mov dword [ebp - 4], 0x10000
jmp 0x42f7ae
xor ebx, ebx
push 8
call fcn.0048d755
add esp, 4
mov edi, eax
push 0
push dword [ebp - 4]
mov dword [edi], esi
mov esi, dword [ebp + 8]
test esi, esi
push edi
push 0x42f5f0
push ebx
setne cl
push 0
mov byte [edi + 4], cl
call dword [sym.imp.KERNEL32.dll_CreateThread]
test eax, eax
jne 0x42f7f1
push edi
call fcn.0048d7cb
add esp, 4
xor al, al
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
test esi, esi
je 0x42f807
mov dword [esi], eax
mov al, 1
mov dword [esi + 4], 0
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
mov al, 1
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x4394c0
Capabilities:
Get thread local storage value

Disassembly:
push esi
mov esi, ecx
call fcn.00439810
mov eax, dword [0x4b29a8]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov edx, eax
test edx, edx
jne 0x4394e1
call fcn.0043c670
mov edx, eax
mov eax, dword [0x4b82c4]
cmp dword [edx + eax*4], 0
jne 0x439529
push 0x70
call fcn.0048d755
add esp, 4
test eax, eax
je 0x439506
push esi
mov ecx, eax
call fcn.00439290
mov esi, eax
jmp 0x439508
xor esi, esi
mov eax, dword [0x4b29a8]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, eax
test ecx, ecx
jne 0x439521
call fcn.0043c670
mov ecx, eax
mov eax, dword [0x4b82c4]
mov dword [ecx + eax*4], esi
pop esi
ret

Function at 0x439530
Capabilities:
Get thread local storage value

Disassembly:
cmp byte [0x4b82c0], 0
push ebx
push esi
push edi
jne 0x439542
xor eax, eax
pop edi
pop esi
pop ebx
ret
mov eax, dword [0x4b29a8]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, eax
test ecx, ecx
jne 0x43955b
call fcn.0043c670
mov ecx, eax
mov eax, dword [0x4b82c4]
mov eax, dword [ecx + eax*4]
test eax, eax
jne 0x4395f2
mov ecx, 0x4b82a4
xor edi, edi
xor ebx, ebx
call fcn.0042e200
mov esi, eax
push esi
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov ecx, dword [0x4b8298]
test ecx, ecx
je 0x43959b
mov eax, dword [ecx + 4]
mov edi, ecx
mov dword [0x4b8298], eax
mov dword [ecx + 4], ebx
jmp 0x4395a8
mov ebx, dword [0x4b82d8]
inc ebx
mov dword [0x4b82d8], ebx
push esi
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
test edi, edi
jne 0x4395cf
push 0x70
call fcn.0048d755
add esp, 4
test eax, eax
je 0x4395cd
push ebx
mov ecx, eax
call fcn.00439350
mov edi, eax
jmp 0x4395cf
xor edi, edi
mov eax, dword [0x4b29a8]
push eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, eax
test ecx, ecx
jne 0x4395e8
call fcn.0043c670
mov ecx, eax
mov eax, dword [0x4b82c4]
mov dword [ecx + eax*4], edi
mov eax, edi
pop edi
pop esi
pop ebx
ret

Function at 0x43b520
Capabilities:
Generate random numbers via rtlgenrandom

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc4
push ebx
push esi
xor ebx, ebx
mov dword [ebp - 8], ecx
mov dword [ebp - 4], ebx
mov esi, 8
push edi
mov dword [ebp - 0xc], esi
mov dword [ebp - 4], 0xffffffff
lea edx, [ebp - 0xc]
cmp esi, 0xffffffff
lea eax, [ebp - 4]
cmovbe eax, edx
mov edi, dword [eax]
push edi
push ecx
call dword [sym.imp.ADVAPI32.dll_SystemFunction036]
test al, al
jne 0x43b566
cmp byte [0x4b82e4], al
jne 0x43b591
int3
test bl, 1
je 0x43b579
lea ecx, [ebp - 0xc0]
and ebx, 0xfffffffe
call fcn.0041f5f0
mov ecx, dword [ebp - 8]
sub esi, edi
add ecx, edi
mov dword [ebp - 0xc], esi
mov dword [ebp - 8], ecx
test esi, esi
jne 0x43b543
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push 1
call fcn.0048ec7d
int3
Function at 0x43b7a0
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x44
mov eax, dword [0x4b1810]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 0xc]
push esi
push edi
mov edi, dword [ebp + 8]
mov dword [ebp - 0x3c], edi
test edi, edi
jne 0x43b7c5
mov dword [ebp - 0x38], edi
jmp 0x43b7e4
cmp byte [edi], 0
jne 0x43b7d3
mov dword [ebp - 0x38], 0
jmp 0x43b7e4
mov ecx, edi
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x43b7d8
sub ecx, edx
mov dword [ebp - 0x38], ecx
lea eax, [ebp - 0x3c]
push eax
lea eax, [ebp - 0x1c]
push eax
call fcn.00427d30
add esp, 8
cmp dword [eax + 0x14], 8
jb 0x43b7fc
mov eax, dword [eax]
push 0
push 0
push eax
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
cmp dword [ebp - 8], 8
mov esi, eax
mov dword [ebp - 0x38], esi
jb 0x43b81d
push dword [ebp - 0x1c]
call fcn.0048d7cb
add esp, 4
test esi, esi
jne 0x43b836
xor al, al
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00491511
mov esp, ebp
pop ebp
ret 8
test ebx, ebx
je 0x43b941
xor ecx, ecx
mov eax, esi
mov edx, 2
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0048e965
add esp, 4
mov dword [ebp - 0x44], edi
mov esi, eax
test edi, edi
jne 0x43b867
mov dword [ebp - 0x40], edi
jmp 0x43b884
cmp byte [edi], 0
jne 0x43b875
mov dword [ebp - 0x40], 0
jmp 0x43b884
lea ecx, [edi + 1]
mov al, byte [edi]
inc edi
test al, al
jne 0x43b878
sub edi, ecx
mov dword [ebp - 0x40], edi
lea eax, [ebp - 0x44]
push eax
lea eax, [ebp - 0x1c]
push eax
call fcn.00427d30
add esp, 8
cmp dword [eax + 0x14], 8
jb 0x43b89c
mov eax, dword [eax]
push dword [ebp - 0x38]
push esi
push eax
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
cmp dword [ebp - 8], 8
jb 0x43b8b8
push dword [ebp - 0x1c]
call fcn.0048d7cb
add esp, 4
push esi
lea ecx, [ebp - 0x1c]
call fcn.00418f70
lea eax, [ebp - 0x1c]
push eax
lea eax, [ebp - 0x34]
push eax
call fcn.00427c20
mov edi, eax
add esp, 8
cmp ebx, edi
je 0x43b900
cmp dword [ebx + 0x14], 0x10
jb 0x43b8e7
push dword [ebx]
call fcn.0048d7cb
add esp, 4
mov dword [ebx + 0x14], 0xf
mov ecx, ebx
mov dword [ebx + 0x10], 0
push edi
mov byte [ebx], 0
call fcn.00419750
cmp dword [ebp - 0x20], 0x10
jb 0x43b911
push dword [ebp - 0x34]
call fcn.0048d7cb
add esp, 4
cmp dword [ebp - 8], 8
mov dword [ebp - 0x20], 0xf
mov dword [ebp - 0x24], 0
mov byte [ebp - 0x34], 0
jb 0x43b934
push dword [ebp - 0x1c]
call fcn.0048d7cb
add esp, 4
test esi, esi
je 0x43b941
push esi
call fcn.0048e960
add esp, 4
mov ecx, dword [ebp - 4]
mov al, 1
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00491511
mov esp, ebp
pop ebp
ret 8
Function at 0x43c670
Capabilities:
Allocate thread local storage
Get thread local storage value
Set thread local storage value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x40c
mov eax, dword [0x4b1810]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [0x4b29a8]
mov dword [ebp - 0x40c], 0
mov dword [ebp - 0x40c], ebx
push esi
push edi
cmp ebx, 0xffffffff
jne 0x43c710
mov edi, dword [sym.imp.KERNEL32.dll_TlsAlloc]
call edi
mov esi, dword [sym.imp.KERNEL32.dll_TlsFree]
cmp eax, ebx
je 0x43c6bd
mov ebx, eax
mov dword [ebp - 0x40c], ebx
jmp 0x43c6ee
cmp byte [0x4b82e4], 0
jne 0x43c787
int3
mov ecx, ebx
mov edx, 0x4b29a8
or eax, 0xffffffff
lock cmpxchg dword [edx], ecx
cmp eax, 0xffffffff
je 0x43c710
push ebx
call esi
mov ebx, dword [0x4b29a8]
mov dword [ebp - 0x40c], ebx
push ebx
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
test eax, eax
je 0x43c725
cmp byte [0x4b82e4], 0
jne 0x43c795
int3
push 0x400
lea eax, [ebp - 0x408]
push 0
push eax
call fcn.00448cc7
add esp, 0xc
lea eax, [ebp - 0x408]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
push 0x400
call fcn.0048e965
add esp, 4
lea esi, [ebp - 0x408]
mov ebx, eax
mov ecx, 0x100
mov edi, ebx
rep movsd dword es:[edi], dword [esi]
push ebx
push dword [ebp - 0x40c]
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
mov ecx, dword [ebp - 4]
mov eax, ebx
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00491511
mov esp, ebp
pop ebp
ret
push 1
call fcn.0048ec7d
push 1
call fcn.0048ec7d
push 1
call fcn.0048ec7d
int3

Function at 0x43c7a0
Capabilities:
Set thread local storage value

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x40c
mov eax, dword [0x4b1810]
xor eax, esp
mov dword [esp + 0x408], eax
mov eax, dword [0x4b29a8]
push ebx
push esi
mov ebx, ecx
mov dword [esp + 8], 0
push edi
mov ecx, 0x100
mov dword [esp + 0xc], eax
mov esi, ebx
lea edi, [esp + 0x10]
rep movsd dword es:[edi], dword [esi]
lea ecx, [esp + 0x10]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
push ebx
call fcn.0048e960
add esp, 4
mov edi, 0x100
jmp 0x43c800
mov esi, dword [0x4b82f4]
xor dl, dl
test esi, esi
jle 0x43c838
lea esp, [esp]
mov ecx, dword [esp + esi*4 + 0x10]
test ecx, ecx
je 0x43c833
mov eax, dword [esi*4 + 0x4b7b80]
test eax, eax
je 0x43c833
push ecx
mov dword [esp + esi*4 + 0x14], 0
call eax
add esp, 4
mov dl, 1
dec esi
test esi, esi
jg 0x43c810
dec edi
test edi, edi
jle 0x43c841
test dl, dl
jne 0x43c800
push 0
push dword [esp + 0x10]
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
mov ecx, dword [esp + 0x414]
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.00491511
mov esp, ebp
pop ebp
ret