joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4f0270
Capabilities:
Parse pe header

Disassembly:
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
je 0x4f02af
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x4f02af
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x4f02af
mov eax, 0x10b
cmp word [ecx + 0x18], ax
jne 0x4f02af
cmp dword [ecx + 0x74], 0xe
jbe 0x4f02af
cmp dword [ecx + 0xe8], 0
setne al
ret
xor al, al
ret

Function at 0x4fcfce
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
mov edx, dword [ebp + 8]
mov ecx, edx
push ebx
mov ebx, dword [ebp + 0xc]
mov eax, edx
sar ecx, 6
and eax, 0x3f
push esi
push edi
imul edi, eax, 0x38
mov eax, dword [ecx*4 + 0x982bd0]
mov dword [ebp - 0x18], ecx
mov ecx, dword [edi + eax + 0x18]
mov dword [ebp - 0x14], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x4fd010
cmp byte [ebx], 0xa
jne 0x4fd010
or byte [edi + eax + 0x28], 4
jmp 0x4fd015
and byte [edi + eax + 0x28], 0xfb
add ecx, ebx
mov eax, ebx
mov dword [ebp - 0x10], ecx
mov esi, ebx
cmp ebx, ecx
jae 0x4fd118
mov cl, byte [eax]
cmp cl, 0x1a
je 0x4fd0f3
lea ebx, [eax + 1]
mov dword [ebp - 8], ebx
mov ebx, dword [ebp + 0xc]
cmp cl, 0xd
je 0x4fd044
mov eax, dword [ebp - 8]
jmp 0x4fd064
mov edx, dword [ebp - 0x10]
cmp dword [ebp - 8], edx
mov edx, dword [ebp + 8]
jae 0x4fd080
mov ebx, dword [ebp - 8]
cmp byte [ebx], 0xa
jne 0x4fd05e
add eax, 2
mov cl, 0xa
jmp 0x4fd061
mov eax, dword [ebp - 8]
mov ebx, dword [ebp + 0xc]
mov byte [esi], cl
mov dword [ebp - 0xc], 1
mov dword [ebp - 8], esi
mov esi, dword [ebp - 0xc]
add esi, dword [ebp - 8]
cmp eax, dword [ebp - 0x10]
jb 0x4fd026
jmp 0x4fd118
push 0
lea eax, [ebp - 0x10]
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 0x4fd0ee
cmp dword [ebp - 0x10], 0
je 0x4fd0ee
mov edx, dword [ebp - 0x18]
mov eax, dword [edx*4 + 0x982bd0]
test byte [eax + edi + 0x28], 0x48
je 0x4fd0cd
mov cl, byte [ebp - 1]
cmp cl, 0xa
jne 0x4fd0bd
mov byte [esi], 0xa
jmp 0x4fd117
mov byte [esi], 0xd
mov eax, dword [edx*4 + 0x982bd0]
mov byte [eax + edi + 0x2a], cl
jmp 0x4fd117
cmp byte [ebp - 1], 0xa
jne 0x4fd0d7
cmp esi, ebx
je 0x4fd0b8
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.00507c1b
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x4fd118
mov byte [esi], 0xd
jmp 0x4fd117
mov eax, edx
and edx, 0x3f
sar eax, 6
imul edx, edx, 0x38
mov edi, dword [eax*4 + 0x982bd0]
mov al, byte [edi + edx + 0x28]
test al, 0x40
jne 0x4fd115
or al, 2
mov byte [edi + edx + 0x28], al
jmp 0x4fd118
mov byte [esi], cl
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x4fd121
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword [ebp + 8]
mov edx, dword [ebp + 8]
and eax, 0x3f
push ebx
mov ebx, dword [ebp + 0xc]
sar edx, 6
push esi
push edi
imul edi, eax, 0x38
mov eax, dword [edx*4 + 0x982bd0]
mov dword [ebp - 8], edx
mov edx, dword [eax + edi + 0x18]
mov dword [ebp - 0x18], edx
mov edx, dword [ebp + 0x10]
test edx, edx
je 0x4fd165
push 0xa
pop esi
cmp word [ebx], si
jne 0x4fd165
or byte [eax + edi + 0x28], 4
jmp 0x4fd16a
and byte [eax + edi + 0x28], 0xfb
lea edx, [ebx + edx*2]
mov eax, ebx
mov dword [ebp - 0x10], edx
mov esi, ebx
cmp ebx, edx
jae 0x4fd2d5
movzx edx, word [eax]
mov ecx, edx
mov dword [ebp - 0xc], ecx
movzx ecx, cx
mov dword [ebp - 0x14], ecx
mov ecx, dword [ebp + 8]
cmp edx, 0x1a
je 0x4fd2ad
lea ebx, [eax + 2]
mov dword [ebp - 4], ebx
push 0xd
pop ebx
cmp dx, bx
mov ebx, dword [ebp + 0xc]
je 0x4fd1b7
mov ebx, dword [ebp - 0x14]
mov edx, esi
mov eax, dword [ebp - 4]
movzx ebx, bx
mov dword [ebp - 4], ebx
jmp 0x4fd1e1
mov edx, dword [ebp - 4]
cmp edx, dword [ebp - 0x10]
jae 0x4fd200
push 0xa
pop ebx
cmp word [edx], bx
jne 0x4fd1ce
push ebx
add eax, 4
pop edx
jmp 0x4fd1d6
mov eax, edx
mov edx, dword [ebp - 0xc]
movzx edx, dx
movzx edx, dx
mov dword [ebp - 4], edx
mov edx, esi
mov dword [ebp - 0x14], esi
mov ecx, dword [ebp - 4]
mov ebx, dword [ebp + 0xc]
mov dword [ebp - 0xc], 2
mov word [esi], cx
mov esi, dword [ebp - 0xc]
add esi, edx
cmp eax, dword [ebp - 0x10]
jb 0x4fd17c
jmp 0x4fd2d5
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 0x4fd2a8
cmp dword [ebp - 0x14], 0
je 0x4fd2a8
mov eax, dword [ebp - 8]
push 0xa
mov eax, dword [eax*4 + 0x982bd0]
test byte [eax + edi + 0x28], 0x48
pop eax
je 0x4fd284
mov dx, word [ebp - 4]
cmp dx, ax
jne 0x4fd24c
mov word [esi], ax
jmp 0x4fd2d2
push 0xd
pop eax
mov word [esi], ax
mov eax, dword [ebp - 8]
movzx ecx, dx
shr ecx, 8
push 0xa
mov eax, dword [eax*4 + 0x982bd0]
mov byte [eax + edi + 0x2a], dl
mov edx, dword [ebp - 8]
mov eax, dword [edx*4 + 0x982bd0]
mov byte [eax + edi + 0x2b], cl
mov eax, dword [edx*4 + 0x982bd0]
pop ecx
mov byte [eax + edi + 0x2c], cl
jmp 0x4fd2d2
cmp word [ebp - 4], ax
jne 0x4fd28e
cmp esi, ebx
je 0x4fd244
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.00507c1b
add esp, 0x10
push 0xa
pop eax
cmp word [ebp - 4], ax
je 0x4fd2d5
push 0xd
pop eax
jmp 0x4fd244
mov eax, ecx
and ecx, 0x3f
sar eax, 6
imul ecx, ecx, 0x38
mov edi, dword [eax*4 + 0x982bd0]
mov al, byte [edi + ecx + 0x28]
test al, 0x40
jne 0x4fd2cf
or al, 2
mov byte [edi + ecx + 0x28], al
jmp 0x4fd2d5
mov word [esi], dx
add esi, 2
sub esi, ebx
and esi, 0xfffffffe
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x4fee3d
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x1020
call fcn.004efba0
mov eax, dword [0x97efc0]
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.00503356
pop ecx
mov ecx, dword [ebp + 8]
mov ebx, eax
cmp dword [ecx + 8], 0
jne 0x4fee7f
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
jmp 0x4feff6
mov eax, dword [ecx]
sub eax, dword [ecx + 4]
push esi
push edi
push 0
cdq
push 2
push edx
push eax
call fcn.004ef6e0
push dword [ebp - 0x100c]
mov ecx, ebx
mov dword [ebp - 0x1008], eax
mov esi, ebx
mov dword [ebp - 0x1014], edx
and ecx, 0x3f
sar esi, 6
imul edi, ecx, 0x38
push 0
mov eax, dword [esi*4 + 0x982bd0]
push dword [edi + eax + 0x24]
push dword [edi + eax + 0x20]
push ebx
call fcn.00507bfd
mov ecx, dword [esi*4 + 0x982bd0]
add esp, 0x14
mov dword [ebp - 0x1010], eax
mov eax, edx
mov edx, dword [ebp - 0x1010]
mov dword [ebp - 0x1020], eax
cmp edx, dword [edi + ecx + 0x20]
jne 0x4fefef
cmp eax, dword [edi + ecx + 0x24]
jne 0x4fefef
xor esi, esi
lea eax, [ebp - 0x101c]
push esi
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 0x4fefef
push dword [ebp - 0x100c]
push esi
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.00507bfd
add esp, 0x14
cmp edx, esi
jl 0x4fefef
jg 0x4fef4a
cmp eax, esi
jb 0x4fefef
mov ebx, dword [ebp - 0x1014]
mov eax, dword [ebp - 0x101c]
cmp ebx, esi
jg 0x4fefef
jl 0x4fef6c
cmp dword [ebp - 0x1008], eax
ja 0x4fefef
lea edi, [ebp - 0x1004]
xorps xmm0, xmm0
add edi, eax
movlpd qword [ebp - 0x1018], xmm0
lea ecx, [ebp - 0x1004]
cmp dword [ebp - 0x1008], esi
jne 0x4fef91
cmp ebx, esi
je 0x4fefd6
mov edx, dword [ebp - 0x1014]
mov esi, dword [ebp - 0x1018]
cmp ecx, edi
jae 0x4fefd6
mov al, byte [ecx]
cmp al, 0xd
jne 0x4fefb7
lea eax, [edi - 1]
cmp ecx, eax
jae 0x4fefc3
cmp byte [ecx + 1], 0xa
jne 0x4fefc3
inc ecx
jmp 0x4fefc3
movzx eax, al
movsx eax, byte [eax + 0x97f120]
add ecx, eax
add esi, 1
adc edx, 0
inc ecx
cmp esi, dword [ebp - 0x1008]
jne 0x4fef9d
cmp edx, ebx
jne 0x4fef9d
lea eax, [ebp - 0x1004]
sub ecx, eax
mov eax, ecx
cdq
add eax, dword [ebp - 0x1010]
adc edx, dword [ebp - 0x1020]
jmp 0x4feff4
or edx, 0xffffffff
mov eax, edx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.004eec95
leave
ret
Function at 0x504243
Capabilities:
Get file size

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
sub esp, 0x18
mov eax, dword [eax + 0xc]
nop
shr eax, 3
test al, 1
je 0x50425d
mov al, 1
leave
ret
mov eax, dword [ebp + 8]
push ebx
push esi
mov eax, dword [eax + 0xc]
nop
test al, 0xc0
mov eax, dword [ebp + 8]
je 0x504274
mov ecx, dword [eax]
cmp ecx, dword [eax + 4]
je 0x5042cc
mov eax, dword [eax + 0x10]
nop
push eax
call fcn.00507955
mov esi, eax
pop ecx
cmp esi, 0xffffffff
je 0x5042cc
xor ebx, ebx
lea eax, [ebp - 0x10]
inc ebx
xorps xmm0, xmm0
push ebx
push eax
movlpd qword [ebp - 8], xmm0
push dword [ebp - 4]
push dword [ebp - 8]
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointerEx]
test eax, eax
je 0x5042cc
lea eax, [ebp - 0x18]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
je 0x5042cc
mov eax, dword [ebp - 0x10]
cmp eax, dword [ebp - 0x18]
jne 0x5042c6
mov eax, dword [ebp - 0xc]
cmp eax, dword [ebp - 0x14]
je 0x5042c8
xor bl, bl
mov al, bl
jmp 0x5042ce
xor al, al
pop esi
pop ebx
leave
ret
Function at 0x507cfd
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]
mov edi, dword [ebp + 0x14]
push dword [ebp + 0xc]
push ebx
call fcn.00507c79
mov eax, dword [ebp - 0x2c]
and eax, dword [ebp - 0x28]
cmp eax, 0xffffffff
je 0x507e6c
mov eax, dword [ebp - 0x24]
and eax, dword [ebp - 0x20]
cmp eax, 0xffffffff
je 0x507e6c
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 8], ecx
mov dword [ebp - 4], eax
test ecx, ecx
jl 0x507e21
jg 0x507d59
test eax, eax
je 0x507e17
push 1
push 0x1000
call fcn.00502af0
mov esi, eax
pop ecx
pop ecx
test esi, esi
jne 0x507d7c
push 0xc
pop ebx
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], ebx
jmp 0x507e0e
push 0x8000
push ebx
call fcn.00500e6a
pop ecx
pop ecx
mov ecx, dword [ebp - 0x1c]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0x18]
test eax, eax
jl 0x507da5
jg 0x507da0
cmp ecx, 0x1000
jb 0x507da5
mov ecx, 0x1000
push edi
push ecx
push esi
push ebx
call fcn.00503e5f
add esp, 0x10
cmp eax, 0xffffffff
je 0x507dea
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 0x507da0
jl 0x507dd1
test ecx, ecx
jne 0x507d92
push dword [ebp - 0xc]
push ebx
call fcn.00500e6a
push esi
call fcn.00502b50
add esp, 0xc
xor ebx, ebx
jmp 0x507e7a
cmp byte [edi + 0x24], 0
je 0x507e01
cmp dword [edi + 0x20], 5
jne 0x507e01
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], 0xd
cmp byte [edi + 0x1c], 0
je 0x507e0c
mov ebx, dword [edi + 0x18]
jmp 0x507e0e
xor ebx, ebx
push esi
call fcn.00502b50
pop ecx
jmp 0x507e7a
test ecx, ecx
jg 0x507de3
jl 0x507e21
test eax, eax
jae 0x507de3
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.00507c1b
and eax, edx
add esp, 0x10
cmp eax, 0xffffffff
jne 0x507e41
cmp byte [edi + 0x1c], 0
je 0x507de3
jmp 0x507e72
push ebx
call fcn.00507955
pop ecx
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x507de3
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 0xd
mov byte [edi + 0x24], 1
mov dword [edi + 0x20], eax
pop ebx
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], ebx
jmp 0x507e7a
cmp byte [edi + 0x1c], 0
je 0x507e77
mov ebx, dword [edi + 0x18]
jmp 0x507e7a
push 0x16
pop ebx
push 0
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
push dword [ebp - 0x14]
call fcn.00507c1b
add esp, 0x10
mov eax, ebx
pop edi
pop esi
pop ebx
leave
ret
Function at 0x5098ab
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 0x509948
push ebx
push esi
call fcn.00509874
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.0050980a
add esp, 0x24
mov dword [ebp - 4], eax
test eax, eax
jne 0x5098f5
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x509947
push edi
push eax
call fcn.00504410
mov edi, eax
pop ecx
push ebx
test edi, edi
jne 0x509915
call fcn.00502b50
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x509946
push ebx
push dword [ebp - 4]
push edi
push dword [ebp - 8]
push esi
push ebx
push ebx
call fcn.0050980a
add esp, 0x20
test eax, eax
jne 0x509934
push edi
call fcn.00502b50
jmp 0x50993c
push ebx
call fcn.00502b50
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 0x50994b
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push esi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
mov esi, eax
test esi, esi
jne 0x50995c
pop esi
ret
push ebx
push edi
push esi
call fcn.00509874
mov ebx, eax
sub ebx, esi
and ebx, 0xfffffffe
push ebx
call fcn.00504410
mov edi, eax
pop ecx
pop ecx
test edi, edi
je 0x509984
push ebx
push esi
push edi
call fcn.004f0550
add esp, 0xc
push 0
call fcn.00502b50
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov eax, edi
pop edi
pop ebx
pop esi
ret

