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

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push edi
xor edi, edi
cmp dword [esi], edi
jne 0x10041782
push edi
push 0x20
push 4
push edi
push 3
push 0xc0000000
lea eax, [esi + 4]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, edi
mov dword [esi], eax
je 0x100417c6
push edi
push dword [esi]
call dword [sym.imp.KERNEL32.dll_GetFileSize]
cmp eax, 0xffffffff
je 0x100417c6
cmp eax, 0x2800
ja 0x100417c6
push 2
lea eax, [ebp - 4]
push eax
push edi
push dword [esi]
mov dword [ebp - 4], edi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push edi
lea eax, [ebp - 8]
push eax
push dword [ebp + 8]
mov dword [ebp - 8], edi
call fcn.100517c0
pop ecx
push eax
push dword [ebp + 8]
push dword [esi]
call dword [sym.imp.KERNEL32.dll_WriteFile]
pop edi
leave
ret 4
Function at 0x10041ac4
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x4c
and dword [ebp - 0x2c], 0
push edi
push 7
xor eax, eax
test edx, edx
pop ecx
lea edi, [ebp - 0x28]
rep stosd dword es:[edi], eax
jne 0x10041ae2
jmp 0x10041c53
push ebx
push esi
lea eax, [edx + 0x20]
mov esi, eax
push 8
pop ebx
mov ecx, ebx
lea edi, [ebp - 0x4c]
rep movsd dword es:[edi], dword [esi]
mov esi, dword [edx + 0x40]
mov ecx, 0x4d34d34d
add esi, ecx
add dword [eax], esi
mov eax, dword [eax]
cmp eax, dword [ebp - 0x4c]
mov eax, 0x2cb2cb2d
sbb esi, esi
neg esi
sub esi, eax
add dword [edx + 0x24], esi
mov esi, dword [edx + 0x24]
cmp esi, dword [ebp - 0x48]
mov esi, 0x34d34d34
sbb edi, edi
neg edi
add edi, esi
add dword [edx + 0x28], edi
mov edi, dword [edx + 0x28]
cmp edi, dword [ebp - 0x44]
mov dword [ebp - 0xc], ebx
sbb edi, edi
neg edi
add edi, ecx
add dword [edx + 0x2c], edi
mov edi, dword [edx + 0x2c]
cmp edi, dword [ebp - 0x40]
sbb edi, edi
neg edi
sub edi, eax
add dword [edx + 0x30], edi
mov edi, dword [edx + 0x30]
cmp edi, dword [ebp - 0x3c]
sbb edi, edi
neg edi
add edi, esi
add dword [edx + 0x34], edi
mov esi, dword [edx + 0x34]
cmp esi, dword [ebp - 0x38]
sbb esi, esi
neg esi
add esi, ecx
add dword [edx + 0x38], esi
mov ecx, dword [edx + 0x38]
cmp ecx, dword [ebp - 0x34]
mov esi, edx
sbb ecx, ecx
neg ecx
sub ecx, eax
add dword [edx + 0x3c], ecx
mov eax, dword [edx + 0x3c]
cmp eax, dword [ebp - 0x30]
mov dword [ebp - 8], esi
sbb eax, eax
neg eax
mov dword [edx + 0x40], eax
lea eax, [ebp - 0x2c]
sub eax, edx
mov ecx, dword [esi + 0x20]
add ecx, dword [esi]
movzx edi, cx
mov esi, ecx
shr esi, 0x10
mov dword [ebp - 4], esi
imul esi, edi
mov ebx, edi
imul ebx, edi
shr ebx, 0x11
add ebx, esi
mov esi, dword [ebp - 4]
imul esi, esi
shr ebx, 0xf
add ebx, esi
mov esi, ecx
imul esi, ecx
xor ebx, esi
mov esi, dword [ebp - 8]
mov dword [eax + esi], ebx
add esi, 4
dec dword [ebp - 0xc]
mov dword [ebp - 8], esi
jne 0x10041b8b
mov eax, dword [ebp - 0x14]
mov ecx, dword [ebp - 0x2c]
mov edi, dword [ebp - 0x10]
mov esi, eax
rol esi, 0x10
add esi, ecx
rol edi, 0x10
add edi, esi
mov esi, ecx
rol esi, 8
add esi, dword [ebp - 0x28]
mov dword [edx], edi
add esi, dword [ebp - 0x10]
mov edi, dword [ebp - 0x28]
mov dword [edx + 4], esi
mov esi, dword [ebp - 0x24]
rol edi, 0x10
add edi, esi
rol ecx, 0x10
add ecx, edi
mov edi, dword [ebp - 0x20]
mov dword [edx + 8], ecx
mov ecx, esi
rol ecx, 8
add ecx, dword [ebp - 0x20]
add ecx, dword [ebp - 0x28]
rol edi, 0x10
rol esi, 0x10
mov dword [edx + 0xc], ecx
mov ecx, dword [ebp - 0x1c]
add edi, ecx
add esi, edi
mov dword [edx + 0x10], esi
mov esi, ecx
rol esi, 8
add esi, dword [ebp - 0x18]
add esi, dword [ebp - 0x20]
mov dword [edx + 0x14], esi
mov esi, dword [ebp - 0x18]
rol esi, 0x10
add esi, eax
rol ecx, 0x10
add ecx, esi
rol eax, 8
add eax, dword [ebp - 0x18]
pop esi
add eax, dword [ebp - 0x10]
mov dword [edx + 0x18], ecx
mov dword [edx + 0x1c], eax
xor eax, eax
inc eax
pop ebx
pop edi
leave
ret
Function at 0x10041c9b
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
test esi, esi
jne 0x10041ca8
xor eax, eax
leave
ret
push ebx
push edi
push 0xc
mov edi, str.QQPCMgrLibrary_s
pop ecx
mov eax, edi
call fcn.10041c56
mov ebx, eax
push 8
pop ecx
mov eax, edi
call fcn.10041c56
mov dword [ebp - 8], eax
push 4
pop ecx
mov eax, edi
call fcn.10041c56
mov dword [ebp - 4], eax
xor ecx, ecx
mov eax, edi
call fcn.10041c56
mov ecx, dword [ebp - 4]
mov edx, dword [ebp - 8]
mov dword [esi + 0x10], ecx
shr ecx, 0x10
mov edi, eax
shl edi, 0x10
or edi, ecx
mov dword [esi + 4], edi
mov ecx, eax
shr ecx, 0x10
mov edi, ebx
shl edi, 0x10
or ecx, edi
mov dword [esi + 0xc], ecx
mov ecx, edx
shl ecx, 0x10
mov edi, ebx
shr edi, 0x10
or ecx, edi
mov dword [esi + 0x14], ecx
mov ecx, dword [ebp - 4]
shl ecx, 0x10
mov edi, edx
shr edi, 0x10
or ecx, edi
mov dword [esi + 0x1c], ecx
mov ecx, dword [ebp - 4]
rol ecx, 0x10
mov dword [esi + 0x20], ecx
mov ecx, eax
rol ecx, 0x10
mov dword [esi + 0x28], ecx
mov ecx, ebx
rol ecx, 0x10
mov edi, edx
mov dword [esi + 0x30], ecx
mov ecx, edx
xor edi, ebx
rol ecx, 0x10
mov dword [esi + 0x38], ecx
mov ecx, 0xffff
and edi, ecx
xor edi, ebx
mov dword [esi + 0x24], edi
mov edi, dword [ebp - 4]
xor edi, edx
mov dword [esi + 8], edx
and edi, ecx
xor edi, edx
mov edx, eax
xor edx, dword [ebp - 4]
mov dword [esi], ebx
and edx, ecx
xor edx, dword [ebp - 4]
mov dword [esi + 0x18], eax
mov dword [esi + 0x34], edx
mov edx, eax
xor edx, ebx
mov dword [esi + 0x2c], edi
and edx, ecx
xor edx, eax
and dword [esi + 0x40], 0
push 4
mov dword [esi + 0x3c], edx
pop edi
mov edx, esi
call fcn.10041ac4
dec edi
jne 0x10041d86
push 0xfffffffffffffffc
pop edx
push 8
mov ecx, esi
pop edi
mov ebx, dword [ecx]
mov eax, edx
and eax, 7
lea eax, [esi + eax*4 + 0x20]
xor dword [eax], ebx
add ecx, 4
inc edx
dec edi
jne 0x10041d98
xor eax, eax
pop edi
inc eax
pop ebx
leave
ret
Function at 0x100436f8
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
test ecx, ecx
push esi
mov esi, edx
jne 0x10043703
xor eax, eax
pop esi
ret
cmp eax, 8
push ebx
not esi
mov edx, 0xff
jb 0x100437b5
push edi
mov edi, eax
shr edi, 3
movzx ebx, byte [ecx]
xor ebx, esi
and ebx, edx
shr esi, 8
xor esi, dword [ebx*4 + 0x10080ff8]
inc ecx
movzx ebx, byte [ecx]
xor ebx, esi
and ebx, edx
shr esi, 8
xor esi, dword [ebx*4 + 0x10080ff8]
inc ecx
movzx ebx, byte [ecx]
xor ebx, esi
and ebx, edx
shr esi, 8
xor esi, dword [ebx*4 + 0x10080ff8]
inc ecx
movzx ebx, byte [ecx]
xor ebx, esi
and ebx, edx
shr esi, 8
xor esi, dword [ebx*4 + 0x10080ff8]
inc ecx
movzx ebx, byte [ecx]
xor ebx, esi
and ebx, edx
shr esi, 8
xor esi, dword [ebx*4 + 0x10080ff8]
inc ecx
movzx ebx, byte [ecx]
xor ebx, esi
and ebx, edx
shr esi, 8
xor esi, dword [ebx*4 + 0x10080ff8]
inc ecx
movzx ebx, byte [ecx]
xor ebx, esi
and ebx, edx
shr esi, 8
xor esi, dword [ebx*4 + 0x10080ff8]
inc ecx
movzx ebx, byte [ecx]
xor ebx, esi
and ebx, edx
shr esi, 8
xor esi, dword [ebx*4 + 0x10080ff8]
inc ecx
sub eax, 8
dec edi
jne 0x1004371a
pop edi
test eax, eax
je 0x100437ce
movzx ebx, byte [ecx]
xor ebx, esi
and ebx, edx
shr esi, 8
xor esi, dword [ebx*4 + 0x10080ff8]
inc ecx
dec eax
jne 0x100437b9
mov eax, esi
pop ebx
not eax
pop esi
ret

