joyce8/EMBER2024-capa huggingface dataset:
Function at 0x401260
Capabilities:
Create process on windows
Create process suspended
Extract resource via kernel32 functions
Get common file path
Write and execute a file
Write file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x484
mov eax, dword [section..data]
xor eax, esp
mov dword [esp + 0x480], eax
push ebx
push esi
push edi
push 0x417584
push 0x65
push 0
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov esi, eax
push esi
push 0
call dword [sym.imp.KERNEL32.dll_LoadResource]
push esi
push 0
mov edi, eax
call dword [sym.imp.KERNEL32.dll_SizeofResource]
push edi
mov ebx, eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov edi, eax
xor eax, eax
push 0x206
push eax
mov word [esp + 0x80], ax
lea eax, [esp + 0x82]
push eax
call fcn.00409000
add esp, 0xc
lea eax, [esp + 0x78]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
push 0x41758c
lea eax, [esp + 0x7c]
push eax
lea eax, [esp + 0x288]
push str._s_s
push eax
call fcn.00401400
add esp, 0x10
lea eax, [esp + 0x280]
push 0
push 0x80
push 2
push 0
push 1
push 2
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
push 0
mov esi, eax
mov dword [esp + 0x14], 0
lea eax, [esp + 0x14]
push eax
push ebx
push edi
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea edx, [esp + 0x78]
lea ecx, [esp + 0x280]
call section..text
push str.appmain.exe
lea eax, [esp + 0x7c]
push eax
lea eax, [esp + 0x288]
push str._s_s
push eax
call fcn.00401400
push 0x40
xorps xmm0, xmm0
mov dword [esp + 0x28], 0xc
lea eax, [esp + 0x48]
movq qword [esp + 0x2c], xmm0
push 0
push eax
mov dword [esp + 0x38], 1
mov dword [esp + 0x34], 0
call fcn.00409000
add esp, 0x1c
xorps xmm0, xmm0
xor eax, eax
mov dword [esp + 0x30], 0x44
mov word [esp + 0x60], ax
lea eax, [esp + 0x20]
push eax
lea eax, [esp + 0x34]
mov dword [esp + 0x60], 1
push eax
push 0
push 0
push 0
push 1
push 0
lea eax, [esp + 0x30]
push eax
lea eax, [esp + 0x2a0]
push eax
push 0
movdqu xmmword [esp + 0x48], xmm0
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
mov ecx, dword [esp + 0x48c]
xor eax, eax
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.00405a04
mov esp, ebp
pop ebp
ret 0x10
Function at 0x4031f0
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
push ebp
mov ebp, esp
test edx, edx
jne 0x4031fb
xor eax, eax
pop ebp
ret
push esi
mov esi, dword [ebp + 8]
not ecx
cmp esi, 8
jb 0x4032c5
push edi
mov edi, esi
shr edi, 3
movzx eax, byte [edx]
sub esi, 8
xor eax, ecx
shr ecx, 8
and eax, 0xff
xor ecx, dword [eax*4 + 0x417840]
movzx eax, byte [edx + 1]
xor eax, ecx
shr ecx, 8
and eax, 0xff
xor ecx, dword [eax*4 + 0x417840]
movzx eax, byte [edx + 2]
xor eax, ecx
shr ecx, 8
and eax, 0xff
xor ecx, dword [eax*4 + 0x417840]
movzx eax, byte [edx + 3]
xor eax, ecx
shr ecx, 8
and eax, 0xff
xor ecx, dword [eax*4 + 0x417840]
movzx eax, byte [edx + 4]
xor eax, ecx
shr ecx, 8
and eax, 0xff
xor ecx, dword [eax*4 + 0x417840]
movzx eax, byte [edx + 5]
xor eax, ecx
shr ecx, 8
and eax, 0xff
xor ecx, dword [eax*4 + 0x417840]
movzx eax, byte [edx + 6]
xor eax, ecx
shr ecx, 8
and eax, 0xff
xor ecx, dword [eax*4 + 0x417840]
movzx eax, byte [edx + 7]
add edx, 8
xor eax, ecx
shr ecx, 8
and eax, 0xff
xor ecx, dword [eax*4 + 0x417840]
dec edi
jne 0x403210
pop edi
test esi, esi
je 0x4032ea
lea esp, [esp]
movzx eax, byte [edx]
lea edx, [edx + 1]
xor eax, ecx
shr ecx, 8
and eax, 0xff
xor ecx, dword [eax*4 + 0x417840]
dec esi
jne 0x4032d0
not ecx
mov eax, ecx
pop esi
pop ebp
ret

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

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

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

