Forum Discussion

praque_135655's avatar
praque_135655
Icon for Nimbostratus rankNimbostratus
Oct 22, 2013

Set Authorisation Header when calling the response URL

Hi All,

 

I want to achieve the following usecase, i have added the code to grab the authorisation header, i need to post the authorisation header to the cookigenerator url to get the sitemindercookie.

 

I dont know how to set the header when calling the url "http://usclspcit192.airservices.eds.com/OAuthDemo/cookiegenerator.html" once the status is "OK"

 

Code: when HTTP_REQUEST { if { [HTTP::header exists "Authorization"] } {

 

      set authzheaders "Authorization: [HTTP::header value Authorization]"

      log local0. $authzheaders
} 

}

 

when HTTP_RESPONSE { if { [HTTP::status] == 200} {

 

       log local0. $authzheaders

       HTTP::redirect "http://usclspcit192.airservices.eds.com/OAuthDemo/cookiegenerator.html"
}

}

 

Regards, Praque

 

2 Replies