joyce8/EMBER2024-capa huggingface dataset:
Function at 0x417725
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
cmp dword [ebp + 0xc], 0
push esi
mov esi, ecx
jne 0x417736
xor eax, eax
jmp 0x417752
push 0
lea eax, [ebp - 4]
push eax
push dword [ebp + 0xc]
push dword [ebp + 8]
push dword [esi + 4]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x417757
mov eax, dword [ebp - 4]
pop esi
leave
ret 8
lea ecx, [esi + 0xc]
call fcn.00402cc0
mov esi, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
push esi
push eax
call fcn.00416fcc
int3

Function at 0x4177c9
Capabilities:
Clear file content

Disassembly:
push ebp
mov ebp, esp
push esi
push edi
mov edi, ecx
push 0
push dword [ebp + 0xc]
mov eax, dword [edi]
push dword [ebp + 8]
mov esi, dword [eax + 0x2c]
mov ecx, esi
call dword [0x4455cc]
mov ecx, edi
call esi
push dword [edi + 4]
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
je 0x4177fc
pop edi
pop esi
pop ebp
ret 8
lea ecx, [edi + 0xc]
call fcn.00402cc0
mov esi, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
push esi
push eax
call fcn.00416fcc
int3

Function at 0x4178d0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
mov esi, dword [ebp + 0xc]
push edi
mov edi, ecx
test esi, esi
je 0x4178fb
push 0
lea eax, [ebp - 4]
push eax
push esi
push dword [ebp + 8]
push dword [edi + 4]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x417901
cmp dword [ebp - 4], esi
jne 0x417918
pop edi
pop esi
leave
ret 8
lea ecx, [edi + 0xc]
call fcn.00402cc0
mov esi, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
push esi
push eax
call fcn.00416fcc
lea ecx, [edi + 0xc]
call fcn.00402cc0
push eax
push 0xffffffffffffffff
push 0xd
call fcn.00416c22
int3
Function at 0x418038
Capabilities:
Get file attributes
Get file size

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x50
mov eax, dword [0x4593b4]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov esi, dword [ebp + 8]
mov ebx, ecx
push edi
push 0x128
xor edi, edi
push edi
push esi
call fcn.0042b550
push 0xffffffffffffffff
push dword [ebx + 0xc]
lea eax, [esi + 0x24]
push 0x104
push eax
call fcn.00432ea5
push eax
call fcn.004041ca
mov eax, dword [ebx + 4]
add esp, 0x20
cmp eax, dword [0x4496d0]
je 0x418196
lea ecx, [ebp - 0x48]
push ecx
lea ecx, [ebp - 0x40]
push ecx
lea ecx, [ebp - 0x38]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_GetFileTime]
test eax, eax
je 0x4181aa
lea eax, [ebp - 0x30]
push eax
push dword [ebx + 4]
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
je 0x4181aa
mov eax, dword [ebp - 0x30]
mov ecx, dword [ebp - 0x2c]
mov dword [esi + 0x18], eax
mov dword [esi + 0x1c], ecx
mov eax, dword [ebx + 0xc]
cmp dword [eax - 0xc], edi
je 0x4180f4
mov ecx, dword [ebx + 0x10]
test ecx, ecx
je 0x4180e8
lea edx, [ebp - 0x28]
push edx
push edi
push eax
call fcn.00417e3f
neg eax
sbb eax, eax
and eax, dword [ebp - 0x28]
jmp 0x4180ef
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x4180f6
mov eax, edi
mov ecx, esi
mov dword [ecx + 0x20], eax
lea eax, [ebp - 0x38]
push eax
call fcn.004182e8
test eax, eax
je 0x41811d
push 0xffffffffffffffff
lea eax, [ebp - 0x38]
push eax
lea ecx, [ebp - 0x50]
call fcn.00417cc6
mov ecx, dword [eax]
mov eax, dword [eax + 4]
jmp 0x418121
mov ecx, edi
mov eax, edi
mov dword [esi], ecx
mov dword [esi + 4], eax
lea eax, [ebp - 0x40]
push eax
call fcn.004182e8
test eax, eax
je 0x418148
push 0xffffffffffffffff
lea eax, [ebp - 0x40]
push eax
lea ecx, [ebp - 0x50]
call fcn.00417cc6
mov ecx, dword [eax]
mov eax, dword [eax + 4]
jmp 0x41814c
mov ecx, edi
mov eax, edi
mov dword [esi + 0x10], ecx
mov dword [esi + 0x14], eax
lea eax, [ebp - 0x48]
push eax
call fcn.004182e8
test eax, eax
je 0x418174
push 0xffffffffffffffff
lea eax, [ebp - 0x48]
push eax
lea ecx, [ebp - 0x50]
call fcn.00417cc6
mov edi, dword [eax]
mov ecx, dword [eax + 4]
jmp 0x418176
mov ecx, edi
mov dword [esi + 8], edi
mov dword [esi + 0xc], ecx
mov eax, dword [esi]
or eax, dword [esi + 4]
jne 0x418188
mov dword [esi], edi
mov dword [esi + 4], ecx
mov eax, dword [esi + 0x10]
or eax, dword [esi + 0x14]
jne 0x418196
mov dword [esi + 0x10], edi
mov dword [esi + 0x14], ecx
xor eax, eax
inc eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00429641
leave
ret 4
xor eax, eax
jmp 0x418199
Function at 0x42a5db
Capabilities:
Parse pe header

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

