Udit Sajjanhar schrieb:
I am implementing openid for buildservice on the frontend.
Webclient is required to send an direct html request to the frontend for the verification of openid.
The problem is that I need to send authentication information in the headers.
Is there already a way in which the headers can be set automatically and I only supply the controller name of the frontend ?
The solution to this is neither straightforward nor documented well, sorry for that. You need to do something like this: -- code -- transport = ActiveXML::Config.transport_for(:project) transport.set_additional_header("Header-Name", "header value") uri = URI("#{FRONTEND_PROTOCOL}:///path/to/frontend/action") transport.direct_http(uri, :method => :post, :data => "") transport.delete_additional_header("Header-Name") -- /code -- Responses other than 2xx raise exceptions inherited from ActiveXML::Transport::Error. In case you're interested, ActiveXML::Transport is implemented in trunk/buildservice/src/common/lib/activexml/transport.rb. Andreas
-- ================================ Udit Sajjanhar
-- Andreas Bauer SUSE LINUX Products GmbH, GF Markus Rex, HRB 16746 AG Nürnberg -- To unsubscribe, e-mail: opensuse-buildservice+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-buildservice+help@opensuse.org