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

Disassembly:
mov eax, dword [esp + 4]
mov edx, dword [esp + 8]
mov ecx, dword [esp + 0xc]

Function at 0x51641c
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
mov dword [ebp - 0xc], esi
mov esi, ecx
mov ecx, dword [ebp + 0x14]
mov dword [ebp - 8], ebx
mov ebx, edx
mov dword [ebp - 4], edi
mov edx, eax
mov dword [ecx], 0
cmp dword [0x64c7c0], 0
je 0x5164f1
cmp dword [ebp + 0x20], 2
je 0x516453
cmp dword [ebp + 0x20], 1
jne 0x516462
mov eax, 0xffffffff
mov ebx, dword [ebp - 8]
mov esi, dword [ebp - 0xc]
mov esp, ebp
pop ebp
ret
cmp dword [ebp + 0x18], 0
je 0x516472
cmp dword [ebp + 0x20], 0xfffffffa
je 0x5165b6
cmp dword [ebp + 0x20], 0
je 0x5165c2
xor ecx, ecx
cmp dword [ebp + 0x18], 0
je 0x5164a5
cmp dword [ebp + 0x1c], 0
je 0x5164a5
push edi
mov dword [ebp - 0x18], ecx
mov dword [ebp - 0x10], edx
call fcn.005ad330
push edi
call fcn.005ad4a0
mov edx, dword [ebp - 0x10]
add esp, 8
mov ecx, dword [ebp - 0x18]
test ecx, ecx
je 0x5164f1
push edi
push esi
push ebx
call fcn.005ad3d0
add esp, 0xc
mov esi, eax
mov eax, dword [ebp + 0x14]
cmp esi, 0xffffffff
mov dword [eax], esi
je 0x5165e6
push 0
push edi
push 2
push 0x5f269c
call fcn.005ad390
add esp, 0x10
mov edx, dword [ebp + 0x14]
mov eax, 1
mov byte [esi + ebx], 0xa
mov ebx, dword [ebp - 8]
mov esi, dword [ebp - 0xc]
mov edi, dword [ebp - 4]
inc dword [edx]
mov esp, ebp
pop ebp
ret
mov dword [ebp - 0x10], edx
push 0
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov edi, dword [ebp + 0x14]
mov ecx, dword [ebp + 0x24]
test ecx, ecx
mov edx, dword [ebp - 0x10]
mov dword [edi], 0
je 0x516519
mov edi, dword [ecx + 0x13c]
test edi, edi
jne 0x51651e
mov edi, 0x20000
cmp esi, edi
jbe 0x516592
cmp dword [ebp + 0x20], 0
je 0x516592
test ecx, ecx
je 0x516536
mov edi, dword [ecx + 0x13c]
test edi, edi
jne 0x51653b
mov edi, 0x20000
mov dword [ebp - 0x10], edx
push 0
mov dword [ebp - 0x14], edi
lea eax, [ebp - 0x18]
push eax
push edi
push ebx
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x516580
mov ecx, dword [ebp + 0x14]
mov edx, dword [ebp - 0x18]
add ebx, edx
sub esi, edx
add dword [ecx], edx
cmp dword [ebp + 0x24], 0
je 0x516575
mov edx, dword [ebp + 0x24]
mov edx, dword [edx + 0x13c]
test edx, edx
jne 0x51657a
mov edx, 0x20000
cmp esi, edx
ja 0x516580
mov edi, esi
test esi, esi
je 0x5165a9
mov edx, dword [ebp - 0x14]
cmp edx, dword [ebp - 0x18]
jne 0x5165a9
test eax, eax
jne 0x51653e
jmp 0x5165a9
push 0
lea ecx, [ebp - 0x18]
push ecx
push esi
push ebx
push edx
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov ecx, dword [ebp + 0x14]
mov edx, dword [ebp - 0x18]
mov dword [ecx], edx
mov ebx, dword [ebp - 8]
mov esi, dword [ebp - 0xc]
mov edi, dword [ebp - 4]
mov esp, ebp
pop ebp
ret
mov edi, edx
mov ecx, 1
jmp 0x516484
mov dword [ebp - 0x10], edx
call fcn.005ad5c0
mov edx, dword [ebp - 0x10]
mov edi, eax
cmp dword [0x64c7c0], 0
je 0x5164a9
mov ecx, 1
jmp 0x51647e
xor eax, eax
mov ebx, dword [ebp - 8]
mov esi, dword [ebp - 0xc]
mov edi, dword [ebp - 4]
mov esp, ebp
pop ebp
ret
Function at 0x51c860
Capabilities:
Check mutex on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
mov eax, dword [ebp + 8]
mov dword [ebp - 8], esi
mov dword [ebp - 4], ebx
mov esi, dword [eax + 0x7c]
test esi, esi
mov dword [ebp - 0xc], edi
je 0x51ca1c
mov edx, dword [0x635300]
mov edi, dword [esi + 0x14]
lea eax, [edi*4]
shl edi, 5
sub edi, eax
cmp edx, 2
lea ebx, [edi + 0x647168]
jge 0x51c8af
mov eax, dword [ebx]
test eax, eax
jne 0x51c8f0
mov dword [edi + 0x647168], 1
jmp 0x51c8f0
push ebx
call fcn.004fa4d0
add esp, 4
test eax, eax
jne 0x51c8ea
cmp dword [edi + 0x647164], 0
je 0x51c9fc
mov dword [edi + 0x647168], 0
push 0xffffffffffffffff
push dword [edi + 0x647164]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push ebx
call fcn.004fa4d0
add esp, 4
mov edx, dword [0x635300]
cmp edx, 1
je 0x51c9e8
mov eax, dword [esi + 0x18]
dec eax
mov dword [esi + 0x18], eax
test eax, eax
jle 0x51c95f
mov eax, dword [0x635300]
cmp eax, 1
je 0x51c944
cmp eax, 2
jge 0x51c91f
mov dword [edi + 0x647168], 0
jmp 0x51c935
mov dword [edi + 0x647168], 0
push dword [edi + 0x647164]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
xor eax, eax
mov ebx, dword [ebp - 4]
mov esi, dword [ebp - 8]
mov edi, dword [ebp - 0xc]
mov esp, ebp
pop ebp
ret
push dword [edi + 0x647178]
push dword [edi + 0x647174]
call fcn.004fa4b0
add esp, 8
mov eax, dword [0x635300]
jmp 0x51c90e
mov edx, dword [esi]
test edx, edx
je 0x51c96b
mov eax, dword [esi + 4]
mov dword [edx + 4], eax
mov eax, dword [esi + 4]
test eax, eax
je 0x51c976
mov dword [eax], edx
jmp 0x51c97c
mov dword [edi + 0x647160], edx
mov eax, dword [ebp + 8]
mov dword [eax + 0x7c], 0
mov eax, dword [0x635300]
cmp eax, 1
je 0x51c9cd
cmp eax, 2
jge 0x51c9a1
mov dword [edi + 0x647168], 0
jmp 0x51c9b7
mov dword [edi + 0x647168], 0
push dword [edi + 0x647164]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
push dword [esi + 8]
call fcn.00505200
push esi
call fcn.00505200
add esp, 8
jmp 0x51c935
push dword [edi + 0x647178]
push dword [edi + 0x647174]
call fcn.004fa4b0
add esp, 8
mov eax, dword [0x635300]
jmp 0x51c990
lea eax, [edi + 0x647174]
push eax
call fcn.004fa480
add esp, 4
jmp 0x51c8f9
xor eax, eax
push eax
push eax
push eax
call dword [sym.imp.KERNEL32.dll_CreateMutexA]
mov dword [edi + 0x647164], eax
mov dword [edi + 0x647168], 0
jmp 0x51c8d3
xor eax, eax
mov esi, dword [ebp - 8]
mov esp, ebp
pop ebp
ret

