joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4097d6
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 0x409873
push ebx
push esi
call fcn.0040979f
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.004096e8
add esp, 0x24
mov dword [ebp - 4], eax
test eax, eax
jne 0x409820
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x409872
push edi
push eax
call fcn.0040a1f3
mov edi, eax
pop ecx
push ebx
test edi, edi
jne 0x409840
call fcn.004068e9
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x409871
push ebx
push dword [ebp - 4]
push edi
push dword [ebp - 8]
push esi
push ebx
push ebx
call fcn.004096e8
add esp, 0x20
test eax, eax
jne 0x40985f
push edi
call fcn.004068e9
jmp 0x409867
push ebx
call fcn.004068e9
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 0x40a8ff
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x412fd8
push 0x412fd0
push 0x411c20
push 0x1e
call fcn.0040a81d
mov esi, eax
add esp, 0x10
test esi, esi
je 0x40a933
push dword [ebp + 8]
mov ecx, esi
call dword [0x41116c]
call esi
jmp 0x40a939
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x40a97d
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x412fe8
push 0x412fe0
push 0x411c44
push 0x20
call fcn.0040a81d
mov esi, eax
add esp, 0x10
test esi, esi
je 0x40a9b4
push dword [ebp + 8]
mov ecx, esi
call dword [0x41116c]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]
Function at 0x40c72c
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x14
mov eax, dword [ebp + 8]
mov ecx, eax
push ebx
mov ebx, dword [ebp + 0xc]
and eax, 0x3f
sar ecx, 6
push esi
push edi
imul edi, eax, 0x38
mov eax, dword [ecx*4 + 0x445620]
mov dword [ebp - 0x10], ecx
mov ecx, dword [eax + edi + 0x18]
mov dword [ebp - 0x14], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x40c76c
cmp byte [ebx], 0xa
jne 0x40c76c
or byte [eax + edi + 0x28], 4
jmp 0x40c771
and byte [eax + edi + 0x28], 0xfb
add ecx, ebx
mov edx, ebx
mov dword [ebp - 0xc], ecx
mov esi, ebx
cmp ebx, ecx
jae 0x40c86f
mov al, byte [edx]
cmp al, 0x1a
je 0x40c851
lea ecx, [edx + 1]
mov dword [ebp - 8], ecx
mov ecx, dword [ebp - 0xc]
cmp al, 0xd
je 0x40c7a0
mov edx, dword [ebp - 8]
mov byte [esi], al
jmp 0x40c7c5
mov eax, dword [ebp - 8]
cmp eax, ecx
jae 0x40c7cf
mov cl, byte [eax]
xor eax, eax
cmp cl, 0xa
sete al
inc eax
add edx, eax
cmp cl, 0xa
sete al
dec al
and al, 3
add al, 0xa
mov byte [esi], al
mov ecx, dword [ebp - 0xc]
inc esi
cmp edx, ecx
jb 0x40c782
jmp 0x40c86f
push 0
lea eax, [ebp - 0xc]
push eax
push 1
lea eax, [ebp - 1]
push eax
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x40c84c
cmp dword [ebp - 0xc], 0
je 0x40c84c
mov ecx, dword [ebp - 0x10]
mov eax, dword [ecx*4 + 0x445620]
test byte [eax + edi + 0x28], 0x48
je 0x40c826
mov dl, byte [ebp - 1]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
cmp dl, 0xa
jne 0x40c811
mov byte [esi], dl
jmp 0x40c822
mov byte [esi], 0xd
mov eax, dword [ecx*4 + 0x445620]
mov byte [eax + edi + 0x2a], dl
mov eax, dword [ebp - 0x14]
mov esi, eax
jmp 0x40c86f
cmp byte [ebp - 1], 0xa
jne 0x40c835
cmp esi, ebx
jne 0x40c835
mov byte [esi], 0xa
jmp 0x40c86e
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.0040c525
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x40c86f
mov byte [esi], 0xd
jmp 0x40c86e
mov ecx, dword [ebp - 0x10]
mov ecx, dword [ecx*4 + 0x445620]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x40c86b
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x40c86f
mov byte [esi], 0x1a
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x40c878
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
mov eax, dword [ebp + 8]
push ebx
push esi
mov esi, dword [ebp + 0xc]
mov ebx, eax
and eax, 0x3f
sar ebx, 6
push edi
imul edi, eax, 0x38
push 0xa
mov eax, dword [ebx*4 + 0x445620]
pop edx
mov dword [ebp - 0x14], edx
mov ecx, dword [edi + eax + 0x18]
mov dword [ebp - 0x18], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x40c8bb
cmp word [esi], dx
jne 0x40c8bb
or byte [edi + eax + 0x28], 4
jmp 0x40c8c0
and byte [edi + eax + 0x28], 0xfb
lea edx, [esi + ecx*2]
mov eax, esi
mov dword [ebp - 8], edx
mov dword [ebp - 4], eax
cmp eax, edx
jae 0x40ca13
mov dword [ebp - 0xc], 0xd
movzx ecx, word [eax]
mov edx, ecx
mov dword [ebp - 0x10], edx
push 0x1a
pop edx
cmp cx, dx
mov edx, dword [ebp - 8]
je 0x40c9f3
add eax, 2
cmp cx, word [ebp - 0xc]
je 0x40c902
mov dword [ebp - 4], eax
mov word [esi], cx
jmp 0x40c938
cmp eax, edx
jae 0x40c944
movzx eax, word [eax]
xor ecx, ecx
cmp ax, word [ebp - 0x14]
mov edx, eax
push 0xa
sete cl
xor eax, eax
lea ecx, [ecx*2 + 2]
add dword [ebp - 4], ecx
pop ecx
cmp dx, cx
mov edx, dword [ebp - 8]
sete al
dec eax
and eax, 3
add eax, ecx
mov word [esi], ax
mov eax, dword [ebp - 4]
add esi, 2
cmp eax, edx
jb 0x40c8da
jmp 0x40ca13
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 0x40c9ef
cmp dword [ebp - 0x14], 0
je 0x40c9ef
mov eax, dword [ebx*4 + 0x445620]
push 0xa
test byte [edi + eax + 0x28], 0x48
je 0x40c9c7
mov dx, word [ebp - 4]
lea eax, [esi + 2]
pop ecx
mov dword [ebp - 0x18], eax
cmp dx, cx
jne 0x40c990
mov word [esi], cx
jmp 0x40c9c3
push 0xd
pop eax
mov word [esi], ax
mov eax, dword [ebx*4 + 0x445620]
movzx ecx, dx
shr ecx, 8
push 0xa
mov byte [edi + eax + 0x2a], dl
mov eax, dword [ebx*4 + 0x445620]
mov byte [edi + eax + 0x2b], cl
mov eax, dword [ebx*4 + 0x445620]
pop ecx
mov byte [edi + eax + 0x2c], cl
mov eax, dword [ebp - 0x18]
mov esi, eax
jmp 0x40ca13
pop ebx
cmp word [ebp - 4], bx
jne 0x40c9d8
cmp esi, dword [ebp + 0xc]
jne 0x40c9d8
mov word [esi], bx
jmp 0x40ca10
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.0040c525
add esp, 0x10
cmp word [ebp - 4], bx
je 0x40ca13
push 0xd
jmp 0x40ca0c
mov ecx, dword [ebx*4 + 0x445620]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x40ca0a
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x40ca13
push 0x1a
pop eax
mov word [esi], ax
add esi, 2
sub esi, dword [ebp + 0xc]
and esi, 0xfffffffe
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x40dc05
Capabilities:
Clear file content

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x2c
push ebx
mov ebx, dword [ebp + 8]
lea ecx, [ebp - 0x2c]
push esi
push edi
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.0040db81
mov eax, dword [ebp - 0x2c]
and eax, dword [ebp - 0x28]
cmp eax, 0xffffffff
je 0x40dd7d
mov eax, dword [ebp - 0x24]
and eax, dword [ebp - 0x20]
cmp eax, 0xffffffff
je 0x40dd7d
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 8], ecx
mov dword [ebp - 4], eax
test ecx, ecx
jl 0x40dd2c
jg 0x40dc5e
test eax, eax
je 0x40dd22
push 1
push 0x1000
call fcn.004082d5
mov esi, eax
pop ecx
pop ecx
test esi, esi
jne 0x40dc84
mov eax, dword [ebp + 0x14]
push 0xc
pop edi
mov byte [eax + 0x1c], 1
mov dword [eax + 0x18], edi
jmp 0x40dd19
push 0x8000
push ebx
call fcn.0040569b
mov edi, dword [ebp + 0x14]
pop ecx
pop ecx
mov ecx, dword [ebp - 0x1c]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0x18]
test eax, eax
jl 0x40dcb0
jg 0x40dcab
cmp ecx, 0x1000
jb 0x40dcb0
mov ecx, 0x1000
push edi
push ecx
push esi
push ebx
call fcn.00407d58
add esp, 0x10
cmp eax, 0xffffffff
je 0x40dcf5
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 0x40dcab
jl 0x40dcdc
test ecx, ecx
jne 0x40dc9d
push dword [ebp - 0xc]
push ebx
call fcn.0040569b
push esi
call fcn.004068e9
add esp, 0xc
xor edi, edi
jmp 0x40dd8e
cmp byte [edi + 0x24], 0
je 0x40dd0c
cmp dword [edi + 0x20], 5
jne 0x40dd0c
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], 0xd
cmp byte [edi + 0x1c], 0
je 0x40dd17
mov edi, dword [edi + 0x18]
jmp 0x40dd19
xor edi, edi
push esi
call fcn.004068e9
pop ecx
jmp 0x40dd8e
test ecx, ecx
jg 0x40dcee
jl 0x40dd2c
test eax, eax
jae 0x40dcee
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.0040c525
and eax, edx
add esp, 0x10
cmp eax, 0xffffffff
jne 0x40dd4f
mov edi, dword [ebp + 0x14]
cmp byte [edi + 0x1c], 0
je 0x40dcee
jmp 0x40dd86
push ebx
call fcn.00409d11
pop ecx
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x40dcee
mov esi, dword [ebp + 0x14]
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 0xd
mov byte [esi + 0x24], 1
mov dword [esi + 0x20], eax
pop edi
mov byte [esi + 0x1c], 1
mov dword [esi + 0x18], edi
jmp 0x40dd8e
mov edi, dword [ebp + 0x14]
cmp byte [edi + 0x1c], 0
je 0x40dd8b
mov edi, dword [edi + 0x18]
jmp 0x40dd8e
push 0x16
pop edi
push 0
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
push dword [ebp - 0x14]
call fcn.0040c525
add esp, 0x10
mov eax, edi
pop edi
pop esi
pop ebx
leave
ret
Function at 0x4066a5
Capabilities:
Contain obfuscated stackstrings

