joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4a6b20
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffde0
push ebx
push esi
xor ebx, ebx
mov dword [ebp - 0x220], ebx
mov dword [ebp - 0x218], ebx
mov dword [ebp - 0x21c], ebx
mov dword [ebp - 0x214], ebx
mov dword [ebp - 0x210], ebx
mov dword [ebp - 8], ebx
test dl, dl
je 0x4a6b5a
add esp, 0xfffffff0
call fcn.00403f0c
mov dword [ebp - 4], ecx
mov ebx, edx
mov esi, eax
mov eax, dword [ebp - 4]
call fcn.00404f88
mov eax, dword [ebp + 0xc]
call fcn.00404f88
mov eax, dword [ebp + 8]
call fcn.00404f88
xor eax, eax
push ebp
push 0x4a6cb3
push dword fs:[eax]
mov dword fs:[eax], esp
mov byte [esi + 0x5d], 0
mov byte [esi + 0x40], 0
lea eax, [esi + 0x44]
mov edx, dword [ebp - 4]
call fcn.00404b10
lea eax, [esi + 0x48]
mov edx, dword [ebp + 0xc]
call fcn.00404b10
lea eax, [esi + 0x4c]
mov edx, dword [ebp + 8]
call fcn.00404b10
lea eax, [ebp - 0x210]
call fcn.004a6960
mov edx, dword [ebp - 0x210]
lea eax, [esi + 0x50]
call fcn.00404b10
lea eax, [ebp - 0x214]
call fcn.004a5e58
mov edx, dword [ebp - 0x214]
lea eax, [esi + 0x54]
call fcn.00404b10
lea eax, [ebp - 0x21c]
call fcn.004a5ec0
mov eax, dword [ebp - 0x21c]
lea edx, [ebp - 0x218]
call fcn.004a667c
mov edx, dword [ebp - 0x218]
lea eax, [esi + 0x58]
call fcn.00404b10
push 0x200
lea eax, [ebp - 0x209]
push eax
call sub.kernel32.dll_GetSystemDirectoryA
lea eax, [ebp - 8]
lea edx, [ebp - 0x209]
mov ecx, 0x201
call fcn.00404d2c
mov eax, dword [ebp - 8]
call fcn.00404d98
mov edx, dword [ebp - 8]
cmp byte [edx + eax - 1], 0x5c
je 0x4a6c4f
lea eax, [ebp - 8]
mov edx, 0x4a6ce4
call fcn.00404da0
lea eax, [ebp - 0x220]
mov ecx, 0x4a6cf0
mov edx, dword [ebp - 8]
call fcn.00404de4
mov eax, dword [ebp - 0x220]
call fcn.00409d98
mov byte [esi + 0x5c], al
xor ecx, ecx
xor edx, edx
mov eax, esi
call fcn.00427488
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4a6cba
lea eax, [ebp - 0x220]
mov edx, 5
call fcn.00404ae0
lea eax, [ebp - 8]
mov edx, 2
call fcn.00404ae0
lea eax, [ebp + 8]
mov edx, 2
call fcn.00404ae0
ret
Function at 0x4bbb94
Capabilities:
Access peb ldr_data
Get kernel32 base address

