ViewState Encryption in ASP.Net

asp.netencryptionviewstate

Why is it that I see the same hash value generated when I use different algorithms for viewstate encryption.
I have added below lines to the web.config file

pages viewstateEncryptionMode="Always" enableViewStateMac="true"…/>

machineKey validationKey="AutoGenerate,IsolateApps" decryptionKey="AutoGenerate,IsolateApps" validation="AES" decryption="Auto" />

Also, compilation debug="false" … > is set.

No matter what I use (AES, MD5, SHA1, 3DES), it generates the same hash. Is there something I am missing out.

Please let me know.

-Thanks

Best Answer

Here is an article on Encrypting Viewstate. It's for ASP.Net 2.0. which should be fine for 3.5.

Related Topic