joyce8/EMBER2024-capa huggingface dataset:
Function at 0x10077400
Capabilities:
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
mov eax, dword [edi + 0x10]
mov ebx, dword [eax]
mov eax, dword [ebp + 0xc]
add eax, 0xfffffffd
cmp eax, 4
ja case.0x1007741d.4
jmp dword [eax*4 + 0x10077634]
lea eax, [edi + 0x15c]
push eax
call fcn.10076dd0
movzx ecx, word [edi + 0x40]
add esp, 4
movzx esi, ax
lea eax, [ecx + 1]
movzx eax, ax
cmp eax, esi
jne 0x1007744d
mov dword [edi + 0x18], 0
jmp 0x10077464
cmp ecx, esi
jne 0x100774d8
push esi
push str.Received_last_DATA_packet_block__d_again._n
push ebx
call fcn.1005af90
add esp, 0xc
mov word [edi + 0x40], si
lea esi, [edi + 0x160]
push 4
push esi
call fcn.10076e30
movzx eax, word [edi + 0x40]
push eax
push esi
call fcn.10076e10
add esp, 0x10
lea eax, [edi + 0xc8]
push dword [edi + 0x148]
push eax
push 0
push 4
push dword [esi]
push dword [edi + 0x14]
call dword [sym.imp.WS2_32.dll_sendto]
test eax, eax
js 0x100775aa
mov eax, dword [edi + 0x154]
xor ecx, ecx
add eax, 4
cmp dword [edi + 0x14c], eax
lea eax, [edi + 0x38]
push eax
setl cl
lea ecx, [ecx*2 + 1]
mov dword [edi], ecx
call fcn.100935c5
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebx
pop ebp
ret
push eax
push esi
push str.Received_unexpected_DATA_packet_block__d__expecting_block__d_n
push ebx
call fcn.1005af90
add esp, 0x10
xor eax, eax
pop edi
pop esi
pop ebx
pop ebp
ret
xor eax, eax
lea esi, [edi + 0x160]
push 4
push esi
mov word [edi + 0x40], ax
mov dword [edi + 0x18], eax
call fcn.10076e30
movzx eax, word [edi + 0x40]
push eax
push esi
call fcn.10076e10
add esp, 0x10
lea eax, [edi + 0xc8]
push dword [edi + 0x148]
push eax
push 0
push 4
push dword [esi]
push dword [edi + 0x14]
call dword [sym.imp.WS2_32.dll_sendto]
test eax, eax
js 0x100775aa
lea eax, [edi + 0x38]
mov dword [edi], 1
push eax
call fcn.100935c5
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebx
pop ebp
ret
movzx eax, word [edi + 0x40]
inc dword [edi + 0x18]
inc eax
push dword [edi + 0x18]
movzx eax, ax
push eax
push str.Timeout_waiting_for_block__d_ACK.__Retries___d_n
push ebx
call fcn.1005af90
mov eax, dword [edi + 0x18]
add esp, 0x10
cmp eax, dword [edi + 0x20]
jle 0x10077586
mov dword [edi + 8], 0xffffff9d
xor eax, eax
mov dword [edi], 3
pop edi
pop esi
pop ebx
pop ebp
ret
push dword [edi + 0x148]
lea eax, [edi + 0xc8]
push eax
push 0
push 4
push dword [edi + 0x160]
push dword [edi + 0x14]
call dword [sym.imp.WS2_32.dll_sendto]
test eax, eax
jns 0x10077610
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push dword [edi + 0x10]
call fcn.10067560
push eax
push 0x1016a53c
push ebx
call fcn.1005aee0
add esp, 0x14
mov eax, 0x37
pop edi
pop esi
pop ebx
pop ebp
ret
lea esi, [edi + 0x160]
push 5
push esi
call fcn.10076e30
movzx eax, word [edi + 0x40]
push eax
push esi
call fcn.10076e10
add esp, 0x10
lea eax, [edi + 0xc8]
push dword [edi + 0x148]
push eax
push 0
push 4
push dword [esi]
push dword [edi + 0x14]
call dword [sym.imp.WS2_32.dll_sendto]
mov dword [edi], 3
pop edi
pop esi
xor eax, eax
pop ebx
pop ebp
ret
push str.tftp_rx:_internal_error
push 0x1016a53c
push ebx
call fcn.1005aee0
add esp, 0xc
mov eax, 0x47
pop edi
pop esi
pop ebx
pop ebp
ret
Function at 0x10077b00
Capabilities:
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
mov ecx, dword [ebp + 8]
mov eax, dword [ecx + 0x10]
mov edx, dword [ecx]
mov eax, dword [eax]
cmp edx, 3
ja case.default.0x10077b12
jmp dword [edx*4 + 0x10077b68]
mov dword [ebp + 8], ecx
pop ebp
jmp fcn.10077650
mov dword [ebp + 8], ecx
pop ebp
jmp fcn.10077400
mov dword [ebp + 8], ecx
pop ebp
jmp fcn.10077d10
push str.TFTP_finished
push 0x10169898
push eax
call fcn.1005af90
add esp, 0xc
xor eax, eax
pop ebp
ret
push str.Internal_state_machine_error
push 0x1016a53c
push eax
call fcn.1005aee0
add esp, 0xc
mov eax, 0x47
pop ebp
ret
Function at 0x1007b4b0
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
pop ebp
jmp fcn.1007b430
Function at 0x1007dc60
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push edi
push 0x10171dc8
xor edi, edi
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov dword [ebp - 4], eax
test eax, eax
jne 0x1007dc80
pop edi
mov esp, ebp
pop ebp
ret
push ebx
push esi
push str.LoadLibraryExA
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov esi, dword [ebp + 8]
mov ebx, eax
push 0x10171de4
push esi
mov dword [ebp - 8], ebx
call fcn.10096b48
add esp, 8
test eax, eax
je 0x1007dccc
test ebx, ebx
je 0x1007dcbc
push 8
push 0
push esi
call ebx
pop esi
mov edi, eax
pop ebx
pop edi
mov esp, ebp
pop ebp
ret
push esi
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
pop esi
mov edi, eax
pop ebx
pop edi
mov esp, ebp
pop ebp
ret
test ebx, ebx
je 0x1007dcf5
push str.AddDllDirectory
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x1007dcf5
push 0x800
push 0
push esi
call ebx
pop esi
mov edi, eax
pop ebx
pop edi
mov esp, ebp
pop ebp
ret
push 0
push 0
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
mov edx, eax
mov dword [ebp - 4], edx
test edx, edx
je 0x1007dda0
mov ecx, esi
lea ebx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x1007dd11
sub ecx, ebx
lea eax, [edx + 1]
add eax, ecx
push eax
call dword [section..data]
mov ebx, eax
add esp, 4
test ebx, ebx
je 0x1007dd96
push dword [ebp - 4]
push ebx
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
test eax, eax
je 0x1007dd96
mov ecx, ebx
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x1007dd42
sub ecx, edx
mov eax, 0x5c
mov word [ecx + ebx], ax
mov ecx, ebx
lea edx, [ecx + 1]
nop dword [eax]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x1007dd60
sub ecx, edx
add ecx, ebx
sub ecx, esi
nop dword [eax]
mov al, byte [esi]
lea esi, [esi + 1]
mov byte [ecx + esi - 1], al
test al, al
jne 0x1007dd70
mov eax, dword [ebp - 8]
test eax, eax
je 0x1007dd8d
push 8
push 0
push ebx
call eax
jmp 0x1007dd94
push ebx
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
push ebx
call dword [0x101c3004]
add esp, 4
pop esi
pop ebx
mov eax, edi
pop edi
mov esp, ebp
pop ebp
ret
Function at 0x1007ea50
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 8]
push edi
mov eax, dword [esi]
cmp dword [eax + 4], 3
jne 0x1007ea7c
mov ecx, dword [esi + 0xc]
test ecx, ecx
jne 0x1007ea6d
pop edi
xor eax, eax
pop esi
pop ebp
ret
push dword [eax + 8]
push dword [ebp + 0x10]
push 1
push dword [ebp + 0xc]
call ecx
jmp 0x1007eab0
cmp dword [esi + 8], 0
jne 0x1007eaa0
push 0x10169b18
push dword [eax + 8]
call fcn.1008d70e
add esp, 8
mov dword [esi + 8], eax
test eax, eax
jne 0x1007eaa0
pop edi
or eax, 0xffffffff
pop esi
pop ebp
ret
push dword [esi + 8]
push dword [ebp + 0x10]
push 1
push dword [ebp + 0xc]
call fcn.100938b6
mov edi, eax
add esp, 0x10
test edi, edi
jne 0x1007ead2
mov eax, dword [esi + 8]
test eax, eax
je 0x1007eacc
push eax
call fcn.1008d47d
add esp, 4
mov dword [esi + 8], edi
mov eax, dword [esi]
mov eax, dword [eax]
mov dword [esi], eax
mov eax, edi
pop edi
pop esi
pop ebp
ret

