joyce8/EMBER2024-capa huggingface dataset:
Function at 0x40c006
Capabilities:
Encode data using xor

Disassembly:
push ebx
mov ecx, 0xcbf
mov ebx, edx
xor word [eax], dx
lea edx, [ebx + edx]
xchg dh, dl
lea eax, [eax + 2]
loop 0x40c00e
pop ebx
ret

Function at 0x4088f7
Capabilities:
Allocate or change rwx memory
Create mailslot
Execute shellcode via indirect call

Disassembly:
push 0x18
push 0xe
push 0x12
push 7
push 0xffffffffffffffff
call dword [sym.imp.KERNEL32.dll_GetMailslotInfo]
mov eax, 0
push 0
push 0x18
push 0x18
push 0
call dword [sym.imp.KERNEL32.dll_CreateMailslotA]
and eax, 0xce
add esi, eax
cmp esi, 0x70143d0
jge 0x40892e
cmp eax, 0
je fcn.004088f7
mov ebx, eax
mov eax, 0x12fef
add eax, 0x2de
mov ecx, edx
push ecx
sub esp, 4
mov dword [esp], 0x40
push 0x3000
push eax
push 0
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov ecx, dword [esp]
add esp, 4
mov ecx, esi
mov esi, dword [esp]
mov edi, eax
add esi, 0x103
push eax
mov ecx, 0x1e3
mov edx, 0x961e18f7
xor ebp, ebp
xor bh, bh
add bh, dl
add bh, byte [esi]
add esi, 1
mov byte [edi], 0
add bh, bl
add byte [edi], bh
add edi, 1
push edx
push ecx
push 0
push 0xc
push 5
push 0x13
push 0
call dword [sym.imp.KERNEL32.dll_GetMailslotInfo]
pop ecx
mov edx, dword [esp]
add esp, 4
add eax, 0xdd985
sub eax, 0xdd981
shr edx, 8
add ebp, 0x2a11f
sub ebp, 0x2a11e
cmp ebp, eax
jne 0x4089ca
mov ebp, 0x961e18f7
mov edx, ebp
mov ebp, 0
sub ecx, 0x47aaf
add ecx, 0x47aae
test ecx, ecx
jne 0x408975
pop eax
mov edx, eax
mov eax, 4
add edx, eax
call edx
test eax, eax
jne 0x40892e
ret 0x4c
Function at 0x402c10
Capabilities:
Set environment variable

Disassembly:
sub esp, 0x1c
mov dword [esp + 4], 0x3d
mov dword [esp], eax
mov dword [esp + 0x10], ebx
mov ebx, eax
mov dword [esp + 0x14], esi
mov dword [esp + 0x18], edi
call sub.msvcrt.dll_strchr
mov edi, dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableA]
mov esi, eax
mov byte [eax], 0
mov dword [esp], ebx
mov dword [esp + 4], str.remove
call edi
mov byte [esi], 0x3d
sub esp, 8
mov dword [esp], ebx
call sub.msvcrt.dll__putenv
mov byte [esi], 0
mov dword [esp], ebx
mov dword [esp + 4], 0
call edi
sub esp, 8
mov dword [esp], ebx
call sub.msvcrt.dll_free
mov ebx, dword [esp + 0x10]
mov esi, dword [esp + 0x14]
mov edi, dword [esp + 0x18]
add esp, 0x1c
ret

Function at 0x402e50
Capabilities:
Print debug messages