Disassembly:
push eax
push dword [ebp - 0x3a4]
push dword [ebp + 0x14]
call fcn.004045ec
add esp, 0xc
mov dword [ebp - 0x37c], eax
cmp dword [ebp - 0x37c], 0
je 0x4066c8
jmp 0x4066cd
jmp 0x405fc9

Function at 0x4069c5
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x23c
push esi
mov esi, 0x104
lea eax, [ebp - 0x23c]
push esi
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
cmp eax, esi
pop esi
jbe 0x4069e9
xor eax, eax
test eax, eax
je 0x4069fc
cmp word [ebp + eax*2 - 0x23e], 0x5c
je 0x4069fc
xor ecx, ecx
jmp 0x4069ff
xor ecx, ecx
inc ecx
push dword [ebp + 8]
lea ecx, [ecx*2 + 0x40a014]
lea eax, [ebp + eax*2 - 0x23c]
push ecx
push str._s_S.dll
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x10
lea eax, [ebp - 0x23c]
push 8
push 0
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
leave
ret 4
Function at 0x401000
Capabilities:
Check if file exists
Create directory
Get file attributes

Disassembly:
push esi
mov esi, dword [esp + 0xc]
test esi, esi
je 0x401090
push ebp
mov ebp, dword [esp + 0x14]
push edi
mov edi, dword [esp + 0x10]
push ebx
cmp byte [esi], 0
je 0x40108d
push 0x5c
push esi
call dword [sym.imp.MSVCR71.dll_strchr]
mov esi, eax
test esi, esi
pop ecx
pop ecx
je 0x40108d
push edi
mov byte [esi], 0
call dword [sym.imp.kernel32.dll_GetFileAttributesA]
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x401066
push 0
push edi
call dword [sym.imp.kernel32.dll_CreateDirectoryA]
test eax, eax
jne 0x40105f
test ebp, ebp
je 0x40105f
push edi
push str.CreateDirectory___s_
push 5
call ebp
add esp, 0xc
jmp 0x401066
push edi
push 1
call ebp
pop ecx
pop ecx
test bl, 0x10
jne 0x401087
push 0xb7
call dword [sym.imp.kernel32.dll_SetLastError]
test ebp, ebp
je 0x401087
push edi
push str.CreateDirectory___s_
push 5
call ebp
add esp, 0xc
mov byte [esi], 0x5c
inc esi
jne 0x401018
pop ebx
pop edi
pop ebp
xor eax, eax
inc eax
pop esi
ret

Function at 0x4031f4
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
pushal
call 0x403203
pop dword [ebp - 0x10]
mov eax, 0xf923f3f1
add eax, 0x71c3e12
sub dword [ebp - 0x10], eax
mov dword [ebp - 0x20], 0xd101dcf8
add dword [ebp - 0x20], 0x7d506853
mov dword [ebp - 0x1c], 0x4cbc3486
add dword [ebp - 0x1c], 0xe57717bf
mov dword [ebp - 0x18], 0xdee14e00
add dword [ebp - 0x18], 0x6d6af62e
mov dword [ebp - 0x14], 0x1ef65053
add dword [ebp - 0x14], 0xe109afad
lea eax, [ebp - 0x20]
push eax
mov eax, 0x9b28e02a
sub eax, 0x9ae85f9e
add eax, dword [ebp - 0x10]
call dword [eax]
mov dword [ebp - 0x20], 0xa1b4fde9
sub dword [ebp - 0x20], 0x2d429493
mov dword [ebp - 0x1c], 0x23ee59c5
add dword [ebp - 0x1c], 0x1d7e07b0
mov dword [ebp - 0x18], 0x8730baaf
add dword [ebp - 0x18], 0xdc3eb1bd
mov dword [ebp - 0x14], 0x4a867817
add dword [ebp - 0x14], 0xb57987e9
lea ebx, [ebp - 0x20]
push ebx
push eax
mov eax, 0xdad1405d
add eax, 0x256f4077
add eax, dword [ebp - 0x10]
call dword [eax]
push 0x40
push 0x1000
push 0x392d5
push 0
call eax
mov ecx, 0x66aaac80
sub ecx, 0x66aa5a2b
xor esi, esi
add esi, eax
mov edi, 0x411000
add edi, dword [ebp - 0x10]
mov ebx, 0xe7f70875
sub ebx, 0x95f1d88f
xor dword [ebp - 8], 0x96c3db39
mov edx, dword [edi]
mov dword [ebp - 0xc], 0xcc8a7df8
add edx, ebx
add dword [ebp - 8], 0x701b6b0c
mov dword [esi], edx
mov dword [ebp - 4], 0x690c5662
add esi, 0xaa2f32e7
add esi, 0x55d0cd1d
add edi, 0x492ffa58
add edi, 0xb6d005ac
loop 0x403321
add eax, 0x70a34e10
sub eax, 0x70a211e9
xor ebx, ebx
add ebx, eax
add eax, 0x1b1d9724
add eax, 0xe4e268e1
mov ecx, 0x3df23305
sub ecx, 0x3db23305
add ecx, dword [ebp - 0x10]
call ebx
leave
ret
Function at 0x2a80c4de
Capabilities:
Check for time delay via gettickcount

Disassembly:
push esi
call dword [sym.imp.kernel32.dll_GetTickCount]
mov esi, eax
shr esi, 4
call dword [sym.imp.kernel32.dll_GetTickCount]
shr eax, 4
sub eax, esi
cmp eax, 0xc
jbe 0x2a80c4ea
pop esi
ret

Function at 0x2a80d252
Capabilities:
Check if file exists

Disassembly:
push 0x64
mov eax, 0x2a84c785
call fcn.2a8015aa
mov ebx, ecx
cmp dword [ebx + 4], 0xffffffff
jne 0x2a80d393
push 0xffffffffffffffff
lea edi, [ebx + 0xc]
push 0x2a853564
mov ecx, edi
call fcn.2a80bdc5
mov eax, dword [ebx]
push 0
push 0xffffffffffffffff
mov esi, dword [eax + 0x10]
mov ecx, esi
call dword [0x2a8523cc]
mov ecx, ebx
call esi
push eax
lea ecx, [ebp - 0x54]
call fcn.2a801558
and dword [ebp - 4], 0
lea eax, [ebp - 0x54]
push eax
mov ecx, edi
call fcn.2a8492f7
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x44]
call fcn.2a803838
lea ecx, [ebp - 0x4c]
call fcn.2a80385d
push edi
lea ecx, [ebp - 0x3c]
call fcn.2a808c68
lea ecx, [ebp - 0x3c]
mov dword [ebp - 4], 1
call fcn.2a849b38
lea eax, [ebp - 0x24]
mov dword [ebp - 4], 2
push eax
call fcn.2a84a405
mov esi, eax
mov dword [ebp - 0x18], vtable.RSSecurityUtilsWin::CLocalFreeGuard.0
pop ecx
mov dword [ebp - 0x14], esi
mov ecx, dword [ebx + 8]
xor edi, edi
mov byte [ebp - 4], 3
cmp dword [ecx], edi
jne 0x2a80d358
lea ecx, [ebp - 0x3c]
call fcn.2a849b38
push edi
push 0x40110000
push 3
lea ecx, [ebp - 0x24]
push ecx
push edi
push 0xc0000000
push eax
call dword [sym.imp.kernel32.dll_CreateFileA]
mov dword [ebx + 4], eax
cmp eax, 0xffffffff
jne 0x2a80d358
call dword [sym.imp.kernel32.dll_GetLastError]
cmp eax, 2
je 0x2a80d3af
cmp eax, 0xe7
jne 0x2a80d399
lea ecx, [ebp - 0x3c]
call fcn.2a849b38
push 0x4e20
push eax
call dword [sym.imp.kernel32.dll_WaitNamedPipeA]
test eax, eax
je 0x2a80d3be
mov eax, dword [ebx + 8]
cmp dword [eax], edi
je 0x2a80d2fe
cmp dword [ebx + 4], 0xffffffff
je 0x2a80d374
push edi
push edi
lea eax, [ebp - 0x10]
mov dword [ebp - 0x10], 2
push eax
push dword [ebx + 4]
call dword [sym.imp.kernel32.dll_SetNamedPipeHandleState]
mov byte [ebp - 4], 6
test esi, esi
je 0x2a80d383
push esi
call dword [sym.imp.kernel32.dll_LocalFree]
lea ecx, [ebp - 0x2c]
call fcn.2a803838
lea ecx, [ebp - 0x34]
call fcn.2a80385d
call fcn.2a80187a
ret
push edi
push 0xffffffffffffffff
push str.Problem_Opening_channel
lea ecx, [ebp - 0x54]
call fcn.2a801558
mov byte [ebp - 4], 4
jmp 0x2a80d3d2
lea ecx, [ebp - 0x70]
call fcn.2a80cfd1
push 0x2a85afe8
jmp 0x2a80d3e3
push edi
push 0xffffffffffffffff
push str.Problem_Opening_channel__all_pipe_instances_are_busy
lea ecx, [ebp - 0x54]
call fcn.2a801558
mov byte [ebp - 4], 5
lea eax, [ebp - 0x54]
push eax
lea ecx, [ebp - 0x70]
call fcn.2a80bdc5
push 0x2a85b040
lea eax, [ebp - 0x70]
push eax
call sub.VCRUNTIME140.dll__CxxThrowException
int3
Function at 0x2a80d67d
Capabilities:
Read file on windows

