~ubuntu-branches/ubuntu/trusty/ipv6toolkit/trusty

« back to all changes in this revision

Viewing changes to manuals/na6.1

  • Committer: Package Import Robot
  • Author(s): Octavio Alvarez
  • Date: 2013-08-24 18:37:54 UTC
  • Revision ID: package-import@ubuntu.com-20130824183754-zulpzbg53eotkwyp
Tags: upstream-1.4
Import upstream version 1.4

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
.TH NA6 1
 
2
.SH NAME
 
3
na6 \- A security assessment tool for attack vectors based on ICMPv6 Neighbor Advertisement messages
 
4
.SH SYNOPSIS
 
5
.B na6
 
6
\-i INTERFACE [\-s SRC_ADDR[/LEN]] [\-d DST_ADDR] [\-S LINK_SRC_ADDR] [\-y FRAG_SIZE] [\-u DST_OPT_HDR_SIZE] [\-U DST_OPT_U_HDR_SIZE] [\-H HBH_OPT_HDR_SIZE] [\-D LINK-DST-ADDR] [\-t TARGET_ADDR[/LEN]] [\-r] [\-c] [\-o] [\-E LINK_ADDR] [\-e] [\-j PREFIX[/LEN]] [\-k PREFIX[/LEN]] [\-J LINK_ADDR] [\-K LINK_ADDR] [\-w PREFIX[/LEN]] [\-b PREFIX[/LEN]] [\-g PREFIX[/LEN]] [\-B LINK_ADDR] [\-G LINK_ADDR] [\-W PREFIX[/LEN]] [\-F N_SOURCES] [\-T N_TARGETS] [\-L | \-l] [\-z] [\-v] [\-V] [\-h]
 
7
 
 
8
.SH DESCRIPTION
 
9
.B na6
 
10
allows the assessment of IPv6 implementations with respect to a variety of attack vectors based on ICMPv6 Neighbor Advertisement messages. It is part of the IPv6 Toolkit v1.3: a security assessment suite for the IPv6 Protocols.
 
11
 
 
12
This tool has two modes of operation: active and passive. In active mode, the tool attacks a specific target, while in passive mode the tool listens to traffic on the local network, and launches an attack in response to such traffic. Active mode is employed if a destination address (IPv6 Destination Address or Ethernet Destination Address) and a Target Address are specified. Passive mode is employed if the "\-L" option (or its long counterpart "\-\-listen") is set. If both an attack target and the "\-L" option are set, the attack is launched against the specified target, and then the tool enters passive mode to respond incoming Neighbor Solicitation messages with Neighbor Advertisement (attack) packets.
 
13
 
 
14
The tool supports filtering of incoming Neighbor Solicitation messages based on the Ethernet Source Address, the Ethernet Destination Address, the IPv6 Source Address, the IPv6 Destination Address, and the Neighbor Solicitation Target Address.  There are two types of filters: "block filters" and "accept filters". If any "block filter" is specified, and the incoming Neighbor Solicitation message matches any of those filters, the message is discarded (and thus no Neighbor Advertisements are sent in response). If any "accept filter" is specified, incoming Neighbor Solicitation messages must match the specified filters in order for the na6 tool to respond with Neighbor Advertisement messages. 
 
15
 
 
16
.SH OPTIONS
 
17
.B na6
 
18
takes its parameters as command-line options. Each of the options can be specified with a short name (one character preceded with the hyphen character, as e.g. "\-i") or with a long name (a string preceded with two hyphen characters, as e.g. "\-\-interface").
 
19
 
 
20
Depending on the amount of information (i.e., options) to be conveyed into the Neighbor Advertisements, it may be necessary for the na6 tool to split that information into more than one Neighbor Advertisement message. Also, if the tool is instructed to flood the victim with Neighbor Advertisements from different sources ("\-\-flood\-sources" option), multiple packets may need to be generated. na6 supports IPv6 fragmentation, which may be of use if a large amount of information needs to be conveyed within a single Neighbor Advertisement message. However, IPv6 fragmentation is not enabled by default, and must be explicitly enabled with the "\-y" option.
 
21
 
 
22
.TP
 
23
\-\-interface, \-i
 