Function at 0x43842c
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x44d630
push 0x44d628
push str.FlsAlloc
push 0x1f
call fcn.004382eb
mov esi, eax
add esp, 0x10
test esi, esi
je 0x438460
push dword [ebp + 8]
mov ecx, esi
call dword [0x4455cc]
call esi
jmp 0x438466
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x4384aa
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x44d640
push 0x44d638
push str.FlsGetValue
push 0x21
call fcn.004382eb
mov esi, eax
add esp, 0x10
test esi, esi
je 0x4384e1
push dword [ebp + 8]
mov ecx, esi
call dword [0x4455cc]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]

Function at 0x4384e9
Capabilities:
Set thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x44d648
push 0x44d640
push str.FlsSetValue
push 0x22
call fcn.004382eb
mov esi, eax
add esp, 0x10
test esi, esi
je 0x438523
push dword [ebp + 0xc]
mov ecx, esi
push dword [ebp + 8]
call dword [0x4455cc]
call esi
pop esi
pop ebp
ret 8
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsSetValue]
Function at 0x43b05a
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 0x43b0f7
push ebx
push esi
call fcn.0043b023
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.00439ca8
add esp, 0x24
mov dword [ebp - 4], eax
test eax, eax
jne 0x43b0a4
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x43b0f6
push edi
push eax
call fcn.00436fad
mov edi, eax
pop ecx
push ebx
test edi, edi
jne 0x43b0c4
call fcn.00436e4b
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x43b0f5
push ebx
push dword [ebp - 4]
push edi
push dword [ebp - 8]
push esi
push ebx
push ebx
call fcn.00439ca8
add esp, 0x20
test eax, eax
jne 0x43b0e3
push edi
call fcn.00436e4b
jmp 0x43b0eb
push ebx
call fcn.00436e4b
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 0x43b0fa
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push esi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
mov esi, eax
test esi, esi
jne 0x43b10b
pop esi
ret
push ebx
push edi
push esi
call fcn.0043b023
mov ebx, eax
sub ebx, esi
and ebx, 0xfffffffe
push ebx
call fcn.00436fad
mov edi, eax
pop ecx
pop ecx
test edi, edi
je 0x43b133
push ebx
push esi
push edi
call fcn.0042afd0
add esp, 0xc
push 0
call fcn.00436e4b
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov eax, edi
pop edi
pop ebx
pop esi
ret

Function at 0x43b503
Capabilities:
Set environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.0043b148
Function at 0x442420
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x44244d
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x44244d
mov edx, 0x10b
xor eax, eax
cmp word [ecx + 0x18], dx
sete al
pop ebp
ret
xor eax, eax
pop ebp
ret
Function at 0x411b2d
Capabilities:
Get common file path
Set current directory

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.0041186a

Function at 0x42a402
Capabilities:
Create thread
Print debug messages

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.0042a189

Function at 0x42c696
Capabilities:
Set environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.0042be70

