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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
push ebx
push esi
push edi
push 0x400
mov esi, ecx
mov dword [ebp - 8], 0
xor bl, bl
call fcn.3015f9e2
mov dword [esi + 0x38], eax
add esp, 4
mov eax, dword [esi + 0x3c]
cmp eax, 0xffffffff
jne 0x30012ce9
mov eax, dword [esi + 0x10]
test eax, eax
je 0x30012dc5
push 0
push 0
push 3
push 0
push 1
push closesocket
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [esi + 0x3c], eax
cmp eax, 0xffffffff
je 0x30012dcc
xor ecx, ecx
mov dword [ebp - 0x14], ecx
mov dword [ebp - 0x10], ecx
test eax, eax
je 0x30012d09
lea ecx, [ebp - 0x14]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
je 0x30012d09
mov ecx, dword [ebp - 0x14]
jmp 0x30012d0b
xor ecx, ecx
push 0
lea eax, [ebp - 8]
mov dword [esi + 0x44], ecx
push eax
push 0x400
push dword [esi + 0x38]
push dword [esi + 0x3c]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x30012db6
push 0x400
push dword [esi + 0x38]
mov ecx, esi
mov bl, 1
call fcn.300131d0
mov ecx, dword [esi + 0x18]
test ecx, ecx
je 0x30012db6
call fcn.30003fc0
cmp eax, 1
jne 0x30012db6
push ecx
mov ecx, esi
call fcn.300133d0
mov edi, eax
cmp edi, 0x400
jbe 0x30012db6
mov eax, dword [esi + 0x44]
test eax, eax
je 0x30012d6e
cmp eax, edi
jae 0x30012d6e
mov edi, eax
push dword [esi + 0x38]
call fcn.3015f9dd
add esp, 4
push edi
call fcn.3015f9e2
add esp, 4
mov dword [esi + 0x38], eax
push 0
push 0
push 0
push dword [esi + 0x3c]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 0
lea eax, [ebp - 8]
push eax
push edi
push dword [esi + 0x38]
push dword [esi + 0x3c]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x30012db6
push edi
push dword [esi + 0x38]
mov ecx, esi
call fcn.300131d0
mov eax, dword [esi + 0x3c]
cmp eax, 0xffffffff
je 0x30012dcc
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [esi + 0x3c], 0xffffffff
pop edi
pop esi
mov al, bl
pop ebx
mov esp, ebp
pop ebp
ret 4
Function at 0x300131d0
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push esi
push edi
mov edi, ecx
mov ecx, dword [ebp + 8]
mov esi, ecx
mov dword [edi + 0x18], ecx
mov dword [edi + 0x24], 0
mov dword [edi + 0x28], 0
mov dword [edi + 0x20], 0
mov dword [edi + 0x1c], 0
mov eax, dword [ecx + 0x3c]
test eax, eax
jle 0x30013236
cmp eax, dword [ebp + 0xc]
jge 0x30013236
add eax, ecx
mov dword [edi + 0x24], eax
mov eax, dword [ecx + 0x3c]
add eax, ecx
mov dword [edi + 0x28], eax
mov eax, dword [ecx + 0x3c]
cmp eax, 0x40
jb 0x3001322c
add eax, 0xffffffc0
mov dword [edi + 0x20], eax
lea eax, [ecx + 0x40]
mov dword [edi + 0x1c], eax
jmp 0x30013236
mov dword [ecx + 0x3c], 0x40
mov esi, dword [edi + 0x18]
cmp dword [esi + 0x3c], 0
lea eax, [esi + 0x3c]
mov edx, 0x14c
mov dword [ebp + 8], 0x8664
jne 0x3001328c
lea ebx, [edi + 0x3dc]
xor edx, edx
cmp eax, ebx
jae 0x3001327b
mov esi, 0x14c
lea esp, [esp]
movzx ecx, word [eax]
cmp cx, si
je 0x3001326e
cmp cx, word [ebp + 8]
jne 0x30013271
lea edx, [eax - 4]
add eax, 4
cmp eax, ebx
jb 0x30013260
mov esi, dword [edi + 0x18]
test edx, edx
je 0x30013287
sub edx, esi
mov dword [esi + 0x3c], edx
mov esi, dword [edi + 0x18]
mov edx, 0x14c
cmp dword [esi + 0x3c], 0
mov ecx, esi
jne 0x3001333b
lea eax, [esi + 0x3c4]
xor ebx, ebx
cmp esi, eax
jae 0x3001333b
movzx eax, word [esi]
cmp ax, dx
je 0x300132b6
cmp ax, word [ebp + 8]
jne 0x300132c4
lea eax, [ecx + 4]
cmp esi, eax
jb 0x300132c4
test ebx, ebx
jne 0x300132c4
lea ebx, [esi - 4]
add esi, 4
test ebx, ebx
je 0x3001332a
cmp ebx, ecx
jne 0x3001332a
push dword [edi + 0x38]
call fcn.3015f9dd
add esp, 4
push 0x400
call fcn.3015f9e2
add esp, 4
mov dword [edi + 0x38], eax
push 0x400
push 0
push eax
call fcn.30162560
mov eax, dword [edi + 0x38]
add esp, 0xc
mov ecx, dword [edi + 0x14]
add eax, 0x40
mov edx, 0x3c0
push eax
call fcn.30015340
add esp, 4
mov edx, 0x14c
test al, al
je 0x3001332a
mov eax, dword [edi + 0x38]
mov dword [edi + 0x18], eax
lea ebx, [eax + 0x40]
mov dword [eax + 0x3c], 0x40
mov ecx, dword [edi + 0x18]
lea eax, [ecx + 0x3c4]
cmp esi, eax
jb 0x300132a8
mov eax, dword [ecx + 0x3c]
mov esi, ecx
test eax, eax
je 0x3001337c
mov edx, 0x5a4d
cmp word [ecx], dx
je 0x3001337c
lea edx, [eax + ecx]
mov esi, 0x10b
movzx eax, word [edx + 0x18]
cmp ax, si
je 0x3001336b
mov ebx, 0x20b
mov esi, ecx
cmp ax, bx
jne 0x3001337c
mov eax, 0x5a4d
mov word [ecx], ax
mov dword [edx], 0x4550
mov esi, dword [edi + 0x18]
mov eax, dword [esi + 0x3c]
test eax, eax
je 0x300133c6
lea edx, [eax + esi]
mov dword [edi + 0x24], edx
mov eax, dword [esi + 0x3c]
add eax, esi
mov dword [edi + 0x28], eax
movzx eax, word [edx + 6]
lea ecx, [eax + eax*4]
movzx eax, word [edx + 0x14]
lea ecx, [eax + ecx*8]
mov eax, dword [esi + 0x3c]
add eax, 0x18
add eax, ecx
cmp eax, 0x400
jae 0x300133c6
mov edx, 0x400
lea ecx, [esi + eax]
sub edx, eax
mov dword [edi + 0x4c], ecx
mov dword [edi + 0x48], edx
call fcn.30003a30
mov dword [edi + 0x48], eax
pop edi
pop esi
pop ebx
pop ecx
pop ebp
ret 8
Function at 0x30013cd0
Capabilities:
Clear file content
Delete file
Move file

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push ebx
push esi
push edi
mov edi, ecx
mov byte [ebp - 1], 1
mov eax, 0x4ec4ec4f
mov edx, dword [edi + 4]
mov esi, dword [edi]
sub edx, esi
mov ebx, dword [edi + 0x24]
imul edx
movzx ecx, word [ebx + 6]
sar edx, 4
mov eax, edx
shr eax, 0x1f
add eax, edx
cmp ecx, eax
jne 0x30013e86
imul eax, ecx, 0x34
mov eax, dword [eax + esi - 0x20]
cmp eax, dword [ebx + 0x3c]
jae 0x30013d2c
push eax
push ecx
push str.PE_Parser:_Error___image_seems_incomplete:___d_sections__PointerToRawData:_0x_x____dump_failed._n
call fcn.30009b40
add esp, 0xc
xor al, al
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
mov ecx, str.CAPE
call fcn.30003280
mov esi, eax
push str.CapeOutput.bin
push esi
call dword [sym.imp.SHLWAPI.dll_PathAppendA]
push 0
push 0x80
push 2
push 0
push 3
push 0xc0000000
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [edi + 0x3c], eax
cmp eax, 0xffffffff
je 0x30013e86
mov ecx, dword [edi + 0x24]
push dword [edi + 0x14]
movzx ecx, word [ecx + 6]
imul edx, ecx, 0x34
mov ecx, dword [edi]
mov esi, dword [edx + ecx - 0x24]
add esi, dword [edx + ecx - 0x20]
xor edx, edx
push esi
mov ecx, eax
call fcn.30015560
add esp, 8
mov bl, al
neg bl
sbb bl, bl
push dword [edi + 0x3c]
and bl, byte [ebp - 1]
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
mov eax, dword [edi + 0x3c]
mov dword [edi + 0xc], esi
cmp eax, 0xffffffff
je 0x30013db8
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [edi + 0x3c], 0xffffffff
mov ecx, str.CAPE
call fcn.30003280
mov esi, eax
push str.CapeOutput.bin
push esi
call dword [sym.imp.SHLWAPI.dll_PathAppendA]
mov edi, dword [sym.imp.KERNEL32.dll_GetFullPathNameA]
push 0
push 0x30239778
push 0x104
push esi
call edi
test eax, eax
je 0x30013e79
call fcn.300033c0
mov esi, eax
push esi
push 0x30239778
call dword [sym.imp.KERNEL32.dll_MoveFileA]
test eax, eax
je 0x30013e40
push 0x104
push 0
push 0x30239778
call fcn.30162560
add esp, 0xc
push 0
push 0x30239778
push 0x104
push esi
call edi
test eax, eax
je 0x30013e79
mov ecx, 0x30239778
call fcn.30009c60
mov al, bl
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
push str.saveCompletePeToDisk:_There_was_a_problem_renaming_the_file
call fcn.30009b60
add esp, 4
push 0x30239778
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
test eax, eax
jne 0x30013e86
push 0x30239778
push str.saveCompletePeToDisk:_There_was_a_problem_deleting_the_file:__s
call fcn.30009b60
add esp, 8
xor al, al
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
push str.saveCompletePeToDisk:_There_was_a_problem_obtaining_the_full_file_path
call fcn.30009b60
add esp, 4
pop edi
pop esi
xor al, al
pop ebx
mov esp, ebp
pop ebp
ret 4
Function at 0x30014490
Capabilities:
Enumerate pe sections

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
push ebx
push esi
mov esi, ecx
push edi
mov ecx, dword [esi + 0x18]
test ecx, ecx
je 0x300144c5
call fcn.30003fc0
cmp eax, 1
jne 0x300144c5
mov ecx, dword [esi + 0x24]
mov edx, 0x10b
movzx eax, word [ecx + 0x18]
cmp ax, dx
jne 0x300144c8
mov edx, dword [ecx + 0x38]
mov eax, dword [ecx + 0x3c]
jmp 0x300144d1
mov ecx, dword [esi + 0x24]
mov eax, dword [esi + 0x28]
mov edx, dword [eax + 0x38]
mov eax, dword [eax + 0x3c]
mov edi, dword [esi + 4]
sub edi, dword [esi]
mov dword [ebp - 4], eax
movzx eax, word [ecx + 6]
mov ecx, dword [esi]
mov dword [ebp - 0x18], eax
mov eax, 0x4ec4ec4f
mov dword [ebp - 8], edx
imul edi
push 0x30014470
sar edx, 4
mov eax, edx
shr eax, 0x1f
add eax, edx
mov edx, dword [esi + 4]
push eax
call fcn.30014b70
mov eax, dword [esi + 0x24]
add esp, 8
mov edx, dword [ebp - 0x18]
mov dword [ebp - 0x14], 0
movzx ecx, word [eax + 0x14]
lea eax, [edx + edx*4]
lea ecx, [ecx + eax*8]
mov eax, dword [esi + 0x18]
mov eax, dword [eax + 0x3c]
add eax, 0x98
add eax, ecx
mov dword [ebp - 0x10], eax
test edx, edx
je 0x300145a7
mov ecx, dword [esi]
xor eax, eax
mov dword [ebp - 0xc], ecx
lea esp, [esp]
imul ebx, eax, 0x34
xor edx, edx
mov ecx, dword [ebx + ecx + 0xc]
dec ecx
add ecx, dword [ebp - 8]
mov eax, ecx
div dword [ebp - 8]
mov eax, dword [ebp - 0xc]
sub ecx, edx
xor edx, edx
mov dword [ebx + eax + 0xc], ecx
mov ecx, dword [ebp - 0x10]
dec ecx
add ecx, dword [ebp - 4]
mov eax, ecx
div dword [ebp - 4]
mov eax, dword [esi]
sub ecx, edx
xor edx, edx
mov dword [ebx + eax + 0x14], ecx
mov edi, dword [esi]
mov ecx, dword [ebp - 4]
dec ecx
add ecx, dword [edi + ebx + 0x2c]
mov eax, ecx
div dword [ebp - 4]
sub ecx, edx
mov dword [edi + ebx + 0x10], ecx
mov ecx, dword [esi]
mov dword [ebp - 0xc], ecx
mov eax, dword [ebx + ecx + 0x14]
add eax, dword [ebx + ecx + 0x10]
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x14]
inc eax
mov dword [ebp - 0x14], eax
movzx eax, ax
cmp eax, dword [ebp - 0x18]
jb 0x30014540
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x300146a0
Capabilities:
Get file size
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
push ebx
push esi
mov esi, ecx
mov byte [ebp - 1], 0
push edi
cmp dword [esi + 0x10], 0
je 0x3001480e
mov ecx, dword [esi + 0x18]
test ecx, ecx
je 0x3001480e
call fcn.30003fc0
cmp eax, 1
jne 0x3001480e
xor edi, edi
push edi
push edi
push 3
push edi
push eax
push closesocket
push dword [esi + 0x10]
mov dword [ebp - 0x1c], edi
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x3001473f
xor eax, eax
mov dword [ebp - 0x10], eax
mov dword [ebp - 0xc], eax
test ebx, ebx
je 0x3001472f
lea eax, [ebp - 0x10]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
jne 0x3001471b
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x1c], edi
call ebx
jmp 0x30014745
mov eax, dword [ebp - 0xc]
mov edi, dword [ebp - 0x10]
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x1c], eax
call ebx
jmp 0x30014745
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_CloseHandle]
xor edi, edi
mov dword [ebp - 0x1c], eax
call ebx
jmp 0x30014745
mov ebx, dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, esi
call fcn.30013440
cmp edi, eax
jbe 0x3001480e
mov edi, dword [esi + 0x3c]
cmp edi, 0xffffffff
jne 0x30014787
mov eax, dword [esi + 0x10]
test eax, eax
je 0x300147fd
push 0
push 0
push 3
push 0
push 1
push closesocket
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
mov dword [esi + 0x3c], edi
cmp edi, 0xffffffff
je 0x30014804
mov ecx, esi
call fcn.30013440
mov dword [ebp - 0xc], eax
xor eax, eax
mov dword [ebp - 0x20], eax
mov dword [ebp - 0x1c], eax
test edi, edi
je 0x300147b1
lea eax, [ebp - 0x20]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
je 0x300147b1
mov ecx, dword [ebp - 0x20]
jmp 0x300147b3
xor ecx, ecx
mov edi, dword [ebp - 0xc]
sub ecx, edi
push ecx
mov dword [esi + 0x30], ecx
call fcn.3015f9e2
add esp, 4
mov dword [esi + 0x2c], eax
push 0
push 0
push edi
push dword [esi + 0x3c]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 0
lea eax, [ebp - 0x14]
push eax
push dword [esi + 0x30]
push dword [esi + 0x2c]
push dword [esi + 0x3c]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x300147f2
mov byte [ebp - 1], 1
mov ecx, dword [esi + 0x3c]
cmp ecx, 0xffffffff
je 0x30014804
push ecx
call ebx
mov dword [esi + 0x3c], 0xffffffff
mov al, byte [ebp - 1]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
pop edi
pop esi
xor al, al
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x3001d1e0
Capabilities:
64-bit execution via heavens gate