24
 
 
25
This option specifies the network interface that the tool will use. The network interface must be specified (i.e., the tool does not select any network interface "by default").
 
26
 
 
27
.TP
 
28
\-\-src\-address, \-s
 
29
 
 
30
This option specifies the IPv6 source address (or IPv6 prefix) to be used for the Source Address of the attack packets. If left unspecified, a random link-local unicast address (fe80::/64) is selected. 
 
31
 
 
32
If the "\-T" ("\-\-flood\-targets") option is specified, this option includes an IPv6 prefix. See the description of the "\-T" option for further information on how the "\-s" option is processed in that specific case.
 
33
 
 
34
.TP
 
35
\-\-dst\-address, \-d
 
36
 
 
37
This option specifies the IPv6 Destination Address of the victim. If left unspecified, but the Ethernet Destination Address is specified, the "all-nodes link-local multicast" address (ff02::1) is selected as the IPv6 Destination Address. 
 
38
 
 
39
When operating in passive mode ("\-L" option), the IPv6 Destination Address is selected according to the IPv6 Source Address of the incoming Neighbor Solicitation message. If the IPv6 Source Address of the Neighbor Solicitation is the unspecified address (::), the "all-nodes link-local multicast" address (ff02::1) is used as the IPv6 Destination Address. Otherwise, the IPv6 Source Address of the incoming Neighbor Solicitation message is used as the IPv6 Destination Address of the outgoing Neighbor Advertisement (attack) messages.
 
40
 
 
41
.TP
 
42
\-\-hop\-limit, \-A
 
43
 
 
44
This option specifies the Hop Limit to be used for the Neighbor Advertisement messages. It defaults to 255. Note that IPv6 nodes are required to check that the Hop Limit of incoming Neighbor Advertisement messages is 255. Therefore, this option is only useful to assess whether an IPv6 implementation fails to enforce the aforementioned check.
 
45
 
 
46
.TP
 
47
\-\-frag\-hdr, \-y
 
48
 
 
49
This option specifies that the resulting packet must be fragmented. The fragment size must be specified as an argument to this option.
 
50
 
 
51
.TP
 
52
\-\-dst\-opt\-hdr, \-u
 
53
 
 
54
This option specifies that a Destination Options header is to be included in the resulting packet. The extension header size must be specified as an argument to this option (the header is filled with padding options). Multiple Destination Options headers may be specified by means of multiple "\-u" options.
 
55
 
 
56
.TP
 
57
\-\-dst\-opt\-u\-hdr, \-U
 
58
 
 
59
This option specifies a Destination Options header to be included in the "unfragmentable part" of the resulting packet. The header size must be specified as an argument to this option (the header is filled with padding options). Multiple Destination Options headers may be specified by means of multiple "\-U" options. This option is only valid if the "\-y" option is specified (as the concept of "unfragmentable part" only makes sense when fragmentation is employed).
 
60
 
 
61
.TP
 
62
\-\-hbh\-opt\-hdr, \-H
 
63
 
 
64
This option specifies that a Hop-by-Hop Options header is to be included in the resulting packet. The header size must be specified as an argument to this option (the header is filled with padding options). Multiple Hop-by-Hop Options headers may be specified by means of multiple "\-H" options.
 
65
 
 
66
.TP
 
67
\-\-src\-link\-address, \-S
 
68
 
 
69
This option specifies the link-layer Source Address of the Neighbor Advertisement messages (currently, only Ethernet is supported). If left unspecified, the link-layer Source Address is randomized.
 
70
 
 
71
When operating in passive mode, the link-layer Source Address is selected according to the IPv6 Destination Address of the incoming Neighbor Solicitation message. 
 
72
If the IPv6 Destination Address of the incoming Neighbor Solicitation message is a multicast address (usually a solicited-node multicast address), the link-layer Source Address is set to the address specified by the "\-S" option (or to a random address if the "\-S" option was left unspecified). If the IPv6 Destination Address of the incoming Neighbor Solicitation is not a multicast address (i.e., it is a unicast address), the link-layer Source Address is set to the Ethernet Destination Address of the incoming Neighbor Solicitation message.
 
73
 
 
74
.TP
 
