joyce8/EMBER2024-capa huggingface dataset:
Function at 0x10044580
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 0xc]
xor al, al
push edi
xor edi, edi
test esi, esi
je 0x10044647
push ebx
mov ecx, dword [ebp + 8]
mov dl, byte [edi + ecx]
xor dl, al
mov cl, dl
shr cl, 1
mov al, cl
xor al, 0x8c
and dl, 1
movzx ebx, al
movzx eax, cl
cmove ebx, eax
mov cl, bl
shr cl, 1
mov al, cl
xor al, 0x8c
and bl, 1
movzx edx, al
movzx eax, cl
cmove edx, eax
mov cl, dl
shr cl, 1
mov al, cl
xor al, 0x8c
and dl, 1
movzx ebx, al
movzx eax, cl
cmove ebx, eax
mov cl, bl
shr cl, 1
mov al, cl
xor al, 0x8c
and bl, 1
movzx edx, al
movzx eax, cl
cmove edx, eax
mov cl, dl
shr cl, 1
mov al, cl
xor al, 0x8c
and dl, 1
movzx ebx, al
movzx eax, cl
cmove ebx, eax
mov cl, bl
shr cl, 1
mov al, cl
xor al, 0x8c
and bl, 1
movzx edx, al
movzx eax, cl
cmove edx, eax
mov cl, dl
shr cl, 1
mov al, cl
xor al, 0x8c
and dl, 1
movzx ebx, al
movzx eax, cl
cmove ebx, eax
mov cl, bl
shr cl, 1
mov al, cl
movzx ecx, cl
xor al, 0x8c
and bl, 1
movzx eax, al
cmove eax, ecx
inc edi
cmp edi, esi
jb 0x10044595
pop ebx
pop edi
pop esi
pop ebp
ret
Function at 0x10045d40
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x10093743
mov eax, dword fs:[0]
push eax
sub esp, 0x80
mov eax, dword [0x100b7314]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, dword [ebp + 0xc]
mov eax, dword [ebp + 8]
mov dword [ebp - 0x80], eax
mov dword [ebp - 0x8c], 0
mov dword [ebx], 0
mov dword [ebp - 0x88], 0
mov dword [ebp - 0x84], 0
push 0x201
push dword [0x100b8378]
lea ecx, [ebp - 0x8c]
mov dword [ebp - 4], 0
push 0x80000002
call fcn.10045c90
mov edi, dword [ebp - 0x8c]
test eax, eax
jne 0x10045f21
push 0x64
lea eax, [ebp - 0x74]
push 0
push eax
call fcn.10061d90
add esp, 0xc
mov dword [ebp - 0x78], 0x64
lea eax, [ebp - 0x78]
push eax
lea eax, [ebp - 0x74]
push eax
lea eax, [ebp - 0x7c]
push eax
push 0
push 0x1009e58c
push edi
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x10045f21
mov eax, dword [ebp - 0x7c]
cmp eax, 1
je 0x10045e15
cmp eax, 2
jne 0x10045f21
mov ecx, dword [ebp - 0x78]
test ecx, ecx
je 0x10045e36
test cl, 1
jne 0x10045f21
mov eax, ecx
shr eax, 1
cmp word [ebp + eax*2 - 0x76], 0
je 0x10045e3c
jmp 0x10045f21
xor eax, eax
mov word [ebp - 0x74], ax
shr ecx, 1
cmp ecx, 0x2d
jne 0x10045f21
call fcn.100091b0
mov ecx, eax
test ecx, ecx
je 0x10045f4c
mov eax, dword [ecx]
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x78], eax
lea eax, [ebp - 0x74]
mov byte [ebp - 4], 1
push eax
lea ecx, [ebp - 0x78]
call fcn.10043ff0
lea eax, [ebp - 0x7c]
mov dword [ebp - 0x7c], 0
push eax
lea eax, [ebp - 0x20]
push 0x1009e594
push eax
call fcn.100463c0
mov esi, dword [ebp - 0x78]
push 0x2a
push esi
call fcn.10044580
movzx eax, al
add esp, 0x14
cmp dword [ebp - 0x7c], eax
jne 0x10045f05
lea edx, [ebp - 0x74]
lea ecx, [edx + 2]
mov ax, word [edx]
add edx, 2
test ax, ax
jne 0x10045ea6
sub edx, ecx
lea eax, [ebp - 0x74]
mov ecx, dword [ebp - 0x80]
sar edx, 1
push edx
push eax
call fcn.10045f60
push dword [0x100b8380]
lea eax, [ebp - 0x74]
push dword [0x100b837c]
push eax
call dword [sym.imp.SHLWAPI.dll_StrCmpNIW]
test eax, eax
jne 0x10045ee2
mov dword [ebx], 1
mov byte [ebp - 4], 0
add esi, 0xfffffff0
or eax, 0xffffffff
lock xadd dword [esi + 0xc], eax
dec eax
test eax, eax
jg 0x10045efe
mov ecx, dword [esi]
push esi
mov eax, dword [ecx]
call dword [eax + 4]
mov esi, 1
jmp 0x10045f23
mov byte [ebp - 4], 0
add esi, 0xfffffff0
or eax, 0xffffffff
lock xadd dword [esi + 0xc], eax
dec eax
test eax, eax
jg 0x10045f21
mov ecx, dword [esi]
push esi
mov eax, dword [ecx]
call dword [eax + 4]
xor esi, esi
test edi, edi
je 0x10045f2e
push edi
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.1003c735
mov esp, ebp
pop ebp
ret
push 0x80004005
call fcn.10008670
int3
Function at 0x100460c0
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x10093778
mov eax, dword fs:[0]
push eax
sub esp, 0x14
push ebx
push esi
push edi
mov eax, dword [0x100b7314]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x18], 0
push 0x202
push dword [0x100b8378]
lea ecx, [ebp - 0x20]
mov dword [ebp - 4], 0
push 0x80000002
call fcn.10045c90
test eax, eax
je 0x100461e8
mov esi, dword [ebp - 0x18]
mov edi, dword [0x100b8378]
mov dword [ebp - 0x10], 0
test esi, esi
je 0x10046193
cmp dword [esi], 0
je 0x10046186
push 0x1009e440
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
jne 0x10046153
mov eax, 1
jmp 0x100461b4
push str.RegCreateKeyTransactedW
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x1004618c
push 0
push dword [esi]
lea ecx, [ebp - 0x14]
push ecx
lea ecx, [ebp - 0x10]
push ecx
push 0
push 0x20206
push 0
push 0
push 0
push edi
push 0x80000002
call eax
jmp 0x100461b4
cmp dword [esi + 4], 0
jne 0x10046193
mov eax, 1
jmp 0x100461b4
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp - 0x10]
push eax
push 0
push 0x20206
push 0
push 0
push 0
push edi
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
test eax, eax
jne 0x100461de
mov ecx, dword [ebp - 0x20]
test ecx, ecx
je 0x100461c6
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov esi, dword [ebp - 0x10]
mov dword [ebp - 0x20], esi
mov dword [ebp - 0x1c], 0x200
test eax, eax
je 0x100461eb
xor ebx, ebx
jmp 0x1004628f
mov esi, dword [ebp - 0x20]
xor ebx, ebx
jmp 0x1004628f
mov esi, dword [ebp - 0x20]
mov edi, dword [ebp + 0xc]
mov ebx, dword [ebp + 8]
mov eax, dword [edi]
cmp dword [eax - 0xc], 0
je 0x10046248
mov ecx, dword [ebx]
test ecx, ecx
je 0x100462ae
push ecx
push eax
call fcn.1006bcaf
add esp, 8
test eax, eax
je 0x10046248
mov edx, dword [edi]
test edx, edx
je 0x10046248
mov ecx, edx
lea edi, [ecx + 2]
nop dword [eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x10046220
sub ecx, edi
sar ecx, 1
lea eax, [ecx*2 + 2]
push eax
push edx
push 1
push 0
push str.m2_old
push esi
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
mov edx, dword [ebx]
test edx, edx
jne 0x10046253
lea eax, [edx + 0xd]
jmp 0x10046288
mov ecx, edx
lea edi, [ecx + 2]
nop dword [eax + eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x10046260
sub ecx, edi
sar ecx, 1
lea eax, [ecx*2 + 2]
push eax
push edx
push 1
push 0
push 0x1009e58c
push esi
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
xor ebx, ebx
test eax, eax
sete bl
test esi, esi
je 0x1004629a
push esi
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push 0x80004005
call fcn.10008670
int3
Function at 0x100479b0
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, dword [ebp + 0xc]
push edi
mov edi, dword [ebp + 0x10]
mov eax, dword [edi]
add eax, eax
mov dword [edi], 0
mov dword [ebp + 0x10], eax
lea eax, [ebp + 0x10]
push eax
push esi
lea eax, [ebp + 0xc]
push eax
push 0
push dword [ebp + 8]
push dword [ecx]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x10047a21
mov eax, dword [ebp + 0xc]
cmp eax, 1
je 0x100479ef
cmp eax, 2
jne 0x10047a0b
mov ecx, dword [ebp + 0x10]
test esi, esi
je 0x10047a1b
test ecx, ecx
je 0x10047a16
test cl, 1
jne 0x10047a0b
mov eax, ecx
shr eax, 1
cmp word [esi + eax*2 - 2], 0
je 0x10047a1b
pop edi
mov eax, 0xd
pop esi
pop ebp
ret 0xc
xor eax, eax
mov word [esi], ax
shr ecx, 1
xor eax, eax
mov dword [edi], ecx
pop edi
pop esi
pop ebp
ret 0xc
Function at 0x1004b930
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x10093f51
mov eax, dword fs:[0]
push eax
sub esp, 0x20
mov eax, dword [0x100b7314]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, dword [ebp + 8]
mov esi, dword [ebp + 0xc]
mov ebx, dword [ebp + 0x14]
mov dword [ebp - 0x28], edi
mov dword [ebp - 0x24], 0
mov dword [ebp - 4], 1
mov dword [ebp - 0x1c], 0
mov dword [edi], 0
call fcn.100091b0
mov ecx, eax
test ecx, ecx
je 0x1004bac4
mov eax, dword [ecx]
call dword [eax + 0xc]
add eax, 0x10
mov dword [edi], eax
lea eax, [ebp - 0x1c]
mov dword [ebp - 0x24], 1
push eax
push 0xf003f
push 0
push dword [ebp + 0x10]
push esi
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x1004ba85
lea eax, [ebp - 0x14]
xorps xmm0, xmm0
push eax
push 0
lea eax, [ebp - 0x18]
movlpd qword [ebp - 0x18], xmm0
push eax
push 0
push ebx
push dword [ebp - 0x1c]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x1004ba77
mov eax, dword [ebp - 0x14]
test eax, eax
je 0x1004ba85
add eax, 0x10
push 0x100bba60
push eax
mov dword [ebp - 0x20], eax
call fcn.1003c9c3
mov esi, eax
add esp, 8
test esi, esi
je 0x1004ba85
push dword [ebp - 0x20]
push 0
push esi
call fcn.10061d90
add esp, 0xc
lea eax, [ebp - 0x20]
push eax
push esi
push 0
push 0
push ebx
push dword [ebp - 0x1c]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
je 0x1004ba3a
push esi
call fcn.1003c754
add esp, 4
jmp 0x1004ba85
mov ecx, esi
lea edx, [ecx + 2]
nop
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x1004ba40
sub ecx, edx
sar ecx, 1
je 0x1004ba6e
mov ecx, esi
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x1004ba56
sub ecx, edx
sar ecx, 1
push ecx
push esi
mov ecx, edi
call fcn.10010c20
push esi
call fcn.1003c754
add esp, 4
mov eax, dword [ebp - 0x1c]
test eax, eax
je 0x1004ba85
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov esi, dword [ebp + 0x10]
or eax, 0xffffffff
mov byte [ebp - 4], 0
add esi, 0xfffffff0
lock xadd dword [esi + 0xc], eax
dec eax
test eax, eax
jg 0x1004baa4
mov ecx, dword [esi]
push esi
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.1003c735
mov esp, ebp
pop ebp
ret 0x10
push 0x80004005
call fcn.10008670
int3
Function at 0x1004bad0
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
mov eax, dword [0x100b7314]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0x10]
mov ecx, dword [ebp + 8]
push ebx
push esi
push edi
mov edi, dword [ebp + 0x14]
mov esi, edi
mov dword [ebp - 0xc], eax
lea edx, [esi + 2]
mov ax, word [esi]
add esi, 2
test ax, ax
jne 0x1004baf4
lea eax, [ebp - 8]
mov dword [ebp - 8], 0
push eax
push 0xf003f
push 0
push dword [ebp + 0xc]
sub esi, edx
push ecx
sar esi, 1
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
xor ebx, ebx
test eax, eax
sete bl
test eax, eax
jne 0x1004bb56
lea eax, [esi*2 + 2]
push eax
push edi
push 1
push 0
push dword [ebp - 0xc]
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
neg eax
sbb ebx, ebx
mov eax, dword [ebp - 8]
inc ebx
test eax, eax
je 0x1004bb56
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, dword [ebp + 0xc]
or ecx, 0xffffffff
add eax, 0xfffffff0
lock xadd dword [eax + 0xc], ecx
dec ecx
test ecx, ecx
jg 0x1004bb71
mov ecx, dword [eax]
push eax
mov edx, dword [ecx]
call dword [edx + 4]
mov ecx, dword [ebp - 4]
mov eax, ebx
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.1003c735
mov esp, ebp
pop ebp
ret 0x10

Function at 0x1004d9f0
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push dword [ebp + 0x1c]
push dword [ebp + 0x18]
push dword [ebp + 0x14]
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateThread]
pop ebp
ret
Function at 0x1007d993
Capabilities:
Allocate thread local storage

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x100a2e80
push 0x100a2e78
push str.FlsAlloc
push 0x1e
call fcn.1007d7c0
mov esi, eax
add esp, 0x10
test esi, esi
je 0x1007d9c7
push dword [ebp + 8]
mov ecx, esi
call dword [0x100963c4]
call esi
jmp 0x1007d9cd
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
pop esi
pop ebp
ret 4

