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

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x538
push ebx
push esi
lea eax, [ebp - 0x10]
push eax
xor ebx, ebx
call dword [sym.imp.KERNEL32.dll_GetLocalTime]
movzx eax, word [ebp - 2]
push eax
movzx eax, word [ebp - 4]
push eax
movzx eax, word [ebp - 6]
push eax
movzx eax, word [ebp - 8]
push eax
movzx eax, word [ebp - 0xa]
push eax
movzx eax, word [ebp - 0xe]
push eax
movzx eax, word [ebp - 0x10]
push eax
push dword [0x101c298]
lea eax, [ebp - 0x338]
push 0x100c320
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x28
lea ecx, [ebp - 0x338]
call fcn.01016fef
push ebx
push 0x80
push 2
push ebx
push 1
push 0x40000000
push eax
mov dword [0x101c2b8], eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
cmp esi, 0xffffffff
jne 0x101773b
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea ecx, [ebp - 0x538]
call fcn.0100e252
push eax
lea eax, [ebp - 0x338]
push eax
push 0x100c2d0
call fcn.01011f22
add esp, 0xc
jmp 0x101779a
push ebx
lea eax, [ebp - 0x18]
push eax
push 2
lea eax, [ebp - 0x14]
push eax
push esi
mov dword [ebp - 0x14], 0xfeff
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x1017768
cmp dword [ebp - 0x18], 2
jne 0x1017768
mov dword [0x101c2b4], esi
mov bl, 1
jmp 0x10177a7
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea ecx, [ebp - 0x538]
call fcn.0100e252
push eax
lea eax, [ebp - 0x338]
push eax
push 0x100c270
call fcn.01011f22
add esp, 0xc
cmp esi, ebx
je 0x101779a
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [0x101c2b8], ebx
je 0x10177a7
call fcn.0101753d
pop esi
mov al, bl
pop ebx
leave
ret
Function at 0x10177b2
Capabilities:
Write file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x40c
push esi
push dword [ebp + 8]
lea eax, [ebp - 0x20c]
push 0x100c490
push 0x104
push eax
call fcn.010199d0
lea eax, [ebp - 0x20c]
push eax
push 0x100c474
push 7
call fcn.01017562
add esp, 0x1c
xor esi, esi
push esi
push esi
push 3
push esi
push 3
push 0x40000080
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
push eax
lea ecx, [ebp + 8]
call fcn.01019f50
cmp dword [ebp + 8], esi
jne 0x101785a
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, esi
jle 0x101782a
and eax, 0xffff
or eax, 0x80070000
mov esi, eax
push esi
lea ecx, [ebp - 0x40c]
call fcn.0100e252
push eax
lea eax, [ebp - 0x20c]
push eax
push 0x1002a7c
call fcn.01011f22
add esp, 0xc
lea ecx, [ebp + 8]
call fcn.01019f70
jmp 0x10178f5
mov eax, dword [ebp + 0xc]
push edi
xor edi, edi
mov ecx, 0xffffff00
inc edi
test eax, ecx
je 0x1017873
inc edi
shl ecx, 8
cmp edi, 4
jb 0x1017866
push dword [ebp + 8]
push edi
push eax
push 0x100c408
push 7
call fcn.01017562
add esp, 0x14
push esi
lea eax, [ebp - 4]
push eax
push 4
lea eax, [ebp + 0xc]
push eax
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x10178d0
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, esi
jle 0x10178b3
and eax, 0xffff
or eax, 0x80070000
mov esi, eax
push esi
lea ecx, [ebp - 0x40c]
call fcn.0100e252
push eax
push 0x100c3dc
call fcn.01011f22
pop ecx
pop ecx
jmp 0x10178ec
cmp dword [ebp - 4], 4
je 0x10178ec
push edi
push dword [ebp - 4]
push 0x100c398
call fcn.01011f22
add esp, 0xc
mov esi, 0xea
lea ecx, [ebp + 8]
call fcn.01019f70
pop edi
mov eax, esi
pop esi
leave
ret 8
Function at 0x1017cb1
Capabilities:
Check if file exists

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x1014
call fcn.01011270
push ebx
push esi
mov esi, dword [ebp + 0xc]
push edi
push esi
push 0x100cab0
push 7
call fcn.01017562
push 0x20
push esi
call fcn.01018aad
add esp, 0x14
test eax, eax
je 0x1017ce8
sub eax, esi
sar eax, 1
jmp 0x1017cef
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenW]
mov edi, eax
xor eax, eax
push edi
mov word [ebp - 0x74], ax
lea eax, [ebp - 0x74]
push esi
push eax
call fcn.01018f80
lea eax, [edi + edi]
xor ecx, ecx
mov word [ebp + eax - 0x74], cx
add esp, 0xc
lea ecx, [eax + esi]
xor edx, edx
call fcn.01019c70
lea ecx, [ebp - 0x74]
mov ebx, eax
call fcn.01012281
mov esi, dword [ebp + 8]
and dword [esi], 0
mov ecx, eax
mov dword [ebp - 4], ecx
test ecx, ecx
je case.0x1017dc7.1
call fcn.01011fc4
test dword [ebp + 0x10], eax
je case.0x1017dc7.1
push 5
lea eax, [ebp - 0x1014]
pop ecx
mov edi, 0x320
xor edx, edx
mov word [eax], dx
add eax, edi
dec ecx
jne 0x1017d52
and dword [ebp + 0xc], ecx
test ebx, ebx
je 0x1017db7
lea eax, [ebp - 0x1014]
mov dword [ebp + 8], eax
cmp word [ebx], 0
je 0x1017db7
cmp dword [ebp + 0xc], 5
jae 0x1017db7
xor edx, edx
mov ecx, ebx
call fcn.01019c70
cmp dword [ebp + 0xc], 0
je 0x1017d97
cmp word [eax], 0x2c
jne 0x1017d97
lea ecx, [eax + 2]
xor edx, edx
call fcn.01019c70
mov edx, dword [ebp + 8]
push 0x100caac
push 0x190
mov ecx, eax
call fcn.0101a1c0
inc dword [ebp + 0xc]
add dword [ebp + 8], edi
mov ebx, eax
test ebx, ebx
jne 0x1017d6c
mov eax, dword [ebp - 4]
xor ebx, ebx
dec eax
inc ebx
cmp eax, 0xa
ja case.default.0x1017dc7
jmp dword [eax*4 + 0x1017ef5]
lea eax, [ebp - 0x1014]
push eax
lea eax, [ebp + 8]
push eax
call fcn.0100ec81
mov eax, dword [eax]
or dword [esi], eax
jmp 0x1017eda
lea eax, [ebp - 0x1014]
push eax
lea eax, [ebp + 0x10]
push eax
call fcn.0100ef5f
jmp 0x1017dde
lea eax, [ebp - 0x1014]
push eax
lea eax, [ebp - 4]
push eax
call fcn.01015861
jmp 0x1017dde
lea eax, [ebp + 0xf]
push eax
lea eax, [ebp - 0x1014]
push eax
lea eax, [ebp - 0x10]
push eax
mov byte [ebp + 0xf], 0
call fcn.0100e05e
mov eax, dword [eax]
or dword [esi], eax
cmp byte [ebp + 0xf], 0
je 0x1017eda
push 0x100ca40
push 0x18
mov byte [0x101c1e0], bl
call fcn.01017562
jmp 0x1017ed8
lea eax, [ebp - 0x1014]
push eax
lea eax, [ebp - 8]
push eax
call fcn.010135cc
jmp 0x1017dde
lea eax, [ebp - 0x394]
push eax
lea eax, [ebp - 0x6b4]
push eax
lea eax, [ebp - 0x9d4]
push eax
lea eax, [ebp - 0xcf4]
push eax
lea eax, [ebp - 0x1014]
push eax
lea eax, [ebp - 0xc]
push eax
call fcn.010179e8
jmp 0x1017dde
lea eax, [ebp - 0x1014]
push eax
call fcn.01014245
test al, al
jne 0x1017eda
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
call edi
cmp eax, 2
je 0x1017eda
call edi
cmp eax, 3
je 0x1017eda
or dword [esi], ebx
jmp 0x1017eda
lea eax, [ebp - 0xcf4]
push eax
lea eax, [ebp - 0x1014]
push eax
call fcn.01014494
jmp 0x1017e97
lea eax, [ebp - 0x74]
push eax
push 0x100ca00
call fcn.01011efc
or dword [esi], ebx
pop ecx
pop ecx
cmp byte [0x101c1e7], 0
je case.0x1017dc7.1
or dword [esi], ebx
mov byte [0x101c1e7], 0
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret 0xc
Function at 0x1018835
Capabilities:
Check for time delay via gettickcount
Create thread

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x204
push ebx
push 0x101c1cc
xor ebx, ebx
push ebx
push ebx
push 0x10187bb
push ebx
push ebx
mov byte [ebp - 1], bl
call dword [sym.imp.KERNEL32.dll_CreateThread]
mov dword [0x101c1c8], eax
cmp eax, ebx
jne 0x1018887
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea ecx, [ebp - 0x202]
call fcn.0100e252
push eax
push 0x100d150
push 9
call fcn.01017562
add esp, 0xc
jmp 0x10188e5
push esi
mov esi, dword [sym.imp.KERNEL32.dll_GetTickCount]
push edi
call esi
mov edi, eax
cmp dword [0x101c1c4], ebx
jne 0x10188d1
call esi
sub eax, edi
cmp eax, 0xbb8
jae 0x10188b6
push 0x32
call dword [sym.imp.KERNEL32.dll_Sleep]
cmp dword [0x101c1c4], ebx
je 0x101889b
cmp dword [0x101c1c4], ebx
jne 0x10188d1
push 3
push 0x100d100
push 9
call fcn.01017562
add esp, 0xc
jmp 0x10188e3
push 1
push dword [0x101c1c4]
call dword [sym.imp.USER32.dll_ShowWindow]
mov byte [ebp - 1], 1
pop edi
pop esi
mov al, byte [ebp - 1]
pop ebx
leave
ret

