Forum Discussion

anujl_5566's avatar
anujl_5566
Icon for Nimbostratus rankNimbostratus
Nov 28, 2011

Simple Question regarding Address type Data Group List

Guys, I have a question regarding Address type Data Group List.

 

 

If in my data group list I add this host 0.0.0.0, will it match all IP's?

 

 

Also is there a way to add comments in Data Group Lists? For documentation sake.

 

4 Replies

  • Hi Anujl,

     

     

    0.0.0.0/0 will match any IP. And no, you can't add comments to a datagroup. You could open a case with F5 Support to request this functionality.

     

     

    Aaron
  • Thanks Aaron,

     

     

    Just to confirm, you wrote 0.0.0.0/0? BUT if I add a host 0.0.0.0, it will be 0.0.0.0/32. So should I add a network 0.0.0.0, with mask 0.0.0.0?
  • e.g.

    [root@ve1023:Active] config  b class testaddress1 list
    class testaddress1 {
       host default inet
    }
    [root@ve1023:Active] config  b class testaddress2 list
    class testaddress2 {
       network default inet
    }
    [root@ve1023:Active] config  b rule myrule list
    rule myrule {
       when RULE_INIT {
            log local0. "testaddress1: [class get testaddress1]"
            log local0. "testaddress2: [class get testaddress2]"
            log local0. "\[class match -- 1.1.1.1 equals testaddress1\]: [class match -- 1.1.1.1 equals testaddress1]"
            log local0. "\[class match -- 1.1.1.1 equals testaddress2\]: [class match -- 1.1.1.1 equals testaddress2]"
    }
    }
    
    [root@ve1023:Active] config  tail /var/log/ltm
    Nov 28 10:47:11 local/ve1023 err mcpd[21973]: 01020066:3: The requested rule (myrule) already exists in partition Common.
    Nov 28 10:47:11 local/tmm info tmm[23027]: Rule myrule : testaddress1: 0.0.0.0/32 {}
    Nov 28 10:47:11 local/tmm info tmm[23027]: Rule myrule : testaddress2: 0.0.0.0 {}
    Nov 28 10:47:11 local/tmm info tmm[23027]: Rule myrule : [class match -- 1.1.1.1 equals testaddress1]: 0
    Nov 28 10:47:11 local/tmm info tmm[23027]: Rule myrule : [class match -- 1.1.1.1 equals testaddress2]: 1
    
    
  • The example irule by nitass, perfectly explains the answer. Thank you