Function at 0x100437d5
Capabilities:
Generate random numbers using the delphi lcg
Hash data with crc32

Disassembly:
mov eax, dword [ecx]
xor edx, eax
push esi
mov esi, 0xff
and edx, esi
mov edx, dword [edx*4 + 0x10080ff8]
shr eax, 8
xor edx, eax
mov eax, dword [ecx + 8]
mov dword [ecx], edx
movzx edx, dl
add edx, dword [ecx + 4]
imul edx, edx, 0x8088405
inc edx
mov dword [ecx + 4], edx
shr edx, 0x18
xor edx, eax
and edx, esi
shr eax, 8
xor eax, dword [edx*4 + 0x10080ff8]
pop esi
mov dword [ecx + 8], eax
ret

Function at 0x10043f09
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push edi
mov edi, dword [ebp + 0xc]
imul edi, dword [ebp + 0x10]
cmp byte [esi], 0
je 0x10043f39
push 0
lea eax, [ebp + 0x10]
push eax
push edi
push dword [ebp + 8]
push dword [esi + 4]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x10043f34
mov byte [esi + 8], 1
mov eax, dword [ebp + 0x10]
jmp 0x10043f71
xor eax, eax
mov ecx, edi
add ecx, dword [esi + 0x28]
adc eax, dword [esi + 0x2c]
cmp eax, dword [esi + 0x24]
jl 0x10043f55
jg 0x10043f4f
cmp ecx, dword [esi + 0x20]
jbe 0x10043f55
mov edi, dword [esi + 0x20]
sub edi, dword [esi + 0x28]
mov eax, dword [esi + 0x1c]
add eax, dword [esi + 0x28]
push edi
push eax
push dword [ebp + 8]
call fcn.10051e60
add esp, 0xc
add dword [esi + 0x28], edi
mov eax, edi
adc dword [esi + 0x2c], 0
xor edx, edx
div dword [ebp + 0xc]
pop edi
pop ebp
ret
Function at 0x10044b6f
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
cmp dword [esi], 0
push edi
jne 0x10044bf6
cmp dword [esi + 4], 0xffffffff
jne 0x10044bf6
lea edi, [esi + 0x244]
push edi
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
push edi
call fcn.1005184b
movzx eax, word [esi + eax*2 + 0x242]
cmp ax, 0x5c
pop ecx
je 0x10044bc8
cmp ax, 0x2f
je 0x10044bc8
push edi
call fcn.1005184b
pop ecx
mov ecx, 0x103
sub ecx, eax
push ecx
push 0x1007bf70
push edi
call fcn.10057a3e
add esp, 0xc
lea eax, [ebp + 8]
push eax
push dword [ebp + 8]
call fcn.10043dbc
test eax, eax
pop ecx
pop ecx
jne 0x10044bdf
mov eax, dword [ebp + 8]
jmp 0x10044bfb
call fcn.1004418e
mov dword [esi], eax
neg eax
sbb eax, eax
and eax, 0xfffffe00
add eax, 0x200
jmp 0x10044bfb
mov eax, 0x1000000
pop edi
pop ebp
ret 4

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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x414
mov eax, dword [0x10095428]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
test ebx, ebx
push esi
mov esi, dword [ebp + 0xc]
je 0x100451e9
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x100451e9
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
movzx ecx, word [esi]
test cx, cx
je 0x100452ab
mov eax, esi
mov edx, esi
movzx ecx, cx
cmp cx, 0x2f
je 0x10045208
cmp cx, 0x5c
jne 0x1004520a
mov eax, edx
inc edx
inc edx
movzx ecx, word [edx]
test cx, cx
jne 0x100451fc
cmp eax, esi
push edi
je 0x10045248
sub eax, esi
sar eax, 1
add eax, eax
mov edi, eax
push edi
lea eax, [ebp - 0x414]
push esi
push eax
call fcn.10051e60
and word [ebp + edi - 0x414], 0
lea eax, [ebp - 0x414]
push eax
push ebx
call fcn.100451b5
add esp, 0x14
and word [ebp - 0x20c], 0
test ebx, ebx
mov edi, 0x103
je 0x1004526a
push edi
lea eax, [ebp - 0x20c]
push ebx
push eax
call fcn.10054a96
add esp, 0xc
lea eax, [ebp - 0x20c]
push eax
call fcn.1005184b
sub edi, eax
push edi
lea eax, [ebp - 0x20c]
push esi
push eax
call fcn.10057a3e
add esp, 0x10
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
pop edi
jne 0x100452ab
push 0
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
mov ecx, dword [ebp - 4]
pop esi
xor ecx, ebp
pop ebx
call fcn.10051861
leave
ret
Function at 0x10045d2a
Capabilities:
Create directory
Get file attributes

