[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: maintaining state?



Agree with Mike.

In our case the remote server sends a sessionID inside the 'cookie' header.

We keep our sessions 'alive' by sending back the cookie (sessionID) info in
subsequent POST's received in the first GET.
This is all done inside the HTTP headers.

Check the examples in LIBHTTP & search for the http_Xproc with 'READ_HDR'
and 'ADDL_HDR'
The READ_HDR gets info from the initial HTTP header received. You can locate
sessions ID's or Cookie info, then you can put the cookie info back into
your (POST) HTTP headers with ADDL_HDR


Regards

Ian Patterson


-----Original Message-----
From: ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx
[mailto:ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx]On Behalf Of Mike Krebs
Sent: 13 February 2009 15:56
To: 'HTTPAPI and FTPAPI Projects'
Subject: RE: maintaining state?


How does the time system maintain state? Two common ways are through cookies
or through session IDs passed in the post.

If it is cookies, search the archives for "cookies ian" and you should find
a post that talks about this including some coding examples.

If the ID is in the post, you shouldn't need to do anything except find the
post in the HTML and do it.

I am not aware of other methods of maintaining state. But, there are always
new tricks out there.

Mike Krebs

> -----Original Message-----
> From: ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx [mailto:ftpapi-
> bounces@xxxxxxxxxxxxxxxxxxxxxx] On Behalf Of schreur@xxxxxxxxxxxxx
> Sent: Friday, February 13, 2009 8:34 AM
> To: ftpapi@xxxxxxxxxxxxxxxxxxxxxx
> Subject: maintaining state?
>
> I have a time system
> that requires that users sign on and review and confirm punches. They
> really
> don't want to have to access yet another browser session, so I've built
> some RPG
> HTTPAPI programs to issue the punches when someone signs into the
> Iseries.
> Supervisors need to log in and review and confirm the punches. I'm
> trying to
> built that as well. My problem is that I issue the login post, and that
> appears
> to be working properly. When I attempt to post the confirm data string,
> I
> receive a 'session timed out please log in" message. I see nothing
> abnormal
> buried in the HTML returned after the login, only a redirect to the
> confirmation
> display page. Is there something I need to look for to maintain state
> so I can
> then post the
>
> kevin

-----------------------------------------------------------------------
This is the FTPAPI mailing list.  To unsubscribe, please go to:
http://www.scottklement.com/mailman/listinfo/ftpapi
-----------------------------------------------------------------------

-----------------------------------------------------------------------
This is the FTPAPI mailing list.  To unsubscribe, please go to:
http://www.scottklement.com/mailman/listinfo/ftpapi
-----------------------------------------------------------------------