Function at 0x101a040
Capabilities:
Get system information on windows
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov cx, word [0x100d620]
sub esp, 8
xor edx, edx
call fcn.01019ba0
mov al, byte [0x101c524]
test al, al
jne 0x101a1a6
push 0x101c408
mov dword [0x101c408], 0x11c
call dword [sym.imp.KERNEL32.dll_GetVersionExW]
test eax, eax
je 0x101a1aa
push esi
mov esi, dword [sym.imp.SHLWAPI.dll_SHGetValueW]
lea eax, [ebp - 4]
push eax
push 0x101c018
lea ecx, [ebp - 8]
push ecx
push 0x100d60c
push 0x100d5b0
push 0x80000002
mov dword [ebp - 4], 4
call esi
lea edx, [ebp - 4]
push edx
push 0x101c530
lea eax, [ebp - 8]
push eax
push 0x100d59c
push 0x100d5b0
push 0x80000002
mov dword [ebp - 4], 0x64
call esi
movzx cx, byte [0x101c40c]
movzx edx, byte [0x101c410]
shl cx, 8
movzx eax, cx
mov ecx, dword [0x101c414]
or eax, edx
mov dword [0x101c528], eax
mov dword [0x101c3e0], ecx
cmp eax, 0x500
jb 0x101a1a0
call fcn.0101a690
test al, al
je 0x101a1a0
push 0x101c3e4
call dword [sym.imp.KERNEL32.dll_GetSystemInfo]
mov edx, 0x100d580
mov ecx, 0x100d574
call fcn.0101a650
mov edx, 0x100d55c
mov ecx, 0x100d574
mov dword [0x101c3d0], eax
call fcn.0101a650
mov edx, 0x100d540
mov ecx, 0x100d52c
mov dword [0x101c3d4], eax
call fcn.0101a650
mov edx, 0x100d50c
mov ecx, 0x100d52c
mov dword [0x101c3cc], eax
call fcn.0101a650
push 0xc
mov dword [0x101c3d8], eax
call fcn.01011250
mov esi, eax
add esp, 4
test esi, esi
je 0x101a196
mov ecx, esi
call fcn.0101a630
mov al, 1
mov dword [0x101c3bc], esi
mov byte [0x101c524], al
pop esi
mov esp, ebp
pop ebp
ret
mov dword [0x101c3bc], 0
mov al, byte [0x101c524]
pop esi
mov esp, ebp
pop ebp
ret
mov al, byte [0x101c524]
mov esp, ebp
pop ebp
ret
Function at 0x407769
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1a4
mov edx, dword [ebp + 8]
xor ecx, ecx
mov eax, 0x40b190
cmp edx, dword [eax]
je 0x40778b
add eax, 8
inc ecx
cmp eax, 0x40b220
jl 0x40777c
push esi
mov esi, ecx
shl esi, 3
cmp edx, dword [esi + 0x40b190]
jne 0x4078b9
mov eax, dword [0x40bbb0]
cmp eax, 1
je 0x407893
test eax, eax
jne 0x4077bc
cmp dword [0x40b0e4], 1
je 0x407893
cmp edx, 0xfc
je 0x4078b9
lea eax, [ebp - 0x1a4]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x4077f3
lea eax, [ebp - 0x1a4]
push str._program_name_unknown_
push eax
call fcn.00408670
pop ecx
pop ecx
lea eax, [ebp - 0x1a4]
push edi
push eax
lea edi, [ebp - 0x1a4]
call fcn.00408490
inc eax
pop ecx
cmp eax, 0x3c
jbe 0x407836
lea eax, [ebp - 0x1a4]
push eax
call fcn.00408490
mov edi, eax
lea eax, [ebp - 0x1a4]
sub eax, 0x3b
push 3
add edi, eax
push 0x40a45c
push edi
call fcn.00408f00
add esp, 0x10
lea eax, [ebp - 0xa0]
push str.Runtime_Error__n_nProgram:
push eax
call fcn.00408670
lea eax, [ebp - 0xa0]
push edi
push eax
call fcn.00408680
lea eax, [ebp - 0xa0]
push 0x40a43c
push eax
call fcn.00408680
push dword [esi + 0x40b194]
lea eax, [ebp - 0xa0]
push eax
call fcn.00408680
push 0x12010
lea eax, [ebp - 0xa0]
push str.Microsoft_Visual_C_Runtime_Library
push eax
call fcn.00408e75
add esp, 0x2c
pop edi
jmp 0x4078b9
lea eax, [ebp + 8]
lea esi, [esi + 0x40b194]
push 0
push eax
push dword [esi]
call fcn.00408490
pop ecx
push eax
push dword [esi]
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
pop esi
leave
ret

