encrypt challenge for pki auth