Cript querystring return value potentially dangerous

P

Paj

hi,

this code cript a querystring by Rijndael class:
_______________________
RijndaelManaged rjm = new RijndaelManaged();
rjm.KeySize = 128;
rjm.BlockSize = 128;
rjm.Key = ASCIIEncoding.ASCII.GetBytes(c­hiave);
rjm.IV = ASCIIEncoding.ASCII.GetBytes(i­v);
Byte[] input = Encoding.UTF8.GetBytes(S);
Byte[] output = rjm.CreateEncryptor().Transfor­mFinalBlock(input,
0,input.Length);
return Convert.ToBase64String(output)­;
______________________________

In one page i have this javascript with cript querystring
''
javascript:window.open('Downlo­adDocumento.aspx?id=hiWQqPNzFs­0ONpwkTsrFCw%3d%3d&est=ohP­sZliSmWSE0hwYNIq7nA%3d%3d .....
''

ASP.NET return this error........................why ?
______________________________­___
Exception Details: System.Web.HttpRequestValidati­onException: A
potentially dangerous Request.QueryString value was


detected from the client (id="...iWQqPNzFs0ONpwkTsrFCw=­=").
______________________________­____

thank you

Paj
 
J

Joe Kaplan \(MVP - ADSI\)

Base64 has a few characters that might still trigger the .NET 1.1 input
validation checker. You should URL encode it before sending it to the user.

Joe K.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,767
Messages
2,569,572
Members
45,046
Latest member
Gavizuho

Latest Threads

Top