V6TEST.CONF(5)

NAME
v6test.conf - config file for v6test

DESCRIPTION
This file describes the configuration file format for v6test(1), an IPv6 testing tool to generate artibitrary IPv6 packets. It declares test entries to be specified in the argument of v6test.

It obeys the famous termcap(5) file format. Each line in the file describes a test entry. Fields are separated by a colon (‘’):, and each field corresponds to an test block to construct the entry. Lines may be concatenated by the ‘\’ character. The comment marker is the ‘#’ character.

ENTRIES
Entries describe the elements of packets to be sent and control v6test(1) behavior. The name of entries should begin with either of the following keywords, except for the entries to be specified in the arguments of v6test(1). Their name determines their properties to be specified. interval ether ip6 hbh icmp6echorpl icmp6echo icmp6err mld rtsol rtadvd nsol nadv redirect frghdr dstopt tcp udp raw

Every description begins with phrases regarding its argument. Its meanings are listed below.
num number.
text
    string quoted by " (double quote).
entry
    other entries.
auto
    you can special keyword auto (not quote it by ") to use the correct value judging from the context.
optional
    not necessary.
hex a sequence of hexadecimal values (XX, where X=0-9, A-F), to declare octet sequence. (e.g. "000102030405060708")

other than the following keywords
    Specifies a packet concaticating each of them in the specified order.

interval (num)
    Just waits for the specified time (unit: millisecond).

ether (entry)
    Ethernet header. Packet type is always 0x8600 (IPv6). Following entries should be specified.
    edst (text, optional)
        Ethernet destination address
    esrc (text, optional)
        Ethernet source address

ip (entry)
    Specify IPv6 basic header. The following entries should be specified.
    ip6_ver (num, optional)
        IPv6 version field. If not specified, 6 is assumed.
    ip6_tc (num, optional)
        IPv6 traffic class field. If not specified, 0 is assumed.
    ip6_flow (num)
        IPv6 Flow ID field.
    ip6_plen (num, auto)
        IPv6 Payload length field.
    ip6_nxt (num, auto)
        IPv6 Next Header field.
    ip6_hlim (num, optinal)
        IPv6 HopLimit field. If not specified, 64 is assumed.
    ip6_src (text)
        IPv6 source address. You can override it by -s option of v6test(1)
    ip6_dst (text)
        IPv6 destination address. You can override it by -d option of v6test(1)

hbh (entry)
    IPv6 hop-by-hop option header. The following entries should be specified.
    hbh_nxt (num, auto)
        Next Header field.
    hbh_len (num)
        option length field
    hbh_opts (entry)
        option data. Following entry can be specified.
        pad1 (no arg)
            length-1 padding.
        padn (entry)
            length-n padding. Its length is specified in the following entries.
            padoptlen (num)
                padding length
            padoptreallen (num, optional)
                Specifies padding length. if not specified, values in padoptlen is used.
        jumbo (entry)
            jumbo-packet hop-by-hop option. Following entry should be specified.
            jumbo_len (num)
                jumbo-payload length field
        rtalert (entry)
            router-alert option. Following entry should be specified.
            rtalert_data (num)
                rtalert options's data
        unknownopt (text)
            unknown option. Following entries should be specified.
            opttype (num)
                option type
            optlen (num)
                option length

icmp6echo, icmp6echorpl (entry)
    ICMPv6 ECHO and ECHO-REPLY data. The following entries should be specified.
    icmp6_code (num)
        ICMPv6 code
    icmp6_id (num)
        ICMPv6 identifier
    icmp6_seq (num)
        ICMPv6 sequence number
    icmp6_len (num, optional)
        ICMPv6 length field. If not specified, 8 (=sizeof(icmp6 header)) is assumed

icmp6err (entry)
    ICMPv6 Error data. The following entries should be specified.
    icmp6_type (num)
        ICMPv6 Type field.
    icmp6_code (num)
        ICMPv6 Code field.
    icmp6_mtu (num)
        path MTU for ICMPv6 Packet-Too-Big message. Can be specified only when icmp6_type is 2 (=ICMP6_PACKET_TOO_BIG).
    icmp6_param (num)
        pointer for ICMPv6 Parameter Problem message. Can be specified only when icmp6_type is 4 (=ICMP6_PARAM_PROB).

mld (entry)
    MLD data. The following entries should be specified.
    mld_type (num)
        MLD Type field.
    mld_code (num, optional)
        MLD Code field. If not specified, 0 is assumed.
    mld_rsv (num, optional)
        MLD reserved field. If not specified, 0 is assumed.
    mld_addr (text)
        MLD multicast address field. Should be an IPv6 address.

rtsol (entry)
    Router-Solicitation message. The following entries should be specified.
    rs_code (num, optional)
        RS code field (=ICMPv6 code field). If not specified, 0 is assumed.
    rs_rsv (num, optional)
        RS Reserved field (=ICMPv6 Data field). If not specified, 0 is assumed.
    rs_opts (entry)
        ND options. The following entries can be specified.
        srclladdr, tgtlladdr (entry, optional)
            Source/Target link-layer address ND option. If not specified, then just omitted.
            len (num, optional)
                ND option Length. If omitted, 1 is assumed.
            lladdr (text)
                Link-layer address. If not specified, then just omitted.
        prefix (entry, optional)
            Prefix option. If not specified, then just omitted.
            len (num, optional)
                ND option Length. If omitted, 4 is assumed.
            pfxlen (num)
                Prefix length field.
            lflg (num, optional)
                Onlink flag. If omitted, 0 (off) is assumed.
            aflg (num, optional)
                Autonomous flag. If omitted, 0 (off) is assumed.
            vltime (num)
                Valid Lifetime.
            pltime (num)
                Preferred Lifetime.
            rsv (num, optional)
                Reserved field in prefix ND option. If omitted, all 0 is assumed.
            prefix (text)
                Prefix field.
        mtu (entry, optional)
            MTU ND option. If not specified, then just omitted.
            len (num, optional)
                ND option Length. If omitted, 1 is assumed.
            rsv (num, optional)
                Reserved field in MTU ND option. If omitted, all 0 is assumed.
            mtu (num)
                MTU field in MTU ND option.
        ndopt (entry, optional)
            Used to configure unknown ND option.
            opttype (num)
                ND option type.
            optlen (num)
                ND option length.

rtadvd (entry)
    Router-Advertisement message. The following entries should be speicified.
    ra_code (num, optional)
        RA code (=ICMPv6 code). if not specified, 0 is assumed.
    ra_cksum (num, optional)
        RA checksum(=ICMPv6 checksum). if not specified, 0 is assumed.
    ra_curhop (num)
        RA curhoplimit
    ra_flag (num, optional)
        RA flag. If not specified, 0 is assumed.
    ra_rltime (num)
        RA router-lifetime
    ra_rtime (num)
        RA router-reachable-time
    ra_retrans (num)
        RA router-retrans-timer
    ra_opts (entry)
        ND options. See rs_opts for detail.

nsol (entry)
    Neighbor Solicitation message. The following entries can be spcified.
    ns_code (num, optional)
        NS code (=ICMPv6 code). if not specified, 0 is assumed.
    ns_cksum (num, optional)
        NS checksum (=ICMPv6 checksum). if not specified, 0 is assumed.
    ns_rsv (num, optional)
        NS reserved field (=ICMPv6 Data field). if not specified, all-0 is assumed.
    ns_tgt (text, auto)
        NS target field. If " auto " is specified, then the destination address is used.
    ns_opts (entry)
        ND options. See rs_opts for detail.

nadv (entry)
    Neighbor-Advertisement message. The following entries should be specified.
    na_code (num, optional)
        NA code (=ICMPv6 code). if not specified, 0 is assumed.
    na_cksum (num, optional)
        NA checksum (=ICMPv6 checksum). if not specified, 0 is assumed.
    na_rflg (num, optional)
        NA router-flag. if not specified, 0 (=off) is assumed.
    na_sflg (num, optional)
        NA solicitated-flag. if not specified, 0 (=off) is assumed.
    na_oflg (num, optional)
        NS override-flag. if not specified, 0 (=off) is assumed.
    na_tgt (text)
        NA target field.
    na_opts (entry)
        ND options. See rs_opts for detail.

redirect (entry)
    Redirect message. The following entries should be specified.
    rd_code (num, optional)
        redirect code (=ICMPv6 code). if not specified, 0 is assumed.
    rd_cksum (num, optional)
        redirect checksum (=ICMPv6 checksum). if not specified, 0 is assumed.
    rd_rsv (num, optional)
        redirect reserved field (=ICMPv6 Data field). if not specified, all-0 is assumed.
    rd_tgt (text)
        redirect target address.
    rd_dst (text)
        redirect destination address.
    rd_opts (entry)
        See rs_opts for detail.

rthdr (entry)
    Routing Header. The following entries should be specified.
    rthdr_nxt (num, auto)
        Next Header field.
    rthdr_len (num, optional)
        Routing Header length. If not specified, it is automatically calculated from the remaining part of this header.
    rthdr_type (num)
        Routing Header Type field.
    rthdr_segleft (num)
        Routing Header Left Segment field.
    rthdr0_hops (num, optional)
        Routing Header Hops field. Valid only if rthdr_type is 0. If not specified, (len - 8)/sizeof(struct ip6_hdr) is assumed. (where len is the valud in rthdr_len , and sizeof(struct ip6_hdr) is 40).

frghdr (entry)
    IPv6 fragment header options. The following entries should be specified.
    frghdr_next (num, auto)
        Next Header field.
    frghdr_rsv (num, auto)
        Reserved field. If not specified, 0 will be fulfilled.
    frghdr_off (num)
        Fragment Offset
    frghdr_more(num, optional)
        Fragment more flag. If not specified, ON(=1) is assumed.
    frghdr_id(num, optional)
        Fragment ID. If not specified, 0 is assumed.

authhdr (entry)
    Authentication header. The following entries should be specified.
    ah_next (num, auto)
        Next Header field.
    ah_len (num, optional)
        length field. If not specified, 4 is assumned
    ah_rsv (num, optional)
        reserved field. If not specified, 0 is assumned
    ah_spi (num)
        SPI field.
    ah_seq (num)
        sequence field

dstopt (entry)
    IPv6 destination option header. The following entries should be specified.
    dst_nxt (num, auto)
        Next Header field.
    dst_len (num)
        length field
    dst_opts (entry)
        Specifies entries. Same entries as hbh_opts can be specified.

tcp (entry)
    TCP message. The following entries should be specified.
    tcp_sport (num)
        TCP source port
    tcp_dport (num)
        TCP destination port
    tcp_seq (num, optional)
        TCP sequence field. If not specified, 0 is assumed.
    tcp_ack (num)
        TCP acknowledgement field. If not specified, 0 is assumed.
    tcp_off (num)
        TCP offset field. If not specified, sizeof(struct tcphdr)/4 is assumed.
    tcp_flags (num, optional)
        TCP flag. If not specified, 0 is assumed.
    tcp_win (num, optional)
        TCP window-size field. If not specified, 8192 is specified.
    tcp_sum (num, optional)
        TCP checksum field. If not specified, 0 is specified.
    tcp_urp (num, optional)
        TCP urgent flag. If not specified, 0 (=off) is specified.
    tcp_data (hex)
        TCP data.

udp (entry)
    UDP message. The following entries should be specified.
    udp_sport (num)
        UDP source port
    udp_dport (num)
        UDP destination port
    udp_len (num, optional)
        UDP length field. If not specified, 8 is assumed.
    udp_data (hex)
        UDP data.

raw (entry)
    Raw message dump for upper-layer protocols above IPv6, such as OSPFv3, Tunneled packet and so on. The following entries should be specified.
    raw_proto (num, optional)
        its protocol type. If not specified, nothing is fulfilled in the next header field of the previos header.
    raw_data (hex)
        its actual data.

EXAMPLES
Here's an example to send looped SYN packet. You can generate this packet by

    	v6test -f (config.file) synloop

command.

    ############################################
    synloop:\
    	:ip6:tcp1:
    ############################################
    ip6:\
            :ip6_flow#0:ip6_plen=auto:ip6_nxt=auto:ip6_hlim#255:\
            :ip6_src="fe80::260:97ff:fe47:9ba1":\
    	:ip6_dst="fe80::260:97ff:fe47:9ba1":
    ############################################
    tcp1:\
    	:tcp_sport#23:tcp_dport#23:tcp_seq#0:tcp_ack#0:tcp_flags#2:
    ############################################

Here's another example to send multiple ping packets by

    	 v6test -f (configfile) ping wait500ms ping

command.

    ############################################
    # just ping
    ping:\
    	:ip6:icmp6echo:
    ############################################
    # interval timer (msec)
    wait500msec:\
    	:interval 500:
    ############################################
    ip6:\
            :ip6_flow#0:ip6_plen=auto:ip6_nxt=auto:ip6_hlim#255:\
            :ip6_src="fe80::2a0:24ff:fea8:6cf1":\
    	:ip6_dst="fe80::260:97ff:fe47:9ba1":
    ############################################
    #echo request packet
    icmp6echo:\
            :icmp6_type=echo:icmp6_code#0:icmp6_cksum=auto:icmp6_id#0:\
    	:icmp6_seq#0:
    ############################################

FILES
./v6test.conf
    The default configuration file

SEE ALSO
termcap(5), v6test(1),

HISTORY
The v6test command first appeared in WIDE Hydrangea IPv6 protocol stack kit.