AESで暗号化された公開鍵/秘密鍵を作成する方法を理解しようとしています。私はそれを次のように使用できるようにしたいと思います:
byte[] BytesToEncrypt = { 0x01, 0x02, 0x03, 0x04, 0x05 };
byte[] PublicKey;
byte[] PrivateKey;
byte[] EncryptedBytes;
byte[] UnencryptedBytes;
PrivateKey = CreatePrivateKey();
PublicKey = CreatePublicKey(PrivateKey);
EncryptedBytes = EncryptBytes(PrivateKey);
// This line should return unencrypted bytes
UnencryptedBytes = UnencryptBytes(EncryptedBytes, PrivateKey);
// This line should also return the unencrypted bytes
UnencryptedBytes = UnencryptBytes(EncryptedBytes, PublicKey);
どうすればこのようなものを実装できますか?パブリック/プライベート暗号化を見てきましたが、私が見たすべての例はRSA暗号化を使用しているようです。AESを使いたい。これは可能ですか?