Function at 0x50a0db
Capabilities:
Set environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.00509bf7

Function at 0x510500
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x51052d
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x51052d
mov edx, 0x10b
xor eax, eax
cmp word [ecx + 0x18], dx
sete al
pop ebp
ret
xor eax, eax
pop ebp
ret
Function at 0x401000
Capabilities:
Get hostname

Disassembly:
sub esp, 0xa8
lea eax, [esp + 0x14]
push esi
push eax
mov dword [esp + 0x1c], 0x94
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
xor ecx, ecx
lea edx, [esp + 4]
mov eax, dword [esp + 0x28]
push edx
cmp eax, 1
push 0x40bc24
sete cl
mov dword [0x40be74], ecx
mov dword [esp + 0xc], 0x29
call dword [sym.imp.KERNEL32.dll_GetComputerNameA]
mov dword [esp + 8], 0x409074
mov dword [esp + 0xc], 0x4011c0
mov esi, dword [esp + 0xb8]
mov eax, dword [esp + 0xb0]
test esi, esi
mov dword [0x40be6c], eax
mov dword [esp + 0x10], 0
mov dword [esp + 0x14], 0
je 0x4010f2
push 0x40906c
push esi
call fcn.00402c80
add esp, 8
test eax, eax
je 0x40109e
call fcn.00401260
xor eax, eax
pop esi
add esp, 0xa8
ret 0x10
push 0x409064
push esi
call fcn.00402c80
add esp, 8
test eax, eax
je 0x4010c1
call fcn.00401330
xor eax, eax
pop esi
add esp, 0xa8
ret 0x10
push 0x409060
push esi
call fcn.00402c80
add esp, 8
test eax, eax
je 0x4010f2
push esi
mov dword [0x40be54], 1
call fcn.00401460
add esp, 4
xor eax, eax
pop esi
add esp, 0xa8
ret 0x10
push 0
push 0x40904c
call fcn.00401bd0
add esp, 8
lea ecx, [esp + 8]
push ecx
call dword [sym.imp.ADVAPI32.dll_StartServiceCtrlDispatcherA]
test eax, eax
jne 0x40111e
push eax
push 0x40903c
call fcn.00401bd0
add esp, 8
xor eax, eax
pop esi
add esp, 0xa8
ret 0x10