Function at 0x51ca30
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
call fcn.0050ce00
mov ebx, dword [ebp + 8]
cmp dword [0x64c7c0], 0
jne 0x51ca57
test ebx, ebx
je 0x51ca4c
mov eax, dword [ebx]
jmp 0x51ca4e
xor eax, eax
push eax
call fcn.00554680
add esp, 4
test ebx, ebx
je 0x51ca5f
mov eax, dword [ebx]
jmp 0x51ca61
xor eax, eax
push eax
call fcn.005ad580
add esp, 4
jmp 0x51ca44
Function at 0x56c0e0
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x635ad4]
jne 0x56c0ea
repz ret
jmp fcn.00580160
Function at 0x40169e
Capabilities:
Accept command line arguments
Hide graphical window

Disassembly:
push ebp
mov ebp, esp
mov dword [0x4042cb], ebp
call dword [sym.imp.kernel32.dll_GetCommandLineA]
mov dword [0x404772], eax
xor eax, eax
push eax
call dword [sym.imp.kernel32.dll_GetModuleHandleA]
mov dword [0x404706], eax
mov dword [0x4042c3], eax
mov dword [0x4046f2], 0x30
mov dword [0x4046f6], 2
jmp 0x4016df
xor eax, eax
mov dword [0x4046fa], 0x403290
mov dword [0x4046fe], eax
mov dword [0x404702], eax
mov eax, 0x4041c7
mov dword [0x404712], 0xe
mov dword [0x40471a], eax
push 0x7f00
push 0
call dword [sym.imp.user32.dll_LoadCursorA]
mov dword [0x40470e], eax
push 0x7f00
push 0
call dword [sym.imp.user32.dll_LoadIconA]
mov dword [0x40470a], eax
mov dword [0x40471e], eax
push 0x4046f2
call dword [sym.imp.user32.dll_RegisterClassExA]
push 0
push dword [0x4042c3]
push 0
push 0
push 0x1e0
push 0x1fe
push 0xfffff862
push 0xfffff8f8
push 0xcf0000
push 0x4046c8
push 0x4041c7
push 0
call dword [sym.imp.user32.dll_CreateWindowExA]
mov dword [0x404766], eax
push 5
push eax
call dword [sym.imp.user32.dll_ShowWindow]
push dword [0x404766]
call dword [sym.imp.user32.dll_UpdateWindow]
xor edi, edi
lea ebx, [0x404722]
jmp 0x4017a6
push ebx
call dword [sym.imp.user32.dll_TranslateMessage]
push ebx
call dword [sym.imp.user32.dll_DispatchMessageA]
push edi
push edi
push edi
push ebx
call dword [sym.imp.user32.dll_GetMessageA]
test al, al
jne 0x401798
mov eax, dword [0x40472a]
jmp 0x4017c1
call 0x402a9e
ret