Disassembly:
push esi
mov eax, 0x10c4
push ebx
call fcn.00410e30
sub esp, eax
mov dword [esp], 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov edx, dword [eax + 0x3c]
sub esp, 4
lea ebx, [esp + 0x1c]
movzx esi, word [eax + edx + 0x5c]
lea eax, [esp + 0x10d4]
mov dword [esp + 8], eax
mov eax, dword [esp + 0x10d0]
mov dword [esp], ebx
mov dword [esp + 4], eax
call sub.msvcrt.dll_vsprintf
mov dword [esp], ebx
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
sub esp, 4
cmp si, 2
je 0x402ef0
mov eax, dword [sym.imp.msvcrt.dll__iob]
mov dword [esp], ebx
add eax, 0x40
mov dword [esp + 4], eax
call sub.msvcrt.dll_fputs
mov eax, dword [sym.imp.msvcrt.dll__iob]
mov dword [esp], 0xa
add eax, 0x40
mov dword [esp + 4], eax
call sub.msvcrt.dll_fputc
mov eax, dword [sym.imp.msvcrt.dll__iob]
add eax, 0x40
mov dword [esp], eax
call sub.msvcrt.dll_fflush
add esp, 0x10c4
pop ebx
pop esi
ret
lea esi, [esp + 0xfbc]
mov dword [esp + 8], 0x104
mov dword [esp + 4], esi
mov dword [esp], 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
sub esp, 0xc
mov dword [esp + 0xc], 0
mov dword [esp + 8], esi
mov dword [esp + 4], ebx
mov dword [esp], 0
call dword [sym.imp.USER32.dll_MessageBoxA]
sub esp, 0x10
jmp 0x402eaa

Function at 0x403110
Capabilities:
Enumerate pe sections

Disassembly:
sub esp, 0x2c
lea eax, [esp + 0x18]
mov dword [esp], eax
call fcn.00410fa0
mov eax, dword [esp + 0x18]
mov dword [esp + 0x1c], eax
lea eax, [esp + 0x1c]
mov dword [esp], eax
call fcn.00410fb0
mov edx, dword [eax + 0x10]
mov ecx, dword [eax + 0xc]
mov eax, dword [eax + 0x14]
add esp, 0x2c
add edx, 1
add eax, 0x76c
jmp fcn.00401f70
Function at 0x4036e0
Capabilities:
Read file on windows

Disassembly:
sub esp, 0x4c
mov dword [esp + 0x3c], ebx
mov dword [esp + 0x40], esi
mov esi, edx
mov dword [esp + 0x44], edi
mov edi, ecx
mov dword [esp + 0x48], ebp
mov dword [esp + 4], 0x4132dd
mov dword [esp], eax
call sub.msvcrt.dll_fopen
test edi, edi
mov ebx, eax
je 0x403710
mov byte [edi], 0
test ebx, ebx
mov eax, 5
je 0x40374d
lea eax, [esp + 0x14]
mov dword [esp + 0xc], ebx
mov dword [esp + 8], 0x10
mov dword [esp + 4], 1
mov dword [esp], eax
call sub.msvcrt.dll_fread
mov dword [esp], ebx
mov ebp, eax
call sub.msvcrt.dll_fclose
cmp ebp, 0x10
mov eax, 4
je 0x403761
mov ebx, dword [esp + 0x3c]
mov esi, dword [esp + 0x40]
mov edi, dword [esp + 0x44]
mov ebp, dword [esp + 0x48]
add esp, 0x4c
ret
cmp byte [esp + 0x18], 2
jne 0x40374d
movzx eax, byte [esp + 0x17]
imul esi, esi, 0x15180
test edi, edi
mov byte [esp + 0x24], al
movzx eax, byte [esp + 0x19]
mov byte [esp + 0x25], al
movzx eax, byte [esp + 0x1b]
mov byte [esp + 0x26], al
movzx eax, byte [esp + 0x1d]
mov byte [esp + 0x27], al
mov ebx, dword [esp + 0x24]
je 0x4037c6
lea eax, [esi + ebx]
mov dword [esp + 0x2c], eax
lea eax, [esp + 0x2c]
mov dword [esp], eax
call fcn.00410fb0
mov edx, dword [eax + 0x10]
mov ecx, dword [eax + 0xc]
mov eax, dword [eax + 0x14]
mov dword [esp], edi
add edx, 1
add eax, 0x76c
call fcn.00402d20
lea edi, [esp + 0x28]
mov dword [esp], edi
call fcn.00410fa0
lea edx, [eax + 0x3f480]
mov eax, 2
cmp ebx, edx
jg 0x40374d
mov dword [esp], edi
add ebx, esi
call fcn.00410fa0
cmp ebx, eax
setl al
movzx eax, al
add eax, 1
jmp 0x40374d

Function at 0x403800
Capabilities:
Get hostname
Get session user name