Function at 0x10081ef0
Capabilities:
Get hostname

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 0xc]
push edi
mov edi, dword [ebp + 8]
push esi
push edi
mov byte [edi], 0
call dword [sym.imp.WS2_32.dll_gethostname]
mov byte [edi + esi - 1], 0
test eax, eax
jne 0x10081f23
push 0x2e
push edi
call fcn.100865f0
add esp, 8
test eax, eax
je 0x10081f21
mov byte [eax], 0
xor eax, eax
pop edi
pop esi
pop ebp
ret
Function at 0x10084300
Capabilities:
Authenticate hmac
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push esi
mov esi, dword [ebp + 8]
push edi
mov ecx, dword [esi + 0xc]
mov eax, dword [esi + 0x14]
lea eax, [eax + ecx*2]
add eax, 0xc
push eax
call dword [section..data]
mov edi, eax
add esp, 4
test edi, edi
jne 0x1008432d
pop edi
pop esi
mov esp, ebp
pop ebp
ret
lea ecx, [edi + 0xc]
mov dword [edi], esi
mov dword [edi + 4], ecx
mov eax, dword [esi + 0xc]
add eax, ecx
push ebx
mov ebx, dword [ebp + 0x10]
mov dword [edi + 8], eax
cmp ebx, dword [esi + 0x10]
jbe 0x10084374
mov eax, dword [esi]
push ecx
call eax
mov eax, dword [esi + 4]
push ebx
push dword [ebp + 0xc]
push dword [edi + 4]
call eax
mov eax, dword [edi + 8]
add eax, dword [esi + 0xc]
push dword [edi + 4]
mov dword [ebp - 4], eax
push eax
mov eax, dword [esi + 8]
call eax
mov ebx, dword [esi + 0x14]
add esp, 0x18
mov dword [ebp + 0x10], ebx
jmp 0x1008437a
mov eax, dword [ebp + 0xc]
mov dword [ebp - 4], eax
push dword [edi + 4]
mov eax, dword [esi]
call eax
push dword [edi + 8]
mov eax, dword [esi]
call eax
mov eax, dword [ebp + 0x10]
add esp, 8
xor ebx, ebx
test eax, eax
je 0x100843db
mov ebx, dword [ebp - 4]
mov dword [ebp - 8], eax
nop word [eax + eax]
movzx eax, byte [ebx]
xor al, 0x36
mov byte [ebp + 0xb], al
lea eax, [ebp + 0xb]
push 1
push eax
push dword [edi + 4]
mov eax, dword [esi + 4]
call eax
movzx eax, byte [ebx]
lea ebx, [ebx + 1]
xor al, 0x5c
mov byte [ebp + 0xb], al
lea eax, [ebp + 0xb]
push 1
push eax
push dword [edi + 8]
mov eax, dword [esi + 4]
call eax
add esp, 0x18
sub dword [ebp + 0x10], 1
jne 0x100843a0
mov ebx, dword [ebp - 8]
cmp ebx, dword [esi + 0x10]
jae 0x10084407
mov eax, dword [esi + 4]
push 1
push 0x101727ce
push dword [edi + 4]
call eax
mov eax, dword [esi + 4]
push 1
push 0x101727cf
push dword [edi + 8]
call eax
inc ebx
add esp, 0x18
cmp ebx, dword [esi + 0x10]
jb 0x100843e0
pop ebx
mov eax, edi
pop edi
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x100940b1
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, 0x101c
call fcn.10084f50
mov eax, dword [0x101c3080]
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.1009d709
pop ecx
mov ecx, dword [ebp + 8]
mov ebx, eax
cmp dword [ecx + 8], 0
jne 0x100940f3
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
jmp 0x1009424f
mov eax, dword [ecx]
sub eax, dword [ecx + 4]
push esi
push edi
push 0
cdq
push 2
push edx
push eax
call fcn.10084910
push dword [ebp - 0x100c]
mov ecx, ebx
mov dword [ebp - 0x1008], eax
mov esi, ebx
mov dword [ebp - 0x1018], edx
and ecx, 0x3f
sar esi, 6
imul edi, ecx, 0x38
push 0
mov eax, dword [esi*4 + 0x101cc1b0]
push dword [eax + edi + 0x24]
push dword [eax + edi + 0x20]
push ebx
call fcn.100957be
mov ecx, dword [esi*4 + 0x101cc1b0]
add esp, 0x14
mov dword [ebp - 0x1010], eax
mov eax, edx
mov edx, dword [ebp - 0x1010]
mov dword [ebp - 0x101c], eax
cmp edx, dword [ecx + edi + 0x20]
jne 0x10094248
cmp eax, dword [ecx + edi + 0x24]
jne 0x10094248
push 0
lea eax, [ebp - 0x1014]
push eax
push 0x1000
lea eax, [ebp - 0x1004]
push eax
push dword [ecx + edi + 0x18]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x10094248
push dword [ebp - 0x100c]
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.100957be
add esp, 0x14
test edx, edx
jl 0x10094248
jg 0x100941be
test eax, eax
jb 0x10094248
mov ebx, dword [ebp - 0x1018]
mov eax, dword [ebp - 0x1014]
test ebx, ebx
jg 0x10094248
jl 0x100941d8
cmp dword [ebp - 0x1008], eax
ja 0x10094248
lea edi, [ebp - 0x1004]
xor edx, edx
add edi, eax
lea ecx, [ebp - 0x1004]
xor esi, esi
cmp dword [ebp - 0x1008], edx
jne 0x100941f6
test ebx, ebx
je 0x1009422f
cmp ecx, edi
jae 0x1009422f
mov al, byte [ecx]
cmp al, 0xd
jne 0x10094210
lea eax, [edi - 1]
cmp ecx, eax
jae 0x1009421c
cmp byte [ecx + 1], 0xa
jne 0x1009421c
inc ecx
jmp 0x1009421c
movzx eax, al
movsx eax, byte [eax + 0x101c3248]
add ecx, eax
add esi, 1
adc edx, 0
inc ecx
cmp esi, dword [ebp - 0x1008]
jne 0x100941f6
cmp edx, ebx
jne 0x100941f6
lea eax, [ebp - 0x1004]
sub ecx, eax
mov eax, ecx
cdq
add eax, dword [ebp - 0x1010]
adc edx, dword [ebp - 0x101c]
jmp 0x1009424d
or edx, 0xffffffff
mov eax, edx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop ebx
call fcn.10084565
leave
ret
Function at 0x100967cb
Capabilities:
Get disk information

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x210
mov eax, dword [0x101c3080]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [ebp + 8]
push 0x10175374
push esi
call fcn.1009eb32
pop ecx
pop ecx
test eax, eax
jne 0x100967f9
xor al, al
jmp 0x10096876
push ebx
lea eax, [ebp - 0x210]
xor ebx, ebx
push eax
push 0x104
lea eax, [ebp - 0x20c]
mov dword [ebp - 0x210], ebx
push esi
push eax
call fcn.100964cd
mov edx, eax
add esp, 0x10
test edx, edx
jne 0x10096833
push dword [ebp - 0x210]
call fcn.1008d01d
xor al, al
jmp 0x10096874
mov ecx, edx
push edi
lea edi, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
cmp ax, bx
jne 0x10096839
sub ecx, edi
sar ecx, 1
pop edi
cmp ecx, 3
je 0x10096859
push edx
call fcn.10096702
pop ecx
test al, al
je 0x10096824
push esi
call dword [sym.imp.KERNEL32.dll_GetDriveTypeW]
cmp eax, 1
jbe 0x10096867
mov bl, 1
push dword [ebp - 0x210]
call fcn.1008d01d
mov al, bl
pop ecx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.10084565
leave
ret