Disassembly:
push 0x14
mov eax, 0x100747b8
call fcn.1005886f
mov edi, ecx
and dword [ebp - 0x18], 0
lea esi, [ebp - 0x10]
call fcn.10045832
and dword [ebp - 4], 0
mov eax, dword [0x10099288]
mov dword [ebp - 0x14], eax
mov byte [ebp - 4], 1
push dword [edi]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0x10
je 0x10045e6c
mov edi, dword [ebp - 0x10]
mov eax, dword [edi - 8]
movzx eax, word [edi + eax*2 - 2]
cmp ax, 0x5c
mov esi, 0x1007bf70
je 0x10045d8e
push esi
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenW]
lea ecx, [ebp - 0x10]
call fcn.10045b83
mov edi, dword [ebp - 0x10]
mov eax, dword [edi - 8]
test eax, eax
jl 0x10045da2
push esi
push edi
call fcn.100525c5
test eax, eax
pop ecx
pop ecx
jne 0x10045da7
or eax, 0xffffffff
jmp 0x10045dab
sub eax, edi
sar eax, 1
cmp eax, 0xffffffff
je 0x10045e6c
lea ecx, [eax + 1]
lea eax, [ebp - 0x1c]
push eax
lea ebx, [ebp - 0x10]
mov dword [ebp - 0x20], ecx
call fcn.100458be
mov byte [ebp - 4], 2
mov eax, dword [eax]
push eax
mov eax, dword [eax - 8]
lea ecx, [ebp - 0x14]
call fcn.10045b83
lea esi, [ebp - 0x1c]
mov byte [ebp - 4], 1
call fcn.10045a88
mov ebx, dword [ebp - 0x20]
test ebx, ebx
mov esi, dword [edi - 8]
jle 0x10045e26
test esi, esi
jle 0x10045e26
cmp ebx, esi
jle 0x10045df8
mov ebx, esi
lea eax, [ebp - 0x10]
call fcn.10045c0a
mov edi, dword [ebp - 0x10]
mov eax, esi
sub eax, ebx
lea eax, [eax + eax + 2]
push eax
lea eax, [edi + ebx*2]
push eax
mov eax, dword [edi - 4]
lea eax, [eax + eax + 2]
push eax
push edi
call fcn.100160d7
add esp, 0x10
sub esi, ebx
mov dword [edi - 8], esi
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
or esi, 0xffffffff
cmp eax, esi
jne 0x10045e45
push 0
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
je 0x10045e73
cmp dword [edi - 8], 0
jl 0x10045e5c
push 0x1007bf70
push edi
call fcn.100525c5
test eax, eax
pop ecx
pop ecx
jne 0x10045e60
mov eax, esi
jmp 0x10045e64
sub eax, edi
sar eax, 1
cmp eax, esi
jne 0x10045db4
mov dword [ebp - 0x18], 1
lea esi, [ebp - 0x14]
call fcn.10045a88
lea esi, [ebp - 0x10]
call fcn.10045a88
mov eax, dword [ebp - 0x18]
call fcn.10058947
ret
Function at 0x100462c8
Capabilities:
Check if file exists
Extract resource via kernel32 functions
Get file attributes