Function at 0x401260
Capabilities:
Create service
Persist via windows service

Disassembly:
sub esp, 0x200
lea eax, [esp]
push esi
push 0x200
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x401294
push 1
push 0x4090d8
call fcn.00401bd0
add esp, 8
pop esi
add esp, 0x200
ret
push 0xf003f
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov esi, eax
test esi, esi
je 0x40130c
push edi
push 0
push 0
push 0x4090c8
push 0
lea ecx, [esp + 0x18]
push 0
push ecx
push 1
push 2
push 0x10
push 0xf01ff
push 0x4090b8
push 0x409074
push esi
call dword [sym.imp.ADVAPI32.dll_CreateServiceA]
mov edi, dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
test eax, eax
je 0x4012f1
push eax
call edi
push esi
call edi
pop edi
pop esi
add esp, 0x200
ret
push 1
push 0x4090a8
call fcn.00401bd0
add esp, 8
push esi
call edi
pop edi
pop esi
add esp, 0x200
ret
push 1
push 0x409094
call fcn.00401bd0
add esp, 8
pop esi
add esp, 0x200
ret
Function at 0x401330
Capabilities:
Delete service
Query service status
Stop service

Disassembly:
push ebp
push 0xf003f
push 0
push 0
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
mov ebp, eax
test ebp, ebp
je 0x40144c
push esi
push 0xf01ff
push 0x409074
push ebp
call dword [sym.imp.ADVAPI32.dll_OpenServiceA]
mov esi, eax
test esi, esi
je 0x401433
push 0x40bc08
push 1
push esi
call dword [sym.imp.ADVAPI32.dll_ControlService]
test eax, eax
je 0x4013e8
push ebx
push edi
push 0
push 0x40915c
call fcn.00401bd0
mov edi, dword [sym.imp.KERNEL32.dll_Sleep]
add esp, 8
push 0x3e8
call edi
mov ebx, dword [sym.imp.ADVAPI32.dll_QueryServiceStatus]
push 0x40bc08
push esi
call ebx
test eax, eax
je 0x4013c4
cmp dword [0x40bc0c], 3
jne 0x4013c4
push 0x3e8
call edi
push 0x40bc08
push esi
call ebx
test eax, eax
jne 0x4013a8
mov eax, dword [0x40bc0c]
pop edi
cmp eax, 1
pop ebx
jne 0x4013d9
push 0
push 0x409150
jmp 0x4013e0
push 1
push 0x409140
call fcn.00401bd0
add esp, 8
push esi
call dword [sym.imp.ADVAPI32.dll_DeleteService]
test eax, eax
je 0x401413
push 0
push 0x409130
call fcn.00401bd0
add esp, 8
push esi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
push ebp
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
pop esi
pop ebp
ret
push 1
push 0x409120
call fcn.00401bd0
add esp, 8
push esi
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
push ebp
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
pop esi
pop ebp
ret
push 1
push 0x409108
call fcn.00401bd0
add esp, 8
push ebp
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
pop esi
pop ebp
ret
push 1
push 0x4090e8
call fcn.00401bd0
add esp, 8
pop ebp
ret