Disassembly:
push ebp
mov ebp, esp
mov ecx, 8
push 0
push 0
dec ecx
jne 0x4bbb9c
push ecx
push ebx
push esi
push edi
mov ebx, eax
xor eax, eax
push ebp
push 0x4bbd8e
push dword fs:[eax]
mov dword fs:[eax], esp
mov esi, dword [ebx + 8]
lea ecx, [ebp - 0xc]
mov edx, 0x4bbda4
mov eax, esi
call fcn.004b8454
mov edx, dword [ebp - 0xc]
lea eax, [ebx + 0xc]
call fcn.00404b10
lea ecx, [ebp - 0x10]
mov edx, 0x4bbdb8
mov eax, esi
call fcn.004b8454
mov edx, dword [ebp - 0x10]
lea eax, [ebx + 0x28]
call fcn.00404b10
lea ecx, [ebp - 0x14]
mov edx, 0x4bbdd0
mov eax, esi
call fcn.004b8454
mov edx, dword [ebp - 0x14]
lea eax, [ebx + 0x10]
call fcn.00404b10
lea ecx, [ebp - 0x18]
mov edx, 0x4bbdec
mov eax, esi
call fcn.004b8454
mov edx, dword [ebp - 0x18]
lea eax, [ebx + 0x14]
call fcn.00404b10
lea ecx, [ebp - 0x1c]
mov edx, 0x4bbe08
mov eax, esi
call fcn.004b8454
mov edx, dword [ebp - 0x1c]
lea eax, [ebx + 0x24]
call fcn.00404b10
lea ecx, [ebp - 0x24]
mov edx, 0x4bbe20
mov eax, esi
call fcn.004b8454
mov eax, dword [ebp - 0x24]
lea edx, [ebp - 0x20]
call fcn.00409514
mov eax, dword [ebp - 0x20]
or edx, 0xffffffff
call fcn.004099c4
mov edi, eax
mov dword [ebx + 0x18], edi
test edi, edi
setge al
mov byte [ebx + 0x4c], al
lea ecx, [ebp - 0x28]
mov edx, 0x4bbe38
mov eax, esi
call fcn.004b8454
mov eax, dword [ebp - 0x28]
call fcn.004ac864
fstp qword [ebx + 0x30]
wait
lea ecx, [ebp - 0x2c]
mov edx, 0x4bbe48
mov eax, esi
call fcn.004b8454
mov eax, dword [ebp - 0x2c]
call fcn.004ac864
fstp qword [ebx + 0x40]
wait
lea ecx, [ebp - 0x30]
mov edx, 0x4bbe60
mov eax, esi
call fcn.004b8454
mov eax, dword [ebp - 0x30]
or edx, 0xffffffff
call fcn.004099c4
inc eax
je 0x4bbd31
lea ecx, [ebp - 0x34]
mov edx, 0x4bbe60
mov eax, esi
call fcn.004b8454
mov eax, dword [ebp - 0x34]
call fcn.00409988
mov edi, eax
mov eax, edi
mov ecx, 0xe10
cdq
idiv ecx
mov dword [ebp - 8], eax
mov eax, edi
mov ecx, 0xe10
cdq
idiv ecx
mov ecx, edx
mov eax, ecx
push ecx
mov ecx, 0x3c
cdq
idiv ecx
pop ecx
mov dword [ebp - 4], eax
mov eax, ecx
mov ecx, 0x3c
cdq
idiv ecx
mov edi, edx
push 0
mov ecx, edi
mov dx, word [ebp - 4]
mov ax, word [ebp - 8]
call fcn.0040b5ec
fstp qword [ebp - 0x3c]
wait
call fcn.0040b9ec
fadd qword [ebp - 0x3c]
fstp qword [ebx + 0x38]
wait
jmp 0x4bbd4c
lea ecx, [ebp - 0x40]
mov edx, 0x4bbe60
mov eax, esi
call fcn.004b8454
mov eax, dword [ebp - 0x40]
call fcn.004ac864
fstp qword [ebx + 0x38]
wait
lea ecx, [ebp - 0x44]
mov edx, 0x4bbe70
mov eax, esi
call fcn.004b8454
mov edx, dword [ebp - 0x44]
lea eax, [ebx + 0x48]
call fcn.00404b10
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4bbd95
lea eax, [ebp - 0x44]
mov edx, 2
call fcn.00404ae0
lea eax, [ebp - 0x34]
mov edx, 0xb
call fcn.00404ae0
ret
Function at 0x4c1548
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffbf8
push ebx
xor edx, edx
mov dword [ebp - 0x408], edx
mov dword [ebp - 4], edx
mov ebx, eax
xor eax, eax
push ebp
push 0x4c15cd
push dword fs:[eax]
mov dword fs:[eax], esp
push 0x3ff
lea eax, [ebp - 0x404]
push eax
call sub.kernel32.dll_GetSystemDirectoryA
lea eax, [ebp - 0x408]
lea edx, [ebp - 0x404]
mov ecx, 0x400
call fcn.00404d2c
mov eax, dword [ebp - 0x408]
lea edx, [ebp - 4]
call fcn.004bfdd0
mov eax, ebx
mov edx, dword [ebp - 4]
call fcn.00404b10
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4c15d4
lea eax, [ebp - 0x408]
call fcn.00404abc
lea eax, [ebp - 4]
call fcn.00404abc
ret