Disassembly:
push 0x60
mov eax, 0x10076398
call fcn.100588d8
mov esi, ecx
xor ebx, ebx
lea edi, [ebp - 0x48]
mov dword [ebp - 0x50], esi
mov byte [ebp - 0x49], bl
call fcn.1004e36b
mov dword [ebp - 4], ebx
mov dword [ebp - 0x14], 7
mov dword [ebp - 0x18], ebx
mov word [ebp - 0x28], bx
mov byte [ebp - 4], 1
cmp dword [esi + 0x14], ebx
jne 0x1004632b
mov eax, edi
push eax
lea ecx, [ebp - 0x6c]
call fcn.1004e0a9
push 0xffffffffffffffff
lea ecx, [ebp - 0x2c]
push ecx
mov byte [ebp - 4], 2
call fcn.10001d68
push ebx
push 1
lea esi, [ebp - 0x6c]
mov byte [ebp - 4], 1
call fcn.10001f1e
jmp 0x1004633a
push 0xffffffffffffffff
lea eax, [ebp - 0x2c]
push eax
xor ebx, ebx
mov eax, esi
call fcn.10001d68
lea esi, [ebp - 0x2c]
call fcn.1004e160
push 0x10086528
lea eax, [ebp - 0x6c]
call fcn.1000189d
lea eax, [ebp - 0x6c]
push eax
mov ecx, esi
mov byte [ebp - 4], 3
call fcn.1004e26e
push 0
push 1
lea esi, [ebp - 0x6c]
mov byte [ebp - 4], 1
call fcn.10001f1e
cmp dword [ebp - 0x14], 8
mov eax, dword [ebp - 0x28]
jae 0x1004637a
lea eax, [ebp - 0x28]
mov ebx, dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
push eax
call ebx
cmp eax, 0xffffffff
je 0x10046394
mov eax, dword [ebp - 0x50]
and dword [eax + 0x1c], 0
jmp 0x10046464
mov edi, dword [ebp - 0x50]
xor esi, esi
inc esi
lea ecx, [ebp - 0x48]
mov dword [edi + 0x1c], esi
call fcn.1004dfb9
push 0x10086540
lea eax, [ebp - 0x6c]
call fcn.1000189d
lea eax, [ebp - 0x6c]
lea ecx, [ebp - 0x48]
mov byte [ebp - 4], 4
call fcn.1004e1f9
push 0
push esi
lea esi, [ebp - 0x6c]
mov byte [ebp - 4], 1
call fcn.10001f1e
cmp dword [ebp - 0x30], 8
mov eax, dword [ebp - 0x44]
jae 0x100463dc
lea eax, [ebp - 0x44]
push eax
call ebx
cmp eax, 0xffffffff
je 0x100463f9
push 0xffffffffffffffff
add edi, 0x80
push edi
xor ebx, ebx
lea eax, [ebp - 0x48]
call fcn.10001d68
jmp 0x10046460
push str.SKIN
push str.QMUIRES.dat
push dword [0x1009a088]
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov esi, eax
test esi, esi
je 0x10046464
push esi
push dword [0x1009a088]
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
je 0x10046464
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
test eax, eax
mov dword [ebp - 0x50], eax
je 0x10046464
push esi
push dword [0x1009a088]
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov ebx, eax
lea esi, [edi + 0xb0]
mov edi, ebx
mov eax, esi
call fcn.10049d27
push ebx
push dword [ebp - 0x50]
push dword [esi]
call fcn.10051e60
add esp, 0xc
mov byte [ebp - 0x49], 1
push 0
push 1
lea esi, [ebp - 0x2c]
call fcn.10001f1e
push 0
push 1
lea esi, [ebp - 0x48]
call fcn.10001f1e
mov al, byte [ebp - 0x49]
call fcn.1005895b
ret
Function at 0x1004687a
Capabilities:
Get file size
Read file on windows

