joyce8/EMBER2024-capa huggingface dataset:
Function at 0x406919
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push esi
mov esi, dword [ebp + 8]
xor ebx, ebx
mov ecx, ebx
push edi
mov dword [ebp - 4], ecx
mov edi, ebx
mov eax, dword [esi + 0x6af90]
mov dword [esi + 0x6af80], 2
jmp 0x406b2b
cmp eax, 3
jb 0x406998
mov edx, dword [esi + 0x6af84]
mov eax, dword [esi + 0x6af7c]
shl eax, 5
movzx ecx, byte [edx + esi + 0x1af72]
xor ecx, eax
and ecx, 0x7fff
and edx, 0x7fff
mov dword [esi + 0x6af7c], ecx
mov eax, dword [esi + ecx*4 + 0x4af70]
mov dword [esi + edx*4 + 0x2af70], eax
mov ecx, dword [esi + 0x6af7c]
mov dword [ebp - 4], eax
mov eax, dword [esi + 0x6af84]
mov dword [esi + ecx*4 + 0x4af70], eax
mov ecx, dword [ebp - 4]
test ecx, ecx
je 0x4069d5
mov eax, dword [esi + 0x6af84]
sub eax, ecx
cmp eax, 0x7efa
ja 0x4069d5
mov eax, dword [esi + 0x6af90]
cmp dword [esi + 0x6afa0], eax
jbe 0x4069bf
mov dword [esi + 0x6afa0], eax
push ecx
push esi
call fcn.00407496
pop ecx
pop ecx
mov ecx, dword [esi + 0x6af90]
mov edi, eax
cmp edi, ecx
cmova edi, ecx
mov ecx, dword [esi + 0x6af84]
cmp edi, 3
jb 0x406ab5
sub ecx, dword [esi + 0x6af88]
lea eax, [edi - 3]
push eax
push ecx
push esi
call fcn.0040643f
mov ecx, dword [esi + 0x6af90]
add esp, 0xc
sub ecx, edi
mov dword [ebp + 8], eax
mov dword [esi + 0x6af90], ecx
cmp edi, dword [esi + 0x6af98]
ja 0x406a7f
cmp ecx, 3
jb 0x406a7f
dec edi
inc dword [esi + 0x6af84]
mov edx, dword [esi + 0x6af84]
mov eax, dword [esi + 0x6af7c]
shl eax, 5
movzx ecx, byte [edx + esi + 0x1af72]
and edx, 0x7fff
xor ecx, eax
and ecx, 0x7fff
mov dword [esi + 0x6af7c], ecx
mov eax, dword [esi + ecx*4 + 0x4af70]
mov dword [esi + edx*4 + 0x2af70], eax
mov ecx, dword [esi + 0x6af7c]
mov dword [ebp - 4], eax
mov eax, dword [esi + 0x6af84]
mov dword [esi + ecx*4 + 0x4af70], eax
sub edi, 1
jne 0x406a17
inc dword [esi + 0x6af84]
mov edx, dword [esi + 0x6af84]
jmp 0x406ab0
mov edx, dword [esi + 0x6af84]
add edx, edi
mov edi, ebx
mov dword [esi + 0x6af84], edx
movzx ecx, byte [edx + esi + 0x1af70]
mov dword [esi + 0x6af7c], ecx
movzx eax, byte [edx + esi + 0x1af71]
shl ecx, 5
xor eax, ecx
mov dword [esi + 0x6af7c], eax
mov eax, dword [ebp + 8]
jmp 0x406ada
movzx eax, byte [ecx + esi + 0x1af70]
push eax
push ebx
push esi
call fcn.0040643f
add esp, 0xc
dec dword [esi + 0x6af90]
inc dword [esi + 0x6af84]
mov edx, dword [esi + 0x6af84]
test eax, eax
je 0x406b0e
mov eax, dword [esi + 0x6af74]
test eax, eax
js 0x406af2
lea ecx, [esi + 0x1af70]
add ecx, eax
jmp 0x406af4
mov ecx, ebx
push ebx
sub edx, eax
push edx
push ecx
push esi
call fcn.00406d23
mov eax, dword [esi + 0x6af84]
add esp, 0x10
mov dword [esi + 0x6af74], eax
mov eax, dword [esi + 0x6af90]
cmp eax, 0x106
jae 0x406b28
push esi
call fcn.00406bdc
mov eax, dword [esi + 0x6af90]
pop ecx
mov ecx, dword [ebp - 4]
test eax, eax
jne 0x406941
mov ecx, dword [esi + 0x6af74]
test ecx, ecx
js 0x406b45
lea ebx, [esi + 0x1af70]
add ebx, ecx
mov eax, dword [esi + 0x6af84]
push 1
sub eax, ecx
push eax
push ebx
push esi
call fcn.00406d23
add esp, 0x10
pop edi
pop esi
pop ebx
leave
ret
Function at 0x40736a
Capabilities:
Encode data using xor
Encrypt data using rc4 prga