Function at 0x401686
Capabilities:
Accept command line arguments
Hide graphical window

Disassembly:
push ebp
mov ebp, esp
call dword [sym.imp.kernel32.dll_GetCommandLineA]
mov dword [0x404474], eax
push 0
call dword [sym.imp.kernel32.dll_GetModuleHandleA]
mov dword [0x4041cf], ebp
mov dword [0x404404], eax
mov dword [0x4041c7], eax
mov dword [0x4043f0], 0x30
mov dword [0x4043f4], 2
jmp 0x4016c6
mov dword [0x4043f8], 0x403051
mov dword [0x4043fc], 0
mov dword [0x404400], 0
push 0x7f00
push 0
call dword [sym.imp.user32.dll_LoadCursorA]
mov dword [0x40440c], eax
push 0x7f00
push 0
call dword [sym.imp.user32.dll_LoadIconA]
mov dword [0x404408], eax
mov dword [0x40441c], eax
mov dword [0x404418], 0x40439a
mov dword [0x404410], 0xf
push 0x4043f0
call dword [sym.imp.user32.dll_RegisterClassExA]
push 0
push dword [0x4041c7]
push 0
push 0
push 0x1e0
push 0x1fe
push 0xfffff862
push 0xfffff8f8
push 0xcf0000
push 0x4043e7
push str.lunt
push 0
call dword [sym.imp.user32.dll_CreateWindowExA]
mov dword [0x404468], eax
push 5
push dword [0x404468]
call dword [sym.imp.user32.dll_ShowWindow]
push dword [0x404468]
call dword [sym.imp.user32.dll_UpdateWindow]
xor edi, edi
lea ebx, [0x404420]
jmp 0x40179a
push ebx
call dword [sym.imp.user32.dll_TranslateMessage]
push ebx
call dword [sym.imp.user32.dll_DispatchMessageA]
push edi
push edi
push edi
push ebx
call dword [sym.imp.user32.dll_GetMessageA]
test al, al
jne 0x40178c
mov eax, dword [0x404428]
jmp 0x4017b5
call 0x402a06
ret
Function at 0x406492
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x120
push esi
mov esi, 0x104
lea eax, [ebp - 0x120]
push esi
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
cmp eax, esi
pop esi
jbe 0x4064b6
xor eax, eax
test eax, eax
je 0x4064c8
cmp byte [ebp + eax - 0x121], 0x5c
je 0x4064c8
xor ecx, ecx
jmp 0x4064cb
xor ecx, ecx
inc ecx
push dword [ebp + 8]
lea ecx, [ecx + 0x40a014]
lea eax, [ebp + eax - 0x120]
push ecx
push str._s_s.dll
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x10
lea eax, [ebp - 0x120]
push 8
push 0
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryExA]
leave
ret 4