Disassembly:
push ebp
mov ebp, esp
mov ecx, dword [ebp + 0x10]
lea edx, [ebp + 0x14]
sub esp, 0x40
push ebx
push esi
push edi
test ecx, ecx
jle 0x3001d208
mov eax, dword [ebp + 0x14]
lea edx, [ebp + 0x1c]
dec ecx
mov dword [ebp - 0x10], eax
mov eax, dword [ebp + 0x18]
mov dword [ebp + 0x10], ecx
mov dword [ebp - 0xc], eax
jmp 0x3001d216
mov dword [ebp - 0x10], 0
mov dword [ebp - 0xc], 0
test ecx, ecx
jle 0x3001d22f
dec ecx
add edx, 8
mov dword [ebp + 0x10], ecx
mov eax, dword [edx - 8]
mov dword [ebp - 0x18], eax
mov eax, dword [edx - 4]
mov dword [ebp - 0x14], eax
jmp 0x3001d23d
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x14], 0
test ecx, ecx
jle 0x3001d256
dec ecx
add edx, 8
mov dword [ebp + 0x10], ecx
mov eax, dword [edx - 8]
mov dword [ebp - 0x20], eax
mov eax, dword [edx - 4]
mov dword [ebp - 0x1c], eax
jmp 0x3001d264
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x1c], 0
test ecx, ecx
jle 0x3001d27d
dec ecx
add edx, 8
mov dword [ebp + 0x10], ecx
mov eax, dword [edx - 8]
mov dword [ebp - 0x28], eax
mov eax, dword [edx - 4]
mov dword [ebp - 0x24], eax
jmp 0x3001d28b
mov dword [ebp - 0x28], 0
mov dword [ebp - 0x24], 0
mov eax, edx
mov dword [ebp - 0x30], 0
cdq
mov dword [ebp - 0x40], eax
mov eax, ecx
mov dword [ebp - 0x3c], edx
cdq
mov dword [ebp - 0x2c], 0
mov dword [ebp - 0x38], eax
mov dword [ebp - 0x34], edx
mov dword [ebp - 4], 0
mov dword [ebp - 8], 0
mov word [ebp - 8], fs
mov eax, 0x2b
mov fs, ax
mov dword [ebp - 4], esp
and esp, 0xfffffff0
push 0x33
call fcn.3001d2d2