Function at 0x10097d45
Capabilities:
Parse pe header

Disassembly:
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
je 0x10097d84
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x10097d84
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x10097d84
mov eax, 0x10b
cmp word [ecx + 0x18], ax
jne 0x10097d84
cmp dword [ecx + 0x74], 0xe
jbe 0x10097d84
cmp dword [ecx + 0xe8], 0
setne al
ret
xor al, al
ret
Function at 0x10098b8b
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x18
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 + 0x101cc1b0]
mov dword [ebp - 0xc], ecx
mov ecx, dword [edi + eax + 0x18]
mov dword [ebp - 0x14], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x10098bcb
cmp byte [ebx], 0xa
jne 0x10098bcb
or byte [edi + eax + 0x28], 4
jmp 0x10098bd0
and byte [edi + eax + 0x28], 0xfb
add ecx, ebx
mov eax, ebx
mov dword [ebp - 0x10], ecx
mov esi, ebx
mov dword [ebp - 8], eax
cmp ebx, ecx
jae 0x10098ccf
mov dl, byte [eax]
cmp dl, 0x1a
je 0x10098cb2
inc eax
cmp dl, 0xd
je 0x10098bfc
mov dword [ebp - 8], eax
mov byte [esi], dl
jmp 0x10098c22
cmp eax, ecx
jae 0x10098c30
mov cl, byte [eax]
xor eax, eax
cmp cl, 0xa
sete al
inc eax
add dword [ebp - 8], eax
cmp cl, 0xa
sete al
dec al
and al, 3
add al, 0xa
mov byte [esi], al
mov eax, dword [ebp - 8]
mov ecx, dword [ebp - 0x10]
xor edx, edx
inc edx
add esi, edx
cmp eax, ecx
jb 0x10098be4
jmp 0x10098ccf
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 0x10098cad
cmp dword [ebp - 0x10], 0
je 0x10098cad
mov ecx, dword [ebp - 0xc]
mov eax, dword [ecx*4 + 0x101cc1b0]
test byte [eax + edi + 0x28], 0x48
je 0x10098c87
mov dl, byte [ebp - 1]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
cmp dl, 0xa
jne 0x10098c72
mov byte [esi], dl
jmp 0x10098c83
mov byte [esi], 0xd
mov eax, dword [ecx*4 + 0x101cc1b0]
mov byte [eax + edi + 0x2a], dl
mov eax, dword [ebp - 0x14]
mov esi, eax
jmp 0x10098ccf
cmp byte [ebp - 1], 0xa
jne 0x10098c96
cmp esi, ebx
jne 0x10098c96
mov byte [esi], 0xa
jmp 0x10098cce
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.100957dc
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x10098ccf
mov byte [esi], 0xd
jmp 0x10098cce
mov ecx, dword [ebp - 0xc]
mov ecx, dword [ecx*4 + 0x101cc1b0]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x10098ccc
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x10098ccf
mov byte [esi], dl
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x10098cd8
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x1c
mov eax, dword [ebp + 8]
mov ecx, eax
push ebx
mov ebx, dword [ebp + 0xc]
and eax, 0x3f
push esi
sar ecx, 6
push edi
imul edi, eax, 0x38
mov dword [ebp - 8], ecx
mov eax, dword [ecx*4 + 0x101cc1b0]
push 0xa
pop edx
mov dword [ebp - 0x18], edx
mov ecx, dword [eax + edi + 0x18]
mov dword [ebp - 0x1c], ecx
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x10098d1e
cmp word [ebx], dx
jne 0x10098d1e
or byte [eax + edi + 0x28], 4
jmp 0x10098d23
and byte [eax + edi + 0x28], 0xfb
lea edx, [ebx + ecx*2]
mov eax, ebx
mov dword [ebp - 0xc], edx
mov esi, ebx
mov dword [ebp - 4], eax
cmp ebx, edx
jae 0x10098e86
mov dword [ebp - 0x10], 0xd
movzx ecx, word [eax]
mov edx, ecx
mov dword [ebp - 0x14], edx
mov edx, dword [ebp - 0xc]
cmp ecx, 0x1a
je 0x10098e66
add eax, 2
cmp cx, word [ebp - 0x10]
je 0x10098d64
mov dword [ebp - 4], eax
mov word [esi], cx
jmp 0x10098d9a
cmp eax, edx
jae 0x10098da8
movzx eax, word [eax]
xor ecx, ecx
cmp ax, word [ebp - 0x18]
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 - 0xc]
sete al
dec eax
and eax, 3
add eax, ecx
mov word [esi], ax
mov eax, dword [ebp - 4]
push 2
pop ecx
add esi, ecx
cmp eax, edx
jb 0x10098d3f
jmp 0x10098e86
push 0
lea eax, [ebp - 0x18]
push eax
push 2
lea eax, [ebp - 4]
push eax
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x10098e61
cmp dword [ebp - 0x18], 0
je 0x10098e61
mov edx, dword [ebp - 8]
push 0xa
mov eax, dword [edx*4 + 0x101cc1b0]
test byte [eax + edi + 0x28], 0x48
je 0x10098e37
lea eax, [esi + 2]
mov dword [ebp - 0x1c], eax
mov ax, word [ebp - 4]
pop ecx
mov word [ebp - 2], ax
cmp ax, cx
jne 0x10098dfb
mov word [esi], cx
jmp 0x10098e32
push 0xd
pop ecx
mov word [esi], cx
movzx ecx, ax
mov eax, dword [edx*4 + 0x101cc1b0]
mov dx, word [ebp - 2]
shr ecx, 8
push 0xa
mov byte [eax + edi + 0x2a], dl
mov edx, dword [ebp - 8]
mov eax, dword [edx*4 + 0x101cc1b0]
mov byte [eax + edi + 0x2b], cl
mov eax, dword [edx*4 + 0x101cc1b0]
pop ecx
mov byte [eax + edi + 0x2c], cl
mov esi, dword [ebp - 0x1c]
jmp 0x10098e86
pop eax
cmp word [ebp - 4], ax
jne 0x10098e47
cmp esi, ebx
jne 0x10098e47
mov word [esi], ax
jmp 0x10098e83
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.100957dc
add esp, 0x10
push 0xa
pop eax
cmp word [ebp - 4], ax
je 0x10098e86
push 0xd
pop eax
jmp 0x10098e42
mov edx, dword [ebp - 8]
mov edx, dword [edx*4 + 0x101cc1b0]
mov al, byte [edx + edi + 0x28]
test al, 0x40
jne 0x10098e80
or al, 2
mov byte [edx + edi + 0x28], al
jmp 0x10098e86
mov word [esi], cx
add esi, 2
sub esi, ebx
and esi, 0xfffffffe
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x1009c25b
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x1017698c
push 0x10176984
push str.FlsAlloc
push 0x1f
call fcn.1009c0da
mov esi, eax
add esp, 0x10
test esi, esi
je 0x1009c28f
push dword [ebp + 8]
mov ecx, esi
call dword [0x10169334]
call esi
jmp 0x1009c295
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x1009c2d9
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x1017699c
push 0x10176994
push str.FlsGetValue
push 0x21
call fcn.1009c0da
mov esi, eax
add esp, 0x10
test esi, esi
je 0x1009c310
push dword [ebp + 8]
mov ecx, esi
call dword [0x10169334]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]

