Function at 0x4016e0
Capabilities:
Encode data using base64 via winapi

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x415e16
mov eax, dword fs:[0]
push eax
sub esp, 0x90
mov eax, dword [0x41e004]
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 dword [ebp - 0x7c], edx
mov dword [ebp - 0x84], ecx
mov dword [ebp - 0x80], 0
xorps xmm0, xmm0
movq qword [ebp - 0x54], xmm0
mov dword [ebp - 0x4c], 0
mov byte [ebp - 0x75], 0
mov dword [ebp - 0x54], 0
mov dword [ebp - 0x50], 0
mov dword [ebp - 0x4c], 0
mov esi, 0x20
mov dword [ebp - 4], 0
lea edi, [ebp - 0x30]
lea ebx, [esi - 0x18]
nop dword [eax + eax]
lea eax, [ebp - 0x5c]
push eax
call fcn.00407d17
mov eax, dword [ebp - 0x5c]
add esp, 4
mov dword [edi], eax
sub esi, 4
add edi, 4
sub ebx, 1
jne 0x401760
test esi, esi
je 0x4017a1
lea eax, [ebp - 0x5c]
push eax
call fcn.00407d17
mov eax, 4
cmp esi, eax
cmova esi, eax
lea eax, [ebp - 0x5c]
push esi
push eax
push edi
call fcn.00404fb0
add esp, 0x10
mov byte [ebp - 4], 1
xor eax, eax
mov edi, dword [sym.imp.CRYPT32.dll_CryptBinaryToStringW]
mov dword [ebp - 0x5c], eax
mov dword [ebp - 0x74], 0
mov word [ebp - 0x74], ax
lea eax, [ebp - 0x5c]
push eax
push 0
push 0x40000001
push 0x20
lea eax, [ebp - 0x30]
mov dword [ebp - 0x64], 0
push eax
mov dword [ebp - 0x60], 7
mov dword [ebp - 0x80], 1
call edi
test eax, eax
je 0x401836
mov eax, dword [ebp - 0x5c]
add eax, eax
push eax
push 0
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov esi, eax
test esi, esi
je 0x401836
lea eax, [ebp - 0x5c]
push eax
push esi
push 0x40000001
push 0x20
lea eax, [ebp - 0x30]
push eax
call edi
test eax, eax
je 0x40182f
mov ecx, esi
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x401816
sub ecx, edx
sar ecx, 1
push ecx
push esi
lea ecx, [ebp - 0x74]
call fcn.00401e90
push esi
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov ecx, dword [ebp - 0x7c]
lea eax, [ebp - 0x74]
push eax
call fcn.00401e00
mov byte [ebp - 4], 0
mov edx, dword [ebp - 0x60]
cmp edx, 8
jb 0x401880
mov ecx, dword [ebp - 0x74]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x401876
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x401ae0
push edx
push ecx
call fcn.00402768
add esp, 8
mov eax, dword [ebp + 8]
cmp eax, 0xc00
je 0x4018d1
cmp eax, 0x1000
je 0x4018b1
push 0x80
push 0x41e8c0
push 0x80
push 0x41eec8
push 0x100
push 0x41e940
jmp 0x4018ef
push 0x100
push 0x41ec48
push 0x100
push 0x41ef48
push 0x200
push 0x41ea48
jmp 0x4018ef
push 0xc0
push 0x41f048
push 0xc0
push 0x41f108
push 0x180
push 0x41ed48
push ecx
lea ecx, [ebp - 0x54]
call fcn.00401270
add esp, 0x1c
lea eax, [ebp - 0x58]
push 0
push str.Microsoft_Platform_Crypto_Provider
push eax
call dword [sym.imp.ncrypt.dll_NCryptOpenStorageProvider]
mov esi, dword [ebp - 0x54]
test eax, eax
jne 0x401a7c
lea ecx, [ebp - 0x9c]
call fcn.00401350
mov ebx, dword [ebp - 0x84]
mov ecx, ebx
push eax
call fcn.00401e00
mov edx, dword [ebp - 0x88]
cmp edx, 8
jb 0x401970
mov ecx, dword [ebp - 0x9c]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x401966
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x401adb
push edx
push ecx
call fcn.00402768
add esp, 8
cmp dword [ebx + 0x14], 8
mov eax, dword [ebx + 0x10]
mov dword [ebp - 0x3c], 8
mov dword [ebp - 0x38], 0x2b
mov dword [ebp - 0x34], 0x41bf00
lea eax, [eax*2 + 2]
mov dword [ebp - 0x44], 0x2d
mov dword [ebp - 0x48], eax
jb 0x4019a1
mov ebx, dword [ebx]
push 0x480
lea eax, [ebp - 0x48]
mov dword [ebp - 0x40], ebx
mov dword [ebp - 0x60], eax
mov eax, dword [ebp - 0x50]
sub eax, esi
mov dword [ebp - 0x68], 0
push eax
push esi
lea eax, [ebp - 0x5c]
mov dword [ebp - 0x64], 2
push eax
lea eax, [ebp - 0x68]
push eax
push 0x41bf08
push 0
push dword [ebp - 0x58]
call dword [sym.imp.ncrypt.dll_NCryptImportKey]
mov edi, dword [sym.imp.ncrypt.dll_NCryptFreeObject]
test eax, eax
jne 0x401a62
mov eax, dword [ebp - 0x7c]
mov ecx, eax
cmp dword [eax + 0x14], 8
jb 0x4019f3
mov ecx, dword [eax]
mov eax, dword [eax + 0x10]
push 0
lea eax, [eax*2 + 2]
push eax
push ecx
push str.SmartCardPin
push dword [ebp - 0x5c]
call dword [sym.imp.ncrypt.dll_NCryptSetProperty]
test eax, eax
jne 0x401a43
push eax
push dword [ebp - 0x5c]
call dword [sym.imp.ncrypt.dll_NCryptFinalizeKey]
test eax, eax
jne 0x401a3b
push eax
push dword [ebp - 0x5c]
mov byte [ebp - 0x75], 1
call dword [sym.imp.ncrypt.dll_NCryptDeleteKey]
push dword [ebp - 0x5c]
call edi
push dword [ebp - 0x58]
call edi
jmp 0x401a8f
push eax
push str.NCryptFinalizeKey_failed.
jmp 0x401a49
push eax
push str.NCryptSetProperty_PIN_failed.
push str._s._Error:_0x_.8X_n
call fcn.00401010
add esp, 0xc
push dword [ebp - 0x5c]
call edi
push dword [ebp - 0x58]
call edi
jmp 0x401a8f
push eax
push str.NCryptImportKey_failed.
push str._s._Error:_0x_.8X_n
call fcn.00401010
add esp, 0xc
push dword [ebp - 0x58]
call edi
jmp 0x401a8f
push eax
push str.NCryptOpenStorageProvider_failed.
push str._s._Error:_0x_.8X_n
call fcn.00401010
add esp, 0xc
test esi, esi
je 0x401abc
mov ecx, dword [ebp - 0x4c]
mov eax, esi
sub ecx, esi
cmp ecx, 0x1000
jb 0x401ab2
mov esi, dword [esi - 4]
add ecx, 0x23
sub eax, esi
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x401ae0
push ecx
push esi
call fcn.00402768
add esp, 8
mov al, byte [ebp - 0x75]
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.0040272a
mov esp, ebp
pop ebp
ret
call fcn.00407f79
call fcn.00407f79
int3