Function at 0x3001d360
Capabilities:
64-bit execution via heavens gate

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push esi
push edi
mov dword [ebp - 4], ecx
push 0x33
call 0x3001d371
add dword [esp], 5
retf
Function at 0x30046a10
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x6c
mov eax, dword [0x3021be88]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
mov dword [ebp - 0x6c], eax
push ebx
mov ebx, edx
test ecx, ecx
je 0x30046c13
test ebx, ebx
je 0x30046c13
test eax, eax
je 0x30046c13
push esi
mov esi, dword [ecx + 0x10]
test esi, esi
je 0x30046c12
cmp dword [esi + 4], 0x73736c35
jne 0x30046c12
push edi
push 0x60
lea eax, [ebp - 0x67]
push 0
push eax
call fcn.30162560
add esp, 0xc
lea edx, [ebp - 0x68]
add esi, 0x1c
mov edi, 0x30
movzx ecx, byte [esi]
lea esi, [esi + 1]
mov eax, ecx
and ecx, 0xf
shr eax, 4
movzx eax, byte [eax + 0x301ef260]
mov byte [edx], al
movzx eax, byte [ecx + 0x301ef260]
mov byte [edx + 1], al
add edx, 2
sub edi, 1
jne 0x30046a76
mov byte [edx], 0
lea ecx, [ebp - 0x68]
mov eax, 0x301f71e6
lea ebx, [ebx]
mov dl, byte [eax]
cmp dl, byte [ecx]
jne 0x30046ad0
test dl, dl
je 0x30046acc
mov dl, byte [eax + 1]
cmp dl, byte [ecx + 1]
jne 0x30046ad0
add eax, 2
add ecx, 2
test dl, dl
jne 0x30046ab0
xor eax, eax
jmp 0x30046ad5
sbb eax, eax
or eax, 1
test eax, eax
je 0x30046c11
mov ecx, ebx
mov eax, 0x301f71e6
mov dl, byte [eax]
cmp dl, byte [ecx]
jne 0x30046b04
test dl, dl
je 0x30046b00
mov dl, byte [eax + 1]
cmp dl, byte [ecx + 1]
jne 0x30046b04
add eax, 2
add ecx, 2
test dl, dl
jne 0x30046ae4
xor eax, eax
jmp 0x30046b09
sbb eax, eax
or eax, 1
test eax, eax
je 0x30046c11
mov edi, dword [ebp - 0x6c]
mov eax, 0x301f71e6
mov ecx, edi
jmp 0x30046b20
mov dl, byte [eax]
cmp dl, byte [ecx]
jne 0x30046b40
test dl, dl
je 0x30046b3c
mov dl, byte [eax + 1]
cmp dl, byte [ecx + 1]
jne 0x30046b40
add eax, 2
add ecx, 2
test dl, dl
jne 0x30046b20
xor eax, eax
jmp 0x30046b45
sbb eax, eax
or eax, 1
test eax, eax
je 0x30046c11
mov ecx, str.tlsdump
mov dword [ebp - 0x6c], 0
call fcn.30003280
mov esi, eax
push str.tlsdump.log
push esi
call dword [sym.imp.SHLWAPI.dll_PathAppendA]
cmp dword [0x30246350], 0
jne 0x30046b8d
push esi
push str.TLS_1.2_secrets_logged_to:__s
mov dword [0x30246350], 1
call fcn.30009b40
add esp, 8
mov eax, dword [0x3026e7a0]
test eax, eax
jne 0x30046bb2
push eax
push 0x80
push 4
push eax
push 1
push 0x40000000
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [0x3026e7a0], eax
cmp eax, 0xffffffff
je 0x30046c11
push 0x1000
push 0
push 0x3026d7a0
call fcn.30162560
lea eax, [ebp - 0x68]
push eax
push edi
push ebx
push str.client_random:__s__server_random:__s__master_secret:__s_n
push 0xffffffffffffffff
push 0x1000
push 0x3026d7a0
call fcn.30009a50
mov ecx, 0x3026d7a0
add esp, 0x28
lea edx, [ecx + 1]
nop
mov al, byte [ecx]
inc ecx
test al, al
jne 0x30046bf0
push 0
lea eax, [ebp - 0x6c]
sub ecx, edx
push eax
push ecx
push 0x3026d7a0
push dword [0x3026e7a0]
call dword [sym.imp.KERNEL32.dll_WriteFile]
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.3015f3bd
mov esp, ebp
pop ebp
ret
Function at 0x30047fc0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push 0x3026d760
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
cmp dword [0x302465d0], 0
jle 0x300480a4
push esi
mov esi, dword [sym.imp.KERNEL32.dll_WriteFile]
jmp 0x30047ff0
cmp dword [0x302465f0], 0xfffffffe
mov dword [ebp - 4], 0xffffffff
jne 0x3004802d
cmp dword [0x302465c8], 0xffffffff
je 0x30048023
push 0
lea eax, [ebp - 4]
push eax
mov eax, dword [0x302465d0]
push eax
push dword [0x302465d4]
push dword [0x302465c8]
jmp 0x3004805a
mov eax, dword [0x302465d0]
mov dword [ebp - 4], eax
jmp 0x3004805f
cmp dword [0x3026d730], 0xffffffff
jne 0x30048042
mov dword [0x302465d0], 0
jmp 0x30048096
push 0
lea eax, [ebp - 4]
push eax
mov eax, dword [0x302465d0]
push eax
push dword [0x302465d4]
push dword [0x3026d730]
call esi
mov eax, dword [ebp - 4]
test eax, eax
js 0x30048096
cmp eax, dword [0x302465d0]
jge 0x30048089
mov eax, dword [0x302465d0]
mov edx, dword [ebp - 4]
sub eax, edx
mov ecx, dword [0x302465d4]
push eax
lea eax, [ecx + edx]
push eax
push ecx
call fcn.30161f30
add esp, 0xc
mov eax, dword [0x302465d0]
sub eax, dword [ebp - 4]
mov dword [0x302465d0], eax
cmp dword [0x302465d0], 0
jg 0x30047ff0
pop esi
push 0x3026d760
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov esp, ebp
pop ebp
ret