Disassembly:
push 0x5c
mov eax, 0x2a84c801
call fcn.2a8015aa
mov edi, ecx
xor ebx, ebx
lea eax, [ebp - 0x30]
push 0x14
push ebx
push eax
mov dword [ebp - 0x10], ebx
call sub.VCRUNTIME140.dll_memset
add esp, 0xc
push ebx
push ebx
push 1
push ebx
call dword [sym.imp.kernel32.dll_CreateEventA]
mov esi, eax
mov dword [ebp - 0x14], esi
mov eax, dword [edi + 8]
mov dword [ebp - 0x20], esi
mov dword [ebp - 0x1c], esi
mov dword [ebp - 4], ebx
mov eax, dword [eax + 0x14]
mov dword [ebp - 0x18], eax
cmp esi, 0xffffffff
je 0x2a80d7e9
lea eax, [ebp - 0x30]
push eax
lea eax, [ebp - 0x10]
push eax
push dword [ebp + 0xc]
push dword [ebp + 8]
push dword [edi + 4]
call dword [sym.imp.kernel32.dll_ReadFile]
test eax, eax
jne 0x2a80d7d3
call dword [sym.imp.kernel32.dll_GetLastError]
cmp eax, 0x3e5
je 0x2a80d755
cmp eax, 0x6d
je 0x2a80d783
push ebx
push 0xffffffffffffffff
push str.Read_Error
lea ecx, [ebp - 0x48]
call fcn.2a801558
mov byte [ebp - 4], 4
jmp 0x2a80d7fd
push ebx
push ebx
lea eax, [ebp - 0x1c]
push eax
push 2
call dword [sym.imp.kernel32.dll_WaitForMultipleObjects]
cmp eax, 1
je 0x2a80d767
push ebx
push ebx
push ebx
lea eax, [ebp - 0x4c]
push eax
call dword [sym.imp.USER32.dll_GetMessageA]
test eax, eax
je 0x2a80d755
cmp eax, 0xffffffff
je 0x2a80d792
lea eax, [ebp - 0x4c]
push eax
call dword [sym.imp.USER32.dll_TranslateMessage]
lea eax, [ebp - 0x4c]
push eax
call dword [sym.imp.USER32.dll_DispatchMessageA]
push ebx
push ebx
lea eax, [ebp - 0x1c]
push eax
push 2
call dword [sym.imp.kernel32.dll_WaitForMultipleObjects]
test eax, eax
jne 0x2a80d718
push 0xffffffffffffffff
push ebx
lea eax, [ebp - 0x1c]
push eax
push 2
call dword [sym.imp.kernel32.dll_WaitForMultipleObjects]
sub eax, ebx
je 0x2a80d79b
sub eax, 1
jne 0x2a80d6ca
lea ecx, [ebp - 0x68]
call fcn.2a80ceef
push 0x2a85b05c
jmp 0x2a80d80e
mov dword [ebp - 4], 2
jmp 0x2a80d7da
push 1
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 0x30]
push eax
push dword [edi + 4]
call dword [sym.imp.kernel32.dll_GetOverlappedResult]
test eax, eax
jne 0x2a80d7d3
call dword [sym.imp.kernel32.dll_GetLastError]
cmp eax, 0x6d
je 0x2a80d783
push ebx
push 0xffffffffffffffff
push str.unexpected_error
lea ecx, [ebp - 0x48]
call fcn.2a801558
mov byte [ebp - 4], 3
jmp 0x2a80d7fd
mov dword [ebp - 4], 5
push esi
call dword [sym.imp.kernel32.dll_CloseHandle]
call fcn.2a80187a
ret 8
push ebx
push 0xffffffffffffffff
push str.Failed_to_create_connection
lea ecx, [ebp - 0x48]
call fcn.2a801558
mov byte [ebp - 4], 1
lea eax, [ebp - 0x48]
push eax
lea ecx, [ebp - 0x68]
call fcn.2a80bdc5
push 0x2a85b040
lea eax, [ebp - 0x68]
push eax
call sub.VCRUNTIME140.dll__CxxThrowException
int3
Function at 0x2a80d818
Capabilities:
Read file on windows

