Function at 0x404470
Capabilities:
Encode data using base64

Disassembly:
push 0xffffffffffffffff
push 0x4116f9
mov eax, dword fs:[0]
push eax
sub esp, 0x18
push ebx
push ebp
push edi
mov eax, dword [0x4170a0]
xor eax, esp
push eax
lea eax, [esp + 0x28]
mov dword fs:[0], eax
mov eax, dword [esp + 0x38]
xor edi, edi
mov dword [esp + 0x20], edi
mov dword [esi + 0x18], 0xf
mov dword [esi + 0x14], edi
mov dword [esp + 0x24], esi
mov byte [esi + 4], 0
xor ebp, ebp
cmp dword [esp + 0x3c], edi
mov dword [esp + 0x30], edi
mov dword [esp + 0x20], 1
je 0x4047c5
mov cl, byte [eax]
sub dword [esp + 0x3c], 1
mov byte [esp + ebp + 0x10], cl
add ebp, 1
add eax, 1
cmp ebp, 3
mov dword [esp + 0x1c], eax
jne 0x4045f1
mov al, byte [esp + 0x10]
mov dl, al
shr dl, 2
mov cl, al
mov al, byte [esp + 0x11]
and cl, 3
mov byte [esp + 0x14], dl
shl cl, 4
mov dl, al
shr dl, 4
add cl, dl
mov byte [esp + 0x15], cl
mov cl, al
mov al, byte [esp + 0x12]
and cl, 0xf
add cl, cl
mov dl, al
add cl, cl
shr dl, 6
add cl, dl
and al, 0x3f
xor ebp, ebp
mov byte [esp + 0x16], cl
mov byte [esp + 0x17], al
mov dword [esp + 0x18], ebp
movzx edi, byte [esp + ebp + 0x14]
cmp edi, dword [0x418130]
jbe 0x404542
call fcn.00407147
cmp dword [0x418134], 0x10
mov eax, dword [0x418120]
jae 0x404555
mov eax, 0x418120
mov bl, byte [eax + edi]
or eax, 0xffffffff
sub eax, dword [esi + 0x14]
cmp eax, 1
ja 0x404568
call fcn.004068f6
mov edi, dword [esi + 0x14]
add edi, 1
cmp edi, 0xfffffffe
jbe 0x404578
call fcn.004068f6
mov eax, dword [esi + 0x18]
cmp eax, edi
jae 0x4045a0
mov ecx, dword [esi + 0x14]
push ecx
push edi
mov ecx, esi
call fcn.004027d0
test edi, edi
jbe 0x4045d9
cmp dword [esi + 0x18], 0x10
mov ecx, dword [esi + 0x14]
lea ebp, [esi + 4]
jb 0x4045bc
mov eax, dword [ebp]
jmp 0x4045be
test edi, edi
jne 0x40458d
cmp eax, 0x10
mov dword [esi + 0x14], edi
jb 0x4045b4
mov eax, dword [esi + 4]
mov byte [eax], 0
jmp 0x4045d9
lea eax, [esi + 4]
mov byte [eax], 0
jmp 0x4045d9
mov eax, ebp
mov byte [eax + ecx], bl
cmp dword [esi + 0x18], 0x10
mov dword [esi + 0x14], edi
jb 0x4045cf
mov eax, dword [ebp]
jmp 0x4045d1
mov eax, ebp
mov ebp, dword [esp + 0x18]
mov byte [eax + edi], 0
add ebp, 1
cmp ebp, 4
mov dword [esp + 0x18], ebp
jl 0x404530
mov eax, dword [esp + 0x1c]
xor ebp, ebp
xor edi, edi
cmp dword [esp + 0x3c], edi
jne 0x4044ca
cmp ebp, edi
je 0x4047c5
cmp ebp, 3
jge 0x40461f
mov edx, 3
sub edx, ebp
push edx
lea eax, [esp + ebp + 0x14]
push 0x30
push eax
call fcn.004077e0
add esp, 0xc
mov cl, byte [esp + 0x10]
mov al, cl
shr al, 2
mov byte [esp + 0x14], al
mov al, byte [esp + 0x11]
mov dl, al
and cl, 3
shl cl, 4
shr dl, 4
add cl, dl
and al, 0xf
mov byte [esp + 0x15], cl
mov cl, byte [esp + 0x12]
add al, al
mov dl, cl
add al, al
shr dl, 6
add al, dl
mov byte [esp + 0x16], al
and cl, 0x3f
lea eax, [ebp + 1]
cmp eax, edi
mov byte [esp + 0x17], cl
mov dword [esp + 0x10], edi
jle 0x40472d
mov eax, dword [esp + 0x10]
movzx edi, byte [esp + eax + 0x14]
cmp edi, dword [0x418130]
jbe 0x404682
call fcn.00407147
cmp dword [0x418134], 0x10
mov eax, dword [0x418120]
jae 0x404695
mov eax, 0x418120
mov bl, byte [eax + edi]
or ecx, 0xffffffff
sub ecx, dword [esi + 0x14]
cmp ecx, 1
ja 0x4046a8
call fcn.004068f6
mov edi, dword [esi + 0x14]
add edi, 1
cmp edi, 0xfffffffe
jbe 0x4046b8
call fcn.004068f6
mov eax, dword [esi + 0x18]
cmp eax, edi
jae 0x4046e1
mov edx, dword [esi + 0x14]
push edx
push edi
mov ecx, esi
call fcn.004027d0
test edi, edi
jbe 0x404717
mov ecx, dword [esi + 0x14]
mov edx, 0x10
cmp dword [esi + 0x18], edx
jb 0x4046fd
mov eax, dword [esi + 4]
jmp 0x404700
test edi, edi
jne 0x4046cd
cmp eax, 0x10
mov dword [esi + 0x14], edi
jb 0x4046f5
mov eax, dword [esi + 4]
mov byte [eax], 0
jmp 0x404717
lea eax, [esi + 4]
mov byte [eax], 0
jmp 0x404717
lea eax, [esi + 4]
mov byte [eax + ecx], bl
cmp dword [esi + 0x18], edx
mov dword [esi + 0x14], edi
jb 0x404710
mov eax, dword [esi + 4]
jmp 0x404713
lea eax, [esi + 4]
mov byte [eax + edi], 0
mov eax, dword [esp + 0x10]
add eax, 1
lea ecx, [ebp + 1]
cmp eax, ecx
mov dword [esp + 0x10], eax
jl 0x40466c
cmp ebp, 3
jge 0x4047c5
mov ebx, 3
sub ebx, ebp
or eax, 0xffffffff
sub eax, dword [esi + 0x14]
cmp eax, 1
ja 0x40474d
call fcn.004068f6
mov edi, dword [esi + 0x14]
add edi, 1
cmp edi, 0xfffffffe
jbe 0x40475d
call fcn.004068f6
mov eax, dword [esi + 0x18]
cmp eax, edi
jae 0x404788
mov ecx, dword [esi + 0x14]
push ecx
push edi
mov ecx, esi
call fcn.004027d0
test edi, edi
jbe 0x4047bc
mov ecx, dword [esi + 0x14]
mov ebp, 0x10
cmp dword [esi + 0x18], ebp
lea edx, [esi + 4]
jb 0x4047a4
mov eax, dword [edx]
jmp 0x4047a6
test edi, edi
jne 0x404772
cmp eax, 0x10
mov dword [esi + 0x14], edi
jb 0x40479c
mov eax, dword [esi + 4]
mov byte [eax], 0
jmp 0x4047bc
lea eax, [esi + 4]
mov byte [eax], 0
jmp 0x4047bc
mov eax, edx
mov byte [eax + ecx], 0x3d
cmp dword [esi + 0x18], ebp
mov dword [esi + 0x14], edi
jb 0x4047b6
mov eax, dword [edx]
jmp 0x4047b8
mov eax, edx
mov byte [eax + edi], 0
sub ebx, 1
jne 0x40473d
mov eax, esi
mov ecx, dword [esp + 0x28]
mov dword fs:[0], ecx
pop ecx
pop edi
pop ebp
pop ebx
add esp, 0x24
ret