Disassembly:
push edi
push esi
push ebx
xor ebx, ebx
sub esp, 0x7f0
movzx edx, byte [eax]
test dl, dl
je 0x403824
add eax, 1
lea ecx, [ebx + ebx*2]
movsx ebx, dl
movzx edx, byte [eax]
add ebx, ecx
test dl, dl
jne 0x403812
lea edi, [esp + 0x7ec]
lea esi, [esp + 0x1c]
mov dword [esp + 0x7ec], 0x7d0
mov dword [esp + 4], edi
mov dword [esp], esi
call dword [sym.imp.ADVAPI32.dll_GetUserNameA]
sub esp, 8
test eax, eax
je 0x403872
movzx eax, byte [esp + 0x1c]
test al, al
je 0x403872
mov edx, esi
lea esi, [esi]
add edx, 1
lea ecx, [ebx + ebx*2]
movsx ebx, al
movzx eax, byte [edx]
add ebx, ecx
test al, al
jne 0x403860
mov dword [esp + 0x7ec], 0x7d0
mov dword [esp + 4], edi
mov dword [esp], esi
call dword [sym.imp.KERNEL32.dll_GetComputerNameA]
sub esp, 8
test eax, eax
je 0x4038b2
movzx eax, byte [esp + 0x1c]
test al, al
je 0x4038b2
lea esi, [esi]
add esi, 1
lea edx, [ebx + ebx*2]
movsx ebx, al
movzx eax, byte [esi]
add ebx, edx
test al, al
jne 0x4038a0
add esp, 0x7f0
mov eax, ebx
pop ebx
pop esi
pop edi
ret
Function at 0x4046c0
Capabilities:
Timestomp file
Write file on windows

Disassembly:
sub esp, 0xbc
mov dword [esp + 0xac], ebx
mov ebx, eax
lea eax, [esp + 0x38]
mov dword [esp + 0xb0], esi
mov esi, edx
mov dword [esp + 0xb4], edi
mov edi, ecx
mov dword [esp + 0xb8], ebp
mov dword [esp + 4], eax
mov dword [esp], edx
call fcn.00410fc0
test eax, eax
jne 0x404808
test ebx, ebx
je 0x4047e5
lea edx, [esp + 0x5c]
mov eax, ebx
call fcn.004035f0
test eax, eax
jne 0x4047e5
mov eax, dword [esp + 0x78]
mov esi, eax
and esi, 0xffffff00
or esi, edi
cmp eax, esi
je 0x4047e5
mov dword [esp], ebx
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], pe_nt_image_headers32
mov dword [esp + 0x10], 3
mov dword [esp + 0xc], 0
mov dword [esp + 8], 3
mov dword [esp + 4], 0x100
call dword [sym.imp.KERNEL32.dll_CreateFileA]
sub esp, 0x1c
cmp eax, 0xffffffff
mov ebx, eax
je 0x4047e5
lea eax, [esp + 0x90]
mov dword [esp + 4], eax
mov dword [esp], 0x413e74
call dword [sym.imp.KERNEL32.dll_SystemTimeToFileTime]
mov eax, 0x989680
mul esi
sub esp, 8
add eax, dword [esp + 0x90]
adc edx, dword [esp + 0x94]
mov dword [esp + 8], 0
mov dword [esp + 0x80], eax
lea eax, [esp + 0x80]
mov dword [esp + 0x84], edx
mov dword [esp + 0xc], eax
mov dword [esp + 4], 0
mov dword [esp], ebx
call dword [sym.imp.KERNEL32.dll_SetFileTime]
sub esp, 0x10
mov dword [esp], ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
sub esp, 4
mov ebx, dword [esp + 0xac]
mov esi, dword [esp + 0xb0]
mov edi, dword [esp + 0xb4]
mov ebp, dword [esp + 0xb8]
add esp, 0xbc
ret
mov dword [esp + 4], 0x413418
mov dword [esp], esi
call sub.msvcrt.dll_fopen
test eax, eax
mov dword [esp + 0x2c], eax
je 0x404700
lea eax, [esp + 0x9c]
xor esi, esi
mov dword [esp], eax
lea ebp, [esp + 0x80]
call fcn.00410fa0
mov eax, dword [esp + 0x9c]
mov dword [esp], eax
call sub.msvcrt.dll_srand
nop
lea esi, [esi]
call sub.msvcrt.dll_rand
mov word [ebp + esi*2], ax
add esi, 1
cmp esi, 8
jne 0x404850
mov eax, dword [esp + 0x9c]
mov dword [esp + 8], 0x10
mov dword [esp + 4], 1
mov dword [esp], ebp
mov edx, eax
shr dx, 8
mov dword [esp + 0x98], eax
mov byte [esp + 0x83], al
mov byte [esp + 0x85], dl
mov edx, eax
shr eax, 0x18
mov byte [esp + 0x89], al
mov eax, edi
mov byte [esp + 0x84], al
mov eax, dword [esp + 0x2c]
shr edx, 0x10
mov byte [esp + 0x87], dl
mov dword [esp + 0xc], eax
call sub.msvcrt.dll_fwrite
mov eax, dword [esp + 0x2c]
mov dword [esp], eax
call sub.msvcrt.dll_fclose
jmp 0x404700
Function at 0x4068c0
Capabilities:
Delete directory