Function at 0x1009c318
Capabilities:
Set thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x101769a4
push 0x1017699c
push str.FlsSetValue
push 0x22
call fcn.1009c0da
mov esi, eax
add esp, 0x10
test esi, esi
je 0x1009c352
push dword [ebp + 0xc]
mov ecx, esi
push dword [ebp + 8]
call dword [0x10169334]
call esi
pop esi
pop ebp
ret 8
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsSetValue]
Function at 0x100a1492
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 0x100a152f
push ebx
push esi
call fcn.100a145b
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.1009f99f
add esp, 0x24
mov dword [ebp - 4], eax
test eax, eax
jne 0x100a14dc
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x100a152e
push edi
push eax
call fcn.1009c88d
mov edi, eax
pop ecx
push ebx
test edi, edi
jne 0x100a14fc
call fcn.1009bf6a
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x100a152d
push ebx
push dword [ebp - 4]
push edi
push dword [ebp - 8]
push esi
push ebx
push ebx
call fcn.1009f99f
add esp, 0x20
test eax, eax
jne 0x100a151b
push edi
call fcn.1009bf6a
jmp 0x100a1523
push ebx
call fcn.1009bf6a
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 0x100a1532
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push esi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
mov esi, eax
test esi, esi
jne 0x100a1543
pop esi
ret
push ebx
push edi
push esi
call fcn.100a145b
mov ebx, eax
sub ebx, esi
and ebx, 0xfffffffe
push ebx
call fcn.1009c88d
mov edi, eax
pop ecx
pop ecx
test edi, edi
je 0x100a156b
push ebx
push esi
push edi
call fcn.10086070
add esp, 0xc
push 0
call fcn.1009bf6a
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov eax, edi
pop edi
pop ebx
pop esi
ret