75
\-\-link\-dst\-address, \-D
 
76
 
 
77
This option specifies the link-layer Destination Address of the Neighbor Advertisement messages (currently, only Ethernet is supported). If left unspecified, it is set to the "all-nodes link-local multicast" address (ff02::1).
 
78
 
 
79
When operating in passive mode, the link-layer Destination Address is set according to the IPv6 Source Address of the incoming Neighbor Solicitation message. 
 
80
If the IPv6 Source Address of the incoming Neighbor Solicitation message is the unspecified address (::), the link-layer destination address is set to "33:33:00:00:00:01" (the Ethernet multicast address corresponding to the IPv6 "all-nodes link-local multicast" address). Otherwise, the link-layer Destination Address is set to the link-layer Source Address of the incoming Neighbor Solicitation message.
 
81
 
 
82
.TP
 
83
\-\-router, \-r
 
84
 
 
85
This option instructs the na6 tool to set the "R" (Router) bit in the Neighbor Advertisement messages that it sends. The "R" bit indicates that the node sending the message is a router. If left unspecified, the "R" bit is not set.
 
86
 
 
87
.TP
 
88
\-\-solicited, \-c
 
89
 
 
90
This option instructs the na6 tool to set the "S" ("Solicited") bit in the Neighbor Advertisement messages that it sends. When operating in passive mode ("\-L" option), the "Solicited" flag is forced to 1 in all responses sent to unicast IPv6 addresses.
 
91
 
 
92
.TP
 
93
\-\-override, \-o
 
94
 
 
95
This option instructs the na6 tool to set the ‘O’ ("Override") bit in the Neighbor Advertisement messages that it sends. If this option is left unspecified, the ‘O’ bit is not set.
 
96
 
 
97
.TP
 
98
\-\-target, \-t
 
99
 
 
100
This option specifies the IPv6 Target Address of the Neighbor Advertisement messages. 
 
101
 
 
102
If the "\-T" ("\-\-flood\-targets") option is specified, this option specifies an IPv6 prefix in the form "\-t prefix/prefixlen". See the description of the "\-T" option for further information on how the "\-t" option is processed in that specific case.
 
103
 
 
104
.TP
 
105
\-\-target\-lla\-opt, \-E
 
106
 
 
107
This option specifies the contents of a target link-layer address option to be included in the Neighbor Advertisement messages. If a single option is specified, it is included in all the outgoing Neighbor Advertisement messages. If more than one target link-layer address is specified (by means of multiple "\-E" options), and all the resulting options cannot be conveyed into a single Neighbor Advertisement message, multiple Neighbor Advertisements will be sent as needed.
 
108
 
 
109
.TP
 
110
\-\-add\-tlla\-opt, \-e
 
111
 
 
112
This option instructs the na6 tool to include a target link-layer address option in the Neighbor Advertisement messages that it sends. The target link-layer address included in the option is the same as the Ethernet Source Address used for the outgoing Neighbor Advertisement messages. The difference between this option and the "\-E" option is that the "\-e" option does not specify the actual value of the option, but just instructs the tool to include a target link-layer address option (the actual value of the option is selected as explained before).
 
113
 
 
114
.TP
 
115
\-\-block\-src, \-j
 
116
 
 
117
This option sets a block filter for the incoming Neighbor Solicitation messages, based on their IPv6 Source Address. It allows the specification of an IPv6 prefix in the form "\-j prefix/prefixlen". If the prefix length is not specified, a prefix length of "/128" is selected (i.e., the option assumes that a single IPv6 address, rather than an IPv6 prefix, has been specified).
 
118
 
 
119
.TP
 
120
\-\-block\-dst, \-k
 
121
 
 
122
This option sets a block filter for the incoming Neighbor Solicitation messages, based on their IPv6 Destination Address. It allows the specification of an IPv6 prefix in the form "\-k prefix/prefixlen". If the prefix length is not specified, a prefix length of "/128" is selected (i.e., the option assumes that a single IPv6 address, rather than an IPv6 prefix, has been specified).
 
123
 
 
124
.TP
 
125
\-\-block\-link\-src, \-J
 