Disassembly:
push ebp
mov ebp, eax
push edi
push esi
push ebx
sub esp, 0x41c
mov dword [esp], eax
call fcn.00406660
test eax, eax
mov esi, eax
je 0x40697f
mov dword [esp], ebp
lea ebx, [esp + 0x10]
call sub.msvcrt.dll_strlen
mov dword [esp + 4], ebp
mov dword [esp], ebx
mov edi, eax
mov dword [esp + 8], eax
call sub.msvcrt.dll_strncpy
movzx eax, byte [esp + edi + 0xf]
cmp al, 0x5c
jne 0x406992
add edi, ebx
nop
lea esi, [esi]
mov dword [esp], esi
call fcn.004067a0
test eax, eax
je 0x406977
cmp byte [eax + 0x10], 0x2e
jne 0x406939
cmp byte [eax + 0x11], 0
je 0x406910
mov edx, dword [eax + 0x10]
and edx, 0xffff00
cmp edx, 0x2e00
je 0x406910
add eax, 0x10
mov dword [esp + 4], eax
mov dword [esp], edi
call sub.msvcrt.dll_strcpy
mov dword [esp + 4], 0x1ff
mov dword [esp], ebx
call sub.msvcrt.dll__chmod
mov dword [esp], ebx
call sub.msvcrt.dll__unlink
test eax, eax
je 0x406910
mov eax, ebx
call fcn.004068c0
mov dword [esp], esi
call fcn.004067a0
test eax, eax
jne 0x40691c
mov dword [esp], esi
call fcn.00406890
mov dword [esp], ebp
call sub.msvcrt.dll__rmdir
add esp, 0x41c
pop ebx
pop esi
pop edi
pop ebp
ret
cmp al, 0x2f
je 0x406909
mov byte [esp + edi + 0x10], 0x5c
add edi, 1
jmp 0x406909
Function at 0x4090b0
Capabilities:
Encode data using xor

