Hybrid cryptography. Length of the data to decrypt is invalid
问题 I am getting above mentioned error during a hybrid cryptography implementation. as per https://en.wikipedia.org/wiki/Hybrid_cryptosystem I am just stucked at the last step My code is private void button1_Click(object sender, EventArgs e) { try { CspParameters cspParams = new CspParameters { ProviderType = 1 }; RSACryptoServiceProvider rsaProvider = new RSACryptoServiceProvider(2048, cspParams); string publicKey =lblPublicKey.Text = Convert.ToBase64String(rsaProvider.ExportCspBlob(false));