Function at 0x409540
Capabilities:
Hash data using sha256
Read file on windows
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x44
push ebx
push esi
push edi
push 1
mov ecx, str.DIGEST_TABLE.bin
call fcn.0040f4a0
add esp, 4
test eax, eax
jne 0x409581
push str.DIGEST_TABLE.bin
push str._s_not_found
push 0x10ee
push str.PrepareDigestTable
push 1
call fcn.00401210
add esp, 0x14
push 1
call fcn.004017c0
mov edi, dword [0x238a86c]
mov eax, dword [0x238a868]
xor ebx, ebx
push ebx
push 0x20
push edi
push eax
mov dword [0x238a790], ebx
mov dword [0x238a794], ebx
call fcn.00421c30
mov ecx, dword [0x238a868]
push ebx
push 0x20
push edi
mov esi, edx
push ecx
mov dword [ebp - 0x30], eax
mov dword [ebp - 0x2c], esi
call fcn.00421ce0
cmp edx, ebx
jl 0x4095d7
jg 0x4095c6
cmp eax, ebx
jbe 0x4095d7
push str.DIGEST_TABLE.bin
push str.Your_DIGEST_TABLE__s_file_is_not_a_multiple_of_32_bytes
push 0x10f9
jmp 0x40956b
mov edi, dword [ebp - 0x30]
push esi
push edi
push str.NumDigestsInFile___lld
push 0x10fd
push str.PrepareDigestTable
push 2
call fcn.00401210
mov eax, dword [0x238a7b8]
mov edx, dword [0x238a7bc]
mov ecx, eax
add esp, 0x18
or ecx, edx
jne 0x40963f
push str.3._In_PrepareDigestTable_AND_MaxNumDigestsPerTable_WAS_ZERO
push 0x1102
push str.PrepareDigestTable
push 4
call fcn.00401210
mov edx, dword [0x3a8659c]
mov eax, dword [0x3a86598]
add esp, 0x10
push ebx
push 0x20
push edx
push eax
call fcn.00421c30
mov dword [0x238a7b8], eax
mov dword [0x238a7bc], edx
sub eax, 1
sbb edx, ebx
mov dword [ebp - 0x38], eax
mov dword [ebp - 0x34], edx
cmp esi, ebx
jl 0x409674
jg 0x409655
cmp edi, 0x36
jb 0x409674
push edx
sub edi, 0x35
push eax
sbb esi, ebx
push esi
push edi
call fcn.00421c30
mov edi, eax
add edi, 1
mov esi, edx
adc esi, ebx
mov dword [ebp - 0x18], edi
mov dword [ebp - 0x14], esi
jmp 0x40967e
mov dword [ebp - 0x18], ebx
mov dword [ebp - 0x14], ebx
mov edi, ebx
mov esi, ebx
mov eax, edi
sub eax, 1
mov ecx, esi
sbb ecx, ebx
mov dword [ebp - 0x3c], ecx
mov dword [ebp - 0x24], ecx
push 0x10
mov edx, 0x42e7e0
mov ecx, str.DIGEST_TABLE.bin
mov dword [ebp - 0x40], eax
mov dword [ebp - 0x28], eax
call fcn.00410f40
add esp, 4
push 0x100000
push ebx
push 0x277b380
mov dword [0x238a77c], eax
call fcn.0041d060
add esp, 0xc
push 0x100000
push ebx
push 0x3b88ec0
call fcn.0041d060
xor eax, eax
add esp, 0xc
mov dword [0x238a7c4], eax
mov dword [0x238a7c8], eax
mov dword [0x238a7cc], eax
mov dword [0x238a7d0], eax
mov dword [0x238a7d4], eax
mov dword [0x238a7d8], eax
mov dword [0x238a7dc], eax
mov dword [0x238a7e0], eax
mov dword [ebp - 0x20], ebx
mov dword [ebp - 0x1c], ebx
cmp esi, ebx
jl 0x4098c2
jg 0x409714
cmp edi, ebx
jbe 0x4098c2
mov esi, 0x277b380
sub esi, 0x20
mov dword [ebp - 4], esi
jmp 0x409726
mov esi, dword [ebp - 4]
xor ebx, ebx
mov ecx, dword [ebp - 0x34]
mov edx, dword [ebp - 0x38]
mov eax, dword [ebp - 0x24]
push ebx
push ecx
mov ecx, dword [ebp - 0x28]
push edx
push eax
push ecx
call fcn.00424b10
add eax, 0x35
adc edx, ebx
shld edx, eax, 5
push edx
mov edx, dword [0x238a77c]
shl eax, 5
push eax
push edx
call fcn.0041935a
mov eax, dword [0x238a77c]
mov ecx, dword [0x3a86598]
push eax
add ecx, 0xffffffe0
push ecx
push 1
push 0x277b380
call fcn.00419c29
mov edx, dword [0x3a86598]
lea edi, [esi + edx]
add esp, 0x20
mov ecx, 8
mov esi, 0x238a7c4
mov dword [0x238a790], eax
mov dword [0x238a794], ebx
rep movsd dword es:[edi], dword [esi]
cmp dword [ebp - 0x1c], ebx
jl 0x4097ae
jg 0x4097a1
cmp dword [ebp - 0x20], ebx
jbe 0x4097ae
add dword [0x238a790], 0x20
adc dword [0x238a794], ebx
mov eax, dword [0x238a77c]
push eax
call fcn.0041809e
mov ecx, dword [0x238a77c]
add esp, 4
push 2
push ebx
push ebx
push ecx
mov esi, eax
mov edi, edx
call fcn.0041935a
mov edx, dword [0x238a77c]
push edx
call fcn.0041809e
add esp, 0x14
cmp esi, eax
jne 0x409800
cmp edi, edx
jne 0x409800
mov eax, dword [0x238a790]
mov byte [eax + 0x277b380], bl
add eax, 1
adc dword [0x238a794], ebx
mov dword [0x238a790], eax
xor eax, eax
cmp eax, 0x3a864e0
je 0x409839
push 0x8c
push ebx
push 0x3a864e0
call fcn.0041d060
mov ecx, 8
mov esi, 0x42bf98
mov edi, 0x3a864e8
rep movsd dword es:[edi], dword [esi]
add esp, 0xc
mov dword [0x3a864e0], ebx
mov dword [0x3a864e4], ebx
mov eax, dword [0x238a790]
cmp eax, ebx
je 0x409859
push 0x3a86528
push 0x3a864e0
mov ecx, 0x277b380
call fcn.00417a60
add esp, 8
mov esi, 0x3a86528
mov ebx, 0x3a864e0
call fcn.00417b60
push esi
mov eax, 0x238a7c4
mov ecx, ebx
call fcn.00417c40
mov eax, dword [ebp - 0x28]
mov edi, eax
shl edi, 5
add edi, 0x3b88ec0
add esp, 4
add eax, 0xffffffff
adc dword [ebp - 0x24], 0xffffffff
add dword [ebp - 0x20], 1
mov dword [ebp - 0x28], eax
mov eax, dword [ebp - 0x1c]
adc eax, 0
mov ecx, 8
mov esi, 0x238a7c4
rep movsd dword es:[edi], dword [esi]
mov dword [ebp - 0x1c], eax
cmp eax, dword [ebp - 0x14]
jl 0x409721
jg 0x4098c0
mov ecx, dword [ebp - 0x18]
cmp dword [ebp - 0x20], ecx
jb 0x409721
xor ebx, ebx
push 0x15
mov edx, 0x42d92c
mov ecx, str.DigestsToSign.bin.mbn
call fcn.00410f40
mov edx, dword [0x238a77c]
add esp, 4
push ebx
push ebx
push ebx
push edx
mov esi, eax
call fcn.0041935a
mov eax, dword [0x238a77c]
push eax
push 0x6a0
push 1
push 0x277b380
call fcn.00419c29
push esi
push 1
lea ecx, [ebp - 0x10]
push 4
push ecx
mov dword [0x238a790], eax
mov dword [0x238a794], ebx
mov dword [ebp - 0x10], 0x1a
mov dword [ebp - 0xc], ebx
call fcn.00419ea9
push esi
push 1
lea edx, [ebp - 0x10]
push 4
push edx
mov dword [ebp - 0x10], 3
mov dword [ebp - 0xc], ebx
call fcn.00419ea9
add esp, 0x40
push esi
push 1
lea eax, [ebp - 0x10]
push 4
push eax
mov dword [ebp - 0x10], 0x28
mov dword [ebp - 0xc], ebx
call fcn.00419ea9
push esi
push 1
lea ecx, [ebp - 0x10]
push 4
push ecx
mov dword [ebp - 0x10], ebx
mov dword [ebp - 0xc], ebx
call fcn.00419ea9
mov edi, dword [ebp - 0x2c]
add esp, 0x20
cmp edi, ebx
jl 0x409986
jg 0x40997a
cmp dword [ebp - 0x30], 0x36
jb 0x409986
mov dword [ebp - 0x10], 0x6c0
mov dword [ebp - 0xc], ebx
jmp 0x40999d
mov edx, dword [ebp - 0x30]
add edx, 1
mov eax, edi
adc eax, ebx
shld eax, edx, 5
shl edx, 5
mov dword [ebp - 0x10], edx
mov dword [ebp - 0xc], eax
push esi
push 1
lea ecx, [ebp - 0x10]
push 4
push ecx
call fcn.00419ea9
push esi
push 1
lea edx, [ebp - 0x10]
push 4
push edx
call fcn.00419ea9
push esi
push 1
lea eax, [ebp - 0x10]
push 4
push eax
mov dword [ebp - 0x10], ebx
mov dword [ebp - 0xc], ebx
call fcn.00419ea9
push esi
push 1
lea ecx, [ebp - 0x10]
push 4
push ecx
mov dword [ebp - 0x10], ebx
mov dword [ebp - 0xc], ebx
call fcn.00419ea9
add esp, 0x40
push esi
push 1
lea edx, [ebp - 0x10]
push 4
push edx
mov dword [ebp - 0x10], ebx
mov dword [ebp - 0xc], ebx
call fcn.00419ea9
push esi
push 1
lea eax, [ebp - 0x10]
push 4
push eax
mov dword [ebp - 0x10], ebx
mov dword [ebp - 0xc], ebx
call fcn.00419ea9
mov ecx, dword [0x238a790]
push esi
push 1
push ecx
push 0x277b380
call fcn.00419ea9
add esp, 0x30
cmp edi, ebx
jg 0x409a42
jl 0x409a2f
cmp dword [ebp - 0x30], 0x36
jae 0x409a42
push 0x100000
push ebx
push 0x3b88ec0
call fcn.0041d060
add esp, 0xc
push esi
push 1
push 0x20
push 0x3b88ec0
call fcn.00419ea9
push esi
call fcn.0041a4c4
add esp, 0x14
push 0x19
mov edx, 0x42d92c
mov ecx, str.ChainedTableOfDigests.bin
call fcn.00410f40
add esp, 4
xor edi, edi
xor esi, esi
mov dword [ebp - 4], eax
cmp dword [ebp - 0x14], ebx
jl 0x409b5d
jg 0x409a90
cmp dword [ebp - 0x18], ebx
jbe 0x409b5d
lea esp, [esp]
mov edx, dword [ebp - 0x34]
mov eax, dword [ebp - 0x38]
push ebx
push edx
push eax
push esi
push edi
call fcn.00424b10
mov ecx, dword [0x238a77c]
add eax, 0x35
adc edx, ebx
shld edx, eax, 5
push edx
shl eax, 5
push eax
push ecx
call fcn.0041935a
push 0x100000
push ebx
push 0x277b380
call fcn.0041d060
mov edx, dword [0x238a77c]
mov eax, dword [0x3a86598]
add esp, 0x1c
push edx
add eax, 0xffffffe0
push eax
push 1
push 0x277b380
call fcn.00419c29
mov ecx, dword [ebp - 4]
push ecx
push 1
push eax
push 0x277b380
mov dword [0x238a790], eax
mov dword [0x238a794], ebx
call fcn.00419ea9
add esp, 0x20
cmp esi, dword [ebp - 0x3c]
jg 0x409b29
jl 0x409b14
cmp edi, dword [ebp - 0x40]
jae 0x409b29
mov edx, dword [ebp - 4]
push edx
mov eax, edi
push 1
shl eax, 5
push 0x20
add eax, 0x3b88ee0
push eax
jmp 0x409b3c
mov ecx, dword [ebp - 4]
push ecx
push 1
push 1
mov byte [0x277b380], bl
push 0x277b380
call fcn.00419ea9
add esp, 0x10
add edi, 1
adc esi, ebx
cmp esi, dword [ebp - 0x14]
jl 0x409a90
jg 0x409b5d
cmp edi, dword [ebp - 0x18]
jb 0x409a90
mov edx, dword [ebp - 4]
push edx
call fcn.0041809e
mov ecx, eax
and ecx, 0x1ff
add esp, 4
or ecx, ebx
jne 0x409bac
mov ecx, dword [0x3a8659c]
push ecx
mov ecx, dword [0x3a86598]
push ecx
push edx
push eax
call fcn.00429070
or eax, edx
je 0x409bac
push str.This_should_not_be_hit._The_Digest_output_file_is_a_multiple_of_512._This_will_cause_the_target_to_hang._Please_re_run_and_add___nop_to_fix_this_issue
push 0x119c
push str.PrepareDigestTable
push 1
call fcn.00401210
add esp, 0x10
jmp 0x40957a
mov edx, dword [ebp - 4]
push edx
call fcn.0041a4c4
mov eax, dword [0x238a77c]
add esp, 4
push eax
call fcn.0041a4c4
add esp, 4
pop edi
pop esi
mov dword [0x238a77c], ebx
pop ebx
mov esp, ebp
pop ebp
ret