Disassembly:
push ebp
mov ebp, esp
push ebx
mov ebx, dword [ebp + 0xc]
push esi
mov esi, dword [ebp + 8]
push edi
lea eax, [ebx - 1]
cmp eax, 7
jbe 0x407388
mov dword [esi + 0x6afa4], str.bad_pack_level
xor edi, edi
mov dword [esi + 0x6af78], edi
cmp dword [esi + 0x6af70], edi
jne 0x4073ac
mov dword [esi + 0x6af78], 1
mov dword [esi + 0x6af70], 0x10000
push 0x1fffc
lea eax, [esi + 0x4af70]
mov dword [esi + 0x6af6c], edi
push edi
push eax
call fcn.00409fd0
movzx eax, word [ebx*8 + 0x41f8f2]
add esp, 0xc
mov dword [esi + 0x6af98], eax
movzx eax, word [ebx*8 + 0x41f8f0]
mov dword [esi + 0x6af9c], eax
movzx eax, word [ebx*8 + 0x41f8f4]
push 2
mov dword [esi + 0x6afa0], eax
movzx eax, word [ebx*8 + 0x41f8f6]
pop ecx
mov dword [esi + 0x6af94], eax
cmp ebx, ecx
jg 0x40740f
mov eax, dword [ebp + 0x10]
or word [eax], 4
jmp 0x40741a
cmp ebx, 8
jl 0x40741a
mov eax, dword [ebp + 0x10]
or word [eax], cx
push 0x10000
lea ebx, [esi + 0x1af70]
mov dword [esi + 0x6af84], edi
push ebx
push esi
mov dword [esi + 0x6af74], edi
call dword [esi + 0xc]
add esp, 0xc
mov dword [esi + 0x6af90], eax
test eax, eax
je 0x407481
cmp eax, 0xffffffff
je 0x407481
mov dword [esi + 0x6af8c], edi
cmp eax, 0x106
jae 0x40745c
push esi
call fcn.00406bdc
pop ecx
mov dword [esi + 0x6af7c], edi
mov ecx, edi
movzx eax, byte [ebx + edi]
shl ecx, 5
xor ecx, eax
and ecx, 0x7fff
inc edi
mov dword [esi + 0x6af7c], ecx
cmp edi, 2
jb 0x407464
jmp 0x407491
mov dword [esi + 0x6af8c], 1
mov dword [esi + 0x6af90], edi
pop edi
pop esi
pop ebx
pop ebp
ret
Function at 0x408190
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
push edi
mov edi, ecx
mov ecx, dword [edi + 0x78]
test ecx, ecx
je 0x4081e0
mov eax, dword [edi + 0x80]
mov esi, dword [edi + 0x7c]
cmp eax, esi
jae 0x40821d
sub esi, eax
cmp esi, dword [ebp + 0xc]
cmova esi, dword [ebp + 0xc]
add eax, ecx
push esi
push eax
push dword [ebp + 8]
call fcn.00409a50
add dword [edi + 0x80], esi
add dword [edi + 0x68], esi
push esi
push dword [ebp + 8]
push dword [edi + 0x6c]
call fcn.004060f5
add esp, 0x18
mov dword [edi + 0x6c], eax
mov eax, esi
jmp 0x40821f
cmp dword [edi + 0x70], 0
je 0x408216
push 0
lea eax, [ebp - 4]
push eax
push dword [ebp + 0xc]
push dword [ebp + 8]
push dword [edi + 0x70]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x40821d
mov esi, dword [ebp - 4]
add dword [edi + 0x68], esi
push esi
push dword [ebp + 8]
push dword [edi + 0x6c]
call fcn.004060f5
add esp, 0xc
jmp 0x4081d9
mov dword [edi + 0x14], 0x1000000
xor eax, eax
pop edi
pop esi
leave
ret 8

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