Disassembly:
push ebx
push esi
mov bl, dl
mov edx, ecx
push edi
mov edi, dword [edx + 8]
mov esi, edi
mov ecx, dword [edx]
and esi, 0xfffd
or esi, 2
mov eax, esi
xor eax, 1
imul eax, esi
shr eax, 8
xor bl, al
movsx eax, bl
xor eax, ecx
shr ecx, 8
and eax, 0xff
mov eax, dword [eax*4 + 0x417840]
xor eax, ecx
mov dword [edx], eax
movzx eax, al
add eax, dword [edx + 4]
imul eax, eax, 0x8088405
inc eax
mov dword [edx + 4], eax
shr eax, 0x18
xor eax, edi
shr edi, 8
and eax, 0xff
xor edi, dword [eax*4 + 0x417840]
mov al, bl
mov dword [edx + 8], edi
pop edi
pop esi
pop ebx
ret
Function at 0x403b20
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push esi
push edi
mov edi, dword [ebp + 0xc]
mov ebx, edx
mov esi, ebx
mov eax, ecx
imul esi, dword [ebp + 8]
mov dword [ebp - 4], eax
cmp byte [edi], 0
je 0x403b63
push 0
lea ecx, [ebp + 8]
push ecx
push esi
push eax
push dword [edi + 4]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x403b55
mov byte [edi + 8], 1
mov eax, dword [ebp + 8]
xor edx, edx
pop edi
pop esi
div ebx
pop ebx
mov esp, ebp
pop ebp
ret
mov edx, dword [edi + 0x1c]
mov ecx, dword [edi + 0x18]
lea eax, [edx + esi]
cmp eax, ecx
jbe 0x403b74
mov esi, ecx
sub esi, edx
mov ecx, dword [edi + 0x14]
push esi
add ecx, edx
push ecx
push dword [ebp - 4]
call fcn.0040b9f0
add dword [edi + 0x1c], esi
add esp, 0xc
mov eax, esi
xor edx, edx
div ebx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x403ba0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push ebx
push esi
mov esi, ecx
mov ebx, edx
push edi
mov dword [ebp - 8], ebx
mov edi, 1
cmp byte [esi], 0
je 0x403bdb
push 0
lea eax, [ebp - 8]
push eax
push edi
lea eax, [ebp - 1]
push eax
push dword [esi + 4]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x403bd6
mov byte [esi + 8], 1
mov edi, dword [ebp - 8]
jmp 0x403c08
mov ebx, dword [esi + 0x1c]
mov ecx, dword [esi + 0x18]
lea eax, [ebx + 1]
cmp eax, ecx
jbe 0x403bec
mov edi, ecx
sub edi, ebx
mov eax, dword [esi + 0x14]
add eax, ebx
push edi
push eax
lea eax, [ebp - 1]
push eax
call fcn.0040b9f0
lea eax, [ebx + edi]
add esp, 0xc
mov ebx, dword [ebp - 8]
mov dword [esi + 0x1c], eax
cmp edi, 1
jne 0x403c1c
movzx eax, byte [ebp - 1]
mov dword [ebx], eax
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
cmp byte [esi], 0
je 0x403c13
cmp byte [esi + 8], 0
je 0x403c13
pop edi
pop esi
or eax, 0xffffffff
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x403ce0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
push edi
mov edi, ecx
mov ecx, dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp byte [edi], 0
je 0x403d15
cmp byte [edi + 1], 0
je 0x403d0d
push 2
push 0
push 0
push dword [edi + 4]
call ecx
mov ecx, dword [sym.imp.KERNEL32.dll_SetFilePointer]
jmp 0x403d1b
or eax, 0xffffffff
pop edi
mov esp, ebp
pop ebp
ret
mov eax, dword [edi + 0x18]
mov dword [edi + 0x1c], eax
cmp byte [edi], 0
push ebx
je 0x403d40
cmp byte [edi + 1], 0
je 0x403d39
push 1
push 0
push 0
push dword [edi + 4]
call ecx
mov ebx, eax
sub ebx, dword [edi + 0xc]
jmp 0x403d43
xor ebx, ebx
mov dword [ebp - 0xc], ebx
jmp 0x403d52
mov ebx, dword [edi + 0x1c]
mov eax, 0xffff
mov dword [ebp - 0xc], ebx
mov dword [ebp - 8], eax
cmp ebx, eax
jae 0x403d55
mov dword [ebp - 8], ebx
push esi
push 0x404
call fcn.00405cb9
mov esi, eax
add esp, 4
test esi, esi
jne 0x403d73
pop esi
pop ebx
or eax, 0xffffffff
pop edi
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 8]
mov eax, 4
mov dword [ebp - 4], 0xffffffff
cmp ecx, eax
jbe 0x403e78
lea ebx, [ebx]
add eax, 0x400
cmp eax, ecx
mov edx, eax
mov eax, 0x404
cmova edx, ecx
mov ecx, ebx
sub ecx, edx
mov dword [ebp - 0x1c], edx
sub ebx, ecx
mov dword [ebp - 0x18], ecx
cmp ebx, 0x404
cmova ebx, eax
cmp byte [edi], 0
je 0x403dda
cmp byte [edi + 1], 0
je 0x403e78
mov eax, dword [edi + 0xc]
push 0
push 0
add eax, ecx
push eax
push dword [edi + 4]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
jmp 0x403ddd
mov dword [edi + 0x1c], ecx
cmp byte [edi], 0
mov ecx, ebx
mov dword [ebp - 0x10], ebx
je 0x403e05
push 0
lea eax, [ebp - 0x14]
push eax
push ebx
push esi
push dword [edi + 4]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x403e00
mov byte [edi + 8], 1
mov eax, dword [ebp - 0x14]
jmp 0x403e2e
mov edx, dword [edi + 0x1c]
lea eax, [edx + ebx]
cmp eax, dword [edi + 0x18]
jbe 0x403e18
mov ecx, dword [edi + 0x18]
sub ecx, edx
mov dword [ebp - 0x10], ecx
push ecx
mov ecx, dword [edi + 0x14]
add ecx, edx
push ecx
push esi
call fcn.0040b9f0
mov eax, dword [ebp - 0x10]
add esp, 0xc
add dword [edi + 0x1c], eax
xor edx, edx
div ebx
cmp eax, 1
jne 0x403e78
lea eax, [ebx - 3]
test eax, eax
js 0x403e60
mov edi, edi
dec eax
cmp byte [eax + esi], 0x50
jne 0x403e5c
cmp byte [eax + esi + 1], 0x4b
jne 0x403e5c
cmp byte [eax + esi + 2], 5
jne 0x403e5c
cmp byte [eax + esi + 3], 6
je 0x403e8b
test eax, eax
jns 0x403e40
mov eax, dword [ebp - 4]
test eax, eax
jne 0x403e78
mov eax, dword [ebp - 0x1c]
mov ecx, dword [ebp - 8]
mov ebx, dword [ebp - 0xc]
cmp eax, ecx
jb 0x403d90
push esi
call fcn.00405be0
mov eax, dword [ebp - 4]
add esp, 4
pop esi
pop ebx
pop edi
mov esp, ebp
pop ebp
ret
add eax, dword [ebp - 0x18]
mov dword [ebp - 4], eax
jmp 0x403e63
Function at 0x404cc0
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
mov esi, ecx
push edi
cmp dword [esi], 0
jne 0x404d67
cmp dword [esi + 4], 0xffffffff
jne 0x404d67
lea edi, [esi + 0x244]
push edi
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
mov ecx, edi
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x404cf2
sub ecx, edx
sar ecx, 1
movzx eax, word [esi + ecx*2 + 0x242]
cmp eax, 0x5c
je 0x404d29
cmp eax, 0x2f
je 0x404d29
add edi, 0xfffffffe
mov ax, word [edi + 2]
lea edi, [edi + 2]
test ax, ax
jne 0x404d16
mov eax, dword [0x4177c4]
mov dword [edi], eax
lea eax, [ebp - 4]
push eax
push ecx
mov ecx, dword [ebp + 8]
call fcn.00403a80
add esp, 8
test eax, eax
jne 0x404d48
mov eax, dword [ebp - 4]
pop edi
pop esi
mov esp, ebp
pop ebp
ret 0xc
mov ecx, eax
call fcn.00403ea0
xor ecx, ecx
mov dword [esi], eax
test eax, eax
mov edx, 0x200
cmove ecx, edx
mov eax, ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret 0xc
pop edi
mov eax, 0x1000000
pop esi
mov esp, ebp
pop ebp
ret 0xc

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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x414
mov eax, dword [section..data]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov esi, ecx
mov ebx, edx
test esi, esi
je 0x4054b2
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x4054b2
push 0
push esi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
movzx eax, word [ebx]
test ax, ax
je 0x40559c
push edi
mov edi, ebx
mov ecx, ebx
cmp ax, 0x2f
je 0x4054cf
cmp ax, 0x5c
jne 0x4054d1
mov edi, ecx
movzx eax, word [ecx + 2]
add ecx, 2
test ax, ax
jne 0x4054c3
cmp edi, ebx
je 0x40551a
sub edi, ebx
lea eax, [ebp - 0x414]
and edi, 0xfffffffe
push edi
push ebx
push eax
call fcn.0040b9f0
add esp, 0xc
cmp edi, 0x208
jae 0x4055ac
xor eax, eax
lea edx, [ebp - 0x414]
mov ecx, esi
mov word [ebp + edi - 0x414], ax
call fcn.00405480
xor eax, eax
mov word [ebp - 0x20c], ax
test esi, esi
je 0x405540
lea ecx, [ebp - 0x20c]
sub ecx, esi
nop
movzx eax, word [esi]
lea esi, [esi + 2]
mov word [ecx + esi - 2], ax
test ax, ax
jne 0x405530
mov esi, ebx
mov ax, word [ebx]
add ebx, 2
test ax, ax
jne 0x405542
lea edi, [ebp - 0x20c]
sub ebx, esi
add edi, 0xfffffffe
jmp 0x405560
mov ax, word [edi + 2]
add edi, 2
test ax, ax
jne 0x405560
mov ecx, ebx
lea eax, [ebp - 0x20c]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
pop edi
cmp eax, 0xffffffff
jne 0x40559c
push 0
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
mov ecx, dword [ebp - 4]
pop esi
xor ecx, ebp
pop ebx
call fcn.00405a04
mov esp, ebp
pop ebp
ret
call fcn.00406119
int3
Function at 0x40b6a8
Capabilities:
Link many functions at runtime
Print debug messages

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [section..data]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_EncodePointer]
push esi
push edi
mov dword [ebp - 0x1c], eax
xor esi, esi
mov eax, dword [ebp + 0xc]
push esi
mov dword [ebp - 0x20], eax
call ebx
mov edi, eax
mov dword [ebp - 0x18], edi
call fcn.00407e8c
mov dword [ebp - 0x14], eax
cmp dword [0x41bf80], esi
jne 0x40b79b
push 0x800
push esi
push 0x414474
call dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
mov edi, eax
test edi, edi
jne 0x40b728
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x57
jne 0x40b87b
push esi
push esi
push 0x414474
call dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
mov edi, eax
test edi, edi
je 0x40b87b
push str.MessageBoxW
push edi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x40b87b
push eax
call ebx
push str.GetActiveWindow
push edi
mov dword [0x41bf80], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
push eax
call ebx
push str.GetLastActivePopup
push edi
mov dword [0x41bf84], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
push eax
call ebx
push str.GetUserObjectInformationW
push edi
mov dword [0x41bf88], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
push eax
call ebx
mov dword [0x41bf90], eax
test eax, eax
je 0x40b798
push str.GetProcessWindowStation
push edi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
push eax
call ebx
mov dword [0x41bf8c], eax
mov edi, dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_IsDebuggerPresent]
test eax, eax
je 0x40b7c0
mov eax, dword [ebp - 0x1c]
test eax, eax
je 0x40b7b3
push eax
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
cmp dword [ebp - 0x14], esi
je 0x40b7d5
push 4
pop eax
jmp 0x40b87d
cmp dword [ebp - 0x14], esi
je 0x40b7d5
push dword [0x41bf80]
call dword [sym.imp.KERNEL32.dll_DecodePointer]
push 3
jmp 0x40b7ba
mov eax, dword [0x41bf8c]
mov ebx, dword [sym.imp.KERNEL32.dll_DecodePointer]
cmp eax, edi
je 0x40b833
cmp dword [0x41bf90], edi
je 0x40b833
push eax
call ebx
push dword [0x41bf90]
mov dword [ebp - 0x14], eax
call ebx
mov ecx, dword [ebp - 0x14]
mov dword [ebp - 0x18], eax
test ecx, ecx
je 0x40b833
test eax, eax
je 0x40b833
call ecx
test eax, eax
je 0x40b828
lea ecx, [ebp - 0x24]
push ecx
push 0xc
lea ecx, [ebp - 0x10]
push ecx
push 1
push eax
call dword [ebp - 0x18]
test eax, eax
je 0x40b828
test byte [ebp - 8], 1
jne 0x40b833
mov edi, dword [ebp + 0x10]
or edi, 0x200000
jmp 0x40b863
mov eax, dword [0x41bf84]
cmp eax, edi
je 0x40b860
push eax
call ebx
test eax, eax
je 0x40b860
call eax
mov esi, eax
test esi, esi
je 0x40b860
mov eax, dword [0x41bf88]
cmp eax, edi
je 0x40b860
push eax
call ebx
test eax, eax
je 0x40b860
push esi
call eax
mov esi, eax
mov edi, dword [ebp + 0x10]
push dword [0x41bf80]
call ebx
test eax, eax
je 0x40b87b
push edi
push dword [ebp - 0x20]
push dword [ebp - 0x1c]
push esi
call eax
jmp 0x40b87d
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00405a04
mov esp, ebp
pop ebp
ret
Function at 0x432003
Capabilities:
Encode data using xor
Packed with generic packer

