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

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x14
mov eax, dword [ebp + 8]
mov ecx, eax
push ebx
mov ebx, dword [ebp + 0xc]
and eax, 0x3f
sar ecx, 6
push esi
push edi
imul edi, eax, 0x38
mov eax, dword [ecx*4 + 0x462990]
mov dword [ebp - 0x10], ecx
mov ecx, dword [eax + edi + 0x18]
mov dword [ebp - 0x14], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x41ade2
cmp byte [ebx], 0xa
jne 0x41ade2
or byte [eax + edi + 0x28], 4
jmp 0x41ade7
and byte [eax + edi + 0x28], 0xfb
add ecx, ebx
mov edx, ebx
mov dword [ebp - 0xc], ecx
mov esi, ebx
cmp ebx, ecx
jae 0x41aee5
mov al, byte [edx]
cmp al, 0x1a
je 0x41aec7
lea ecx, [edx + 1]
mov dword [ebp - 8], ecx
mov ecx, dword [ebp - 0xc]
cmp al, 0xd
je 0x41ae16
mov edx, dword [ebp - 8]
mov byte [esi], al
jmp 0x41ae3b
mov eax, dword [ebp - 8]
cmp eax, ecx
jae 0x41ae45
mov cl, byte [eax]
xor eax, eax
cmp cl, 0xa
sete al
inc eax
add edx, eax
cmp cl, 0xa
sete al
dec al
and al, 3
add al, 0xa
mov byte [esi], al
mov ecx, dword [ebp - 0xc]
inc esi
cmp edx, ecx
jb 0x41adf8
jmp 0x41aee5
push 0
lea eax, [ebp - 0xc]
push eax
push 1
lea eax, [ebp - 1]
push eax
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x41aec2
cmp dword [ebp - 0xc], 0
je 0x41aec2
mov ecx, dword [ebp - 0x10]
mov eax, dword [ecx*4 + 0x462990]
test byte [eax + edi + 0x28], 0x48
je 0x41ae9c
mov dl, byte [ebp - 1]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
cmp dl, 0xa
jne 0x41ae87
mov byte [esi], dl
jmp 0x41ae98
mov byte [esi], 0xd
mov eax, dword [ecx*4 + 0x462990]
mov byte [eax + edi + 0x2a], dl
mov eax, dword [ebp - 0x14]
mov esi, eax
jmp 0x41aee5
cmp byte [ebp - 1], 0xa
jne 0x41aeab
cmp esi, ebx
jne 0x41aeab
mov byte [esi], 0xa
jmp 0x41aee4
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.0041b922
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x41aee5
mov byte [esi], 0xd
jmp 0x41aee4
mov ecx, dword [ebp - 0x10]
mov ecx, dword [ecx*4 + 0x462990]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x41aee1
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x41aee5
mov byte [esi], 0x1a
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x41aeee
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword [ebp + 8]
push ebx
push esi
mov esi, dword [ebp + 0xc]
mov ebx, eax
and eax, 0x3f
sar ebx, 6
push edi
imul edi, eax, 0x38
push 0xa
mov eax, dword [ebx*4 + 0x462990]
pop edx
mov dword [ebp - 0x14], edx
mov ecx, dword [edi + eax + 0x18]
mov dword [ebp - 0x18], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x41af31
cmp word [esi], dx
jne 0x41af31
or byte [edi + eax + 0x28], 4
jmp 0x41af36
and byte [edi + eax + 0x28], 0xfb
lea edx, [esi + ecx*2]
mov eax, esi
mov dword [ebp - 8], edx
mov dword [ebp - 4], eax
cmp eax, edx
jae 0x41b089
mov dword [ebp - 0xc], 0xd
movzx ecx, word [eax]
mov edx, ecx
mov dword [ebp - 0x10], edx
push 0x1a
pop edx
cmp cx, dx
mov edx, dword [ebp - 8]
je 0x41b069
add eax, 2
cmp cx, word [ebp - 0xc]
je 0x41af78
mov dword [ebp - 4], eax
mov word [esi], cx
jmp 0x41afae
cmp eax, edx
jae 0x41afba
movzx eax, word [eax]
xor ecx, ecx
cmp ax, word [ebp - 0x14]
mov edx, eax
push 0xa
sete cl
xor eax, eax
lea ecx, [ecx*2 + 2]
add dword [ebp - 4], ecx
pop ecx
cmp dx, cx
mov edx, dword [ebp - 8]
sete al
dec eax
and eax, 3
add eax, ecx
mov word [esi], ax
mov eax, dword [ebp - 4]
add esi, 2
cmp eax, edx
jb 0x41af50
jmp 0x41b089
push 0
lea eax, [ebp - 0x14]
push eax
push 2
lea eax, [ebp - 4]
push eax
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x41b065
cmp dword [ebp - 0x14], 0
je 0x41b065
mov eax, dword [ebx*4 + 0x462990]
push 0xa
test byte [edi + eax + 0x28], 0x48
je 0x41b03d
mov dx, word [ebp - 4]
lea eax, [esi + 2]
pop ecx
mov dword [ebp - 0x18], eax
cmp dx, cx
jne 0x41b006
mov word [esi], cx
jmp 0x41b039
push 0xd
pop eax
mov word [esi], ax
mov eax, dword [ebx*4 + 0x462990]
movzx ecx, dx
shr ecx, 8
push 0xa
mov byte [edi + eax + 0x2a], dl
mov eax, dword [ebx*4 + 0x462990]
mov byte [edi + eax + 0x2b], cl
mov eax, dword [ebx*4 + 0x462990]
pop ecx
mov byte [edi + eax + 0x2c], cl
mov eax, dword [ebp - 0x18]
mov esi, eax
jmp 0x41b089
pop ebx
cmp word [ebp - 4], bx
jne 0x41b04e
cmp esi, dword [ebp + 0xc]
jne 0x41b04e
mov word [esi], bx
jmp 0x41b086
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.0041b922
add esp, 0x10
cmp word [ebp - 4], bx
je 0x41b089
push 0xd
jmp 0x41b082
mov ecx, dword [ebx*4 + 0x462990]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x41b080
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x41b089
push 0x1a
pop eax
mov word [esi], ax
add esi, 2
sub esi, dword [ebp + 0xc]
and esi, 0xfffffffe
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x401eb2
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x34
push ebx
push esi
push edi
mov edi, edx
mov esi, ecx
mov dword [ebp - 0xc], edi
call fcn.00406850
cmp eax, 1
jle 0x401fef
push 0
push 0x8000000
push 3
push 0
push 7
push 0x80000000
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x401ffb
test ebx, ebx
je 0x401ffb
push 4
push 0x1000
push 0xf4240
xor esi, esi
push esi
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov dword [ebp - 4], eax
test eax, eax
je 0x401fd5
mov dword [ebp - 8], esi
cmp dword [ebp + 8], esi
jle 0x401fc8
fld qword [0x434990]
mov esi, edi
lea edi, [ebp - 0x30]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
fmul qword [ebp - 0x30]
call fcn.004264a0
xor esi, esi
lea ecx, [ebp - 0x20]
push esi
push ecx
push esi
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
je 0x401fe6
fld qword [ebp - 0x28]
fld qword [0x434990]
fmul st(1), st(0)
jmp 0x401f99
fxch st(1)
fcomi st(1)
jbe 0x401f6e
fstp st(0)
jmp 0x401f70
fstp st(1)
lea eax, [ebp - 0x10]
push esi
push eax
call fcn.004264a0
push eax
push dword [ebp - 4]
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x401fde
cmp dword [ebp - 0x10], esi
jbe 0x401fde
fld qword [ebp - 0x18]
fld qword [0x434990]
fsub st(1), st(0)
fxch st(1)
fst qword [ebp - 0x18]
fldz
fxch st(1)
fcomi st(1)
fstp st(1)
ja 0x401f64
fstp st(0)
mov eax, dword [ebp - 8]
mov edi, dword [ebp - 0xc]
inc eax
add edi, 0x10
mov dword [ebp - 8], eax
mov dword [ebp - 0xc], edi
cmp eax, dword [ebp + 8]
jl 0x401f2e
mov eax, dword [ebp - 4]
fstp st(0)
push 0x8000
push esi
push eax
call dword [sym.imp.KERNEL32.dll_VirtualFree]
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x401ffb
fld qword [0x434990]
jmp 0x401faa
mov eax, dword [ebp - 4]
test eax, eax
je 0x401fd5
jmp 0x401fc8
mov dl, byte [ebp + 0xc]
push ecx
mov ecx, esi
call fcn.0040a770
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x402199
Capabilities:
Set current directory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x420
mov eax, dword [0x438070]
xor eax, ebp
mov dword [ebp - 8], eax
push ebx
push esi
mov esi, dword [ebp + 0x14]
mov ebx, edx
push edi
mov edi, dword [ebp + 0x10]
mov dword [ebp - 0x420], edi
test edi, edi
je 0x40234a
test esi, esi
je 0x40234a
cmp dword [ebp + 0x18], 0
je 0x40234a
test ebx, ebx
je 0x4021ec
push esi
call fcn.0040110c
pop ecx
push eax
push esi
lea ecx, [ebx + 0x24]
call fcn.00403fa7
xor eax, eax
push 0x208
push eax
lea eax, [ebp - 0x41c]
push eax
call fcn.004123f0
add esp, 0xc
lea eax, [ebp - 0x214]
push 0x208
push 0
push eax
call fcn.004123f0
lea edx, [ebp - 0x214]
add esp, 0xc
mov ecx, edi
sub edx, edi
movzx eax, word [ecx]
mov word [edx + ecx], ax
add ecx, 2
test ax, ax
jne 0x402223
mov edx, dword [ebp + 0x18]
push esi
push ecx
lea ecx, [ebp - 0x214]
call fcn.00401b9a
pop ecx
pop ecx
xor edx, edx
mov ecx, edx
movzx eax, word [ebp + ecx - 0x214]
lea ecx, [ecx + 2]
mov word [ebp + ecx - 0x41e], ax
test ax, ax
jne 0x402248
lea edi, [ebp - 0x214]
sub edi, 2
mov ax, word [edi + 2]
lea edi, [edi + 2]
cmp ax, dx
jne 0x402269
mov eax, dword [0x4342d4]
mov dword [edi], eax
lea edi, [ebp - 0x214]
sub edi, 2
mov ax, word [edi + 2]
add edi, 2
cmp ax, dx
jne 0x402285
push 5
pop ecx
lea eax, [ebp - 0x41c]
mov esi, str.kugou.dll
rep movsd dword es:[edi], dword [esi]
push eax
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
cmp byte [ebp + 8], 0
jne 0x4022f2
mov edx, dword [ebp + 0x18]
push str.kugou.dll
push ecx
mov ecx, dword [ebp - 0x420]
call fcn.00401b9a
push dword [ebp + 0xc]
mov edx, dword [ebp - 0x420]
xor edi, edi
push edi
push ebx
call fcn.00402002
mov esi, eax
add esp, 0x14
test esi, esi
jne 0x402346
push dword [ebp + 0xc]
lea edx, [ebp - 0x214]
push edi
push ebx
call fcn.00402002
add esp, 0xc
jmp 0x402344
push dword [ebp + 0xc]
lea edx, [ebp - 0x214]
push dword [ebp + 8]
push ebx
call fcn.00402002
mov esi, eax
add esp, 0xc
test esi, esi
jne 0x402346
call fcn.00401c10
test al, al
je 0x402346
call fcn.00414702
mov edx, dword [ebp + 0x18]
push str.kugou.dll
push ecx
mov ecx, dword [ebp - 0x420]
call fcn.00401b9a
push dword [ebp + 0xc]
mov edx, dword [ebp - 0x420]
push dword [ebp + 8]
push ebx
call fcn.00402002
add esp, 0x14
mov esi, eax
mov eax, esi
jmp 0x40234c
xor eax, eax
mov ecx, dword [ebp - 8]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0040f284
mov esp, ebp
pop ebp
ret
Function at 0x40235d
Capabilities:
Create directory
Get common file path
Read file via mapping

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x238
mov eax, dword [0x438070]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
xor eax, eax
push 0x208
push eax
mov bl, al
lea eax, [ebp - 0x20c]
push eax
call fcn.004123f0
add esp, 0xc
lea eax, [ebp - 0x20c]
push eax
xor eax, eax
push eax
push eax
push 0x23
push eax
call dword [sym.imp.SHELL32.dll_SHGetFolderPathW]
push 1
lea eax, [ebp - 0x238]
push eax
call dword [sym.imp.ADVAPI32.dll_InitializeSecurityDescriptor]
xor eax, eax
xor esi, esi
push eax
push eax
inc esi
lea eax, [ebp - 0x238]
push esi
push eax
call dword [sym.imp.ADVAPI32.dll_SetSecurityDescriptorDacl]
lea edi, [ebp - 0x20c]
mov dword [ebp - 0x224], 0xc
lea eax, [ebp - 0x238]
mov dword [ebp - 0x21c], esi
sub edi, 2
mov dword [ebp - 0x220], eax
xor ecx, ecx
mov ax, word [edi + 2]
add edi, 2
cmp ax, cx
jne 0x4023eb
mov esi, 0x4342d8
lea eax, [ebp - 0x224]
push eax
lea eax, [ebp - 0x20c]
push eax
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
lea edi, [ebp - 0x20c]
sub edi, 2
xor edx, edx
mov ax, word [edi + 2]
add edi, 2
cmp ax, dx
jne 0x402420
push 8
pop ecx
push edx
push 0x8000000
push 4
lea eax, [ebp - 0x224]
mov esi, str._startup_record
push eax
push 7
push 0xc0000000
lea eax, [ebp - 0x20c]
rep movsd dword es:[edi], dword [esi]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x218], eax
cmp eax, 0xffffffff
je 0x402534
test eax, eax
je 0x402534
xor ecx, ecx
push ecx
push 0xc
push ecx
push 4
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileMappingW]
mov edi, eax
cmp edi, 0xffffffff
je 0x402522
test edi, edi
je 0x402522
push 0xc
xor eax, eax
push eax
push eax
push 6
push edi
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov esi, eax
test esi, esi
je 0x402519
mov ecx, dword [esi + 4]
mov dword [ebp - 0x210], ecx
test ecx, ecx
je 0x4024f9
fild dword [esi]
fstp dword [ebp - 0x214]
fld dword [ebp - 0x214]
fild dword [ebp - 0x210]
fstp dword [ebp - 0x210]
fdiv dword [ebp - 0x210]
fstp dword [ebp - 0x210]
fld dword [0x434974]
fld dword [ebp - 0x210]
fcompi st(1)
fstp st(0)
ja 0x4024f9
cmp byte [esi + 9], 0
jne 0x4024f9
xor ecx, ecx
mov bl, cl
jmp 0x402503
lea eax, [ecx + 1]
mov bl, 1
mov dword [esi + 4], eax
xor ecx, ecx
push 0xc
push esi
mov byte [esi + 8], bl
mov byte [esi + 9], cl
call dword [sym.imp.KERNEL32.dll_FlushViewOfFile]
push esi
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x402526
xor ecx, ecx
mov bl, cl
push dword [ebp - 0x218]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x40253e
call dword [sym.imp.KERNEL32.dll_GetLastError]
xor ecx, ecx
mov bl, cl
mov ecx, dword [ebp - 4]
mov al, bl
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0040f284
mov esp, ebp
pop ebp
ret
Function at 0x4066e0
Capabilities:
Check os version
Get system information on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x148
mov eax, dword [0x438070]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, ecx
push edi
mov dword [esi], 0
mov dword [esi + 0x18], 3
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push str.IsWow64Process
push str.kernel32.dll
mov edi, eax
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x406751
lea ecx, [ebp - 0x124]
mov dword [ebp - 0x124], 0
push ecx
push edi
call eax
test eax, eax
jne 0x406746
mov eax, 2
jmp 0x406751
xor eax, eax
cmp dword [ebp - 0x124], eax
setne al
push 0x118
mov dword [esi + 0x24], eax
lea eax, [ebp - 0x11c]
push 0
push eax
mov dword [ebp - 0x120], 0x11c
call fcn.004123f0
add esp, 0xc
lea eax, [ebp - 0x120]
push eax
call dword [sym.imp.KERNEL32.dll_GetVersionExW]
mov eax, dword [ebp - 0x114]
mov ecx, dword [ebp - 0x11c]
mov edx, dword [ebp - 0x118]
push eax
mov dword [esi + 4], ecx
mov dword [esi + 8], edx
mov dword [esi + 0xc], eax
call fcn.00406590
mov dword [esi], eax
add esp, 4
movzx eax, word [ebp - 0xc]
mov dword [esi + 0x10], eax
movzx eax, word [ebp - 0xa]
mov dword [esi + 0x14], eax
xor eax, eax
mov dword [ebp - 0x148], eax
mov dword [ebp - 0x144], eax
mov dword [ebp - 0x140], eax
mov dword [ebp - 0x13c], eax
mov dword [ebp - 0x138], eax
mov dword [ebp - 0x134], eax
mov dword [ebp - 0x130], eax
mov dword [ebp - 0x12c], eax
mov dword [ebp - 0x128], eax
lea eax, [ebp - 0x148]
push eax
call dword [sym.imp.KERNEL32.dll_GetNativeSystemInfo]
movzx eax, word [ebp - 0x148]
test eax, eax
je 0x406821
cmp eax, 6
je 0x406818
cmp eax, 9
jne 0x406828
mov dword [esi + 0x18], 1
jmp 0x406828
mov dword [esi + 0x18], 2
jmp 0x406828
mov dword [esi + 0x18], 0
mov ecx, dword [ebp - 0x134]
mov eax, esi
mov dword [esi + 0x1c], ecx
mov ecx, dword [ebp - 0x12c]
mov dword [esi + 0x20], ecx
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.0040f284
mov esp, ebp
pop ebp
ret

