Ajax request (from .NET) give me unexpected results

Posted by ironnailpiercethesky on Stack Overflow See other posts from Stack Overflow or by ironnailpiercethesky
Published on 2010-04-22T05:39:04Z Indexed on 2010/04/22 5:43 UTC
Read the original article Hit count: 260

Filed under:
|
|
|
|

I wanted to learn a little more about web and .NET so i decided to write a program to download binaries, webpages and does a little ajax.

The first download site i tried was too easy. So i went against uploading.com. It seemed good, no captcha, some ajax use required, you cant guess all the data, it was perfect.

After 2hours of messing around i got frustrated. For the life of me i could not get the ajax response to give me what i was expecting. I decided to use tamper data clear my cookies, click on the entry for the ajax request. Copy the Referer, cookies and postdata and came up with this code.

It does not work! I am shocked that copying those fields did not work. I even tried setting the user agent (not in code linked) and it still did not work.

Why isnt this POST on the ajax request not giving me the correct file?

I notice the JsHttpRequest=12719132559480-xml changes based on time so if you want to run the code you should grab a new snapshot with tamperdata (or at least update that url).

I dont see any extra headers in tamper data so does anyone know why i might not be getting the response expected? I know disabling cookies or javascript will make the link 'expired' automatically. I dont think javascript will matter because i got the data from tamperdata at the moment of request so what gives? What am i forgetting or what data am i not submitting properly?

© Stack Overflow or respective owner

Related posts about .NET

Related posts about httpwebrequest