Disassembly:
pushal
nop
nop
nop
mov eax, section..rsrc
nop
nop
push 4
nop
nop
nop
nop
nop
nop
pop edi
nop
nop
cmp eax, 0
nop
nop
je 0x432072
nop
nop
nop
nop
mov ebx, 0x40c7d0
nop
nop
nop
mov ecx, ebx
nop
nop
nop
nop
sub ecx, eax
nop
nop
nop
nop
nop
xor edx, edx
nop
push eax
nop
nop
nop
nop
nop
mov eax, ecx
nop
nop
nop
nop
div edi
nop
nop
nop
nop
xchg ecx, eax
nop
nop
nop
nop
nop
nop
nop
nop
pop eax
nop
nop
mov esi, 0x302f417e
nop
nop
nop
nop
nop
xor dword [eax], esi
nop
nop
add eax, edi
nop
nop
nop
loop 0x432060
nop
nop
nop
mov eax, section..data
nop
cmp eax, 0
nop
nop
nop
nop
nop
je 0x4320d2
nop
nop
nop
mov ebx, 0x42f314
nop
nop
nop
nop
mov ecx, ebx
nop
nop
nop
nop
sub ecx, eax
xor edx, edx
nop
nop
nop
nop
nop
nop
nop
nop
nop
push eax
mov eax, ecx
nop
nop
nop
nop
div edi
nop
nop
nop
nop
nop
nop
nop
nop
xchg ecx, eax
nop
nop
nop
nop
nop
nop
pop eax
mov esi, 0x6d1f1bfd
nop
xor dword [eax], esi
nop
nop
nop
nop
nop
nop
nop
nop
add eax, edi
loop 0x4320c0
nop
nop
nop
nop
nop
popal
nop
nop
nop
nop
jmp 0x431219
Function at 0x401180
Capabilities:
Check internet connectivity via wininet
Connect to http server
Create http request