Function at 0x4065b7
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
cmp dword [0x42ce24], 0
push esi
jne 0x4065ee
xor ecx, ecx
push 8
mov eax, ecx
pop esi
mov edx, eax
and dl, 1
neg dl
sbb edx, edx
and edx, 0xedb88320
shr eax, 1
xor eax, edx
dec esi
jne 0x4065c8
mov dword [ecx*4 + 0x42ce20], eax
inc ecx
cmp ecx, 0x100
jl 0x4065c3
mov edx, dword [esp + 0x10]
mov eax, dword [esp + 8]
test edx, edx
not eax
jbe 0x40661f
mov ecx, dword [esp + 0xc]
push edi
movzx edi, byte [ecx]
mov esi, eax
and esi, 0xff
xor esi, edi
shr eax, 8
mov esi, dword [esi*4 + 0x42ce20]
xor eax, esi
inc ecx
dec edx
jne 0x406601
pop edi
not eax
pop esi
ret 0xc

Function at 0x40893a
Capabilities:
Encode data using xor

Disassembly:
mov eax, 0x4085d8
add edi, 0xa186b2b2
call fcn.0040895e
xor dword [edx], eax
sub ebx, 0xf31cb763
add edx, 1
cmp edx, esi
jne fcn.0040893a
dec edi
ret
Function at 0x4025a9
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x54
push ebx
push esi
lea ecx, [ebp - 0xc]
call fcn.00411481
lea ecx, [ebp - 0x18]
call fcn.00411481
push 0x3c
xor esi, esi
lea eax, [ebp - 0x54]
push esi
push eax
call fcn.00416940
mov ebx, dword [ebp + 0xc]
add esp, 0xc
mov eax, dword [ebp + 0x10]
mov ecx, 0x740
mov dword [ebp - 0x54], 0x3c
mov dword [ebp - 0x3c], eax
mov dword [ebp - 0x50], ecx
mov dword [ebp - 0x38], 0xa
test bl, 1
je 0x402601
mov ecx, 0x8740
mov dword [ebp - 0x38], esi
mov dword [ebp - 0x50], ecx
test bl, 2
mov eax, str.runas
cmove eax, dword [ebp - 0x48]
mov dword [ebp - 0x48], eax
and ebx, 0x10000
jne 0x402621
or ecx, 0x100
mov dword [ebp - 0x50], ecx
mov eax, dword [0x430e6c]
push 5
push eax
mov dword [ebp - 0x4c], eax
call dword [sym.imp.USER32.dll_ShowWindow]
push dword [ebp - 0x4c]
call dword [sym.imp.USER32.dll_BringWindowToTop]
lea eax, [ebp - 0xc]
push eax
push dword [ebp + 8]
call fcn.00404cf6
pop ecx
pop ecx
push eax
lea ecx, [ebp - 0x18]
call fcn.004115b3
cmp dword [ebp - 8], esi
je 0x402689
mov eax, dword [ebp - 0xc]
mov dword [ebp - 0x44], eax
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x40], eax
lea eax, [ebp - 0x54]
push eax
call dword [sym.imp.SHELL32.dll_ShellExecuteExW]
test eax, eax
je 0x40268c
test ebx, ebx
jne 0x402680
push 0xffffffffffffffff
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor esi, esi
inc esi
push dword [ebp - 0x18]
call fcn.00419919
push dword [ebp - 0xc]
call fcn.00419919
pop ecx
pop ecx
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x402900
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
push edi
push dword [ebp + 8]
mov esi, ecx
call fcn.0040323d
xor edi, edi
mov dword [0x430e5c], esi
lea eax, [ebp - 4]
mov dword [0x430e64], edi
push eax
push edi
push esi
push 0x402cd8
push edi
push edi
call dword [sym.imp.KERNEL32.dll_CreateThread]
mov edx, eax
mov dword [0x430e60], edx
test edx, edx
je 0x402960
cmp dword [0x430e98], 2
je 0x402951
call fcn.004083b4
mov edx, dword [0x430e60]
push 0xffffffffffffffff
push edx
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov edx, dword [0x430e60]
mov eax, dword [0x430e64]
mov dword [0x430ffc], edi
test eax, eax
je 0x4029a2
cmp eax, 1
je 0x402996
cmp eax, 2
je 0x402992
cmp eax, 3
je 0x40298e
cmp eax, 0x67
jle 0x402988
cmp eax, 0x6b
jle 0x402a06
push eax
push 0x14
push edi
jmp 0x4029fe
push 0x12
jmp 0x402998
push 0x13
jmp 0x402998
push 0x11
push edi
call fcn.00409adc
pop ecx
pop ecx
jmp 0x402a06
mov ecx, edi
mov dword [ebp + 8], ecx
cmp dword [0x431000], ecx
jne 0x402a06
test edx, edx
je 0x4029cd
lea eax, [ebp + 8]
push eax
push edx
call dword [sym.imp.KERNEL32.dll_GetExitCodeThread]
mov ecx, dword [ebp + 8]
test eax, eax
je 0x4029cd
test ecx, ecx
jne 0x4029cd
xor eax, eax
jmp 0x402a0b
mov edx, 0x80070000
mov eax, ecx
and eax, edx
cmp eax, edx
je 0x4029df
push ecx
push 0x21
jmp 0x40298b
movzx eax, cx
cmp eax, 0xe
jne 0x4029f0
cmp dword [0x430e9c], 0xffffffff
je 0x402a06
push eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
push dword [ebp + 8]
push 0x22
push 1
call fcn.00409adc
add esp, 0xc
mov eax, 0x80004005
pop edi
pop esi
leave
ret 4
Function at 0x403769
Capabilities:
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_lstrlenW]
push ebx
lea ecx, [ebp - 0x18]
mov dword [ebp - 4], eax
mov edi, eax
call fcn.0041144a
xor esi, esi
lea ecx, [ebp - 0x18]
push esi
call fcn.00404031
push 0x2f
mov ebx, eax
mov eax, dword [ebp + 8]
pop ecx
push 0x5c
pop edx
movzx eax, word [eax + edi*2 - 2]
cmp ax, dx
je 0x4037af
cmp ax, cx
jne 0x4037e3
xor eax, eax
mov word [ebx + edi*2 - 2], ax
dec edi
mov dword [ebp - 4], edi
jmp 0x4037e3
test edi, edi
jle 0x4037db
push 0x2f
pop ecx
push 0x5c
pop edx
movzx eax, word [ebx + edi*2]
cmp ax, cx
je 0x4037d9
cmp ax, dx
je 0x4037d9
dec edi
test edi, edi
jg 0x4037c6
test edi, edi
je 0x403838
xor eax, eax
mov word [ebx + edi*2], ax
push ebx
call fcn.004057e3
pop ecx
test eax, eax
je 0x4037bc
lea eax, [ebp - 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemTimeAsFileTime]
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
test al, 0x10
jne 0x403817
lea eax, [ebp - 0xc]
push eax
push ebx
call fcn.00404399
pop ecx
pop ecx
test eax, eax
jne 0x4038bc
push ebx
call fcn.004057e3
pop ecx
test eax, eax
jne 0x4038b2
push ebx
push 0xc
push 1
call fcn.00409adc
add esp, 0xc
jmp 0x4038bc
cmp dword [ebp - 4], 2
mov ecx, dword [ebp + 8]
jne 0x403859
mov ax, word [ecx]
or ax, 0x20
sub ax, 0x61
cmp ax, 0x19
ja 0x403859
cmp word [ecx + 2], 0x3a
je 0x4038b9
push ecx
jmp 0x403827
sub eax, edi
lea esi, [ebx + edi*2]
inc eax
push eax
mov eax, dword [ebp + 8]
lea eax, [eax + edi*2]
push eax
push esi
call fcn.00416aa0
xor ecx, ecx
lea eax, [edi + 1]
add esp, 0xc
cmp word [esi], cx
cmove eax, edi
mov edi, eax
jmp 0x403896
movzx eax, cx
push 0x5c
pop ecx
cmp ax, cx
je 0x4038a1
push 0x2f
pop ecx
cmp ax, cx
je 0x4038a1
inc edi
movzx eax, word [ebx + edi*2]
mov ecx, eax
test ax, ax
jne 0x403882
xor eax, eax
push ebx
mov word [ebx + edi*2], ax
call fcn.004057e3
pop ecx
test eax, eax
je 0x4038cc
mov eax, dword [ebp - 4]
cmp edi, eax
jl 0x40385c
xor esi, esi
inc esi
push dword [ebp - 0x18]
call fcn.00419919
pop ecx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
push ebx
push 0xc
push 1
call fcn.00409adc
add esp, 0xc
xor esi, esi
jmp 0x4038bc
Function at 0x403be2
Capabilities:
Check if file exists
Get common file path
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
mov ecx, edi
call fcn.00411481
push 2
mov ecx, edi
call fcn.00404031
push eax
push 1
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
mov esi, eax
xor ebx, ebx
mov eax, dword [edi]
xor ecx, ecx
mov dword [edi + 4], ebx
mov word [eax], cx
test esi, esi
je 0x403c39
inc esi
mov ecx, edi
push esi
call fcn.00404031
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
mov esi, dword [edi]
push esi
call fcn.00404eab
pop ecx
xor ecx, ecx
mov dword [edi + 4], eax
mov word [esi + eax*2], cx
mov esi, dword [edi + 4]
mov dword [ebp + 8], esi
lea eax, [esi + 0xf]
push eax
mov ecx, edi
call fcn.00404031
push ebx
push dword [ebp + 0xc]
lea eax, [eax + esi*2]
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
mov esi, dword [edi]
push esi
call fcn.00404eab
add esp, 0x10
mov dword [edi + 4], eax
xor ecx, ecx
mov word [esi + eax*2], cx
push dword [edi]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x403c88
mov esi, dword [ebp + 8]
inc ebx
lea eax, [esi + 0xf]
cmp ebx, 0xfff
jl 0x403c42
mov eax, edi
pop edi
pop esi
pop ebx
pop ebp
ret