Function at 0xae89f4
Capabilities:
Encode data using xor

Disassembly:
xor al, al
mov al, byte [edi]
xor al, bl
mov byte [edi], al
inc edi
cmp edi, ecx
jne fcn.00ae89f4
ret
Function at 0x40a4cc
Capabilities:
Encode data using xor

Disassembly:
inc eax
pop esi
xor dword [esi + 0xe], 0x2ffcd374
sub esi, 0xfffffffc
loop 0x40a4cf
inc ebp
sbb bl, byte [edx + 0x3a59dae]
invalid
Function at 0x4021f0
Capabilities:
Check if file exists
Get common file path
Get file attributes

Disassembly:
sub esp, 0x148
mov eax, dword [0x40e3e0]
xor eax, esp
mov dword [esp + 0x144], eax
push ebp
mov ebp, dword [esp + 0x154]
push esi
push edi
push 0x104
lea eax, [esp + 0x50]
push 0
push eax
call fcn.00404c50
mov eax, dword [esp + 0x164]
mov edi, dword [sym.imp.KERNEL32.dll_lstrlenA]
add esp, 0xc
sub eax, 1
je 0x4022b0
sub eax, 1
je 0x40229e
sub eax, 1
jne 0x402300
lea ecx, [esp + 0x4c]
push ecx
push eax
push eax
push 0x23
push eax
call fcn.00403140
add esp, 0x14
lea edx, [esp + 0x4c]
push edx
call edi
cmp byte [esp + eax + 0x4b], 0x5c
je 0x40226c
mov byte [esp + eax + 0x4c], 0x5c
mov byte [esp + eax + 0x4d], 0
lea eax, [esp + 0x4c]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x402300
mov byte [ebp], 0
pop edi
pop esi
xor eax, eax
pop ebp
mov ecx, dword [esp + 0x144]
xor ecx, esp
call fcn.00404c23
add esp, 0x148
ret
lea ecx, [esp + 0x4c]
push ecx
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
jmp 0x402254
push 0x104
lea ecx, [esp + 0x50]
push ecx
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
lea edx, [esp + 0x4c]
push edx
call edi
cmp byte [esp + eax + 0x4b], 0x5c
je 0x4022d4
mov byte [esp + eax + 0x4c], 0x5c
inc eax
lea esi, [esp + eax + 0x4c]
push str.Temp
push esi
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
lea eax, [esp + 0x4c]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x402280
push 0x40b28c
push esi
call dword [sym.imp.KERNEL32.dll_lstrcatA]
push str.24101817283862757652396
call edi
dec eax
cmp eax, 8
jl 0x402284
mov al, byte [eax + str.24101817283862757652396]
cmp al, 0x30
jl 0x402284
cmp al, 0x39
jg 0x402284
movsx esi, al
sub esi, 0x30
and esi, reloc.WS2_32.dll_closesocket
jns 0x40233a
dec esi
or esi, 0xfffffffc
inc esi
push str.24101817283862757652396
add esi, 4
call edi
sub eax, esi
dec eax
xor ecx, ecx
lea eax, [eax + str.24101817283862757652396]
nop
mov dl, byte [eax]
test dl, dl
je 0x4023b5
test esi, esi
jle 0x4023b5
add dl, dl
inc dl
inc eax
mov byte [esp + ecx + 0xc], dl
mov dl, byte [eax]
dec esi
test dl, dl
je 0x4023aa
test esi, esi
jle 0x4023aa
add dl, dl
inc dl
inc eax
mov byte [esp + ecx + 0xd], dl
mov dl, byte [eax]
dec esi
test dl, dl
je 0x4023ad
test esi, esi
jle 0x4023ad
add dl, dl
inc dl
inc eax
mov byte [esp + ecx + 0xe], dl
mov dl, byte [eax]
dec esi
test dl, dl
je 0x4023b2
test esi, esi
jle 0x4023b2
add dl, dl
inc dl
mov byte [esp + ecx + 0xf], dl
add ecx, 4
dec esi
inc eax
cmp ecx, 0x40
jb 0x402350
jmp 0x4023b5
inc ecx
jmp 0x4023b5
add ecx, 2
jmp 0x4023b5
add ecx, 3
mov byte [esp + ecx + 0xc], 0x2e
push 0x40b288
lea ecx, [esp + ecx + 0x11]
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
lea edx, [esp + 0x4c]
push edx
call edi
mov ecx, 0x104
sub ecx, eax
push ecx
lea edx, [esp + 0x10]
push edx
lea eax, [esp + 0x54]
push eax
call edi
mov esi, dword [sym.imp.KERNEL32.dll_lstrcpynA]
lea ecx, [esp + eax + 0x54]
push ecx
call esi
push 0x103
lea edx, [esp + 0x50]
push edx
push ebp
call esi
mov ecx, dword [esp + 0x150]
pop edi
pop esi
pop ebp
xor ecx, esp
mov eax, 1
call fcn.00404c23
add esp, 0x148
ret
Function at 0x401156
Capabilities:
Get graphical window text

