Forum Discussion

tsm_329805's avatar
tsm_329805
Icon for Nimbostratus rankNimbostratus
Aug 29, 2017

iRule to Check Internet Explorer browser..!

Dear ,

 

Could you please help in providing the condition to check the IE browser check.? Earlier below syntax use to work, but not it stopped working..!

 

// switch -glob [HTTP::header value "User-Agent"] { "MSIE 6" - "MSIE 7" - "MSIE 8" - "MSIE 9" -

 

"MSIE 10" - "MSIE 11" - "Firefox" { ....

 

//

 

can someone help.?

 

Thanks

 

2 Replies

  • Hello TSM,

     

    Which version of IE are you using ?

     

    Could you add the following lines to your irule

     

    if { [IP::client_addr] eq "x.x.x.x" } { log local0. "User Agent value [HTTP::header value "User-Agent"]" }

     

    and check logs in file /var/log/ltm

     

    Regards

     

  • Hi TSM,

    to identify Internet Explorer regardless of its version, you have to check for the pattern "MSIE " or "Trident/".

    switch -glob -- [HTTP::header value "User-Agent"] { 
        "Mozilla/*MSIE *" - "Mozilla/*Trident/*" {
            set is_internet_explorer true
        }
        default {
            set is_internet_explorer false
        }
    }
    

    Note: For further information which UA-String is used by which browser you may check up the following page [click me].

    Cheers, Kai