Disassembly:
push 0x50
mov eax, 0x10076340
call fcn.100588d8
mov eax, dword [ebp + 8]
xor ebx, ebx
cmp dword [eax + 0x14], ebx
mov dword [ebp - 0x3c], ecx
mov ecx, dword [ebp + 0xc]
mov edi, edx
mov dword [ebp - 0x40], ecx
mov byte [ebp - 0x2d], bl
je 0x100469a6
lea esi, [ebp - 0x2c]
call fcn.100018c9
mov dword [ebp - 4], ebx
call fcn.1004e160
call dword [0x1009660c]
cmp dword [edi + 0x18], 0x10
mov dword [ebp - 0x34], eax
jb 0x100468c6
mov esi, dword [edi + 4]
jmp 0x100468c9
lea esi, [edi + 4]
cmp esi, ebx
je 0x100468df
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov edi, eax
inc edi
cmp edi, 0x3fffffff
jle 0x100468e3
xor eax, eax
jmp 0x100468f9
lea eax, [edi + edi]
call fcn.10062ae0
mov eax, esp
push dword [ebp - 0x34]
push edi
push esi
mov esi, eax
call fcn.100204a5
push eax
lea eax, [ebp - 0x5c]
call fcn.1000189d
lea eax, [ebp - 0x5c]
push eax
lea ecx, [ebp - 0x2c]
mov byte [ebp - 4], 1
call fcn.1004e26e
push ebx
push 1
lea esi, [ebp - 0x5c]
mov byte [ebp - 4], bl
call fcn.10001f1e
cmp dword [ebp - 0x14], 8
mov eax, dword [ebp - 0x28]
jae 0x1004692c
lea eax, [ebp - 0x28]
push ebx
push 0x80
push 3
push ebx
push 1
push SysReAllocString
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
mov dword [ebp - 0x34], eax
je 0x1004699b
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
cmp esi, ebx
je 0x10046992
lea eax, [esi + 1]
push eax
mov dword [ebp - 0x38], ebx
call fcn.10050eaa
mov edi, dword [ebp - 0x3c]
pop ecx
push ebx
lea ecx, [ebp - 0x38]
push ecx
push esi
push eax
push dword [ebp - 0x34]
mov dword [edi], eax
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x10046992
cmp dword [ebp - 0x38], esi
jne 0x10046992
mov eax, dword [ebp - 0x40]
mov dword [eax], esi
mov eax, dword [edi]
mov byte [esi + eax], bl
mov byte [ebp - 0x2d], 1
push dword [ebp - 0x34]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push ebx
push 1
lea esi, [ebp - 0x2c]
call fcn.10001f1e
mov al, byte [ebp - 0x2d]
lea esp, [ebp - 0x6c]
call fcn.1005895b
ret 8
Function at 0x10047882
Capabilities:
Delete file
Get common file path
Write file on windows