Disassembly:
push ebp
mov ebp, esp
push 0
push 0x55105f
push 0x55105f
push 0
push eax
call dword [sym.imp.WININET.dll_InternetOpenA]
mov dword [0x5863f4], eax
test eax, eax
jne 0x4011d1
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [0x586400], eax
mov eax, dword [ebp + 8]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4011cb
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
xor eax, eax
pop ebp
ret 0x10
mov ecx, dword [ebp + 0x14]
mov edx, dword [ebp + 0x10]
push 0
push 0x4400000
push 3
push ecx
mov ecx, dword [ebp + 0xc]
push edx
mov edx, dword [ebp + 8]
push ecx
push edx
push eax
call dword [sym.imp.WININET.dll_InternetConnectA]
mov dword [0x5863f8], eax
test eax, eax
jne 0x401236
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [0x586400], eax
mov eax, dword [0x5863f4]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp + 8]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4011cb
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
xor eax, eax
pop ebp
ret 0x10
push 0
call dword [sym.imp.WININET.dll_InternetAttemptConnect]
test eax, eax
je 0x401290
push esi
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [0x5863f8]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
push ecx
mov dword [0x586400], eax
call esi
mov edx, dword [0x5863f4]
push edx
call esi
mov eax, dword [ebp + 8]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
pop esi
test edx, edx
jg 0x4011cb
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
xor eax, eax
pop ebp
ret 0x10
mov eax, dword [ebp + 8]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4012af
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, 1
pop ebp
ret 0x10
Function at 0x402360
Capabilities:
Read data from internet
Receive data

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x780c
call fcn.005043d0
mov eax, dword [0x56f360]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push 0x77ff
lea ecx, [ebp - 0x7803]
push 0
push ecx
mov dword [ebp - 0x780c], eax
mov dword [ebp - 0x7808], 0x3e800
mov byte [ebp - 0x7804], 0
call fcn.00500fb0
add esp, 0xc
cmp dword [0x5863fc], 0
jne 0x4023cd
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [0x586400], eax
xor eax, eax
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004fd9f8
mov esp, ebp
pop ebp
ret 4
push 0x3e800
push 0
push ebx
call fcn.00500fb0
add esp, 0xc
mov dword [esi], 0
push edi
mov edi, dword [0x5863fc]
test edi, edi
je 0x40244c
push 0x7800
lea edx, [ebp - 0x7804]
push 0
push edx
call fcn.00500fb0
add esp, 0xc
push 0x576fac
push 0x7800
lea eax, [ebp - 0x7804]
push eax
push edi
call dword [sym.imp.WININET.dll_InternetReadFile]
test eax, eax
je 0x40244c
mov ecx, dword [0x576fac]
mov edi, ecx
test ecx, ecx
je 0x402457
mov eax, dword [esi]
cmp eax, 0x3e800
jae 0x402457
push ecx
lea ecx, [ebp - 0x7804]
push ecx
add eax, ebx
push eax
call fcn.00503a10
add esp, 0xc
add dword [esi], edi
jmp 0x4023e4
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [0x586400], eax
mov edx, dword [ebp - 0x7808]
mov edi, dword [ebp - 0x780c]
push edx
push 0
push edi
call fcn.00500fb0
mov ecx, dword [0x5863fc]
add esp, 0xc
push 0
lea eax, [ebp - 0x7808]
push eax
push edi
push 0x16
push ecx
call dword [sym.imp.WININET.dll_HttpQueryInfoA]
pop edi
test eax, eax
je 0x4023b0
mov ecx, dword [ebp - 4]
xor eax, eax
cmp dword [esi], eax
setne al
xor ecx, ebp
call fcn.004fd9f8
mov esp, ebp
pop ebp
ret 4
Function at 0x402850
Capabilities:
Get file size