Function at 0x1007da11
Capabilities:
Get thread local storage value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push esi
push 0x100a2e90
push 0x100a2e88
push str.FlsGetValue
push 0x20
call fcn.1007d7c0
mov esi, eax
add esp, 0x10
test esi, esi
je 0x1007da48
push dword [ebp + 8]
mov ecx, esi
call dword [0x100963c4]
call esi
pop esi
pop ebp
ret 4
pop esi
pop ebp
jmp dword [sym.imp.KERNEL32.dll_TlsGetValue]
Function at 0x1008264c
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 0x100826e9
push ebx
push esi
call fcn.10082615
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.100802cc
add esp, 0x24
mov dword [ebp - 4], eax
test eax, eax
jne 0x10082696
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x100826e8
push edi
push eax
call fcn.1007c44a
mov edi, eax
pop ecx
push ebx
test edi, edi
jne 0x100826b6
call fcn.1007a1db
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
xor eax, eax
jmp 0x100826e7
push ebx
push dword [ebp - 4]
push edi
push dword [ebp - 8]
push esi
push ebx
push ebx
call fcn.100802cc
add esp, 0x20
test eax, eax
jne 0x100826d5
push edi
call fcn.1007a1db
jmp 0x100826dd
push ebx
call fcn.1007a1db
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 0x100826ec
Capabilities:
Query environment variable