Function at 0x100a1cc5
Capabilities:
Set environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.100a17e0
Function at 0x100a2290
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.100a220c
mov eax, dword [ebp - 0x2c]
and eax, dword [ebp - 0x28]
cmp eax, 0xffffffff
je 0x100a23ff
mov eax, dword [ebp - 0x24]
and eax, dword [ebp - 0x20]
cmp eax, 0xffffffff
je 0x100a23ff
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 8], ecx
mov dword [ebp - 4], eax
test ecx, ecx
jl 0x100a23b4
jg 0x100a22ec
test eax, eax
je 0x100a23aa
push 1
push 0x1000
call fcn.1009b524
mov esi, eax
pop ecx
pop ecx
test esi, esi
jne 0x100a230f
push 0xc
pop ebx
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], ebx
jmp 0x100a23a1
push 0x8000
push ebx
call fcn.100a213d
pop ecx
pop ecx
mov ecx, dword [ebp - 0x1c]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0x18]
test eax, eax
jl 0x100a2338
jg 0x100a2333
cmp ecx, 0x1000
jb 0x100a2338
mov ecx, 0x1000
push edi
push ecx
push esi
push ebx
call fcn.10099df5
add esp, 0x10
cmp eax, 0xffffffff
je 0x100a237d
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 0x100a2333
jl 0x100a2364
test ecx, ecx
jne 0x100a2325
push dword [ebp - 0xc]
push ebx
call fcn.100a213d
push esi
call fcn.1009bf6a
add esp, 0xc
xor ebx, ebx
jmp 0x100a240d
cmp byte [edi + 0x24], 0
je 0x100a2394
cmp dword [edi + 0x20], 5
jne 0x100a2394
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], 0xd
cmp byte [edi + 0x1c], 0
je 0x100a239f
mov ebx, dword [edi + 0x18]
jmp 0x100a23a1
xor ebx, ebx
push esi
call fcn.1009bf6a
pop ecx
jmp 0x100a240d
test ecx, ecx
jg 0x100a2376
jl 0x100a23b4
test eax, eax
jae 0x100a2376
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.100957dc
and eax, edx
add esp, 0x10
cmp eax, 0xffffffff
jne 0x100a23d4
cmp byte [edi + 0x1c], 0
je 0x100a2376
jmp 0x100a2405
push ebx
call fcn.1009e77d
pop ecx
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x100a2376
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 0x100a240d
cmp byte [edi + 0x1c], 0
je 0x100a240a
mov ebx, dword [edi + 0x18]
jmp 0x100a240d
push 0x16
pop ebx
push 0
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
push dword [ebp - 0x14]
call fcn.100957dc
add esp, 0x10
mov eax, ebx
pop edi
pop esi
pop ebx
leave
ret