Disassembly:
push ebp
sub esp, 0x410
lea ebp, [esp - 4]
mov eax, dword [0x10095428]
xor eax, ebp
mov dword [ebp + 0x410], eax
push 8
mov eax, 0x10075928
call fcn.1005886f
mov eax, dword [ebp + 0x41c]
mov esi, 0x206
xor edi, edi
push esi
mov dword [ebp - 0x14], eax
lea eax, [ebp + 0x20a]
push edi
push eax
mov word [ebp + 0x208], di
call fcn.10051de0
push esi
lea eax, [ebp + 2]
push edi
push eax
mov word [ebp], di
call fcn.10051de0
add esp, 0x18
push edi
push 0x1a
lea eax, [ebp + 0x208]
push eax
push edi
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
push str.kingsoftkclear_temp
lea eax, [ebp + 0x208]
push eax
call dword [sym.imp.SHLWAPI.dll_PathAppendW]
mov eax, dword [0x10099288]
mov dword [ebp - 0x10], eax
lea eax, [ebp + 0x208]
shr eax, 0x10
test ax, ax
lea eax, [ebp + 0x208]
jne 0x1004792a
movzx eax, ax
push eax
lea ecx, [ebp - 0x10]
call fcn.10045930
jmp 0x1004795f
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
mov esi, eax
cmp esi, edi
je 0x1004795f
push esi
lea eax, [ebp - 0x10]
push eax
call fcn.10045ab0
test eax, eax
je 0x1004795f
lea eax, [esi + esi]
push eax
lea ecx, [ebp + 0x208]
push ecx
add eax, 2
push eax
push dword [ebp - 0x10]
call fcn.1001454c
add esp, 0x10
lea ecx, [ebp - 0x10]
mov dword [ebp - 4], edi
call fcn.10045d2a
lea esi, [ebp - 0x10]
mov ebx, eax
call fcn.10045a88
cmp ebx, edi
je 0x100479d4
lea eax, [ebp]
push eax
push edi
push 0x10086648
lea eax, [ebp + 0x208]
push eax
call dword [sym.imp.KERNEL32.dll_GetTempFileNameW]
lea eax, [ebp]
push 0x10086650
push eax
call fcn.10056675
mov esi, eax
cmp esi, edi
pop ecx
pop ecx
je 0x100479d4
push esi
push dword [ebp + 0x420]
push 1
push dword [ebp - 0x14]
call fcn.10056837
push esi
call fcn.1005692b
add esp, 0x14
push 0x10
push 0x20
push 0x20
push 1
lea eax, [ebp]
push eax
push edi
call dword [sym.imp.USER32.dll_LoadImageW]
mov edi, eax
lea eax, [ebp]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0x410]
xor ecx, ebp
call fcn.10051861
add ebp, 0x414
leave
ret