Function at 0x403c8f
Capabilities:
Delete directory
Delete file
Enumerate files on windows
Enumerate files recursively
Set current directory
Set file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x25c
push ebx
push esi
push dword [ebp + 8]
lea ecx, [ebp - 0xc]
call fcn.0041144a
push 0x426ba8
lea ecx, [ebp - 0xc]
call fcn.00411751
lea eax, [ebp - 0x25c]
push eax
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov ebx, eax
xor esi, esi
cmp ebx, 0xffffffff
je 0x403d6b
push dword [ebp + 8]
lea ecx, [ebp - 0xc]
call fcn.004115b3
push 0x5c
lea ecx, [ebp - 0xc]
call fcn.004018e1
lea eax, [ebp - 0x230]
push eax
lea ecx, [ebp - 0xc]
call fcn.00411751
test byte [ebp - 0x25c], 0x10
je 0x403d33
push 0x426bb0
lea eax, [ebp - 0x230]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpW]
test eax, eax
je 0x403d4e
push 0x426bb4
lea eax, [ebp - 0x230]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpW]
test eax, eax
je 0x403d4e
push dword [ebp - 0xc]
call fcn.00403c8f
pop ecx
jmp 0x403d4a
push esi
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
test eax, eax
je 0x403d95
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
je 0x403d95
lea eax, [ebp - 0x25c]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x403ccf
push ebx
call dword [sym.imp.KERNEL32.dll_FindClose]
push dword [0x430ed8]
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
push esi
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
test eax, eax
je 0x403d95
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
test eax, eax
je 0x403d95
xor esi, esi
inc esi
push dword [ebp - 0xc]
call fcn.00419919
pop ecx
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x404dc3
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
push edi
push 1
lea eax, [ebp - 4]
push eax
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
mov ecx, dword [ebp + 8]
mov edi, eax
call fcn.00411481
mov ecx, dword [ebp + 8]
lea esi, [edi + 2]
push esi
call fcn.00404031
lea eax, [edi + 1]
mov edi, dword [ebp + 8]
push eax
push esi
mov ecx, edi
call fcn.00404031
push eax
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
mov esi, dword [edi]
push esi
call fcn.00404eab
pop ecx
mov dword [edi + 4], eax
xor ecx, ecx
mov word [esi + eax*2], cx
mov eax, edi
pop edi
pop esi
leave
ret

