Showing changes from revision #2 to #3:
Added | Removed | Changed
Entry | |||
---|---|---|---|
R0 | Flags | ||
Bit 0 => | Set to enumerate stored cookies; unset to enumerate queued cookies | ||
Bits 1-31 => | Reserved. Must be zero | ||
R1 | Unique cookie handle. 0 for initial call. |
Exit | |||
---|---|---|---|
R0 | Cookie flags | ||
Bit 0 => | Set if cookie has the Secure attribute. | ||
Bits 1-31 => | Reserved. Must be zero | ||
R1 | Unique cookie handle. 0 for no more cookies. | ||
R2 | Total number of cookies created. | ||
R3 | Number of cookies in the queue. | ||
R4 | Pointer to domain name string. | ||
R5 | Pointer to name string. | ||
R6 | Pointer to value string. | ||
R7 | Pointer to path string. |
All cookies received during an HTTP response are added to a queue, and a flag is set in the R0 status value returned by URL_Status and URL_ReadData to indicate to the client that cookies have been found. This call allows a client to enumerate the cookies which have been queued or which are already in the cookie store. Cookies which are in the queue can then either be accepted (moved to the store) or rejected using HTTP_ConsumeCookie.
If queued cookies are left unprocessed, the cookie queue will eventually reach its length limit, whereupon adding further cookies will cause the earlier cookies to be discarded.
The cookie enumeration will not complete successfully if any cookies are added or removed from the queue or the store after enumeration has started. In particular this means that if a cookie is retrieved by enumerating the queue and is then processed with HTTP_ConsumeCookie, enumeration cannot be resumed. It is therefore simplest, if processing all members of the queue, to reset R1 to 0 before every call to HTTP_EnumerateCookies.
The return values in R4-R7 are all pointers to NULL-terminated strings. If R1 is zero on exit then R4-R7 will all be zero also.
The cookie queue and the store are shared across all clients.
The expiry of the cookie does not appear to be available to the client.
It appears that the HttpOnly cookie attribute is unsupported.
Cookies will be moved automatically from the queue to the store if Browse$AcceptAllCookies is set and is not equal to “off”.