As stated above the flash file uploader dont send the session its a bug in flash and with firefox. http://bugs.adobe.com/jira/browse/FP-201%3Bjsessionid=CEBE32E5F80472837199BC420886771B
So the only way to get the already authenticated user to be authenticated also in the ajax service routine is to send the session id with the request. And in this case its easiest as get-data. And then in the ajax routine i want to check the session ids to make sure the user is_logged_in. /R On Jun 21, 10:28 pm, mdipierro <[email protected]> wrote: > The requested session id is in request.sesssion_id and the response > session id is in response.session_id. The two should match if the > requested session is found. > > Anyway, why don't you explain what you are trying to accomplish. I do > not see why one would ever need to access this. > > Massimo > > On Jun 21, 3:04 pm, Trollkarlen <[email protected]> wrote: > > > I just need the info how i can get the session ID from the session > > object. > > And then on the other page from the get-data set the session-id back > > to the session, so its seams like that person is logged in. > > > Like this in poseido code: > > > @auth.requires_login() > > def upload_image() > > sessionid = session.id > > return dict(sessionid=sessionid) > > # Then the files are uploaded to "uploader_handler?sessionID=%s" > > sessionid > > > def uploader_handler(): > > if not hasattr(request.vars, 'sessionID'): > > raise HTTP(404, "No such page") > > sesson.setID(request.vars.sessionID) > > if not auth.is_logged_in(): > > raise HTTP(404, "No such page") > > # Save files > > > /R > > > On Jun 20, 4:29 pm, Trollkarlen <[email protected]> wrote: > > > > Can anyone describe how to set and get the session id and set it as an > > > get.data ? > > > > /R > > > > On Jun 19, 3:50 pm, "mr.freeze" <[email protected]> wrote: > > > > > It seems to be a bug in flash's > > > > FileReference.upload:http://www.visible-form.com/blog/flash-file-upload-and-session-cookie... > > > > > On Jun 19, 8:11 am, mdipierro <[email protected]> wrote: > > > > > > Yes but I am sure there is a way to pass the cookie in flash. > > > > > > On Jun 19, 7:58 am, "mr.freeze" <[email protected]> wrote: > > > > > > > Would it be possible to pass a session id with the upload url and > > > > > > manually connect to the session somehow? > > > > > > > On Jun 19, 7:24 am, mdipierro <[email protected]> wrote: > > > > > > > > There must be a way to pass the cookie. If you find a solution > > > > > > > let us > > > > > > > know. > > > > > > > > On Jun 19, 1:22 am, Trollkarlen <[email protected]> wrote: > > > > > > > > > I think that can be hard because the user is in this case > > > > > > > > already > > > > > > > > logged in. > > > > > > > > The upload page requiers login, then it sends the files to a > > > > > > > > new page. > > > > > > > > > So in this stage i dont have the login credentials (password). > > > > > > > > > /R > > > > > > > > > On Jun 19, 5:28 am, mdipierro <[email protected]> wrote: > > > > > > > > > > you can try using basic authentication. > > > > > > > > > > On Jun 18, 2:36 pm, Robert Marklund <[email protected]> > > > > > > > > > wrote: > > > > > > > > > > > Hi, > > > > > > > > > > I have a flash uploader that don't send the session cookie > > > > > > > > > > to the upload > > > > > > > > > > function. > > > > > > > > > > And there for cant do auth. > > > > > > > > > > > Is there any way i solve this ? > > > > > > > > > > Perhaps with post or get data to send the session id ? > > > > > > > > > > > /R > > > > > > > > > > > -- > > > > > > > > > > ______________________________________________ > > > > > > > > > > Robert Marklund > > > > > > > > > > > Phone: +46 (0)46 19 36 82 > > > > > > > > > > Mobile: +46 (0)70 213 22 76 > > > > > > > > > > E-mail: [email protected] > > > > > > > > > > ______________________________________________ --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "web2py Web Framework" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~----------~----~----~----~------~----~------~--~---