Function at 0x42c6a1
Capabilities:
Set environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.0042c0ab

Function at 0x29a10f52
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
pushal
call 0x29a10f61
pop dword [ebp - 0xc]
mov eax, 0xfd6d6865
sub eax, 0xd3cc5904
sub dword [ebp - 0xc], eax
mov dword [ebp - 0x1c], 0xed03e045
sub dword [ebp - 0x1c], 0x9eb19afa
mov dword [ebp - 0x18], 0xf5e86154
add dword [ebp - 0x18], 0x3c4aeaf1
mov dword [ebp - 0x14], 0x3243ba9b
add dword [ebp - 0x14], 0x1a088993
mov dword [ebp - 0x10], 0x6524de56
add dword [ebp - 0x10], 0x9adb21aa
lea eax, [ebp - 0x1c]
push eax
mov eax, 0x73026c37
add eax, 0xb69ed455
add eax, dword [ebp - 0xc]
call dword [eax]
mov dword [ebp - 0x1c], 0x127adabe
sub dword [ebp - 0x1c], 0x9e087168
mov dword [ebp - 0x18], 0x22e450a3
add dword [ebp - 0x18], 0x1e8810d2
mov dword [ebp - 0x14], 0x8f193ad3
add dword [ebp - 0x14], 0xd4563199
mov dword [ebp - 0x10], 0xedf4a8b8
sub dword [ebp - 0x10], 0xedf4a8b8
lea ebx, [ebp - 0x1c]
push ebx
push eax
mov eax, 0x78784873
add eax, 0xb128f7d1
add eax, dword [ebp - 0xc]
call dword [eax]
push 0x40
push 0x1000
push 0x38e25
push 0
call eax
mov ecx, 0x838d8448
sub ecx, 0x838d4221
xor ebx, ebx
add ebx, eax
mov edi, 0x158a5cc9
add edi, 0x1417c337
add edi, dword [ebp - 0xc]
mov edx, 0xfcf19a60
sub edx, 0xcc51f864
xor dword [ebp - 4], edi
mov esi, dword [edi]
sub dword [ebp - 8], 0xf3eca92e
xor esi, edx
xor dword [ebp - 4], 0xed669616
mov dword [ebx], esi
sub dword [ebp - 8], edx
add ebx, 4
add edi, 0x36b2a3d4
sub edi, 0x36b2a3d0
loop 0x29a11085
add eax, 0x4dc11771
add eax, 0xb23fe3fe
mov ebx, eax
add eax, 0x774c27c1
add eax, 0x88b3d844
mov ecx, 0x91ee26cb
sub ecx, 0x684e26cb
add ecx, dword [ebp - 0xc]
call ebx
leave
ret
Function at 0x403d61
Capabilities:
Encode data using xor

Disassembly:
push eax
push ebx
mov eax, 0x499
mov ecx, 0x404498
mov bl, byte [ecx]
sub bl, 0xf2
rol bl, 2
sub bl, cl
ror bl, 1
mov byte [ecx], bl
dec ecx
dec eax
jne 0x403d6d
mov eax, 0x261d
mov ecx, 0x403764
mov bl, byte [ecx]
rol bl, 7
ror bl, 2
sub bl, cl
xor bl, 0x91
mov byte [ecx], bl
dec ecx
dec eax
jne 0x403d8a
pop ebx
pop eax
add ecx, 0x2c1a
jmp ecx

Function at 0x40f4a0
Capabilities:
Packed with generic packer

