Function at 0x4202b0
Capabilities:
Encrypt or decrypt data via bcrypt

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x44
mov eax, dword [0x4e500c]
xor eax, ebp
mov dword [ebp - 4], eax
mov dword [ebp - 0x2c], 0
mov dword [ebp - 0x28], 0
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x44], 0
mov dword [ebp - 0x24], 0
mov dword [ebp - 0x40], 0
mov dword [ebp - 0x38], 0
mov dword [ebp - 0x1c], 0
mov dword [ebp - 8], 0
mov dword [ebp - 0x34], 0
mov dword [ebp - 0x30], 0xc00000e5
mov dword [ebp - 0x3c], 0
push 0
push 0x4e5db8
push 0x4e5db0
lea eax, [ebp - 0x18]
push eax
call dword [sym.imp.bcrypt.dll_BCryptOpenAlgorithmProvider]
mov dword [ebp - 0x30], eax
cmp dword [ebp - 0x30], 0
jge 0x42033f
jmp 0x4204be
push 0
lea ecx, [ebp - 8]
push ecx
push 4
lea edx, [ebp - 0x24]
push edx
push str.ObjectLength
mov eax, dword [ebp - 0x18]
push eax
call dword [sym.imp.bcrypt.dll_BCryptGetProperty]
mov dword [ebp - 0x30], eax
cmp dword [ebp - 0x30], 0
jge 0x420368
jmp 0x4204be
push 0
lea ecx, [ebp - 8]
push ecx
push 4
lea edx, [ebp - 0x1c]
push edx
push str.BlockLength
mov eax, dword [ebp - 0x18]
push eax
call dword [sym.imp.bcrypt.dll_BCryptGetProperty]
mov dword [ebp - 0x30], eax
cmp dword [ebp - 0x30], 0
jge 0x420391
jmp 0x4204be
push 0
lea ecx, [ebp - 8]
push ecx
push 0xc
lea edx, [ebp - 0x14]
push edx
push str.KeyLengths
mov eax, dword [ebp - 0x18]
push eax
call dword [sym.imp.bcrypt.dll_BCryptGetProperty]
mov dword [ebp - 0x30], eax
cmp dword [ebp - 0x30], 0
jge 0x4203ba
jmp 0x4204be
mov ecx, dword [ebp - 0x24]
push ecx
lea edx, [ebp - 0x2c]
push edx
call fcn.00420e40
add esp, 8
mov dword [ebp - 0x44], eax
cmp dword [ebp - 0x44], 0
jne 0x4203df
mov dword [ebp - 0x30], 0xc0000017
jmp 0x4204be
mov eax, dword [ebp - 0x1c]
push eax
lea ecx, [ebp - 0x28]
push ecx
call fcn.00420e40
add esp, 8
mov dword [ebp - 0x38], eax
cmp dword [ebp - 0x38], 0
jne 0x420404
mov dword [ebp - 0x30], 0xc0000017
jmp 0x4204be
mov edx, dword [ebp - 0x10]
shr edx, 3
mov dword [ebp - 0x40], edx
mov eax, dword [ebp + 0xc]
cmp eax, dword [ebp - 0x40]
jae 0x420421
mov dword [ebp - 0x30], 0xc0000023
jmp 0x4204be
push 0
mov ecx, dword [ebp - 0x40]
push ecx
mov edx, dword [ebp + 8]
push edx
mov eax, dword [ebp - 0x24]
push eax
mov ecx, dword [ebp - 0x44]
push ecx
lea edx, [ebp - 0x20]
push edx
mov eax, dword [ebp - 0x18]
push eax
call dword [sym.imp.bcrypt.dll_BCryptGenerateSymmetricKey]
mov dword [ebp - 0x30], eax
cmp dword [ebp - 0x30], 0
jge 0x42044c
jmp 0x4204be
mov dword [ebp - 0x34], 0
jmp 0x42045e
mov ecx, dword [ebp - 0x34]
add ecx, 1
mov dword [ebp - 0x34], ecx
mov edx, dword [ebp - 0x34]
cmp edx, dword [ebp - 0x1c]
jae 0x420473
mov eax, dword [ebp - 0x38]
add eax, dword [ebp - 0x34]
mov cl, byte [ebp - 0x34]
mov byte [eax], cl
jmp 0x420455
push 0
lea edx, [ebp - 8]
push edx
mov eax, dword [ebp + 0x1c]
push eax
mov ecx, dword [ebp + 0x18]
push ecx
mov edx, dword [ebp - 0x1c]
push edx
mov eax, dword [ebp - 0x38]
push eax
push 0
mov ecx, dword [ebp + 0x14]
push ecx
mov edx, dword [ebp + 0x10]
push edx
mov eax, dword [ebp - 0x20]
push eax
call dword [sym.imp.bcrypt.dll_BCryptEncrypt]
mov dword [ebp - 0x30], eax
cmp dword [ebp - 0x30], 0
jge 0x4204a8
jmp 0x4204be
cmp dword [ebp + 0x20], 0
je 0x4204b6
mov ecx, dword [ebp + 0x20]
mov edx, dword [ebp - 8]
mov dword [ecx], edx
xor eax, eax
jne 0x42031b
cmp dword [ebp - 0x20], 0
je 0x4204d1
mov ecx, dword [ebp - 0x20]
push ecx
call dword [sym.imp.bcrypt.dll_BCryptDestroyKey]
mov dword [ebp - 0x3c], eax
cmp dword [ebp - 0x28], 0
je 0x4204e3
mov edx, dword [ebp - 0x28]
push edx
call fcn.00420e80
add esp, 4
cmp dword [ebp - 0x2c], 0
je 0x4204f5
mov eax, dword [ebp - 0x2c]
push eax
call fcn.00420e80
add esp, 4
cmp dword [ebp - 0x18], 0
je 0x42050a
push 0
mov ecx, dword [ebp - 0x18]
push ecx
call dword [sym.imp.bcrypt.dll_BCryptCloseAlgorithmProvider]
mov dword [ebp - 0x3c], eax
mov eax, dword [ebp - 0x30]
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0043a792
mov esp, ebp
pop ebp
ret