126
 
 
127
This option sets a block filter for the incoming Neighbor Solicitation messages, based on their link-layer Source Address. The option must be followed by a link-layer address (currently, only Ethernet is supported).
 
128
 
 
129
.TP
 
130
\-\-block\-link\-dst, \-K
 
131
 
 
132
This option sets a block filter for the incoming Neighbor Solicitation messages, based on their link-layer Destination Address. The option must be followed by a link-layer address (currently, only Ethernet is supported).
 
133
 
 
134
.TP
 
135
\-\-block\-target, \-w
 
136
 
 
137
This option sets a block filter for the incoming Neighbor Solicitation messages, based on their Target Address. It allows the specification of an IPv6 prefix in the form "\-w prefix/prefixlen". If the prefix length is not specified, a prefix length of "/128" is selected (i.e., the option assumes that a single IPv6 address, rather than an IPv6 prefix, has been specified).
 
138
 
 
139
.TP
 
140
\-\-accept\-src, \-b
 
141
 
 
142
This option sets an accept filter for the incoming Neighbor Solicitation messages, based on their IPv6 Source Address. It allows the specification of an IPv6 prefix in the form "\-b prefix/prefixlen". If the prefix length is not specified, a prefix length of "/128" is selected (i.e., the option assumes that a single IPv6 address, rather than an IPv6 prefix, has been specified).
 
143
 
 
144
.TP
 
145
\-\-accept\-dst, \-g
 
146
 
 
147
This option sets a accept filter for the incoming Neighbor Solicitation messages, based on their IPv6 Destination Address. It allows the specification of an IPv6 prefix in the form "\-g prefix/prefixlen". If the prefix length is not specified, a prefix length of "/128" is selected (i.e., the option assumes that a single IPv6 address, rather than an IPv6 prefix, has been specified).
 
148
 
 
149
.TP
 
150
\-\-accept\-link\-src, \-B
 
151
 
 
152
This option sets an accept filter for the incoming Neighbor Solicitation messages, based on their link-layer Source Address. The option must be followed by a link-layer address (currently, only Ethernet is supported).
 
153
 
 
154
.TP
 
155
\-\-accept\-link\-dst, \-K
 
156
 
 
157
This option sets an accept filter for the incoming Neighbor Solicitation messages, based on their link-layer Destination Address. The option must be followed by a link-layer address (currently, only Ethernet is supported).
 
158
 
 
159
.TP
 
160
\-\-accept\-target, \-W
 
161
 
 
162
This option sets a accept filter for the incoming Neighbor Solicitation messages, based on their Target Address. It allows the specification of an IPv6 prefix in the form "\-W prefix/prefixlen". If the prefix length is not specified, a prefix length of "/128" is selected (i.e., the option assumes that a single IPv6 address, rather than an IPv6 prefix, has been specified).
 
163
 
 
164
.TP
 
165
\-\-flood\-targets, \-T
 
166
 
 
167
This option instructs the na6 tool to send Neighbor Advertisements for multiple Target Addresses. The number of different Target Addresses is specified as "\-T number". The Target Address of each packet is randomly selected from the prefix fe80::/64, unless a different prefix has been specified by means of the "\-t" option. The IPv6 Source Address of each Neighbor Advertisement message is set according to the IPv6 address or prefix specified with the "\-s" option, and defaults to a random link-local unicast address (fe80::/64) if the "\-s" option is left unspecified.
 
168
 
 
169
.TP
 
170
\-\-flood\-sources, \-F
 
171
 
 
172
This option instructs the tool to send multiple Neighbor Advertisement messages with different Source Addresses. The number of different sources is specified as "\-F number". The Source Address of each Neighbor Advertisement is randomly selected from the prefix specified by the "\-s" option. If the "\-F" option is specified but the "\-s" option is left unspecified, the Source Address of the packets is randomly selected from the prefix fe80::/64 (link-local unicast). It should be noted that hosts are required to discard Router Advertisement messages that do not have a link-local unicast address as the Source Address.
 
173
 
 
174
.TP
 
175
\-\-loop, \-l
 