Disassembly:
push edi
push esi
push ebx
sub esp, 0x20
mov ebx, dword [esp + 0x30]
mov esi, dword [esp + 0x34]
mov eax, dword [ebx + 0x18]
test eax, eax
je 0x409237
mov edx, dword [ebx]
mov ecx, dword [eax + 8]
mov edx, dword [edx + 4]
cmp edx, 0x2000000
je 0x4091e0
and ecx, 1
test cl, cl
je 0x409140
cmp edx, 0x2000000
mov edx, dword [eax]
je 0x409200
mov dword [esp + 0x1c], edx
mov edx, dword [eax + 4]
add eax, 0xc
mov dword [esp + 8], eax
lea eax, [esp + 0x1c]
mov dword [esp + 0xc], edx
mov dword [esp + 4], eax
mov dword [esp], esi
call fcn.0040b1f0
test eax, eax
jne 0x409133
mov eax, dword [ebx]
mov edx, dword [ebx + 0x18]
mov eax, dword [eax + 4]
mov ecx, dword [edx]
cmp eax, 0x2000000
je 0x409230
cmp ecx, dword [esp + 0x1c]
je 0x4091a2
xor esi, esi
add esp, 0x20
mov eax, esi
pop ebx
pop esi
pop edi
ret
cmp edx, 0x2000000
mov edi, dword [eax]
je 0x409210
mov ecx, dword [eax + 4]
cmp edi, ecx
je 0x409179
mov dword [esp + 8], 0x9d
mov dword [esp + 4], str.....BFS_src_bfs.c
mov dword [esp], str.BFS_U32N_i__bfs__i__file__f_entity_size___BFS_U32N_i__bfs__i__file__f_stored_size_
call fcn.004113e0
mov eax, dword [ebx]
mov edx, dword [eax + 4]
mov eax, dword [ebx + 0x18]
cmp edx, 0x2000000
mov edx, dword [eax]
je 0x409224
add eax, 0xc
mov dword [esp + 8], edx
mov dword [esp + 4], eax
mov dword [esp], esi
call sub.msvcrt.dll_memcpy
mov eax, dword [ebx]
mov edx, dword [ebx + 0x18]
mov eax, dword [eax + 4]
cmp eax, 0x2000000
je 0x4091f0
test byte [edx + 8], 2
setne cl
test cl, cl
je 0x409135
cmp eax, 0x2000000
mov edx, dword [edx]
je 0x409220
test edx, edx
mov eax, esi
je 0x409135
xor byte [eax], 0xea
add eax, 1
sub edx, 1
jne 0x4091c7
add esp, 0x20
mov eax, esi
pop ebx
pop esi
pop edi
ret
bswap ecx
and ecx, 1
jmp 0x4090e0
mov ecx, dword [edx + 8]
bswap ecx
and ecx, 2
setne cl
jmp 0x4091b0
bswap edx
mov dword [esp + 0x1c], edx
mov edx, dword [eax + 4]
bswap edx
jmp 0x4090f9
mov ecx, dword [eax + 4]
bswap edi
bswap ecx
jmp 0x409151
bswap edx
jmp 0x4091bd
bswap edx
jmp 0x409187
bswap ecx
jmp 0x40912d
mov dword [esp + 8], 0x8e
mov dword [esp + 4], str.....BFS_src_bfs.c
mov dword [esp], str.i__file
call fcn.004113e0
mov eax, dword [ebx + 0x18]
jmp 0x4090c9
Function at 0x409620
Capabilities:
Encode data using xor
Extract resource via kernel32 functions

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x1c
mov esi, dword [esp + 0x30]
mov dword [esp], 0x18
call sub.msvcrt.dll_malloc
test eax, eax
mov ebx, eax
je 0x409788
test esi, esi
mov dword [eax + 4], esi
mov dword [eax + 8], 1
mov dword [eax + 0xc], 0
je 0x40977e
mov dword [esp], esi
call sub.msvcrt.dll__strdup
test eax, eax
mov dword [ebx + 4], eax
je 0x40977e
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
sub esp, 4
test eax, eax
mov esi, eax
je 0x409743
mov dword [esp + 8], 0x413f80
mov dword [esp + 4], 0x413f84
mov dword [esp], esi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
sub esp, 0xc
test eax, eax
je 0x409792
mov dword [esp + 4], eax
mov dword [esp], esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
sub esp, 8
test eax, eax
je 0x409792
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_LockResource]
sub esp, 4
mov esi, eax
mov dword [ebx], eax
test esi, esi
je 0x4097c2
mov dword [esp + 8], 4
mov dword [esp + 4], 0x413f87
mov dword [esp], esi
call sub.msvcrt.dll_memcmp
test eax, eax
jne 0x4097a0
cmp dword [esi + 4], 0x2000000
mov edi, dword [esi + 8]
je 0x4097b0
movzx ebp, word [esi + 0xc]
sub edi, ebp
mov dword [esp], edi
call sub.msvcrt.dll_malloc
test eax, eax
mov dword [ebx], eax
je 0x40976c
test edi, edi
mov dword [ebx + 0xc], 1
je 0x4097a2
xor edx, edx
lea ebp, [esi + ebp]
nop
lea esi, [esi]
mov ecx, dword [ebp + edx]
xor ecx, dword [esi + 8]
mov dword [eax + edx], ecx
add edx, 4
cmp edi, edx
ja 0x409730
jmp 0x4097a2
mov dword [esp + 8], 2
mov dword [esp + 4], 0
mov eax, dword [ebx + 4]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryExA]
sub esp, 0xc
test eax, eax
mov esi, eax
jne 0x409683
mov edx, dword [ebx + 0xc]
test edx, edx
jne 0x4097c6
mov eax, dword [ebx + 4]
mov dword [esp], eax
call sub.msvcrt.dll_free
mov dword [esp], ebx
xor ebx, ebx
call sub.msvcrt.dll_free
add esp, 0x1c
mov eax, ebx
pop ebx
pop esi
pop edi
pop ebp
ret
mov esi, dword [ebx]
jmp 0x4096cf
mov eax, esi
mov dword [esp], eax
call fcn.00408da0
test eax, eax
jne 0x409788
jmp 0x40976c
movzx ebp, word [esi + 0xc]
bswap edi
rol bp, 8
movzx ebp, bp
jmp 0x40970b
xor eax, eax
jmp 0x4097a2
mov eax, dword [ebx]
mov dword [esp], eax
call sub.msvcrt.dll_free
jmp 0x409773
Function at 0x409c33
Capabilities:
Allocate or change rwx memory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x30
mov eax, dword [ebp + 8]
mov dword [ebp - 0x14], eax
mov ecx, dword [ebp - 0x14]
mov dword [ebp - 0xc], ecx
mov edx, dword [ebp - 0xc]
mov eax, dword [ebp - 0x14]
add eax, dword [edx + 0x3c]
mov dword [ebp - 0x10], eax
push 1
mov ecx, dword [ebp - 0x10]
push ecx
call fcn.00409de1
add esp, 8
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0
jne 0x409c6f
xor eax, eax
jmp 0x409ddd
mov edx, dword [ebp - 4]
mov eax, dword [ebp - 0x14]
add eax, dword [edx]
mov dword [ebp - 0x1c], eax
mov ecx, dword [ebp - 4]
mov edx, dword [ecx]
push edx
mov eax, dword [ebp - 0x14]
push eax
call fcn.00409e1d
add esp, 8
mov dword [ebp - 8], eax
cmp dword [ebp - 8], 0
jne 0x409c9c
xor eax, eax
jmp 0x409ddd
lea ecx, [ebp - 0x18]
push ecx
push 0x40
mov edx, dword [ebp - 8]
mov eax, dword [edx + 8]
push eax
mov ecx, dword [ebp - 8]
mov edx, dword [ebp - 0x14]
add edx, dword [ecx + 0xc]
push edx
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x409cc4
xor eax, eax
jmp 0x409ddd
mov eax, dword [ebp - 0x1c]
cmp dword [eax], 0
je 0x409dbe
push str.KERNEL32.dll
mov ecx, dword [ebp - 0x1c]
mov edx, dword [ebp - 0x14]
add edx, dword [ecx + 0xc]
push edx
call dword [sym.imp.msvcrt.dll__stricmp]
add esp, 8
test eax, eax
jne 0x409db0
mov eax, dword [ebp - 0x1c]
mov ecx, dword [ebp - 0x14]
add ecx, dword [eax]
mov dword [ebp - 0x20], ecx
mov edx, dword [ebp - 0x1c]
mov eax, dword [ebp - 0x14]
add eax, dword [edx + 0x10]
mov dword [ebp - 0x24], eax
mov ecx, dword [ebp - 0x20]
cmp dword [ecx], 0
je 0x409dae
mov edx, dword [ebp - 0x20]
mov eax, dword [edx]
and eax, 0x80000000
test eax, eax
jne 0x409d97
mov dword [ebp - 0x30], str.DisableThreadLibraryCalls
mov ecx, dword [ebp - 0x20]
mov edx, dword [ebp - 0x14]
add edx, dword [ecx]
mov dword [ebp - 0x28], edx
mov eax, dword [ebp - 0x28]
mov cl, byte [eax + 2]
mov byte [ebp - 0x2c], cl
movsx edx, byte [ebp - 0x2c]
cmp edx, 0x44
je 0x409d60
movsx eax, byte [ebp - 0x2c]
cmp eax, 0x46
je 0x409d60
movsx ecx, byte [ebp - 0x2c]
cmp ecx, 0x47
je 0x409d60
movsx edx, byte [ebp - 0x2c]
cmp edx, 0x4c
jne 0x409d97
mov eax, dword [ebp - 0x30]
cmp dword [eax], 0
je 0x409d97
mov ecx, dword [ebp - 0x28]
add ecx, 2
push ecx
mov edx, dword [ebp - 0x30]
mov eax, dword [edx]
push eax
call sub.msvcrt.dll_strcmp
add esp, 8
test eax, eax
jne 0x409d8c
mov ecx, dword [ebp - 0x24]
mov edx, dword [ebp - 0x30]
mov eax, dword [edx + 8]
mov dword [ecx], eax
mov ecx, dword [ebp - 0x30]
add ecx, 0xc
mov dword [ebp - 0x30], ecx
jmp 0x409d60
mov edx, dword [ebp - 0x20]
add edx, 4
mov dword [ebp - 0x20], edx
mov eax, dword [ebp - 0x24]
add eax, 4
mov dword [ebp - 0x24], eax
jmp 0x409d07
jmp 0x409dbe
mov ecx, dword [ebp - 0x1c]
add ecx, 0x14
mov dword [ebp - 0x1c], ecx
jmp 0x409cc4
lea edx, [ebp - 0x18]
push edx
mov eax, dword [ebp - 0x18]
push eax
mov ecx, dword [ebp - 8]
mov edx, dword [ecx + 8]
push edx
mov eax, dword [ebp - 8]
mov ecx, dword [ebp - 0x14]
add ecx, dword [eax + 0xc]
push ecx
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
mov esp, ebp
pop ebp
ret
Function at 0x409e1d
Capabilities:
Enumerate pe sections

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
mov eax, dword [ebp + 8]
mov dword [ebp - 0xc], eax
mov ecx, dword [ebp - 0xc]
mov edx, dword [ebp + 8]
add edx, dword [ecx + 0x3c]
mov dword [ebp - 0x10], edx
mov eax, dword [ebp - 0x10]
xor ecx, ecx
mov cx, word [eax + 0x14]
mov edx, dword [ebp - 0x10]
lea eax, [edx + ecx + 0x18]
mov dword [ebp - 8], eax
mov dword [ebp - 4], 0
jmp 0x409e63
mov ecx, dword [ebp - 4]
add ecx, 1
mov dword [ebp - 4], ecx
mov edx, dword [ebp - 8]
add edx, 0x28
mov dword [ebp - 8], edx
mov eax, dword [ebp - 0x10]
xor ecx, ecx
mov cx, word [eax + 6]
cmp dword [ebp - 4], ecx
jge 0x409e94
mov edx, dword [ebp - 8]
mov eax, dword [edx + 0xc]
cmp eax, dword [ebp + 0xc]
ja 0x409e92
mov ecx, dword [ebp - 8]
mov edx, dword [ecx + 0xc]
mov eax, dword [ebp - 8]
add edx, dword [eax + 8]
cmp dword [ebp + 0xc], edx
jae 0x409e92
mov eax, dword [ebp - 8]
jmp 0x409e96
jmp 0x409e51
xor eax, eax
mov esp, ebp
pop ebp
ret
Function at 0x4100d0
Capabilities:
Write file on windows