Disassembly:
push ebx
push edi
mov edi, dword [0x5773e4]
xor ebx, ebx
cmp edi, dword [0x5773e8]
jae 0x4028d0
push esi
mov eax, dword [edi + 0x2900]
dec eax
je 0x4028bb
dec eax
jne 0x4028c1
push eax
push 0x80
push 3
push eax
push 1
push SysReAllocString
lea eax, [edi + 0x100]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
jne 0x4028a2
push esi
add ebx, 0x1800
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x4028c1
push 0
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
push esi
lea ebx, [ebx + eax + 0x1800]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x4028c1
add ebx, 0x2000
add edi, 0x2904
cmp edi, dword [0x5773e8]
jb 0x402863
pop esi
pop edi
mov eax, ebx
pop ebx
ret

Function at 0x4028e0
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
mov eax, edi
mov dword [ebp - 8], 0x400
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4028f2
sub eax, edx
push esi
mov esi, eax
je 0x40291a
push 1
lea eax, [esi + edi]
push 0x55101c
push eax
call fcn.004fde35
add esp, 0xc
test eax, eax
je 0x40291a
dec esi
jne 0x402900
lea ecx, [ebp - 4]
push ecx
push 1
push 0
add esi, edi
push esi
push SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
pop esi
test eax, eax
jne 0x40297f
lea edx, [ebp - 8]
push edx
push 0x576fb0
push eax
push eax
mov eax, dword [ebp - 4]
push str.Content_Type
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
je 0x40296c
push 0xffffffffffffffff
push str.application_octet_stream
push 0x400
push 0x576fb0
call fcn.004fdef5
add esp, 0x10
mov ecx, dword [ebp - 4]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, 0x576fb0
mov esp, ebp
pop ebp
ret
push 0xffffffffffffffff
push str.application_octet_stream
push 0x400
push 0x576fb0
call fcn.004fdef5
add esp, 0x10
mov eax, 0x576fb0
mov esp, ebp
pop ebp
ret

Function at 0x403360
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
push ebx
mov ebx, dword [ebp + 8]
push edi
mov edi, dword [ebp + 0xc]
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
jne 0x40337b
pop edi
pop ebx
pop ebp
ret
push esi
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov esi, eax
test esi, esi
je 0x4033b2
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov ecx, dword [ebp + 0x10]
add eax, esi
and ecx, 0xf
jbe 0x4033ae
jmp 0x4033a0
cmp esi, eax
jae 0x4033b2
dec ecx
movzx edx, word [esi]
lea esi, [esi + edx*2 + 2]
jne 0x4033a0
cmp esi, eax
jb 0x4033b9
pop esi
pop edi
xor eax, eax
pop ebx
pop ebp
ret
movzx eax, word [esi]
neg eax
sbb eax, eax
and eax, esi
pop esi
pop edi
pop ebx
pop ebp
ret