Function at 0x4016a0
Capabilities:
Create tcp socket
Create thread
Create udp socket
Initialize winsock library

Disassembly:
sub esp, 0x228
lea eax, [esp + 0x98]
push eax
push 0x101
call sub.WS2_32.dll_WSAStartup
test eax, eax
je 0x4016cb
push 0
push 0x4091e8
call fcn.00401bd0
add esp, 8
push 0
push 1
push 2
call sub.WS2_32.dll_socket
push 0x1216
mov dword [0x40bb04], eax
mov dword [esp + 0x10], 0
mov word [esp + 0xc], 2
call sub.WS2_32.dll_htons
mov edx, dword [0x40bb04]
lea ecx, [esp + 8]
push 0x10
push ecx
push edx
mov word [esp + 0x16], ax
call sub.WS2_32.dll_bind
cmp eax, 0xffffffff
jne 0x401720
push 0
push 0x4091d8
call fcn.00401bd0
add esp, 8
lea eax, [esp]
push esi
mov esi, dword [sym.imp.KERNEL32.dll_CreateThread]
push eax
push 0
push 0
push 0x401550
push 0x1000
push 0
mov dword [esp + 0x1c], 0x64
call esi
lea ecx, [esp + 8]
mov dword [esp + 8], 0x65
push ecx
push 0
push 0
push 0x4014c0
push 0x1000
push 0
call esi
lea edx, [esp + 0x1c]
push 0x4091d0
push edx
call dword [sym.imp.USER32.dll_wsprintfA]
lea eax, [esp + 0x24]
push 0
push eax
call fcn.00401bd0
add esp, 0x10
mov eax, 1
pop esi
add esp, 0x228
ret
Function at 0x404b11
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1a4
mov edx, dword [ebp + 8]
xor ecx, ecx
mov eax, 0x409948
cmp edx, dword [eax]
je 0x404b33
add eax, 8
inc ecx
cmp eax, 0x4099d8
jl 0x404b24
push esi
mov esi, ecx
shl esi, 3
cmp edx, dword [esi + 0x409948]
jne 0x404c61
mov eax, dword [0x40be84]
cmp eax, 1
je 0x404c3b
test eax, eax
jne 0x404b64
cmp dword [0x409684], 1
je 0x404c3b
cmp edx, 0xfc
je 0x404c61
lea eax, [ebp - 0x1a4]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x404b9b
lea eax, [ebp - 0x1a4]
push str._program_name_unknown_
push eax
call fcn.00406500
pop ecx
pop ecx
lea eax, [ebp - 0x1a4]
push edi
push eax
lea edi, [ebp - 0x1a4]
call fcn.004065f0
inc eax
pop ecx
cmp eax, 0x3c
jbe 0x404bde
lea eax, [ebp - 0x1a4]
push eax
call fcn.004065f0
mov edi, eax
lea eax, [ebp - 0x1a4]
sub eax, 0x3b
push 3
add edi, eax
push 0x40850c
push edi
call fcn.00403190
add esp, 0x10
lea eax, [ebp - 0xa0]
push str.Runtime_Error__n_nProgram:
push eax
call fcn.00406500
lea eax, [ebp - 0xa0]
push edi
push eax
call fcn.00406510
lea eax, [ebp - 0xa0]
push 0x4084ec
push eax
call fcn.00406510
push dword [esi + 0x40994c]
lea eax, [ebp - 0xa0]
push eax
call fcn.00406510
push 0x12010
lea eax, [ebp - 0xa0]
push str.Microsoft_Visual_C_Runtime_Library
push eax
call fcn.00406c3f
add esp, 0x2c
pop edi
jmp 0x404c61
lea eax, [ebp + 8]
lea esi, [esi + 0x40994c]
push 0
push eax
push dword [esi]
call fcn.004065f0
pop ecx
push eax
push dword [esi]
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
pop esi
leave
ret
Function at 0x401830
Capabilities:
Create process on windows

