F5 is upgrading its customer support chat feature on My.F5.com. Chat support will be unavailable from 6am-10am PST on 1/20/26. Refer to K000159584 for details.

Forum Discussion

melit_staff_233's avatar
melit_staff_233
Icon for Nimbostratus rankNimbostratus
Jan 21, 2018

Can I change the condition of iRule from [HTTP :: host] to [URI :: host [HTTP :: uri]]?

Assignment by HOST header of Web communication is done as follows.

 

NOW iRule: not ( [HTTP::host] matches_regex {^..*.test.com(:\d+)?$}) )

 

However, it was found that there is a difference between the contents of the HOST header and the FQDN of the request URI, and it does not result in the allocation as expected. For that reason, I am planning to change the setting as follows so that assignment is made by FQDN of the request URI.

 

NEW iRule: not ( [URI::host [HTTP::uri]] matches_regex {^..*.test.com(:\d+)?$}) )

 

Is it ok to use [URI::host [HTTP::uri]] instead of [HTTP::host]? Also, is [URI::host [HTTP::uri]] the correct way to get the FQDN of the request URI?

 

1 Reply