private static RSA CreateRsa(RsaKeyLengths rsaKeyLength) { var rsa = RSA.Create(); rsa.KeySize = (int)rsaKeyLength; return rsa; }