Disassembly:
sub esp, 0x144
push ebx
mov ebx, dword [esp + 0x14c]
push ebp
push esi
mov esi, ecx
mov ebp, ebx
shl ebp, 0xa
mov ecx, dword [esi + 8]
mov eax, dword [esi + 0xc]
shl ecx, 0xa
push edi
lea edx, [ecx + eax + 0x40]
lea eax, [eax + ebp + 0x40]
push edx
push eax
call dword [sym.imp.MSVCRT.dll_wcscpy]
mov edx, dword [esp + 0x164]
mov eax, dword [esi + 0xc]
add esp, 8
xor ecx, ecx
cmp dx, 5
lea edi, [esp + 0x14]
sete cl
mov dword [eax + ebp + 0x2c], ecx
mov ecx, 0x10
xor eax, eax
mov dword [esp + 0x10], 0x44
rep stosd dword es:[edi], eax
mov ecx, 0x11
lea edi, [esp + 0x10]
rep stosd dword es:[edi], eax
lea eax, [ebx + ebx*4]
mov word [esp + 0x40], dx
mov ecx, dword [esi + 0xc]
xor edi, edi
lea eax, [eax + eax*4]
mov dword [esp + 0x24], 0x64
mov dword [esp + 0x28], edi
mov dword [esp + 0x2c], edi
lea eax, [eax + eax*4]
mov dword [esp + 0x3c], 5
shl eax, 3
cdq
idiv dword [esi + 8]
mov dword [esp + 0x20], eax
mov eax, dword [ecx + ebp + 0x28]
cmp eax, 1
jne 0x4018e9
mov edx, dword [esi + 0x14]
push edx
push ebx
push str._SrCalc.exe____d:_d_
jmp 0x4019b6
cmp eax, 3
jne 0x401902
mov ecx, dword [esi + 0x14]
lea edx, [esp + 0x54]
push ecx
push ebx
push str._SoCalc.exe____d:_d_
push edx
jmp 0x4019bb
cmp eax, edi
jne 0x40191a
mov eax, dword [esi + 0x14]
lea ecx, [esp + 0x54]
push eax
push ebx
push str._SvCalc.exe____d:_d_
push ecx
jmp 0x4019bb
cmp eax, 0x64
jne 0x40192e
mov edx, dword [esi + 0x14]
push edx
push ebx
push str._Request.exe____d:_d_
jmp 0x4019b6
cmp eax, 0x65
jne 0x401994
mov al, byte [esi + 5]
test al, al
je 0x40194b
mov ecx, dword [esi + 0x14]
lea edx, [esp + 0x54]
push ecx
push ebx
push str._ETMarkServer.exe____d:_d_
push edx
jmp 0x4019bb
mov ecx, esi
call fcn.00401b40
test al, al
je 0x40193a
mov eax, dword [esi + 0xc]
push 0x4053f4
lea ecx, [eax + ebp + 0x388]
push ecx
call dword [sym.imp.MSVCRT.dll_wcscpy]
mov edx, dword [esp + 0x168]
mov eax, dword [esp + 0x164]
add esp, 8
mov ecx, esi
push edx
push eax
push ebx
call fcn.00401a30
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x144
ret 0xc
mov al, byte [esi + 4]
test al, al
je 0x4019ac
mov eax, dword [esi + 0x14]
lea ecx, [esp + 0x54]
push eax
push ebx
push str._SdCalcu64.exe____d:_d_
push ecx
jmp 0x4019bb
mov edx, dword [esi + 0x14]
push edx
push ebx
push str._SvCalc.exe____d:_d_
lea eax, [esp + 0x60]
push eax
call dword [sym.imp.MSVCRT.dll_swprintf]
mov ecx, dword [esp + 0x170]
add esp, 0x10
lea edx, [esp + 0x10]
lea eax, [esp + 0x54]
push ecx
push edx
push edi
push edi
push 0x10
push 1
push edi
push edi
push eax
push edi
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
test eax, eax
je 0x4019fb
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x144
ret 0xc
mov ecx, dword [esi + 0xc]
push edi
push 0x1b
lea edx, [ecx + ebp + 0x388]
push edx
push 0x400
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push edi
push 0x1000
call dword [sym.imp.KERNEL32.dll_FormatMessageW]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x144
ret 0xc