Forum Discussion

Mack_Hanson_107's avatar
Mack_Hanson_107
Icon for Nimbostratus rankNimbostratus
May 11, 2005

Getting full path of request

How do I get the full path of the request, e.g. 'http://www.someplace.com/dirname/somepage.html'?

 

 

[HTTP::uri] only returns the path '/dirname/somepage.html', while

 

[HTTP::header location] is showing me nothing. Here's my test rule:

 

 

when HTTP_REQUEST {

 

 

log local7. "header names: [HTTP::header names]"

 

log local7. "location: [HTTP::header Location]"

 

log local7. "uri: [HTTP::uri]"

 

}
  • unRuleY_95363's avatar
    unRuleY_95363
    Historic F5 Account
    The location header is generally only used with a redirect response. The host portion of a request is found in the Host header. So, the following would get you closer to the complete url:

     

     

    [HTTP::host][HTTP::uri]