Disassembly:
mov edi, edi
push esi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
mov esi, eax
test esi, esi
jne 0x100826fd
pop esi
ret
push ebx
push edi
push esi
call fcn.10082615
mov ebx, eax
sub ebx, esi
and ebx, 0xfffffffe
push ebx
call fcn.1007c44a
mov edi, eax
pop ecx
pop ecx
test edi, edi
je 0x10082725
push ebx
push esi
push edi
call fcn.10061fe0
add esp, 0xc
push 0
call fcn.1007a1db
pop ecx
push esi
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov eax, edi
pop edi
pop ebx
pop esi
ret

Function at 0x10082ae9
Capabilities:
Set environment variable

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
pop ebp
jmp fcn.1008273a
Function at 0x100831b5
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.10083131
mov eax, dword [ebp - 0x2c]
and eax, dword [ebp - 0x28]
cmp eax, 0xffffffff
je 0x1008332d
mov eax, dword [ebp - 0x24]
and eax, dword [ebp - 0x20]
cmp eax, 0xffffffff
je 0x1008332d
mov ecx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 8], ecx
mov dword [ebp - 4], eax
test ecx, ecx
jl 0x100832dc
jg 0x1008320e
test eax, eax
je 0x100832d2
push 1
push 0x1000
call fcn.1007c028
mov esi, eax
pop ecx
pop ecx
test esi, esi
jne 0x10083234
mov eax, dword [ebp + 0x14]
push 0xc
pop edi
mov byte [eax + 0x1c], 1
mov dword [eax + 0x18], edi
jmp 0x100832c9
push 0x8000
push ebx
call fcn.10082c2e
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 0x10083260
jg 0x1008325b
cmp ecx, 0x1000
jb 0x10083260
mov ecx, 0x1000
push edi
push ecx
push esi
push ebx
call fcn.100793dc
add esp, 0x10
cmp eax, 0xffffffff
je 0x100832a5
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 0x1008325b
jl 0x1008328c
test ecx, ecx
jne 0x1008324d
push dword [ebp - 0xc]
push ebx
call fcn.10082c2e
push esi
call fcn.1007a1db
add esp, 0xc
xor edi, edi
jmp 0x1008333e
cmp byte [edi + 0x24], 0
je 0x100832bc
cmp dword [edi + 0x20], 5
jne 0x100832bc
mov byte [edi + 0x1c], 1
mov dword [edi + 0x18], 0xd
cmp byte [edi + 0x1c], 0
je 0x100832c7
mov edi, dword [edi + 0x18]
jmp 0x100832c9
xor edi, edi
push esi
call fcn.1007a1db
pop ecx
jmp 0x1008333e
test ecx, ecx
jg 0x1008329e
jl 0x100832dc
test eax, eax
jae 0x1008329e
push 0
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ebx
call fcn.10078a91
and eax, edx
add esp, 0x10
cmp eax, 0xffffffff
jne 0x100832ff
mov edi, dword [ebp + 0x14]
cmp byte [edi + 0x1c], 0
je 0x1008329e
jmp 0x10083336
push ebx
call fcn.100830c7
pop ecx
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x1008329e
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 0x1008333e
mov edi, dword [ebp + 0x14]
cmp byte [edi + 0x1c], 0
je 0x1008333b
mov edi, dword [edi + 0x18]
jmp 0x1008333e
push 0x16
pop edi
push 0
push dword [ebp - 0x28]
push dword [ebp - 0x2c]
push dword [ebp - 0x14]
call fcn.10078a91
add esp, 0x10
mov eax, edi
pop edi
pop esi
pop ebx
leave
ret
Function at 0x10083358
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 + 0x100bc768]
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 0x10083398
cmp byte [ebx], 0xa
jne 0x10083398
or byte [eax + edi + 0x28], 4
jmp 0x1008339d
and byte [eax + edi + 0x28], 0xfb
add ecx, ebx
mov edx, ebx
mov dword [ebp - 0xc], ecx
mov esi, ebx
cmp ebx, ecx
jae 0x1008349b
mov al, byte [edx]
cmp al, 0x1a
je 0x1008347d
lea ecx, [edx + 1]
mov dword [ebp - 8], ecx
mov ecx, dword [ebp - 0xc]
cmp al, 0xd
je 0x100833cc
mov edx, dword [ebp - 8]
mov byte [esi], al
jmp 0x100833f1
mov eax, dword [ebp - 8]
cmp eax, ecx
jae 0x100833fb
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 0x100833ae
jmp 0x1008349b
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 0x10083478
cmp dword [ebp - 0xc], 0
je 0x10083478
mov ecx, dword [ebp - 0x10]
mov eax, dword [ecx*4 + 0x100bc768]
test byte [eax + edi + 0x28], 0x48
je 0x10083452
mov dl, byte [ebp - 1]
lea eax, [esi + 1]
mov dword [ebp - 0x14], eax
cmp dl, 0xa
jne 0x1008343d
mov byte [esi], dl
jmp 0x1008344e
mov byte [esi], 0xd
mov eax, dword [ecx*4 + 0x100bc768]
mov byte [eax + edi + 0x2a], dl
mov eax, dword [ebp - 0x14]
mov esi, eax
jmp 0x1008349b
cmp byte [ebp - 1], 0xa
jne 0x10083461
cmp esi, ebx
jne 0x10083461
mov byte [esi], 0xa
jmp 0x1008349a
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.10078a91
add esp, 0x10
cmp byte [ebp - 1], 0xa
je 0x1008349b
mov byte [esi], 0xd
jmp 0x1008349a
mov ecx, dword [ebp - 0x10]
mov ecx, dword [ecx*4 + 0x100bc768]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x10083497
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x1008349b
mov byte [esi], 0x1a
inc esi
sub esi, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x100834a4
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 + 0x100bc768]
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 0x100834e7
cmp word [esi], dx
jne 0x100834e7
or byte [edi + eax + 0x28], 4
jmp 0x100834ec
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 0x1008363f
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 0x1008361f
add eax, 2
cmp cx, word [ebp - 0xc]
je 0x1008352e
mov dword [ebp - 4], eax
mov word [esi], cx
jmp 0x10083564
cmp eax, edx
jae 0x10083570
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 0x10083506
jmp 0x1008363f
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 0x1008361b
cmp dword [ebp - 0x14], 0
je 0x1008361b
mov eax, dword [ebx*4 + 0x100bc768]
push 0xa
test byte [edi + eax + 0x28], 0x48
je 0x100835f3
mov dx, word [ebp - 4]
lea eax, [esi + 2]
pop ecx
mov dword [ebp - 0x18], eax
cmp dx, cx
jne 0x100835bc
mov word [esi], cx
jmp 0x100835ef
push 0xd
pop eax
mov word [esi], ax
mov eax, dword [ebx*4 + 0x100bc768]
movzx ecx, dx
shr ecx, 8
push 0xa
mov byte [edi + eax + 0x2a], dl
mov eax, dword [ebx*4 + 0x100bc768]
mov byte [edi + eax + 0x2b], cl
mov eax, dword [ebx*4 + 0x100bc768]
pop ecx
mov byte [edi + eax + 0x2c], cl
mov eax, dword [ebp - 0x18]
mov esi, eax
jmp 0x1008363f
pop ebx
cmp word [ebp - 4], bx
jne 0x10083604
cmp esi, dword [ebp + 0xc]
jne 0x10083604
mov word [esi], bx
jmp 0x1008363c
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.10078a91
add esp, 0x10
cmp word [ebp - 4], bx
je 0x1008363f
push 0xd
jmp 0x10083638
mov ecx, dword [ebx*4 + 0x100bc768]
mov al, byte [ecx + edi + 0x28]
test al, 0x40
jne 0x10083636
or al, 2
mov byte [ecx + edi + 0x28], al
jmp 0x1008363f
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