Disassembly:
push 0x58
mov eax, 0x2a84c843
call fcn.2a8015aa
mov edi, ecx
xor ebx, ebx
lea eax, [ebp - 0x30]
push 0x14
push ebx
push eax
mov dword [ebp - 0x10], ebx
call sub.VCRUNTIME140.dll_memset
add esp, 0xc
push ebx
push ebx
push 1
push ebx
call dword [sym.imp.kernel32.dll_CreateEventA]
mov esi, eax
mov dword [ebp - 0x14], esi
mov eax, dword [edi + 8]
mov dword [ebp - 0x20], esi
mov dword [ebp - 0x1c], esi
mov dword [ebp - 4], ebx
mov eax, dword [eax + 0x14]
mov dword [ebp - 0x18], eax
cmp esi, 0xffffffff
je 0x2a80d924
lea eax, [ebp - 0x30]
push eax
lea eax, [ebp - 0x10]
push eax
push dword [ebp + 0xc]
push dword [ebp + 8]
push dword [edi + 4]
call dword [sym.imp.kernel32.dll_ReadFile]
test eax, eax
jne 0x2a80d90e
call dword [sym.imp.kernel32.dll_GetLastError]
cmp eax, 0x3e5
jne 0x2a80d8f3
push 0xffffffffffffffff
push ebx
lea eax, [ebp - 0x1c]
push eax
push 2
call dword [sym.imp.kernel32.dll_WaitForMultipleObjects]
sub eax, ebx
je 0x2a80d8bb
sub eax, 1
jne 0x2a80d865
lea ecx, [ebp - 0x64]
call fcn.2a80ceef
push 0x2a85b05c
jmp 0x2a80d949
push 1
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 0x30]
push eax
push dword [edi + 4]
call dword [sym.imp.kernel32.dll_GetOverlappedResult]
test eax, eax
jne 0x2a80d90e
call dword [sym.imp.kernel32.dll_GetLastError]
cmp eax, 0x6d
je 0x2a80d8a9
push ebx
push 0xffffffffffffffff
push str.unexpected_error
lea ecx, [ebp - 0x48]
call fcn.2a801558
mov byte [ebp - 4], 2
jmp 0x2a80d938
cmp eax, 0x6d
je 0x2a80d8a9
push ebx
push 0xffffffffffffffff
push str.Read_Error
lea ecx, [ebp - 0x48]
call fcn.2a801558
mov byte [ebp - 4], 3
jmp 0x2a80d938
push esi
mov dword [ebp - 4], 4
call dword [sym.imp.kernel32.dll_CloseHandle]
call fcn.2a80187a
ret 8
push ebx
push 0xffffffffffffffff
push str.Failed_to_create_connection
lea ecx, [ebp - 0x48]
call fcn.2a801558
mov byte [ebp - 4], 1
lea eax, [ebp - 0x48]
push eax
lea ecx, [ebp - 0x64]
call fcn.2a80bdc5
push 0x2a85b040
lea eax, [ebp - 0x64]
push eax
call sub.VCRUNTIME140.dll__CxxThrowException
int3
Function at 0x2a80d983
Capabilities:
Write file on windows