Disassembly:
mov eax, dword [0x4425c0]
push esi
test eax, eax
mov esi, ecx
je 0x40120f
movzx ecx, word [esi + 0x18]
push ecx
push eax
call dword [sym.imp.USER32.dll_LoadBitmapA]
test eax, eax
mov dword [esi + 0x28], eax
je 0x40120f
push ebx
push edi
mov edi, dword [sym.imp.USER32.dll_GetWindowLongA]
push 0xfffffffffffffff0
push dword [esi + 8]
call edi
push 0xffffffffffffffec
mov ebx, eax
push dword [esi + 8]
call edi
test bl, 0x20
jne 0x40119f
test ah, 0x10
je 0x4011a3
mov byte [esi + 0xc], 1
lea eax, [esi + 0x4c]
push 0x40
push eax
push dword [esi + 8]
call dword [sym.imp.USER32.dll_GetWindowTextA]
push 0
push 0
push 0x31
push dword [esi + 4]
call dword [sym.imp.USER32.dll_SendMessageA]
push dword [esi + 8]
mov dword [esi + 0x48], eax
call dword [sym.imp.USER32.dll_IsWindowEnabled]
test eax, eax
jne 0x4011dc
mov byte [esi + 0xd], 1
mov dword [esi + 0x10], 5
push 0xfffffffffffffff0
push dword [esi + 8]
call edi
mov edi, dword [sym.imp.USER32.dll_SetWindowLongA]
or al, 0xb
push eax
push 0xfffffffffffffff0
push dword [esi + 8]
call edi
push 0x401211
push 0xfffffffffffffffc
push dword [esi + 8]
call edi
push esi
push 0xffffffffffffffeb
push dword [esi + 8]
mov dword [esi + 0x164], eax
call edi
pop edi
pop ebx
pop esi
ret
Function at 0x401e01
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x28
push ebx
push esi
mov eax, dword [ebp + 0x10]
push edi
push 4
pop ebx
push 1
pop edx
cmp ax, dx
ja 0x401e1d
mov dword [ebp + 0x10], edx
jmp 0x401e45
cmp ax, bx
ja 0x401e27
mov dword [ebp + 0x10], ebx
jmp 0x401e45
push 8
pop ecx
cmp ax, cx
ja 0x401e34
mov dword [ebp + 0x10], ecx
jmp 0x401e45
mov cx, 0x18
cmp cx, ax
sbb eax, eax
and al, 0xec
add eax, 0x18
mov dword [ebp + 0x10], eax
mov eax, dword [ebp + 0xc]
mov edi, dword [ebp + 8]
mov dword [ebp - 0x20], eax
mov ax, word [ebp + 0x10]
mov word [ebp - 0x1a], ax
lea eax, [ebp - 0x28]
xor esi, esi
push eax
mov dword [ebp - 0x28], 0x28
mov dword [ebp - 0x24], edi
mov word [ebp - 0x1c], dx
mov dword [ebp - 0x18], esi
mov dword [ebp - 0x14], esi
mov dword [ebp - 0x10], esi
mov dword [ebp - 0xc], esi
mov dword [ebp - 8], esi
mov dword [ebp - 4], esi
call fcn.00401fdd
pop ecx
mov edx, dword [ebp - 0x28]
movzx ecx, ax
movzx eax, word [ebp + 0x10]
imul eax, edi
add eax, 0x1f
add edx, ecx
shr eax, 3
and eax, 0x1ffffffc
imul eax, dword [ebp + 0xc]
add eax, edx
push eax
push 0x42
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
cmp eax, esi
mov dword [ebp + 0xc], eax
jne 0x401eb9
xor eax, eax
jmp 0x401f9f
push eax
call dword [sym.imp.KERNEL32.dll_GlobalLock]
cmp word [ebp + 0x10], bx
push 0xa
pop ecx
lea esi, [ebp - 0x28]
mov edi, eax
mov dword [ebp + 8], eax
rep movsd dword es:[edi], dword [esi]
jne 0x401edc
mov dword [eax + 0x20], 0x10
jmp 0x401eea
cmp word [ebp + 0x10], 8
jne 0x401eea
mov dword [eax + 0x20], 0x100
mov ecx, dword [eax]
push 0x10
add ecx, eax
mov eax, dword [eax + 0x20]
cdq
pop edi
xor esi, esi
idiv edi
test eax, eax
jle 0x401f93
and dword [ecx], 0
add ecx, ebx
mov eax, dword [ebp + 8]
push 0x10
mov dword [ecx], 0x800000
add ecx, ebx
pop edi
mov dword [ecx], 0x8000
add ecx, ebx
mov dword [ecx], 0x808000
add ecx, ebx
mov dword [ecx], 0x80
add ecx, ebx
mov dword [ecx], 0x800080
add ecx, ebx
mov dword [ecx], 0x8080
add ecx, ebx
mov dword [ecx], 0xc0c0c0
add ecx, ebx
mov dword [ecx], 0x808080
add ecx, ebx
mov dword [ecx], 0xff0000
add ecx, ebx
mov dword [ecx], 0xff00
add ecx, ebx
mov dword [ecx], 0xffff00
add ecx, ebx
mov dword [ecx], 0xff
add ecx, ebx
mov dword [ecx], 0xff00ff
add ecx, ebx
mov dword [ecx], 0xffff
add ecx, ebx
mov dword [ecx], 0xffffff
mov eax, dword [eax + 0x20]
cdq
idiv edi
add ecx, ebx
inc esi
cmp esi, eax
jl 0x401f01
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_GlobalUnlock]
mov eax, dword [ebp + 0xc]
pop edi
pop esi
pop ebx
leave
ret
Function at 0x4021c0
Capabilities:
Extract resource via kernel32 functions
Get common file path