Disassembly:
push ebp
mov ebp, esp
mov edx, dword [ebp + 8]
movsx eax, byte [ebp + 0xc]
mov ecx, dword [edx]
xor eax, ecx
movzx eax, al
shr ecx, 8
xor ecx, dword [eax*4 + 0x41f958]
movzx eax, cl
add eax, dword [edx + 4]
imul eax, eax, 0x8088405
mov dword [edx], ecx
mov ecx, dword [edx + 8]
inc eax
mov dword [edx + 4], eax
shr eax, 0x18
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x41f958]
mov dword [edx + 8], ecx
pop ebp
ret

Function at 0x4086df
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ebx
mov ebx, dword [ebp + 8]
push esi
mov esi, ecx
push edi
mov edi, dword [ebp + 0xc]
cmp byte [esi + 0x2d], 0
je 0x408757
mov ecx, dword [esi + 0x3c]
mov eax, ecx
test ecx, ecx
je 0x40870e
cmp dword [esi + 0x40], edi
jae 0x40870e
push ecx
call fcn.00408852
and dword [esi + 0x3c], 0
pop ecx
jmp 0x408712
test eax, eax
jne 0x408722
lea eax, [edi + edi]
push eax
call fcn.00408849
pop ecx
mov dword [esi + 0x3c], eax
mov dword [esi + 0x40], edi
push edi
push ebx
push eax
call fcn.00409a50
add esp, 0xc
xor ebx, ebx
test edi, edi
je 0x408754
lea ecx, [esi + 0x30]
mov eax, dword [esi + 0x3c]
movzx eax, byte [ebx + eax]
push eax
push ecx
call fcn.004087b1
pop ecx
pop ecx
mov ecx, dword [esi + 0x3c]
mov byte [ebx + ecx], al
inc ebx
lea ecx, [esi + 0x30]
cmp ebx, edi
jb 0x408736
mov ebx, dword [esi + 0x3c]
mov ecx, dword [esi + 0x20]
test ecx, ecx
je 0x408786
mov edx, dword [esi + 0x24]
lea eax, [edx + edi]
cmp eax, dword [esi + 0x28]
jb 0x408772
mov dword [esi + 0x14], 0x30000
jmp 0x4087a8
push edi
add ecx, edx
push ebx
push ecx
call fcn.00409a50
add esp, 0xc
mov eax, edi
add dword [esi + 0x24], edi
jmp 0x4087aa
mov eax, dword [esi + 4]
test eax, eax
je 0x4087a1
push 0
lea ecx, [ebp + 8]
push ecx
push edi
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [ebp + 8]
jmp 0x4087aa
mov dword [esi + 0x14], 0x1000000
xor eax, eax
pop edi
pop esi
pop ebx
pop ebp
ret 8
Function at 0x40cb7a
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x101c
call fcn.004087e0
mov eax, dword [0x428024]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0x14]
push ebx
push dword [ebp + 8]
mov dword [ebp - 0x100c], eax
call fcn.00410d95
pop ecx
mov ecx, dword [ebp + 8]
mov ebx, eax
cmp dword [ecx + 8], 0
jne 0x40cbbc
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
jmp 0x40cd18
mov eax, dword [ecx]
sub eax, dword [ecx + 4]
push esi
push edi
push 0
cdq
push 2
push edx
push eax
call fcn.00408880
push dword [ebp - 0x100c]
mov ecx, ebx
mov dword [ebp - 0x1008], eax
mov esi, ebx
mov dword [ebp - 0x1018], edx
and ecx, 0x3f
sar esi, 6
imul edi, ecx, 0x38
push 0
mov eax, dword [esi*4 + 0x429248]
push dword [edi + eax + 0x24]
push dword [edi + eax + 0x20]
push ebx
call fcn.00413139
mov ecx, dword [esi*4 + 0x429248]
add esp, 0x14
mov dword [ebp - 0x1010], eax
mov eax, edx
mov edx, dword [ebp - 0x1010]
mov dword [ebp - 0x101c], eax
cmp edx, dword [edi + ecx + 0x20]
jne 0x40cd11
cmp eax, dword [edi + ecx + 0x24]
jne 0x40cd11
push 0
lea eax, [ebp - 0x1014]
push eax
push 0x1000
lea eax, [ebp - 0x1004]
push eax
push dword [edi + ecx + 0x18]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x40cd11
push dword [ebp - 0x100c]
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.00413139
add esp, 0x14
test edx, edx
jl 0x40cd11
jg 0x40cc87
test eax, eax
jb 0x40cd11
mov ebx, dword [ebp - 0x1018]
mov eax, dword [ebp - 0x1014]
test ebx, ebx
jg 0x40cd11
jl 0x40cca1
cmp dword [ebp - 0x1008], eax
ja 0x40cd11
lea edi, [ebp - 0x1004]
xor edx, edx
add edi, eax
lea ecx, [ebp - 0x1004]
xor esi, esi
cmp dword [ebp - 0x1008], edx
jne 0x40ccbf
test ebx, ebx
je 0x40ccf8
cmp ecx, edi
jae 0x40ccf8
mov al, byte [ecx]
cmp al, 0xd
jne 0x40ccd9
lea eax, [edi - 1]
cmp ecx, eax
jae 0x40cce5
cmp byte [ecx + 1], 0xa
jne 0x40cce5
inc ecx
jmp 0x40cce5
movzx eax, al
movsx eax, byte [eax + 0x428228]
add ecx, eax
add esi, 1
adc edx, 0
inc ecx
cmp esi, dword [ebp - 0x1008]
jne 0x40ccbf
cmp edx, ebx
jne 0x40ccbf
lea eax, [ebp - 0x1004]
sub ecx, eax
mov eax, ecx
cdq
add eax, dword [ebp - 0x1010]
adc edx, dword [ebp - 0x101c]
jmp 0x40cd16
or edx, 0xffffffff
mov eax, edx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.00408b75
leave
ret
Function at 0x412244
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 + 0x429248]
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 0x412284
cmp byte [ebx], 0xa
jne 0x412284
or byte [eax + edi + 0x28], 4
jmp 0x412289
and byte [eax + edi + 0x28], 0xfb
add ecx, ebx
mov edx, ebx
mov dword [ebp - 0xc], ecx
mov esi, ebx
cmp ebx, ecx
jae 0x412387
mov al, byte [edx]
cmp al, 0x1a
je 0x412369
lea ecx, [edx + 1]
mov dword [ebp - 8], ecx
mov ecx, dword [ebp - 0xc]
cmp al, 0xd
je 0x4122b8
mov edx, dword [ebp - 8]
mov byte [esi], al
jmp 0x4122dd
mov eax, dword [ebp - 8]
cmp eax, ecx
jae 0x4122e7
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 0x41229a
jmp 0x412387
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 0x412364
cmp dword [ebp - 0xc], 0
je 0x412364
mov ecx, dword [ebp - 0x10]
mov eax, dword [ecx*4 + 0x429248]
test byte [eax + edi + 0x28], 0x48
je 0x41233e
mov dl, byte [ebp - 1]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
cmp dl, 0xa
jne 0x412329
mov byte [esi], dl
jmp 0x41233a
mov byte [esi], 0xd
mov eax, dword [ecx*4 + 0x429248]
mov byte [eax + edi + 0x2a], dl
mov eax, dword [ebp - 0x14]
mov esi, eax
jmp 0x412387
cmp byte [ebp - 1], 0xa
jne 0x41234d
cmp esi, ebx
jne 0x41234d
mov byte [esi], 0xa
jmp 0x412386
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.00413157
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x412387
mov byte [esi], 0xd
jmp 0x412386
mov ecx, dword [ebp - 0x10]
mov ecx, dword [ecx*4 + 0x429248]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x412383
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x412387
mov byte [esi], 0x1a
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x412390
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 + 0x429248]
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 0x4123d3
cmp word [esi], dx
jne 0x4123d3
or byte [edi + eax + 0x28], 4
jmp 0x4123d8
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 0x41252b
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 0x41250b
add eax, 2
cmp cx, word [ebp - 0xc]
je 0x41241a
mov dword [ebp - 4], eax
mov word [esi], cx
jmp 0x412450
cmp eax, edx
jae 0x41245c
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 0x4123f2
jmp 0x41252b
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 0x412507
cmp dword [ebp - 0x14], 0
je 0x412507
mov eax, dword [ebx*4 + 0x429248]
push 0xa
test byte [edi + eax + 0x28], 0x48
je 0x4124df
mov dx, word [ebp - 4]
lea eax, [esi + 2]
pop ecx
mov dword [ebp - 0x18], eax
cmp dx, cx
jne 0x4124a8
mov word [esi], cx
jmp 0x4124db
push 0xd
pop eax
mov word [esi], ax
mov eax, dword [ebx*4 + 0x429248]
movzx ecx, dx
shr ecx, 8
push 0xa
mov byte [edi + eax + 0x2a], dl
mov eax, dword [ebx*4 + 0x429248]
mov byte [edi + eax + 0x2b], cl
mov eax, dword [ebx*4 + 0x429248]
pop ecx
mov byte [edi + eax + 0x2c], cl
mov eax, dword [ebp - 0x18]
mov esi, eax
jmp 0x41252b
pop ebx
cmp word [ebp - 4], bx
jne 0x4124f0
cmp esi, dword [ebp + 0xc]
jne 0x4124f0
mov word [esi], bx
jmp 0x412528
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.00413157
add esp, 0x10
cmp word [ebp - 4], bx
je 0x41252b
push 0xd
jmp 0x412524
mov ecx, dword [ebx*4 + 0x429248]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x412522
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x41252b
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 0x412d4c
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.00412bbd
Function at 0x416ef3
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
mov esi, eax
test esi, esi
je 0x416f90
push ebx
push esi
call fcn.00416ebc
xor ebx, ebx
sub eax, esi
push ebx
push ebx
push ebx
push ebx
sar eax, 1
push eax
push esi
push ebx
push ebx
mov dword [ebp - 8], eax
call fcn.00416e05
add esp, 0x24
mov dword [ebp - 4], eax
test eax, eax
jne 0x416f3d
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x416f8f
push edi
push eax
call fcn.0041445f
mov edi, eax
pop ecx
push ebx
test edi, edi
jne 0x416f5d
call fcn.00410af2
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x416f8e
push ebx
push dword [ebp - 4]
push edi
push dword [ebp - 8]
push esi
push ebx
push ebx
call fcn.00416e05
add esp, 0x20
test eax, eax
jne 0x416f7c
push edi
call fcn.00410af2
jmp 0x416f84
push ebx
call fcn.00410af2
mov ebx, edi
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov eax, ebx
pop edi
pop ebx
pop esi
leave
ret