Function at 0x4ca8c4
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffff7f0
push ebx
push esi
push edi
xor edx, edx
mov dword [ebp - 0x810], edx
mov dword [ebp - 4], edx
mov dword [ebp - 8], edx
mov dword [ebp - 0xc], edx
mov ebx, eax
xor eax, eax
push ebp
push 0x4ca9a6
push dword fs:[eax]
mov dword fs:[eax], esp
xor eax, eax
push ebp
push 0x4ca976
push dword fs:[eax]
mov dword fs:[eax], esp
lea eax, [ebp - 0x80c]
push eax
push 0x7ff
call sub.kernel32.dll_GetTempPathA
lea eax, [ebp - 4]
lea edx, [ebp - 0x80c]
mov ecx, 0x800
call fcn.00404d2c
lea eax, [ebp - 0xc]
mov edx, 0x4ca9bc
call fcn.00404b54
lea edx, [ebp - 8]
mov eax, dword [ebp - 0xc]
call fcn.004a5adc
lea eax, [ebp - 0x810]
mov ecx, dword [ebp - 8]
mov edx, dword [ebp - 4]
call fcn.00404de4
mov eax, dword [ebp - 0x810]
push eax
mov eax, dword [ebp - 4]
push eax
mov ecx, dword [ebp - 0xc]
mov dl, 1
mov eax, dword [0x4a68c4]
call fcn.004a6b20
mov dword [ebx + 0x350], eax
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x4ca980
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4ca9ad
lea eax, [ebp - 0x810]
call fcn.00404abc
lea eax, [ebp - 0xc]
mov edx, 3
call fcn.00404ae0
ret
Function at 0x402f4e
Capabilities:
Read file on windows
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
xor edi, edi
cmp eax, edi
jl 0x402f7b
mov ecx, dword [0x7a2ff8]
push edi
add eax, ecx
push edi
push eax
mov dword [0x79594c], eax
push dword [0x409024]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 4
pop esi
push esi
call fcn.00403079
cmp eax, edi
jl 0x403072
lea eax, [ebp - 4]
mov ebx, dword [sym.imp.KERNEL32.dll_ReadFile]
push edi
push eax
lea eax, [ebp + 8]
push esi
push eax
push dword [0x409024]
call ebx
test eax, eax
je 0x40306f
cmp dword [ebp - 4], esi
jne 0x40306f
push dword [ebp + 8]
add dword [0x79594c], esi
call fcn.00403079
cmp eax, edi
mov dword [ebp - 8], eax
jl 0x403072
cmp dword [ebp + 0x10], edi
jne 0x40303e
cmp dword [ebp + 8], edi
jle 0x40306a
mov esi, 0x791908
mov edi, 0x4000
cmp dword [ebp + 8], edi
jge 0x402fee
mov edi, dword [ebp + 8]
lea eax, [ebp - 4]
push 0
push eax
push edi
push esi
push dword [0x409024]
call ebx
test eax, eax
je 0x40306f
cmp edi, dword [ebp - 4]
jne 0x40306f
lea eax, [ebp + 0x14]
push 0
push eax
push dword [ebp - 4]
push esi
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x40303a
cmp dword [ebp + 0x14], edi
jne 0x40303a
mov eax, dword [ebp - 4]
add dword [ebp - 8], eax
sub dword [ebp + 8], eax
add dword [0x79594c], eax
cmp dword [ebp + 8], 0
jg 0x402fe1
jmp 0x40306a
push 0xfffffffffffffffe
jmp 0x403071
mov eax, dword [ebp + 8]
cmp eax, dword [ebp + 0x14]
jl 0x403049
mov eax, dword [ebp + 0x14]
lea ecx, [ebp - 4]
push edi
push ecx
push eax
push dword [ebp + 0x10]
push dword [0x409024]
call ebx
test eax, eax
je 0x40306f
mov eax, dword [ebp - 4]
add dword [0x79594c], eax
mov dword [ebp - 8], eax
mov eax, dword [ebp - 8]
jmp 0x403072
push 0xfffffffffffffffd
pop eax
pop edi
pop esi
pop ebx
leave
ret 0x10
Function at 0x403079
Capabilities:
Check for time delay via gettickcount
Write file on windows