Disassembly:
pushal
mov esi, 0x40b015
lea edi, [esi - 0xa015]
push edi
or ebp, 0xffffffff
jmp 0x40f4c2
mov al, byte [esi]
inc esi
mov byte [edi], al
inc edi
add ebx, ebx
jne 0x40f4c9
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x40f4b8
mov eax, 1
add ebx, ebx
jne 0x40f4db
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc eax, eax
add ebx, ebx
jae 0x40f4d0
jne 0x40f4ec
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jae 0x40f4d0
xor ecx, ecx
sub eax, 3
jb 0x40f500
shl eax, 8
mov al, byte [esi]
inc esi
xor eax, 0xffffffff
je 0x40f572
mov ebp, eax
add ebx, ebx
jne 0x40f50b
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
add ebx, ebx
jne 0x40f518
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
jne 0x40f53c
inc ecx
add ebx, ebx
jne 0x40f528
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
add ebx, ebx
jae 0x40f51d
jne 0x40f539
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jae 0x40f51d
add ecx, 2
cmp ebp, 0xfffff300
adc ecx, 1
lea edx, [edi + ebp]
cmp ebp, 0xfffffffc
jbe 0x40f55c
mov al, byte [edx]
inc edx
mov byte [edi], al
inc edi
dec ecx
jne 0x40f54d
jmp 0x40f4be
mov eax, dword [edx]
add edx, 4
mov dword [edi], eax
add edi, 4
sub ecx, 4
ja 0x40f55c
add edi, ecx
jmp 0x40f4be
pop esi
mov edi, esi
mov ecx, 0x210
mov al, byte [edi]
inc edi
sub al, 0xe8
cmp al, 1
ja 0x40f57a
cmp byte [edi], 5
jne 0x40f57a
mov eax, dword [edi]
mov bl, byte [edi + 4]
shr ax, 8
rol eax, 0x10
xchg ah, al
sub eax, edi
sub bl, 0xe8
add eax, esi
mov dword [edi], eax
add edi, 5
mov al, bl
loop 0x40f57f
lea edi, [esi + 0xd000]
mov eax, dword [edi]
or eax, eax
je 0x40f5ee
mov ebx, dword [edi + 4]
lea eax, [eax + esi + 0x10710]
add ebx, esi
push eax
add edi, 8
call dword [esi + 0x107c4]
xchg ebp, eax
mov al, byte [edi]
inc edi
or al, al
je 0x40f5ac
mov ecx, edi
push edi
dec eax
repne scasb al, byte es:[edi]
push ebp
call dword [esi + 0x107c8]
or eax, eax
je 0x40f5e8
mov dword [ebx], eax
add ebx, 4
jmp 0x40f5c9
call dword [esi + 0x107d8]
mov ebp, dword [esi + 0x107cc]
lea edi, [esi - 0x1000]
mov ebx, 0x1000
push eax
push esp
push 4
push ebx
push edi
call ebp
lea eax, [edi + 0x19f]
and byte [eax], 0x7f
and byte [eax + 0x28], 0x7f
pop eax
push eax
push esp
push eax
push ebx
push edi
call ebp
pop eax
popal
lea eax, [esp - 0x80]
push 0
cmp esp, eax
jne 0x40f622
sub esp, 0xffffff80
jmp section.UPX0
Function at 0x432000
Capabilities:
Encode data using xor