Function at 0x4057e3
Capabilities:
Check if file exists
Create directory
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push esi
push 0
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x405825
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, 0xb7
cmp eax, esi
je 0x405810
push eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
jmp 0x405828
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x405825
test al, 0x10
jne 0x405825
push esi
jmp 0x405806
xor eax, eax
inc eax
pop esi
pop ebp
ret
Function at 0x405a7a
Capabilities:
Create process on windows
Get disk information
Self delete
Set file attributes
Write and execute a file
Write file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
sub esp, 0x30
push ebx
push edi
push 0x3a
pop edx
cmp word [eax + 2], dx
jne 0x405bfc
movzx ecx, word [eax + 4]
push esi
push 0x5c
pop esi
cmp cx, si
je 0x405aa8
cmp ecx, 0x2f
jne 0x405bfb
mov ax, word [eax]
mov word [ebp - 0xc], ax
xor eax, eax
mov word [ebp - 6], ax
lea eax, [ebp - 0xc]
push eax
mov word [ebp - 0xa], dx
mov word [ebp - 8], si
call dword [sym.imp.KERNEL32.dll_GetDriveTypeW]
cmp eax, 3
jne 0x405bf8
lea eax, [ebp - 0x24]
push str.7ZSfx_03x.cmd
push eax
call fcn.00403be2
pop ecx
pop ecx
xor eax, eax
push eax
push 0x80
push 2
push eax
push eax
push 0x40000000
push dword [ebp - 0x24]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
cmp edi, 0xffffffff
je 0x405bef
lea ecx, [ebp - 0x18]
call fcn.00411481
push str.:Repeat_r_n
lea ecx, [ebp - 0x18]
call fcn.004115b3
mov ebx, str.del__
lea ecx, [ebp - 0x18]
push ebx
call fcn.00411751
lea eax, [ebp + 8]
push eax
lea ecx, [ebp - 0x18]
call fcn.00411713
mov esi, 0x427c74
lea ecx, [ebp - 0x18]
push esi
call fcn.00411751
push str.if_exist__
lea ecx, [ebp - 0x18]
call fcn.00411751
lea eax, [ebp + 8]
push eax
lea ecx, [ebp - 0x18]
call fcn.00411713
push str.__goto_Repeat_r_n
lea ecx, [ebp - 0x18]
call fcn.00411751
push ebx
lea ecx, [ebp - 0x18]
call fcn.00411751
lea eax, [ebp - 0x24]
push eax
lea ecx, [ebp - 0x18]
call fcn.00411713
push esi
lea ecx, [ebp - 0x18]
call fcn.00411751
mov esi, dword [ebp - 0x14]
lea eax, [ebp - 0x18]
push 1
push eax
lea eax, [ebp - 0x30]
push eax
call fcn.00405873
add esp, 0xc
lea ecx, [ebp - 4]
xor ebx, ebx
push ebx
push ecx
push esi
push dword [eax]
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push dword [ebp - 0x30]
mov esi, eax
call fcn.00419919
pop ecx
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test esi, esi
je 0x405c07
mov eax, dword [ebp - 4]
cmp eax, dword [ebp - 0x14]
jne 0x405c07
push ebx
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
push ebx
push ebx
push ebx
push dword [ebp - 0x24]
push str.open
push ebx
call dword [sym.imp.SHELL32.dll_ShellExecuteW]
push dword [ebp - 0x18]
call fcn.00419919
pop ecx
push dword [ebp - 0x24]
call fcn.00419919
pop ecx
mov eax, dword [ebp + 8]
pop esi
push eax
call fcn.00419919
pop ecx
pop edi
pop ebx
leave
ret
push dword [ebp - 0x24]
call fcn.00403da4
push dword [ebp - 0x18]
call fcn.00419919
push dword [ebp - 0x24]
call fcn.00419919
add esp, 0xc
jmp 0x405bf8