Forum OpenACS Development: Using Authorization: header with gatekeeper package

Referring to: https://openacs.org/forums/message-view?message_id=155987

I've added the following to gatekeeper:

set cookies [ns_set iget $headers cookie]
ns_set idelkey $headers cookie
ns_set put $headers Cookie [gateway_munge_cookies $cookies]

+ acs_user::get -array user
+ set username $user(username)
+ set authtype "Basic [base64::encode $username: ]"
+ ns_set put $headers Authorization $authtype $username: ]"

But I don't see the headers on the request to the GuardUrl. I've traced the packets, and the destination server, they don't go out on the wire.

Has anyone else been successful adding headers to the gatekeeper code? Other experiences at all? Did I goof the code with ns_set?

Cheers!

Collapse
Posted by Sam Nicholson on
Yes, I've been successful adding headers to the gatekeeper code.
One must remember to either watch the source in the package manager or otherwise reload the code in question to expect it to work.

Cheers!