Function at 0x4178e8
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x422780
push 0x422778
push str.FlsAlloc
push 0x1e
call fcn.00417806
mov esi, eax
add esp, 0x10
test esi, esi
je 0x41791c
push dword [ebp + 8]
mov ecx, esi
call dword [0x41f230]
call esi
jmp 0x417922
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x417966
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x422790
push 0x422788
push str.FlsGetValue
push 0x20
call fcn.00417806
mov esi, eax
add esp, 0x10
test esi, esi
je 0x41799d
push dword [ebp + 8]
mov ecx, esi
call dword [0x41f230]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]
Function at 0x41b8a5
Capabilities:
Clear file content

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x2c
push ebx
mov ebx, dword [ebp + 8]
lea ecx, [ebp - 0x2c]
push esi
push edi
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.0041b821
mov eax, dword [ebp - 0x2c]
and eax, dword [ebp - 0x28]
cmp eax, 0xffffffff
je 0x41ba1d
mov eax, dword [ebp - 0x24]
and eax, dword [ebp - 0x20]
cmp eax, 0xffffffff
je 0x41ba1d
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 8], ecx
mov dword [ebp - 4], eax
test ecx, ecx
jl 0x41b9cc
jg 0x41b8fe
test eax, eax
je 0x41b9c2
push 1
push 0x1000
call fcn.00415b5d
mov esi, eax
pop ecx
pop ecx
test esi, esi
jne 0x41b924
mov eax, dword [ebp + 0x14]
push 0xc
pop edi
mov byte [eax + 0x1c], 1
mov dword [eax + 0x18], edi
jmp 0x41b9b9
push 0x8000
push ebx
call fcn.00410265
mov edi, dword [ebp + 0x14]
pop ecx
pop ecx
mov ecx, dword [ebp - 0x1c]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0x18]
test eax, eax
jl 0x41b950
jg 0x41b94b
cmp ecx, 0x1000
jb 0x41b950
mov ecx, 0x1000
push edi
push ecx
push esi
push ebx
call fcn.00413aa2
add esp, 0x10
cmp eax, 0xffffffff
je 0x41b995
mov ecx, dword [ebp - 4]
cdq
sub ecx, eax
mov eax, dword [ebp - 8]
mov dword [ebp - 4], ecx
sbb eax, edx
mov dword [ebp - 8], eax
test eax, eax
jg 0x41b94b
jl 0x41b97c
test ecx, ecx
jne 0x41b93d
push dword [ebp - 0xc]
push ebx
call fcn.00410265
push esi
call fcn.00410af2
add esp, 0xc
xor edi, edi
jmp 0x41ba2e
cmp byte [edi + 0x24], 0
je 0x41b9ac
cmp dword [edi + 0x20], 5
jne 0x41b9ac
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], 0xd
cmp byte [edi + 0x1c], 0
je 0x41b9b7
mov edi, dword [edi + 0x18]
jmp 0x41b9b9
xor edi, edi
push esi
call fcn.00410af2
pop ecx
jmp 0x41ba2e
test ecx, ecx
jg 0x41b98e
jl 0x41b9cc
test eax, eax
jae 0x41b98e
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.00413157
and eax, edx
add esp, 0x10
cmp eax, 0xffffffff
jne 0x41b9ef
mov edi, dword [ebp + 0x14]
cmp byte [edi + 0x1c], 0
je 0x41b98e
jmp 0x41ba26
push ebx
call fcn.004143f5
pop ecx
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x41b98e
mov esi, dword [ebp + 0x14]
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 0xd
mov byte [esi + 0x24], 1
mov dword [esi + 0x20], eax
pop edi
mov byte [esi + 0x1c], 1
mov dword [esi + 0x18], edi
jmp 0x41ba2e
mov edi, dword [ebp + 0x14]
cmp byte [edi + 0x1c], 0
je 0x41ba2b
mov edi, dword [edi + 0x18]
jmp 0x41ba2e
push 0x16
pop edi
push 0
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
push dword [ebp - 0x14]
call fcn.00413157
add esp, 0x10
mov eax, edi
pop edi
pop esi
pop ebx
leave
ret
Function at 0x403100
Capabilities:
Get disk information

