httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Allasso Travesser <allassopra...@gmail.com>
Subject [users@httpd] unable to set cookie in
Date Fri, 13 Dec 2013 14:56:19 GMT
Hello,

I am attempting to extend auth_digest_module for 2.2.  I am trying to set a cookie from a
callback in the ap_hook_check_user_id hook, but the cookie does not get set.  I am using this
code for setting the cookie:

static void setLowLevelInitCookie(request_rec *r)
{
    apr_table_set(r->headers_out, "Set-Cookie", "XXXXXXXXXXXX=1");
    ap_log_rerror(APLOG_MARK, APLOG_NOTICE, r, "Digest : XXXXX setting low-level init cookie");
}

I believe the code is getting run without throwing exception, because the code after it runs
and updates the log.  Neither do I get any errors when compiling or restarting Apache.

I can run the same code for setting the cookie from ap_hook_handler in the same module and
it works fine.

Are there only certain hooks from which you can set r->headers_out, or set cookies?

Thank you kindly,

Allasso



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message