Disassembly:
push ecx
push ecx
push ebx
push ebp
push esi
xor ebp, ebp
push edi
mov dword [esp + 0x10], ebp
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov esi, dword [0x79594c]
mov edi, eax
sub esi, dword [0x40b03c]
add edi, 0x1f4
add esi, dword [esp + 0x1c]
cmp esi, ebp
jle 0x40324f
push dword [0x79d95c]
call fcn.0040328c
push ebp
push ebp
push dword [0x40b03c]
push dword [0x409024]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov dword [0x79d958], esi
mov dword [0x795948], ebp
mov eax, dword [0x795950]
mov ebx, 0x4000
sub eax, dword [0x79d95c]
cmp eax, ebx
jg 0x4030ec
mov ebx, eax
mov esi, 0x791908
push ebx
push esi
call fcn.0040325a
test eax, eax
je 0x40321a
add dword [0x79d95c], ebx
mov dword [0x40b040], esi
mov dword [0x40b044], ebx
cmp dword [0x7a2fa8], ebp
je 0x40317d
cmp dword [0x7a3040], ebp
jne 0x40317d
cmp dword [esp + 0x10], ebp
je 0x40314a
mov eax, dword [0x79d958]
push ebp
sub eax, dword [0x79594c]
sub eax, dword [esp + 0x20]
add eax, dword [0x40b03c]
mov dword [0x795948], eax
call fcn.00405ea6
jmp 0x40317d
call dword [sym.imp.KERNEL32.dll_GetTickCount]
cmp eax, edi
jbe 0x40317d
mov eax, dword [0x7a2fa4]
neg eax
sbb eax, eax
not eax
and eax, str.unpacking_data:__d__
push eax
push 0x402ba6
push ebp
push 0x6f
push dword [0x7a2fa0]
call dword [sym.imp.USER32.dll_CreateDialogParamA]
mov dword [esp + 0x10], eax
push 0x40b040
mov dword [0x40b048], 0x789908
mov dword [0x40b04c], 0x8000
call fcn.00405f47
test eax, eax
jl 0x403223
mov esi, dword [0x40b048]
mov eax, 0x789908
sub esi, eax
je 0x4031e4
lea ecx, [esp + 0x14]
push ebp
push ecx
push esi
push eax
push dword [0x409024]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x40321f
cmp esi, dword [esp + 0x14]
jne 0x40321f
add dword [0x40b03c], esi
cmp dword [0x40b044], ebp
jne 0x403112
jmp 0x4031f0
cmp dword [0x40b044], ebp
jne 0x403223
cmp ebx, ebp
je 0x403223
mov eax, dword [0x79594c]
mov ecx, eax
sub ecx, dword [0x40b03c]
add ecx, dword [esp + 0x1c]
test ecx, ecx
jg 0x4030d6
push ebp
push ebp
push eax
push dword [0x409024]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
jmp 0x403228
or eax, 0xffffffff
jmp 0x403251
push 0xfffffffffffffffe
jmp 0x403225
push 0xfffffffffffffffd
pop eax
jmp 0x403251
mov esi, dword [esp + 0x10]
cmp esi, ebp
je 0x40324f
mov eax, dword [0x79d958]
push ebp
push ebp
push 0x113
push esi
mov dword [0x795948], eax
call dword [sym.imp.USER32.dll_SendMessageA]
push esi
call dword [sym.imp.USER32.dll_DestroyWindow]
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
pop ecx
pop ecx
ret 4
Function at 0x4053e1
Capabilities:
Check if file exists
Create process on windows
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push dword [ebp + 0xc]
mov dword [0x7a15b0], 0x44
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
xor ecx, ecx
cmp eax, 0xffffffff
je 0x405405
test al, 0x10
jne 0x405408
mov dword [ebp + 0xc], ecx
lea eax, [ebp - 0x10]
push eax
push 0x7a15b0
push dword [ebp + 0xc]
push ecx
push ecx
push ecx
push ecx
push ecx
push dword [ebp + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
test eax, eax
je 0x405433
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x10]
leave
ret 8
Function at 0x40549b
Capabilities:
Delete directory
Delete file
Enumerate files on windows
Enumerate files recursively

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x148
push ebx
mov ebx, dword [ebp + 8]
push esi
push ebx
call fcn.0040573c
mov ecx, dword [ebp + 0xc]
mov dword [ebp - 8], eax
test cl, 8
je 0x4054d1
push ebx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
neg eax
sbb eax, eax
inc eax
add dword [0x7a3028], eax
jmp 0x405656
mov dword [ebp + 8], ecx
push edi
and dword [ebp + 8], 1
je 0x4054ec
test eax, eax
je 0x405601
test cl, 2
je 0x405601
mov esi, 0x7a05b0
push ebx
push esi
call fcn.00405b69
cmp dword [ebp + 8], 0
je 0x40550b
push str..
push esi
call sub.KERNEL32.dll_lstrcatA
jmp 0x405511
push ebx
call fcn.004056a3
push 0x409010
push ebx
call sub.KERNEL32.dll_lstrcatA
push ebx
call sub.KERNEL32.dll_lstrlenA
mov edi, eax
lea eax, [ebp - 0x148]
push eax
push esi
add edi, ebx
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
cmp eax, 0xffffffff
mov dword [ebp - 4], eax
je 0x4055f7
lea eax, [ebp - 0x11c]
push 0x3f
push eax
lea esi, [ebp - 0x11c]
call fcn.00405687
cmp byte [eax], 0
je 0x405562
cmp byte [ebp - 0x18], 0
je 0x405562
lea esi, [ebp - 0x18]
cmp byte [esi], 0x2e
jne 0x405578
mov al, byte [esi + 1]
test al, al
je 0x4055d6
cmp al, 0x2e
jne 0x405578
cmp byte [esi + 2], 0
je 0x4055d6
push esi
push edi
call fcn.00405b69
test byte [ebp - 0x148], 0x10
je 0x40559d
mov eax, dword [ebp + 0xc]
and eax, 3
cmp al, 3
jne 0x4055d6
push dword [ebp + 0xc]
push ebx
call fcn.0040549b
jmp 0x4055d6
push ebx
call fcn.00405820
push ebx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
test eax, eax
jne 0x4055ce
test byte [ebp + 0xc], 4
je 0x4055c6
push ebx
push 0xfffffffffffffff1
call fcn.00404efd
push 0
push ebx
call fcn.004058b6
jmp 0x4055d6
inc dword [0x7a3028]
jmp 0x4055d6
push ebx
push 0xfffffffffffffff2
call fcn.00404efd
lea eax, [ebp - 0x148]
push eax
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x405540
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_FindClose]
cmp dword [ebp + 8], 0
je 0x405601
and byte [edi - 1], 0
xor esi, esi
pop edi
cmp dword [ebp + 8], esi
je 0x405656
cmp dword [ebp - 8], esi
jne 0x405616
inc dword [0x7a3028]
jmp 0x405656
push ebx
call fcn.00405e3e
test eax, eax
je 0x405656
push ebx
call fcn.0040565c
push ebx
call fcn.00405820
push ebx
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
test eax, eax
jne 0x40564e
test byte [ebp + 0xc], 4
je 0x40560e
push ebx
push 0xfffffffffffffff1
call fcn.00404efd
push esi
push ebx
call fcn.004058b6
jmp 0x405656
push ebx
push 0xffffffffffffffe5
call fcn.00404efd
pop esi
pop ebx
leave
ret 8
Function at 0x40573c
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push esi
push edi
push dword [esp + 0xc]
mov esi, 0x7a09b0
push esi
call fcn.00405b69
push esi
call fcn.004056ef
mov edi, eax
test edi, edi
jne 0x40575d
xor eax, eax
jmp 0x4057af
push edi
call fcn.00405da5
test byte [0x7a2fb0], 0x80
je 0x405776
mov al, byte [edi]
test al, al
je 0x405759
cmp al, 0x5c
je 0x405759
sub edi, esi
jmp 0x40578e
call fcn.00405e3e
test eax, eax
je 0x405788
test byte [eax], 0x10
je 0x405759
push esi
call fcn.004056a3
push esi
call sub.KERNEL32.dll_lstrlenA
cmp eax, edi
push esi
jg 0x40577a
call fcn.0040565c
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
xor ecx, ecx
cmp eax, 0xffffffff
setne cl
mov eax, ecx
pop edi
pop esi
ret 4

