Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Flash FileReference Upload HTTP Post User Authentication

Status
Not open for further replies.

lprisr

Programmer
Feb 26, 2007
1
US
I am using ASP.NET and Flash FileReference.upload to upload photos. I want to have .NET form authentication and have Flash's HTTP POST send back the authenticated user information so I can associate this uploaded photo with it.

I don’t know how long it took me to finally figured out that FileReference.upload is actually passing back the IE cookie in the header, when I am using FireFox! This is absolutely the strangest thing. B-(

To my surprise, when I am logged in as User ONE on Firefox and upload a file, I received User TWO from IE’s login. I changed to login as User THREE in IE, the upload in FireFox passed back User THREE. I tried deleting all cookies from IE and FireFox, but didn't make any difference.

I am able to upload photos through flash to the server, so the upload and http post is working. I am posting back to the same aspx page. I also set up 2 separate servers and both results are the same. And also use 2 different computers to test the client side, no luck there.

Can someone explain to me why this is, and what I am doing wrong? How do I make it post back work like a normal ASP.NET post back, because I might need the session cookie too.

Is that possible at all? Or do I have to pass the cookie value in FileReference.upload("uploadphoto.aspx?cookie=" + cookievalue)? Ideally I wouldn't have to reveal cookie information in the page itself. [ponder]

Thanks!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top