Disassembly:
pushal
nop
nop
nop
nop
nop
mov eax, section..text
nop
mov ebx, 0x40c7d0
nop
nop
mov ecx, 0x64043e37
nop
nop
nop
test eax, eax
nop
nop
nop
nop
nop
je 0x43204e
nop
xor dword [eax], ecx
nop
nop
nop
nop
inc eax
nop
nop
nop
nop
nop
nop
nop
nop
nop
inc eax
nop
nop
nop
nop
nop
inc eax
nop
inc eax
nop
nop
nop
nop
nop
nop
nop
cmp eax, ebx
nop
jne 0x432024
nop
nop
nop
nop
mov eax, section..data
nop
nop
mov ebx, 0x42f314
nop
mov ecx, 0x3476342d
nop
nop
nop
test eax, eax
nop
nop
je 0x432084
nop
nop
nop
xor dword [eax], ecx
nop
nop
nop
nop
nop
nop
nop
add eax, 4
nop
nop
nop
nop
cmp eax, ebx
jne 0x43206c
nop
nop
nop
nop
popal
nop
nop
nop
nop
nop
jmp 0x431219
Function at 0x1002a910
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x4c
pushal
call 0x1002a91f
pop dword [ebp - 0x3c]
mov eax, 0x1002a91f
sub dword [ebp - 0x3c], eax
mov dword [ebp - 0x4c], 0xba6d3e57
sub dword [ebp - 0x4c], 0x6c1af90c
mov dword [ebp - 0x48], 0x526d23c9
add dword [ebp - 0x48], 0xdfc6287c
mov dword [ebp - 0x44], 0xff4d8153
sub dword [ebp - 0x44], 0xb3013d25
mov dword [ebp - 0x40], 0x2e9b04f5
add dword [ebp - 0x40], 0xd164fb0b
lea eax, [ebp - 0x4c]
push eax
mov eax, sym.imp.kernel32.dll_GetModuleHandleA
add eax, dword [ebp - 0x3c]
call dword [eax]
mov dword [ebp - 0x4c], 0xdedd2c54
sub dword [ebp - 0x4c], 0x6a6ac2fe
mov dword [ebp - 0x48], 0xdee05f03
sub dword [ebp - 0x48], 0x9d73fd8e
mov dword [ebp - 0x44], 0x8843d14f
add dword [ebp - 0x44], 0xdb2b9b1d
mov dword [ebp - 0x40], 0x246cff
sub dword [ebp - 0x40], 0x246cff
lea ebx, [ebp - 0x4c]
push ebx
push eax
mov eax, sym.imp.kernel32.dll_GetProcAddress
add eax, dword [ebp - 0x3c]
call dword [eax]
push 0x40
push 0x1000
push 0x4999f
push 0
call eax
mov ecx, 0xd29036f7
sub ecx, 0xd28fe320
mov edi, eax
mov ebx, 0x837a94b3
add ebx, 0x8c8ad94d
add ebx, dword [ebp - 0x3c]
mov edx, 0x15058afc
sub edx, 0xb037af0f
mov esi, dword [ebx]
mov dword [ebp - 0x38], 0x1a4785d4
xor esi, edx
add dword [ebp - 0x10], ecx
mov dword [edi], esi
xor dword [ebp - 0x14], 0x7c1bfa1b
add edi, 4
add ebx, 0xcfc81725
sub ebx, 0xcfc81721
loop 0x1002aa32
add eax, 0x4807b1fb
add eax, 0xb7f99034
mov ebx, eax
add eax, 0xf7998ba7
add eax, 0x866745e
mov ecx, 0x24911592
add ecx, 0xeb6eea6e
add ecx, dword [ebp - 0x3c]
call ebx
leave
ret
Function at 0x1002b710
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x1003df35
mov eax, dword fs:[0]
push eax
sub esp, 0x50
mov eax, dword [0x1004f37c]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 0xc]
mov esi, dword [ebp + 8]
push 1
push eax
lea eax, [ebp - 0x28]
mov dword [ebp - 0x5c], esi
push eax
call fcn.1002a910
add esp, 0xc
cmp dword [ebp - 0x14], 8
lea eax, [ebp - 0x28]
push 0
cmovae eax, dword [ebp - 0x28]
push 0
push eax
mov dword [ebp - 4], 0
call dword [sym.imp.kernel32.dll_GetEnvironmentVariableW]
mov edi, eax
test edi, edi
jg 0x1002b7e7
mov dword [esi + 0x10], 0
mov dword [esi + 0x14], 0xf
mov byte [esi], 0
mov dword [esi + 0x10], 0
mov byte [esi], 0
mov edx, dword [ebp - 0x14]
cmp edx, 8
jb 0x1002b7ca
mov ecx, dword [ebp - 0x28]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x1002b7c0
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x1002b91b
push edx
push ecx
call fcn.1002a910
add esp, 8
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.10038620
mov esp, ebp
pop ebp
ret
xor ecx, ecx
mov edx, 2
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.1002a910
add esp, 4
mov dword [ebp - 0x5c], eax
cmp dword [ebp - 0x14], 8
lea eax, [ebp - 0x28]
cmovae eax, dword [ebp - 0x28]
push edi
mov edi, dword [ebp - 0x5c]
push edi
push eax
call dword [sym.imp.kernel32.dll_GetEnvironmentVariableW]
mov ecx, edi
mov dword [ebp - 0x30], 0
xor eax, eax
mov dword [ebp - 0x2c], 7
mov word [ebp - 0x40], ax
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x1002b833
sub ecx, edx
sar ecx, 1
push ecx
push edi
lea ecx, [ebp - 0x40]
call fcn.1002a910
push edi
mov byte [ebp - 4], 1
call fcn.10038743
push 1
lea eax, [ebp - 0x40]
push eax
lea eax, [ebp - 0x58]
push eax
call fcn.1002a910
movups xmm0, xmmword [ebp - 0x58]
mov edx, dword [ebp - 0x2c]
add esp, 0x10
mov dword [esi + 0x10], 0
mov dword [esi + 0x14], 0
mov byte [ebp - 0x58], 0
movups xmmword [esi], xmm0
movq xmm0, qword [ebp - 0x48]
movq qword [esi + 0x10], xmm0
mov dword [ebp - 0x48], 0
mov dword [ebp - 0x44], 0xf
cmp edx, 8
jb 0x1002b8cf
mov ecx, dword [ebp - 0x40]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x1002b8c5
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x1002b91b
push edx
push ecx
call fcn.1002a910
add esp, 8
mov edx, dword [ebp - 0x14]
xor eax, eax
mov dword [ebp - 0x30], 0
mov dword [ebp - 0x2c], 7
mov word [ebp - 0x40], ax
cmp edx, 8
jb 0x1002b7ca
mov ecx, dword [ebp - 0x28]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x1002b7c0
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x1002b7c0
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
Function at 0x10031820
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x30
mov eax, dword [0x1004f37c]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
push esi
mov esi, ecx
cmp ebx, 0xffffffff
jne 0x10031850
pop esi
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.10038620
mov esp, ebp
pop ebp
ret 4
mov eax, dword [esi + 0x20]
mov eax, dword [eax]
test eax, eax
je 0x10031880
mov edx, dword [esi + 0x30]
mov edx, dword [edx]
add edx, eax
cmp eax, edx
jae 0x10031880
call dword [sym.imp.MSVCP140.dll_protected:_char____thiscall_std::basic_streambuf_char__struct_std::char_traits_char__::_Pninc_void_]
pop esi
mov byte [eax], bl
mov eax, ebx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.10038620
mov esp, ebp
pop ebp
ret 4
cmp dword [esi + 0x4c], 0
push edi
je 0x1003197a
mov edi, dword [esi + 0xc]
lea eax, [esi + 0x3c]
cmp dword [edi], eax
jne 0x100318a9
mov edx, dword [esi + 0x54]
mov ecx, dword [esi + 0x50]
sub edx, ecx
mov dword [edi], ecx
mov eax, dword [esi + 0x1c]
mov dword [eax], ecx
mov eax, dword [esi + 0x2c]
mov dword [eax], edx
mov ecx, dword [esi + 0x38]
test ecx, ecx
jne 0x100318dd
push dword [esi + 0x4c]
movsx eax, bl
push eax
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fputc]
add esp, 8
or ecx, 0xffffffff
cmp eax, ecx
cmovne ecx, ebx
pop edi
pop esi
mov eax, ecx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.10038620
mov esp, ebp
pop ebp
ret 4
lea eax, [ebp - 0x2c]
mov byte [ebp - 0x28], bl
push eax
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x30]
push eax
lea eax, [ebp - 0x27]
push eax
lea eax, [ebp - 0x28]
push eax
lea eax, [esi + 0x40]
push eax
call dword [sym.imp.MSVCP140.dll_public:_int___thiscall_std::codecvt_char__char__struct__Mbstatet_::out_struct__Mbstatet___char_const___char_const___char_const____char___char___char___const]
test eax, eax
js 0x1003197a
cmp eax, 1
jle 0x1003193b
cmp eax, 3
jne 0x1003197a
push dword [esi + 0x4c]
push dword [ebp - 0x28]
call fcn.1002a910
add esp, 8
or ecx, 0xffffffff
test al, al
cmovne ecx, ebx
pop edi
pop esi
mov eax, ecx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.10038620
mov esp, ebp
pop ebp
ret 4
mov edi, dword [ebp - 0x2c]
lea eax, [ebp - 0x24]
sub edi, eax
je 0x10031959
push dword [esi + 0x4c]
push edi
push 1
push eax
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
add esp, 0x10
cmp edi, eax
jne 0x1003197a
lea eax, [ebp - 0x28]
mov byte [esi + 0x3d], 1
cmp dword [ebp - 0x30], eax
je 0x1003197a
pop edi
pop esi
mov eax, ebx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.10038620
mov esp, ebp
pop ebp
ret 4
mov ecx, dword [ebp - 4]
or eax, 0xffffffff
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.10038620
mov esp, ebp
pop ebp
ret 4
Function at 0x10036f80
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x1003ecf8
mov eax, dword fs:[0]
push eax
sub esp, 8
push ebx
push esi
push edi
mov eax, dword [0x1004f37c]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [0x1004f338]
cmp eax, 0xffffffff
jne 0x10036fb6
xor ebx, ebx
jmp 0x10036fbf
push eax
call dword [sym.imp.kernel32.dll_TlsGetValue]
mov ebx, eax
mov dword [ebp - 0x10], ebx
mov dword [ebp - 4], 0
test ebx, ebx
je 0x10036fff
mov eax, dword [ebx + 0x18]
mov esi, dword [ebx + 0xc]
test eax, eax
jne 0x1003703e
test esi, esi
jne 0x10037042
push 0x10035760
push 0x10050e58
call fcn.1002a910
mov eax, dword [0x1004f338]
add esp, 8
cmp eax, 0xffffffff
je 0x10036fff
push esi
push eax
call dword [sym.imp.kernel32.dll_TlsSetValue]
mov dword [ebp - 4], 1
test ebx, ebx
je 0x1003702c
or eax, 0xffffffff
lock xadd dword [ebx + 4], eax
jne 0x1003702c
mov eax, dword [ebx]
mov ecx, ebx
push 0
call dword [eax]
push ebx
push 0
call dword [sym.imp.kernel32.dll_GetProcessHeap]
push eax
call dword [sym.imp.kernel32.dll_HeapFree]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
test esi, esi
je 0x10037084
mov eax, dword [esi + 4]
mov dword [ebx + 0xc], eax
mov ecx, dword [esi]
test ecx, ecx
je 0x1003706d
mov eax, dword [ecx]
call dword [eax + 4]
mov edi, dword [esi]
mov ecx, edi
push 0
mov eax, dword [edi]
call dword [eax]
push edi
push 0
call dword [sym.imp.kernel32.dll_GetProcessHeap]
push eax
call dword [sym.imp.kernel32.dll_HeapFree]
push esi
push 0
call dword [sym.imp.kernel32.dll_GetProcessHeap]
push eax
call dword [sym.imp.kernel32.dll_HeapFree]
mov esi, dword [ebx + 0xc]
test esi, esi
jne 0x10037042
mov eax, dword [ebx + 0x18]
test eax, eax
je 0x10036fd0
nop
mov esi, dword [ebx + 0x14]
mov esi, dword [esi]
mov ecx, dword [esi + 0x14]
test ecx, ecx
je 0x100370a9
mov edx, dword [esi + 0x1c]
test edx, edx
je 0x100370a9
mov eax, dword [ecx]
push edx
call dword [eax + 4]
push esi
lea eax, [ebp - 0x14]
push eax
lea ecx, [ebx + 0x14]
call fcn.1002a910
mov eax, dword [ebx + 0x18]
test eax, eax
jne 0x10037090
jmp 0x10036fd0

Function at 0x100370d0
Capabilities:
Create thread
Resume thread

Disassembly:
push ebx
push esi
mov esi, ecx
mov edx, dword [esi]
lea eax, [edx + 0x10]
push eax
push 4
push edx
push 0x10037130
push 0
push 0
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__beginthreadex]
mov ebx, eax
add esp, 0x18
test ebx, ebx
jne 0x100370fa
pop esi
xor al, al
pop ebx
ret
mov eax, dword [esi]
push edi
add eax, 4
lock inc dword [eax]
mov edi, dword [esi]
mov eax, dword [edi + 8]
test eax, eax
je 0x10037118
cmp eax, 0xffffffff
je 0x10037118
push eax
call dword [sym.imp.kernel32.dll_CloseHandle]
mov dword [edi + 8], ebx
mov eax, dword [esi]
push dword [eax + 8]
call dword [sym.imp.kernel32.dll_ResumeThread]
pop edi
pop esi
mov al, 1
pop ebx
ret