Function at 0x1004d07a
Capabilities:
Generate random numbers using the delphi lcg

Disassembly:
mov eax, dword [ecx]
mov edx, eax
xor edx, dword [esp + 4]
push esi
mov esi, 0xff
and edx, esi
mov edx, dword [edi + edx*4]
shr eax, 8
xor edx, eax
mov eax, dword [ecx + 8]
mov dword [ecx], edx
movzx edx, dl
add edx, dword [ecx + 4]
imul edx, edx, 0x8088405
inc edx
mov dword [ecx + 4], edx
shr edx, 0x18
xor edx, eax
and edx, esi
shr eax, 8
xor eax, dword [edi + edx*4]
pop esi
mov dword [ecx + 8], eax
mov eax, dword [esp + 4]
ret
Function at 0x10051861
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x10095428]
jne 0x1005186b
repz ret
jmp fcn.1005c69f
Function at 0x10061348
Capabilities:
Write file on windows

Disassembly:
push ecx
push ebx
mov ebx, dword [esp + 0xc]
push esi
push edi
xor esi, esi
xor edi, edi
cmp ebx, dword [edi*8 + 0x10095b98]
je 0x10061363
inc edi
cmp edi, 0x17
jb 0x10061354
cmp edi, 0x17
jae 0x100614e3
push ebp
push 3
call fcn.10068cf1
cmp eax, 1
pop ecx
je 0x100614af
push 3
call fcn.10068cf1
test eax, eax
pop ecx
jne 0x10061397
cmp dword [0x100995b8], 1
je 0x100614af
cmp ebx, 0xfc
je 0x100614e2
push 0x1007a970
mov ebx, 0x314
push ebx
mov ebp, 0x10099af8
push ebp
call fcn.1005d288
add esp, 0xc
test eax, eax
je 0x100613cd
push esi
push esi
push esi
push esi
push esi
call fcn.10051648
add esp, 0x14
push 0x104
mov esi, 0x10099b11
push esi
push 0
mov byte [0x10099c15], 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x10061411
push 0x1007a958
push 0x2fb
push esi
call fcn.1005d288
add esp, 0xc
test eax, eax
je 0x10061411
xor eax, eax
push eax
push eax
push eax
push eax
push eax
call fcn.10051648
add esp, 0x14
push esi
call fcn.100517c0
inc eax
cmp eax, 0x3c
pop ecx
jbe 0x10061456
push esi
call fcn.100517c0
sub esi, 0x3b
add eax, esi
push 3
mov ecx, 0x10099e0c
push 0x1007a954
sub ecx, eax
push ecx
push eax
call fcn.10057ae0
add esp, 0x14
test eax, eax
je 0x10061456
xor esi, esi
push esi
push esi
push esi
push esi
push esi
call fcn.10051648
add esp, 0x14
jmp 0x10061458
xor esi, esi
push 0x1007a950
push ebx
push ebp
call fcn.10066a1e
add esp, 0xc
test eax, eax
je 0x10061478
push esi
push esi
push esi
push esi
push esi
call fcn.10051648
add esp, 0x14
push dword [edi*8 + 0x10095b9c]
push ebx
push ebp
call fcn.10066a1e
add esp, 0xc
test eax, eax
je 0x1006149a
push esi
push esi
push esi
push esi
push esi
call fcn.10051648
add esp, 0x14
push 0x12010
push 0x1007a928
push ebp
call fcn.10068b34
add esp, 0xc
jmp 0x100614e2
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
mov ebp, eax
cmp ebp, esi
je 0x100614e2
cmp ebp, 0xffffffff
je 0x100614e2
push 0
lea eax, [esp + 0x14]
push eax
lea esi, [edi*8 + 0x10095b9c]
push dword [esi]
call fcn.100517c0
pop ecx
push eax
push dword [esi]
push ebp
call dword [sym.imp.KERNEL32.dll_WriteFile]
pop ebp
pop edi
pop esi
pop ebx
pop ecx
ret