When I tried other 'key' strings I got error(s).
What I read from here:
https://stackoverflow.com/questions/2919...-algorithm
The AES key can only be 128, 192, or 256 bits.
1.
How do you calculate the bit (and byte) size of a string, for example
str s="ABC"
What is the bit size?
And how do I get byte size? (sizeof?)
2.
str s="ABC"
How to pad "s" so it becomes 128, 192, or 256 bits?
I assume when I padded my custom key so it becomes 128, 192 or 256 bits then I will not get the error (?)
Sorry for these basic questions.
Quote:Error encrypting: Specified key is not a valid size for this algorithm.
at Aes.Encrypt(String plainText, String key). <help #IDP_ERR>?
What I read from here:
https://stackoverflow.com/questions/2919...-algorithm
The AES key can only be 128, 192, or 256 bits.
1.
How do you calculate the bit (and byte) size of a string, for example
str s="ABC"
What is the bit size?
And how do I get byte size? (sizeof?)
2.
str s="ABC"
How to pad "s" so it becomes 128, 192, or 256 bits?
I assume when I padded my custom key so it becomes 128, 192 or 256 bits then I will not get the error (?)
Sorry for these basic questions.