Function at 0x406c70
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
cmp dword [ecx + 0x14], 8
push esi
push edi
mov esi, edx
jb 0x406c82
mov ecx, dword [ecx]
lea eax, [ebp - 8]
mov dword [ebp - 4], 0
push eax
lea eax, [ebp - 4]
push eax
push 0
push 0x20006
push 0
push 0
push 0
push ecx
push 0x80000001
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
test eax, eax
jne 0x406cf1
mov edi, dword [ebp - 4]
test edi, edi
je 0x406cf1
cmp dword [esi + 0x14], 8
jb 0x406cbd
mov esi, dword [esi]
mov ecx, esi
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x406cc2
sub ecx, edx
sar ecx, 1
lea eax, [ecx*2 + 2]
push eax
push esi
push 1
push 0
push str.ErrCode
push edi
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
push edi
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x406d00
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
push esi
xor esi, esi
cmp dword [ecx + 0x14], 8
jb 0x406d12
mov ecx, dword [ecx]
lea eax, [ebp - 4]
mov dword [ebp - 4], esi
push eax
push 0x20019
push 0
push ecx
push 0x80000001
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x406d83
mov esi, dword [ebp - 4]
test esi, esi
je 0x406d83
mov dword [ebp - 0xc], eax
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0xc]
mov dword [ebp - 4], 4
push eax
lea eax, [ebp - 4]
mov dword [ebp - 8], 4
push eax
push 0
push str.Status
push esi
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x406d83
mov eax, dword [ebp - 4]
cmp eax, 4
je 0x406d73
cmp eax, 3
jne 0x406d83
cmp dword [ebp - 8], 4
jne 0x406d83
cmp dword [ebp - 0xc], 2
jne 0x406d83
mov bl, 1
jmp 0x406d85
xor bl, bl
test esi, esi
je 0x406d90
push esi
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop esi
mov al, bl
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x406da0
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
cmp dword [ecx + 0x14], 8
push esi
push edi
mov esi, edx
jb 0x406db2
mov ecx, dword [ecx]
lea eax, [ebp - 8]
mov dword [ebp - 4], 0
push eax
lea eax, [ebp - 4]
push eax
push 0
push 0x20006
push 0
push 0
push 0
push ecx
push 0x80000001
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
test eax, eax
jne 0x406e21
mov edi, dword [ebp - 4]
test edi, edi
je 0x406e21
cmp dword [esi + 0x14], 8
jb 0x406ded
mov esi, dword [esi]
mov ecx, esi
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x406df2
sub ecx, edx
sar ecx, 1
lea eax, [ecx*2 + 2]
push eax
push esi
push 1
push 0
push str.CurrPatchVersion
push edi
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
push edi
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
pop esi
mov esp, ebp
pop ebp
ret

