resolv_txt: Returns the DNS TXT records for a given FQDN

Description Usage Arguments Value See Also Examples

Description

Returns the DNS TXT records for a given FQDN

Usage

1
2
resolv_txt(fqdn, nameserver = NA_character_, showWarnings = FALSE,
  full = FALSE)

Arguments

fqdn

input character vector (FQDN)

nameserver

the nameserver to send the request to (optional; uses standard resolver behavior if not specified)

showWarnings

display R warning messages (bool)

full

include full record response information in results (bool)

Value

vector or data frame (if full==TRUE) of TXT records or character(0) if none

See Also

http://www.nlnetlabs.nl/projects/ldns/

http://www.cambus.net/interesting-dns-hacks/ (cool DNS TXT hacks vla https://twitter.com/habbie/status/460067198586081280)

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
## Not run: 
require(resolv)

## get the TXT record for Google
resolv_txt("google.com")
[1] "\"v=spf1 include:_spf.google.com ip4:216.73.93.70/31 ip4:216.73.93.72/31 ~all\""

## Use Team CYMRU ASN TXT record lookup service
resolv_txt("31.108.90.216.origin.asn.cymru.com")
[1] "\"23028 | 216.90.108.0/24 | US | arin |\""

## Wikipedia lookups:
resolv_txt("bind.wp.dg.cx")
[1] "\"BIND , or named , is the most widely used DNS software on the Internet. On Unix-like operating systems it is the de facto standard. http://en.wikipedia.org/wiki/BIND\""

## seekrit URLs
browseURL(gsub("\"", "", resolv_txt("google-public-dns-a.google.com")))

## get the TXT records for PayPal
resolv_txt("paypal.com")
[1] "\"MS=ms96239109\""
[2] "\"yandex-verification: 73acb90f6a9abd76\""
[3] "\"google-site-verification=NrhK1Hj7KuCPua1OcvfacDawt46H9VjByS4IAw5vsFA\""
[4] "\"v=spf1 include:pp._spf.paypal.com include:3rdparty._spf.paypal.com include:3rdparty1._spf.paypal.com include:3rdparty2._spf.paypal.com include:3rdparty3._spf.paypal.com include:c._spf.ebay.com ~all\""

## End(Not run)

hrbrmstr/resolv documentation built on May 17, 2019, 5:12 p.m.