Disassembly:
push ebx
sub esp, 0x18
mov eax, dword [sym.imp.msvcrt.dll__iob]
mov dword [esp + 8], 0x1b
lea ebx, [esp + 0x24]
mov dword [esp + 4], 1
mov dword [esp], str.Mingw_w64_runtime_failure:_n
add eax, 0x40
mov dword [esp + 0xc], eax
call sub.msvcrt.dll_fwrite
mov eax, dword [esp + 0x20]
mov dword [esp + 8], ebx
mov dword [esp + 4], eax
mov eax, dword [sym.imp.msvcrt.dll__iob]
add eax, 0x40
mov dword [esp], eax
call sub.msvcrt.dll_vfprintf
call sub.msvcrt.dll_abort
jmp fcn.00410130
Function at 0x410620
Capabilities:
Parse pe header

Disassembly:
mov edx, dword [esp + 4]
xor eax, eax
cmp word [edx], 0x5a4d
je 0x410630
repz ret
add edx, dword [edx + 0x3c]
cmp dword [edx], 0x4550
jne 0x41062d
xor eax, eax
cmp word [edx + 0x18], 0x10b
sete al
ret

Function at 0x410bf0
Capabilities:
Get thread local storage value

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x1c
mov dword [esp], 0x417504
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov ebx, dword [0x41751c]
sub esp, 4
test ebx, ebx
je 0x410c45
mov ebp, dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
lea esi, [esi]
mov eax, dword [ebx]
mov dword [esp], eax
call ebp
sub esp, 4
mov esi, eax
call edi
test eax, eax
jne 0x410c3e
test esi, esi
je 0x410c3e
mov eax, dword [ebx + 4]
mov dword [esp], esi
call eax
mov ebx, dword [ebx + 8]
test ebx, ebx
jne 0x410c20
mov dword [esp], 0x417504
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
sub esp, 4
add esp, 0x1c
pop ebx
pop esi
pop edi
pop ebp
ret
Function at 0x411200
Capabilities:
Contain obfuscated stackstrings

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x33c
mov esi, dword [esp + 0x350]
lea ebp, [esp + 0x126]
mov ebx, dword [esp + 0x354]
mov dword [esp], 0x2000
call sub.msvcrt.dll_malloc
test esi, esi
lea ecx, [esi + 0x208]
mov edi, eax
mov eax, ebp
jne 0x41124c
jmp 0x411254
add esi, 2
mov byte [eax], dl
add eax, 1
cmp esi, ecx
je 0x411254
movzx edx, word [esi]
test dx, dx
jne 0x411240
lea esi, [esp + 0x22b]
test ebx, ebx
mov byte [eax], 0
lea ecx, [ebx + 0x208]
mov eax, esi
jne 0x41127c
jmp 0x411284
add ebx, 2
mov byte [eax], dl
add eax, 1
cmp ebx, ecx
je 0x411284
movzx edx, word [ebx]
test dx, dx
jne 0x411270
mov byte [eax], 0
cmp byte [esp + 0x22b], 0
je 0x411340
cmp byte [esp + 0x126], 0
je 0x41136e
lea ebx, [esp + 0x21]
mov byte [esp + 0x125], 0
mov dword [esp + 8], 0x104
mov dword [esp + 4], ebx
mov dword [esp], 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
sub esp, 0xc
test eax, eax
je 0x411380
mov eax, dword [esp + 0x358]
mov dword [esp + 0x14], ebp
mov dword [esp + 0xc], esi
mov dword [esp + 8], ebx
mov dword [esp + 0x10], eax
mov dword [esp + 4], str.Assertion_failed__n_nProgram:__s_nFile:__s__Line__u_n_nExpression:__s
mov dword [esp], edi
call sub.msvcrt.dll_sprintf
mov eax, dword [0x417188]
test eax, eax
je 0x4113b9
mov dword [esp + 0xc], 0x12012
mov dword [esp + 8], str.MinGW_Runtime_Assertion
mov dword [esp + 4], edi
mov dword [esp], 0
call dword [sym.imp.USER32.dll_MessageBoxA]
sub esp, 0x10
cmp eax, 3
je 0x4113a1
cmp eax, 5
jne 0x41139c
add esp, 0x33c
pop ebx
pop esi
pop edi
pop ebp
ret
cmp byte [esp + 0x126], 0
mov dword [esp + 0x22b], 0x6b6e753c
mov dword [esp + 0x22f], 0x6e776f6e
mov word [esp + 0x233], 0x3e
jne 0x4112a3
mov word [esp + 0x126], 0x3f
jmp 0x4112a3
mov dword [esp + 0x21], 0x6b6e753c
mov dword [esp + 0x25], 0x6e776f6e
mov word [esp + 0x29], 0x3e
jmp 0x4112d3
call sub.msvcrt.dll_abort
mov dword [esp], 0x16
call sub.msvcrt.dll_raise
mov dword [esp], 3
call sub.msvcrt.dll__exit
mov eax, dword [sym.imp.msvcrt.dll__iob]
mov dword [esp + 8], edi
mov dword [esp + 4], 0x416fa1
add eax, 0x40
mov dword [esp], eax
call sub.msvcrt.dll_fprintf
call sub.msvcrt.dll_abort
lea esi, [esi]