Disassembly:
sub esp, 0x83c
mov eax, dword [esp + 0x840]
mov ecx, dword [eax]
mov edx, dword [0x43ff5c]
push ebx
push ebp
push esi
mov esi, dword [eax + 4]
mov eax, dword [0x43ff58]
mov dword [esp + 0x40], eax
push edi
lea eax, [esp + 0x10]
mov dword [esp + 0x28], ecx
mov dword [esp + 0x10], 0
mov dword [esp + 0x3c], 0x9e3779b9
mov dword [esp + 0x34], edx
call fcn.004030d0
mov eax, dword [0x43ff60]
mov edx, dword [0x43ff64]
add dword [esp + 0x10], 0x23f
mov edi, dword [sym.imp.KERNEL32.dll_GetExitCodeProcess]
mov ebx, dword [sym.imp.KERNEL32.dll_GetLogicalDriveStringsW]
mov ebp, dword [sym.imp.KERNEL32.dll_CreateHardLinkW]
mov dword [esp + 0x40], eax
mov dword [esp + 0x38], edx
mov dword [esp + 0x2c], 0x20
jmp 0x403180
mov dword [esp + 0x20], 2
add dword [esp + 0x20], 3
mov eax, dword [0x824d94]
shl ecx, 4
add ecx, dword [esp + 0x40]
mov dword [esp + 0x14], ecx
cmp eax, 0xfa9
jne 0x4031b0
mov dword [0x824d90], 0xedeb2e40
jmp 0x4031c1
cmp eax, 0x3eb
jne 0x4031c1
mov dword [0x821c98], 0
mov eax, dword [esp + 0x28]
mov dword [esp + 0x24], eax
mov eax, dword [esp + 0x10]
add dword [esp + 0x24], eax
mov eax, dword [esp + 0x28]
shr eax, 5
mov dword [esp + 0x18], eax
mov ecx, dword [esp + 0x38]
lea eax, [esp + 0x18]
mov dword [0x824d8c], 0xf4ea3dee
call fcn.004030e0
mov eax, dword [esp + 0x24]
xor dword [esp + 0x14], eax
mov eax, dword [esp + 0x14]
xor dword [esp + 0x18], eax
cmp dword [0x824d94], 0x213
jne 0x40324a
push 0
push 0
call edi
lea ecx, [esp + 0x4c]
push ecx
push 0
call ebx
push 0
push 0x402c40
push 0x402ca4
call ebp
lea edx, [esp + 0x48]
push edx
push 0x402cb8
call dword [sym.imp.KERNEL32.dll_GetCompressedFileSizeA]
push 0
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_ChangeTimerQueueTimer]
sub esi, dword [esp + 0x18]
lea ecx, [esp + 0x14]
mov eax, esi
mov dword [esp + 0x30], esi
call fcn.004030c0
mov eax, dword [esp + 0x44]
add dword [esp + 0x14], eax
mov dword [esp + 0x1c], 0
mov eax, dword [esp + 0x10]
add dword [esp + 0x1c], eax
mov eax, dword [esp + 0x30]
nop
add dword [esp + 0x1c], eax
mov eax, dword [esp + 0x1c]
mov dword [esp + 0x24], eax
mov ecx, esi
shr ecx, 5
add ecx, dword [esp + 0x34]
mov dword [esp + 0x18], ecx
mov eax, dword [esp + 0x24]
xor dword [esp + 0x14], eax
cmp dword [0x824d94], 0x121
jne 0x4032b6
push 0
push 0
lea edx, [esp + 0x54]
push edx
call dword [sym.imp.KERNEL32.dll_GetConsoleAliasesA]
mov ecx, dword [esp + 0x14]
xor ecx, dword [esp + 0x18]
lea eax, [esp + 0x28]
mov dword [esp + 0x14], ecx
call fcn.004030f0
mov eax, dword [esp + 0x3c]
sub dword [esp + 0x10], eax
sub dword [esp + 0x2c], 1
mov ecx, dword [esp + 0x28]
jne 0x403180
mov eax, dword [esp + 0x850]
pop edi
mov dword [eax + 4], esi
pop esi
pop ebp
mov dword [eax], ecx
pop ebx
add esp, 0x83c
ret 4