176
 
 
177
This option instructs the na6 tool to send periodic Neighbor Advertisements to the victim node. The amount of time to pause between sending Neighbor Advertisements can be specified by means of the "\-z" option, and defaults to 1 second. Note that this option cannot be set in conjunction with the "\-L" ("\-\-listen") option.
 
178
 
 
179
.TP
 
180
\-\-sleep, \-z
 
181
 
 
182
This option specifies the amount of time to pause between sending Neighbor Solicitations (when the "\-\-loop" option is set). If left unspecified, it defaults to 1 second.
 
183
 
 
184
.TP
 
185
\-\-listen, \-L
 
186
 
 
187
This instructs the na6 tool to operate in passive mode (possibly after attacking a given node, if the ‘\-d’ or ‘\-D’ options were specified). Note that this option cannot be used in conjunction with the "\-l" ("\-\-loop") option.
 
188
 
 
189
.TP
 
190
\-\-verbose, \-v
 
191
 
 
192
This option instructs the na6 tool to be verbose.  When the option is set twice, the tool is "very verbose", and the tool also informs which packets have been accepted or discarded as a result of applying the specified filters. 
 
193
 
 
194
.TP
 
195
\-\-help, \-h
 
196
 
 
197
Print help information for the na6 tool. 
 
198
 
 
199
.SH EXAMPLES
 
200
 
 
201
The following sections illustrate typical use cases of the
 
202
.B na6
 
203
tool.
 
204
 
 
205
\fBExample #1\fR
 
206
 
 
207
# na6 \-i eth0 \-d fe80::1 \-t 2001:db8::1 \-c \-o \-e
 
208
 
 
209
Use the network interface "eth0" to send a Neighbor Advertisement using a random link-local unicast IPv6 Source Address and a random Ethernet Source Address, to the IPv6 Destination address ffe80::1 and the Ethernet Destination Address 33:33:00:00:00:01 (selected by default). The target of the Neighbor Advertisement is 2001:db8::1, and the message has both the "Override" and the "Solicited" flags set. The Neighbor Advertisement also includes a target link-layer address option that contains the same Ethernet address as that used for the Ethernet Source Address of the packet. 
 
210
 
 
211
\fBExample #2\fR
 
212
 
 
213
# na6 \-i eth0 \-j fe80::1 \-j 2001:db8::/32 \-W fe80::/64 \-c \-o \-e \-L \-v \-v
 
214
 
 
215
Listen for incoming Neighbor Solicitation messages on the interface "eth0". Discard those messages that have an IPv6 Source Address equal to fe80::1, an IPv6 Source Address that belongs to the prefix 2001:db8::/32, or a Target Address that does not belong to the prefix fe80::/64. Respond (to those messages that are accepted) with a Neighbor Advertisement with a randomized Ethernet Source Address and a randomized link-local unicast IPv6 Source Address (unless the Destination Address of the Neighbor Solicitation was a unicast address), the IPv6 Destination Address set to the Source Address of the incoming NS message (unless it was the unspecified address), the Target Address set to the same value as the Target Address of the incoming NS, and the "Solicited" and "Override" flags set. Be very verbose ("\-v \-v" options).
 
216
 
 
217
.SH SEE ALSO
 
218
"Security/Robustness Assessment of IPv6 Neighbor Discovery Implementations" (available at: <http://www.si6networks.com/tools/ipv6toolkit/si6networks-ipv6\-nd-assessment.pdf>) for a discussion of Neighbor Discovery vulnerabilities, and additional examples of how to use the na6 tool to exploit them.
 
219
 
 
220
.SH AUTHOR
 
221
The
 
222
.B na6
 
223
tool and the corresponding manual pages were produced by Fernando Gont 
 
224
.I <fgont@si6networks.com>
 
225
for SI6 Networks 
 
226
.IR <http://www.si6networks.com> .
 
227
 
 
228
.SH COPYRIGHT
 
229
Copyright (c) 2011\-2013 Fernando Gont.
 
230
 
 
231
Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.3 or any later version published by the Free Software Foundation; with the Invariant Sections being just "AUTHOR" and "COPYRIGHT", with no Front-Cover Texts, and with no Back-Cover Texts.  A copy of the license is available at
 
232
.IR <http://www.gnu.org/licenses/fdl.html> .
 
233