Function at 0x405820
Capabilities:
Check if file exists
Get file attributes
Set file attributes

Disassembly:
push dword [esp + 4]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x40583c
and al, 0xfe
push eax
push dword [esp + 8]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
ret 4

Function at 0x40583f
Capabilities:
Get file attributes

Disassembly:
push dword [esp + 4]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
mov ecx, eax
push 0
inc ecx
neg ecx
sbb ecx, ecx
and ecx, eax
push ecx
push dword [esp + 0x14]
push 0
push 1
push dword [esp + 0x1c]
push dword [esp + 0x1c]
call dword [sym.imp.KERNEL32.dll_CreateFileA]
ret 0xc

Function at 0x40586e
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 8]
push edi
push 0x64
pop edi
dec edi
mov dword [ebp + 8], 0x61736e
call dword [sym.imp.KERNEL32.dll_GetTickCount]
push 0x1a
xor edx, edx
pop ecx
div ecx
push esi
lea eax, [ebp + 8]
push 0
push eax
push dword [ebp + 0xc]
add byte [ebp + 0xa], dl
call dword [sym.imp.KERNEL32.dll_GetTempFileNameA]
test eax, eax
jne 0x4058b2
test edi, edi
jne 0x405879
and byte [esi], 0
pop edi
pop esi
pop ebp
ret 8
mov eax, esi
jmp 0x4058ac
Function at 0x4058b6
Capabilities:
Get common file path
Get file size
Read file on windows
Write file on windows