Function at 0x406e30
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
cmp dword [ecx + 0x14], 8
push esi
push edi
mov edi, edx
jb 0x406e42
mov ecx, dword [ecx]
lea eax, [ebp - 0xc]
mov dword [ebp - 4], 0
push eax
lea eax, [ebp - 4]
push eax
push 0
push 0x20006
push 0
push 0
push 0
push ecx
push 0x80000001
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
test eax, eax
jne 0x406e95
mov esi, dword [ebp - 4]
test esi, esi
je 0x406e95
push 4
lea eax, [ebp - 8]
mov dword [ebp - 8], edi
push eax
push 4
push 0
push str.AlreadyRunCount
push esi
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
push esi
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x406ea0
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
cmp dword [ecx + 0x14], 8
push ebx
push esi
push edi
mov esi, edx
jb 0x406eb3
mov ecx, dword [ecx]
lea eax, [ebp - 8]
mov dword [ebp - 4], 0
push eax
lea eax, [ebp - 4]
push eax
push 0
push 0x20006
push 0
push 0
push 0
push ecx
push 0x80000001
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
test eax, eax
jne 0x406f2b
mov edi, dword [ebp - 4]
test edi, edi
je 0x406f2b
mov edx, dword [ebp + 8]
cmp dword [edx + 0x14], 8
jb 0x406ef1
mov edx, dword [edx]
cmp dword [esi + 0x14], 8
jb 0x406ef9
mov esi, dword [esi]
mov ecx, edx
lea ebx, [ecx + 2]
mov edi, edi
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x406f00
sub ecx, ebx
sar ecx, 1
lea eax, [ecx*2 + 2]
push eax
push edx
push 1
push 0
push esi
push edi
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
push edi
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x4082d0
Capabilities:
Read file on windows
Write file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x121c
call fcn.00410310
mov eax, dword [0x438070]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ecx + 0x2c]
add ecx, 0x1c
push ebx
push esi
push edi
cmp dword [ecx + 0x14], 8
mov dword [ebp - 0x1210], 2
mov dword [ebp - 0x120c], eax
jb 0x408308
mov ecx, dword [ecx]
lea edx, [ebp - 0x1208]
mov edi, edi
movzx eax, word [ecx]
lea ecx, [ecx + 2]
mov word [edx], ax
lea edx, [edx + 2]
test ax, ax
jne 0x408310
push 0
push 0
push 3
push 0
push 0
push 0xc0000000
push str..pipeKuGouServicePipe
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebx, eax
mov dword [ebp - 0x1214], 0
cmp ebx, 0xffffffff
je 0x4083e5
push 0x9ff
lea eax, [ebp - 0xa07]
push 0
push eax
call fcn.004123f0
add esp, 0xc
mov dword [ebp - 0xa08], 0xc8
lea eax, [ebp - 0x1218]
mov ecx, 0x202
lea esi, [ebp - 0x1210]
lea edi, [ebp - 0xa04]
push 0
push eax
push 0xa00
lea eax, [ebp - 0xa08]
push eax
rep movsd dword es:[edi], dword [esi]
push ebx
mov word [ebp - 0x1fc], 0x101
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x4083e5
push 0
lea eax, [ebp - 0x1218]
push eax
push 4
lea eax, [ebp - 0x1214]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x4083e5
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [ebp - 0x1214]
xor edx, edx
cmp eax, 0xea
cmove ecx, edx
mov dword [ebp - 0x1214], ecx
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 4]
xor eax, eax
cmp dword [ebp - 0x1214], eax
pop edi
setne al
xor ecx, ebp
pop esi
pop ebx
call fcn.0040f284
mov esp, ebp
pop ebp
ret
Function at 0x408410
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x427088
mov eax, dword fs:[0]
push eax
sub esp, 0xa8
mov eax, dword [0x438070]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
push 0x44
lea eax, [ebp - 0xb0]
xor bl, bl
push 0
push eax
call fcn.004123f0
xor eax, eax
mov dword [ebp - 0xb0], 0x44
mov dword [ebp - 0x64], eax
add esp, 0xc
cmp dword [esi + 0x30], 8
mov dword [ebp - 0x60], eax
mov dword [ebp - 0x5c], eax
mov dword [ebp - 0x58], eax
lea eax, [esi + 0x1c]
jb 0x408477
mov eax, dword [eax]
lea ecx, [ebp - 0x64]
push ecx
lea ecx, [ebp - 0xb0]
push ecx
push 0
push 0
push 0
push 0
push 0
push 0
push eax
push 0
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
test eax, eax
je 0x4085b2
push 0xffffffffffffffff
push dword [ebp - 0x64]
mov bl, 1
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
xor ecx, ecx
movzx ebx, bl
test eax, eax
mov dword [ebp - 0x54], 0x7fffff
lea eax, [ebp - 0x54]
push eax
push dword [ebp - 0x64]
cmovne ebx, ecx
call dword [sym.imp.KERNEL32.dll_GetExitCodeProcess]
test eax, eax
mov eax, dword [ebp - 0x54]
jne 0x4084d9
test eax, eax
je 0x4084d9
xor bl, bl
jmp 0x4084e1
test bl, bl
jne 0x4085b2
xor ecx, ecx
mov dword [ebp - 0x3c], 7
mov dword [ebp - 0x38], ecx
mov dword [ebp - 0x34], ecx
mov dword [ebp - 0x30], ecx
mov dword [ebp - 0x2c], ecx
mov dword [ebp - 0x28], ecx
mov dword [ebp - 0x24], ecx
mov dword [ebp - 0x20], ecx
mov dword [ebp - 0x1c], ecx
mov dword [ebp - 0x18], ecx
mov dword [ebp - 0x14], ecx
mov dword [ebp - 0x40], ecx
mov word [ebp - 0x50], cx
mov dword [ebp - 4], ecx
lea ecx, [ebp - 0x38]
push 0x10
push ecx
push eax
call fcn.00418fba
add esp, 0xc
cmp word [ebp - 0x38], 0
jne 0x40852c
xor ecx, ecx
jmp 0x408541
lea ecx, [ebp - 0x38]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x408532
sub ecx, edx
sar ecx, 1
push ecx
lea eax, [ebp - 0x38]
push eax
lea ecx, [ebp - 0x50]
call fcn.00403fa7
lea ecx, [esi + 0x34]
lea edx, [ebp - 0x50]
call fcn.00406c70
mov eax, dword [ebp - 0x3c]
cmp eax, 8
jb 0x4085b2
mov ecx, dword [ebp - 0x50]
inc eax
cmp eax, 0x7fffffff
jbe 0x408571
call fcn.0041873b
add eax, eax
cmp eax, 0x1000
jb 0x4085a9
test byte [ebp - 0x50], 0x1f
je 0x408585
call fcn.0041873b
mov eax, dword [ecx - 4]
cmp eax, ecx
jb 0x408591
call fcn.0041873b
sub ecx, eax
cmp ecx, 4
jae 0x40859d
call fcn.0041873b
cmp ecx, 0x23
jbe 0x4085a7
call fcn.0041873b
mov ecx, eax
push ecx
call fcn.0040f771
add esp, 4
push dword [ebp - 0x64]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
push dword [ebp - 0x60]
call esi
mov al, bl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0040f284
mov esp, ebp
pop ebp
ret