Disassembly:
mov eax, 0x433304
call fcn.0041bd98
sub esp, 0x21c
push ebx
push esi
push edi
lea eax, [ebp - 0x228]
mov dword [ebp - 4], 1
push eax
push 0x96
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
call fcn.00431e41
push dword [ebp + 8]
mov eax, dword [eax + 8]
push dword [ebp + 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_FindResourceA]
mov esi, eax
xor ebx, ebx
cmp esi, ebx
je 0x402346
call fcn.00431e41
mov eax, dword [eax + 8]
push esi
push eax
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov dword [ebp - 0x18], eax
call fcn.00431e41
mov eax, dword [eax + 8]
push esi
push eax
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov edi, dword [ebp + 0x10]
cmp eax, ebx
mov byte [edi], bl
je 0x402346
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
cmp eax, ebx
mov dword [ebp - 0x14], eax
je 0x402346
push ecx
mov esi, 0x4425cc
mov ecx, esp
mov dword [ebp - 0x10], esp
push esi
call fcn.0042b00b
push ecx
mov byte [ebp - 4], 2
mov ecx, esp
mov dword [ebp - 0x1c], esp
push esi
call fcn.0042b00b
push ecx
mov byte [ebp - 4], 3
mov ecx, esp
mov dword [ebp - 0x20], esp
push 0x43c1b8
call fcn.0042b00b
lea eax, [ebp + 0x10]
mov byte [ebp - 4], 1
push eax
call fcn.0040338d
add esp, 0x10
mov eax, dword [ebp + 0x10]
cmp dword [eax - 8], ebx
je 0x402305
push eax
lea eax, [ebp - 0x124]
push eax
call fcn.0041c320
pop ecx
lea eax, [ebp - 0x124]
pop ecx
push ebx
push eax
call dword [sym.imp.KERNEL32.dll__lcreat]
cmp eax, 0xffffffff
mov dword [ebp - 0x10], eax
je 0x402305
lea eax, [ebp - 0x124]
push eax
push edi
call fcn.0041c320
mov edi, dword [ebp - 0x18]
pop ecx
pop ecx
cmp edi, ebx
je 0x40232c
mov esi, 0x7fff
cmp edi, esi
ja 0x4022e3
movzx esi, di
push esi
push dword [ebp - 0x14]
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll__lwrite]
cmp eax, 0xffffffff
je 0x4022fc
sub edi, esi
add dword [ebp - 0x14], esi
jmp 0x4022d3
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll__lclose]
lea ecx, [ebp + 0x10]
mov byte [ebp - 4], 1
call fcn.0042af9d
lea ecx, [ebp + 8]
mov byte [ebp - 4], bl
call fcn.0042af9d
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0xc]
call fcn.0042af9d
xor eax, eax
jmp 0x402361
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll__lclose]
lea ecx, [ebp + 0x10]
mov byte [ebp - 4], 1
call fcn.0042af9d
push 1
pop esi
jmp 0x402348
xor esi, esi
lea ecx, [ebp + 8]
mov byte [ebp - 4], bl
call fcn.0042af9d
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0xc]
call fcn.0042af9d
mov eax, esi
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
leave
ret