Function at 0x30048160
Capabilities:
Write file on windows

Disassembly:
push 0x3026d740
call dword [sym.imp.KERNEL32.dll_TryEnterCriticalSection]
test eax, eax
je 0x300481b1
mov ecx, dword [0x302465d8]
test ecx, ecx
je 0x30048199
mov edx, dword [0x302465dc]
call fcn.300480c0
mov ecx, dword [0x302465d8]
call fcn.300011f0
mov dword [0x302465d8], 0
push 0x3026d740
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
cmp dword [0x302465d4], 0
jne fcn.30047fc0
ret
Function at 0x3004ca70
Capabilities:
Access peb ldr_data

Disassembly:
mov eax, dword fs:[0x30]
mov edx, dword [eax + 0xc]
mov eax, dword [edx + 0xc]
add edx, 0xc
cmp eax, edx
je 0x3004ca8e
cmp dword [eax + 0x18], ecx
je 0x3004ca91
mov eax, dword [eax]
cmp eax, edx
jne 0x3004ca83
xor eax, eax
ret
add eax, 0x2c
ret

Function at 0x3004caa0
Capabilities:
Access peb ldr_data

Disassembly:
push esi
mov esi, dword fs:[0x30]
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov ecx, dword [esi + 0xa0]
xor edx, edx
pop esi
cmp eax, dword [ecx + 0xc]
sete dl
mov eax, edx
ret
Function at 0x3004e900
Capabilities:
Enumerate pe sections

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
mov eax, ecx
mov dword [ebp - 4], edx
push ebx
push esi
mov dword [ebp - 0x10], eax
mov esi, dword [eax + 0x3c]
add esi, eax
push edi
xor edi, edi
movzx eax, word [esi + 0x14]
lea ecx, [esi + 0x18]
add ecx, eax
movzx eax, word [esi + 6]
mov dword [ebp - 0xc], ecx
mov dword [ebp - 8], eax
test eax, eax
je 0x3004e99f
mov ebx, ecx
mov eax, edx
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x3004e936
mov esi, dword [ebp - 4]
sub eax, edx
mov edx, ebx
sub eax, 4
jb 0x3004e961
lea esp, [esp]
mov ecx, dword [edx]
cmp ecx, dword [esi]
jne 0x3004e966
add edx, 4
add esi, 4
sub eax, 4
jae 0x3004e950
cmp eax, 0xfffffffc
je 0x3004e9a8
mov cl, byte [edx]
cmp cl, byte [esi]
jne 0x3004e993
cmp eax, 0xfffffffd
je 0x3004e9a8
mov cl, byte [edx + 1]
cmp cl, byte [esi + 1]
jne 0x3004e993
cmp eax, 0xfffffffe
je 0x3004e9a8
mov cl, byte [edx + 2]
cmp cl, byte [esi + 2]
jne 0x3004e993
cmp eax, 0xffffffff
je 0x3004e9a8
mov al, byte [edx + 3]
cmp al, byte [esi + 3]
je 0x3004e9a8
mov edx, dword [ebp - 4]
inc edi
add ebx, 0x28
cmp edi, dword [ebp - 8]
jb 0x3004e931
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 0xc]
lea eax, [edi + edi*4]
mov edx, dword [ebp - 0x10]
lea ecx, [ecx + eax*8]
mov eax, dword [ebp + 8]
add edx, dword [ecx + 0xc]
mov ecx, dword [ecx + 8]
pop edi
mov dword [eax], edx
add ecx, edx
mov eax, dword [ebp + 0xc]
pop esi
pop ebx
mov dword [eax], ecx
mov eax, 1
mov esp, ebp
pop ebp
ret
Function at 0x3004f7c0
Capabilities:
Connect pipe
Read pipe
Write pipe

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
mov edx, dword [ebp + 0x10]
lea eax, [ebp + 0x14]
push eax
xor ecx, ecx
call fcn.3004f0d0
mov ecx, eax
add esp, 4
mov dword [ebp - 8], ecx
test ecx, ecx
jle 0x3004f8bd
push ebx
push esi
push edi
pushfd
mov eax, dword fs:[0x18]
pop ebx
test eax, eax
jne 0x3004f7fb
or esi, 0xffffffff
or edi, 0xffffffff
jmp 0x3004f804
mov esi, dword [eax + 0x34]
mov edi, dword [eax + 0xbf4]
lea eax, [ecx + 1]
push eax
push 8
push dword [0x30272510]
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ecx, eax
mov eax, dword fs:[0x18]
mov dword [ebp - 4], ecx
test eax, eax
je 0x3004f834
mov dword [eax + 0x34], esi
mov dword [eax + 0xbf4], edi
test ebx, ebx
je 0x3004f834
push ebx
popfd
mov edx, dword [ebp + 0x10]
lea eax, [ebp + 0x14]
push eax
call fcn.3004f0d0
mov eax, dword [ebp + 0xc]
add esp, 4
push 0xffffffffffffffff
push eax
push dword [eax]
push dword [ebp + 8]
push dword [ebp - 8]
push dword [ebp - 4]
push 0x3026e840
call dword [sym.imp.KERNEL32.dll_CallNamedPipeW]
mov esi, eax
neg esi
sbb esi, esi
not esi
pushfd
mov ebx, dword fs:[0x18]
pop dword [ebp - 8]
test ebx, ebx
jne 0x3004f87e
or edi, 0xffffffff
or ebx, 0xffffffff
jmp 0x3004f887
mov edi, dword [ebx + 0x34]
mov ebx, dword [ebx + 0xbf4]
push dword [ebp - 4]
push 0
push dword [0x30272510]
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov eax, dword fs:[0x18]
test eax, eax
je 0x3004f8b4
mov dword [eax + 0x34], edi
mov dword [eax + 0xbf4], ebx
mov eax, dword [ebp - 8]
test eax, eax
je 0x3004f8b4
push eax
popfd
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
or eax, 0xffffffff
mov esp, ebp
pop ebp
ret
Function at 0x30054d00
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push edi
mov edi, dword [ebp + 8]
mov ebx, edx
mov dword [ebp - 4], ecx
test edi, edi
jne 0x30054d1a
pop edi
mov eax, ecx
pop ebx
mov esp, ebp
pop ebp
ret
add edi, 0xffffffff
je 0x30054d4f
push esi
movzx eax, byte [ebx]
mov esi, edi
and esi, 0x1f
inc ebx
mov ecx, esi
neg ecx
mov edx, dword [eax*4 + 0x301ef2b0]
and ecx, 0x1f
mov eax, edx
shr eax, cl
mov ecx, esi
shl edx, cl
mov ecx, dword [ebp - 4]
or eax, edx
xor ecx, eax
mov dword [ebp - 4], ecx
sub edi, 1
jne 0x30054d20
pop esi
movzx eax, byte [ebx]
pop edi
pop ebx
mov eax, dword [eax*4 + 0x301ef2b0]
xor eax, ecx
mov esp, ebp
pop ebp
ret