Forum Discussion
Livius
Cirrus
May 31, 2018Extract the IP address in iRule from ADDITIONAL SECTION response in DNS query
Hi,
I have a piece of code in iRule triggering a DNS query on a VS as follows :
set original_fqdn [findstr $RouteValue "sip:N" 4 ";"]
if {$static::debug} {log local0.info "fqdn =...
Leonardo_Souza
Cirrocumulus
Jun 04, 2018The lindex just gets an element from a list, starting from 0. Dump the variable resolved_ip to the logs and look what is inside of the list.
If the addition section is not on the list, just get the name, and make another query for a A record. Is not efficient, as you are doing 2 queries, but works. The information in the additional section is to avoid systems to have to do a second query, but if you can't do that with RESOLV::lookup, that is a valid option.
Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects