private static Track2Sdk.JsonWebKey CreateTrack2SdkJWK(RSA rsa, WebKeyConverterExtraInfo extraInfo = null) { if (rsa == null) { throw new ArgumentNullException("rsa"); } RSAParameters rsaParameters = rsa.ExportParameters(true); var webKey = new Track2Sdk.JsonWebKey(rsa, default, extraInfo?.KeyOps?.Select(op => new Track2Sdk.KeyOperation(op)))
private Track2Sdk.JsonWebKey ConvertToTrack2SdkJsonWebKey(string byokFileName, WebKeyConverterExtraInfo extraInfo = null) { byte[] byokBlob = File.ReadAllBytes(byokFileName); if (byokBlob == null || byokBlob.Length == 0) { throw new ArgumentException(string.Format(KeyVaultProperties.Resources.InvalidKeyBlob, "BYOK")); } return(new Track2Sdk.JsonWebKey(new RSACryptoServiceProvider(), default, extraInfo?.KeyOps?.Select(op => new Track2Sdk.KeyOperation(op)))