Disassembly:
push ebx
push ebp
push esi
push edi
push str.MoveFileExA
push str.KERNEL32.dll
call fcn.00405e7c
test eax, eax
mov esi, dword [esp + 0x18]
je 0x4058e2
push 5
push esi
push dword [esp + 0x1c]
call eax
test eax, eax
jne 0x405a21
mov ebx, dword [sym.imp.KERNEL32.dll_GetShortPathNameA]
mov dword [0x7a1738], 0x4c554e
test esi, esi
mov edi, 0x400
mov ebp, 0x7a1738
je 0x405926
push 1
push 0
push esi
call fcn.0040583f
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
push ebp
push esi
call ebx
test eax, eax
je 0x405a27
cmp eax, edi
jg 0x405a27
mov esi, 0x7a11b0
push edi
push esi
push dword [esp + 0x1c]
call ebx
test eax, eax
je 0x405a27
cmp eax, edi
jg 0x405a27
push esi
push ebp
push str._s_s_r_n
push 0x7a0db0
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x10
mov ebx, eax
push 0x3f0
push esi
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
push str.wininit.ini
push esi
call sub.KERNEL32.dll_lstrcatA
push 4
push 0xc0000000
push esi
call fcn.0040583f
mov ebp, eax
cmp ebp, 0xffffffff
mov dword [esp + 0x14], ebp
je 0x405a21
push 0
push ebp
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
lea eax, [edi + ebx + 0xa]
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov esi, eax
test esi, esi
je 0x405a1a
lea eax, [esp + 0x18]
push 0
push eax
push edi
push esi
push ebp
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x405a1a
cmp edi, dword [esp + 0x18]
jne 0x405a1a
push str._Rename__r_n
push esi
call fcn.004057b4
test eax, eax
jne 0x405a2e
lea eax, [esi + edi]
push str._Rename__r_n
push eax
call fcn.00405b69
add edi, 0xa
mov eax, edi
push ebx
add eax, esi
push 0x7a0db0
push eax
call fcn.00405800
xor eax, eax
push eax
push eax
push eax
push ebp
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
lea eax, [esp + 0x18]
push 0
add edi, ebx
push eax
push edi
push esi
push ebp
call dword [sym.imp.KERNEL32.dll_WriteFile]
push esi
call dword [sym.imp.KERNEL32.dll_GlobalFree]
push ebp
call dword [sym.imp.KERNEL32.dll_CloseHandle]
inc dword [0x7a3030]
pop edi
pop esi
pop ebp
pop ebx
ret 8
add eax, 0xa
push 0x409320
push eax
call fcn.004057b4
test eax, eax
je 0x4059e5
inc eax
lea ecx, [esi + edi]
cmp eax, ecx
mov ebp, eax
jae 0x405a55
mov dl, byte [ebp]
mov byte [ebx + ebp], dl
inc ebp
cmp ebp, ecx
jb 0x405a4a
mov ebp, dword [esp + 0x14]
sub eax, esi
jmp 0x4059e7
Function at 0x405a5d
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push ebx
lea eax, [ebp + 0xc]
push esi
mov esi, dword [ebp + 0x14]
xor ebx, ebx
push eax
push 0x20019
push ebx
push dword [ebp + 0xc]
mov byte [esi], bl
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x405ac1
lea eax, [ebp + 8]
mov dword [ebp + 8], 0x400
push eax
lea eax, [ebp + 0x14]
push esi
push eax
push ebx
push dword [ebp + 0x10]
push dword [ebp + 0xc]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x405ab0
cmp dword [ebp + 0x14], 1
je 0x405ab2
cmp dword [ebp + 0x14], 2
je 0x405ab2
mov byte [esi], bl
push dword [ebp + 0xc]
mov byte [esi + 0x3ff], bl
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop esi
pop ebx
pop ebp
ret 0x10
Function at 0x405b8b
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
push ebx
mov ebx, dword [ebp + 0xc]
push esi
push edi
test ebx, ebx
jge 0x405bac
mov ecx, dword [0x7a277c]
lea eax, [ebx*4 + 4]
sub ecx, eax
mov ebx, dword [ecx]
mov eax, dword [0x7a2fd8]
mov ecx, dword [ebp + 8]
add ebx, eax
mov eax, 0x7a1f40
sub ecx, eax
mov edi, eax
cmp ecx, 0x800
jae 0x405d7f
mov edi, dword [ebp + 8]
and dword [ebp + 8], 0
jmp 0x405d7f
mov edx, edi
sub edx, eax
cmp edx, 0x400
jge 0x405d8c
inc ebx
cmp cl, 0xfc
jbe 0x405d72
movsx eax, byte [ebx + 1]
movsx ecx, byte [ebx]
mov esi, eax
mov edx, ecx
and esi, 0x7f
and edx, 0x7f
shl esi, 7
or esi, edx
mov edx, 0x8000
mov dword [ebp - 0x18], ecx
mov dword [ebp - 0x10], eax
or ecx, edx
or eax, edx
inc ebx
mov dword [ebp - 0x14], ecx
inc ebx
cmp byte [ebp + 0xf], 0xfe
mov dword [ebp - 0xc], eax
jne 0x405d1d
and dword [ebp + 0xc], 0
and byte [edi], 0
push 4
pop esi
cmp dword [ebp - 0x10], esi
jne 0x405c40
mov dword [ebp + 0xc], str.MicrosoftInternet_ExplorerQuick_Launch
jmp 0x405cb8
mov eax, dword [ebp - 0x18]
cmp eax, 0x2b
jne 0x405c5f
push edi
push str.CommonFilesDir
push str.SoftwareMicrosoftWindowsCurrentVersion
push 0x80000002
call fcn.00405a5d
jmp 0x405cb3
cmp eax, 0x26
jne 0x405c8f
push edi
push str.ProgramFilesDir
push str.SoftwareMicrosoftWindowsCurrentVersion
push 0x80000002
call fcn.00405a5d
cmp byte [edi], 0
jne 0x405d15
push str.C:Program_Files
push edi
call fcn.00405b69
jmp 0x405cb3
cmp eax, 0x25
jne 0x405ca2
push 0x400
push edi
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
jmp 0x405cb3
cmp eax, 0x24
jne 0x405cb8
push 0x400
push edi
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
cmp byte [edi], 0
jne 0x405d15
cmp dword [0x7a3024], 0
jne 0x405cc4
push 2
pop esi
lea eax, [ebp - 4]
dec esi
push eax
push dword [ebp + esi*4 - 0x18]
push dword [0x7a2fa4]
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderLocation]
test eax, eax
jne 0x405cfa
push edi
push dword [ebp - 4]
call dword [sym.imp.SHELL32.dll_SHGetPathFromIDListA]
push dword [ebp - 4]
mov dword [ebp - 8], eax
call fcn.004053b6
cmp dword [ebp - 8], 0
jne 0x405d01
jmp 0x405cfd
and byte [edi], 0
test esi, esi
jne 0x405cc4
cmp byte [edi], 0
je 0x405d15
cmp dword [ebp + 0xc], 0
je 0x405d15
push dword [ebp + 0xc]
push edi
call sub.KERNEL32.dll_lstrcatA
push edi
call fcn.00405da5
jmp 0x405d63
cmp byte [ebp + 0xf], 0xfd
jne 0x405d51
cmp esi, 0x1b
jne 0x405d36
push dword [0x7a2fa4]
push edi
call fcn.00405ac7
jmp 0x405d47
mov eax, esi
shl eax, 0xa
add eax, section..ndata
push eax
push edi
call fcn.00405b69
add esi, 0xffffffeb
cmp esi, 6
jae 0x405d63
jmp 0x405d15
cmp byte [ebp + 0xf], 0xff
jne 0x405d63
or eax, 0xffffffff
sub eax, esi
push eax
push edi
call fcn.00405b8b
push edi
call sub.KERNEL32.dll_lstrlenA
add edi, eax
mov eax, 0x7a1f40
jmp 0x405d7f
jne 0x405d7c
mov cl, byte [ebx]
mov byte [edi], cl
inc edi
inc ebx
jmp 0x405d7f
mov byte [edi], cl
inc edi
mov cl, byte [ebx]
test cl, cl
mov byte [ebp + 0xf], cl
jne 0x405bd7
and byte [edi], 0
cmp dword [ebp + 8], 0
pop edi
pop esi
pop ebx
je 0x405da1
push eax
push dword [ebp + 8]
call fcn.00405b69
leave
ret 8
Function at 0x405ed9
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
cmp dword [0x7a1b3c], 0
push esi
jne 0x405f10
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 0x405eea
mov dword [ecx*4 + 0x7a1b38], eax
inc ecx
cmp ecx, 0x100
jl 0x405ee5
mov edx, dword [esp + 0x10]
mov eax, dword [esp + 8]
test edx, edx
not eax
jbe 0x405f41
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 + 0x7a1b38]
xor eax, esi
inc ecx
dec edx
jne 0x405f23
pop edi
not eax
pop esi
ret 0xc

Function at 0x404988
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff0
mov eax, section.sect_0
call 0x404988
lcall 0x5de5, 0x8b10c483
jmp loc.00840ff0