Disassembly:
push 0x74
mov eax, 0x2a84c87d
call fcn.2a8015aa
mov edi, ecx
cmp dword [edi + 4], 0xffffffff
je 0x2a80dabd
xor ebx, ebx
lea eax, [ebp - 0x30]
push 0x14
push ebx
push eax
mov dword [ebp - 0x10], ebx
call sub.VCRUNTIME140.dll_memset
add esp, 0xc
push ebx
push ebx
push 1
push ebx
call dword [sym.imp.kernel32.dll_CreateEventA]
mov esi, eax
mov dword [ebp - 0x14], esi
mov eax, dword [edi + 8]
mov dword [ebp - 0x20], esi
mov dword [ebp - 0x1c], esi
mov dword [ebp - 4], ebx
mov eax, dword [eax + 0x14]
mov dword [ebp - 0x18], eax
cmp esi, 0xffffffff
jne 0x2a80d9ff
push ebx
push esi
push str.Failed_to_create_connection
lea ecx, [ebp - 0x48]
call fcn.2a801558
lea eax, [ebp - 0x48]
mov byte [ebp - 4], 1
push eax
lea ecx, [ebp - 0x64]
call fcn.2a80bdc5
push 0x2a85b040
jmp 0x2a80daca
lea eax, [ebp - 0x30]
push eax
lea eax, [ebp - 0x10]
push eax
push dword [ebp + 0xc]
push dword [ebp + 8]
push dword [edi + 4]
call dword [sym.imp.kernel32.dll_WriteFile]
test eax, eax
jne 0x2a80da54
call dword [sym.imp.kernel32.dll_GetLastError]
cmp eax, 0x3e5
jne 0x2a80da6a
push 0xffffffffffffffff
push ebx
lea eax, [ebp - 0x1c]
push eax
push 2
call dword [sym.imp.kernel32.dll_WaitForMultipleObjects]
sub eax, ebx
je 0x2a80da41
sub eax, 1
jne 0x2a80d9ff
jmp 0x2a80dabd
push 1
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 0x30]
push eax
push dword [edi + 4]
call dword [sym.imp.kernel32.dll_GetOverlappedResult]
push esi
mov dword [ebp - 4], 3
call dword [sym.imp.kernel32.dll_CloseHandle]
call fcn.2a80187a
ret 8
call dword [sym.imp.kernel32.dll_GetLastError]
cmp eax, 0xe8
je 0x2a80daae
call dword [sym.imp.kernel32.dll_GetLastError]
cmp eax, 0xe9
je 0x2a80daae
push ebx
push 0xffffffffffffffff
push str.Connection_Closed
lea ecx, [ebp - 0x48]
call fcn.2a801558
lea eax, [ebp - 0x48]
mov byte [ebp - 4], 2
push eax
lea ecx, [ebp - 0x80]
call fcn.2a80bdc5
push 0x2a85b040
lea eax, [ebp - 0x80]
jmp 0x2a80dacd
lea ecx, [ebp - 0x80]
call fcn.2a80ceef
push 0x2a85b05c
jmp 0x2a80daa9
lea ecx, [ebp - 0x64]
call fcn.2a80ceef
push 0x2a85b05c
lea eax, [ebp - 0x64]
push eax
call sub.VCRUNTIME140.dll__CxxThrowException
int3