Function at 0x402370
Capabilities:
Delete file
Set file attributes

Disassembly:
push esi
mov esi, dword [esp + 8]
push esi
call fcn.004025f7
test eax, eax
pop ecx
je 0x402393
push 0x80
push esi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
pop esi
ret
Function at 0x402630
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
lea eax, [ebp + 8]
push esi
push eax
lea eax, [ebp + 0xc]
xor esi, esi
push eax
push esi
push 0xf003f
push esi
push esi
push esi
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
test eax, eax
je 0x40265b
xor eax, eax
jmp 0x402689
push dword [ebp + 0x14]
call fcn.0041c410
pop ecx
push eax
push dword [ebp + 0x14]
push 1
push esi
push dword [ebp + 0x10]
push dword [ebp + 0xc]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
jne 0x40267e
push 1
pop esi
push dword [ebp + 0xc]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, esi
pop esi
pop ebp
ret

Function at 0x40268c
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
lea eax, [ebp + 8]
push esi
push eax
lea eax, [ebp + 0xc]
xor esi, esi
push eax
push esi
push 0xf003f
push esi
push esi
push esi
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
test eax, eax
je 0x4026b7
xor eax, eax
jmp 0x4026de
lea eax, [ebp + 0x14]
push 4
push eax
push 4
push esi
push dword [ebp + 0x10]
push dword [ebp + 0xc]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
jne 0x4026d3
push 1
pop esi
push dword [ebp + 0xc]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, esi
pop esi
pop ebp
ret

Function at 0x4026e1
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
lea eax, [ebp + 0xc]
push esi
push eax
push 1
push 0
mov dword [ebp - 4], 0x103
push dword [ebp + 0xc]
mov dword [ebp - 8], 1
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x40272b
mov esi, dword [ebp + 0x14]
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 8]
push esi
push eax
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
je 0x40272f
xor eax, eax
jmp 0x40273f
mov eax, dword [ebp - 4]
add eax, esi
cmp byte [eax], 0
je 0x40273c
and byte [eax], 0
push 1
pop eax
pop esi
leave
ret