Skip to content

Commit c39742d

Browse files
gcoxmozcron2
authored andcommitted
Update --learn-address man page with ipv6 information
The `--learn-address` option is very v4-specific in its man page. This expands the docs based on things I tripped over when bringing up a dual-stack server. Signed-off-by: Greg Cox <[email protected]> Github: closes #1009 Acked-by: Gert Doering <[email protected]> Message-Id: <[email protected]> URL: https://www.mail-archive.com/[email protected]/msg36363.html Signed-off-by: Gert Doering <[email protected]>
1 parent 3ba7602 commit c39742d

File tree

1 file changed

+13
-5
lines changed

1 file changed

+13
-5
lines changed

doc/man-sections/script-options.rst

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ Script Order of Execution
5252

5353
#. ``--learn-address``
5454

55-
Executed in ``--mode server`` mode whenever an IPv4 address/route or MAC
55+
Executed in ``--mode server`` mode whenever an IP address/route or MAC
5656
address is added to OpenVPN's internal routing table.
5757

5858
#. ``--auth-user-pass-verify``
@@ -331,10 +331,14 @@ SCRIPT HOOKS
331331
OpenVPN's internal routing table.
332332

333333
:code:`$2` - [address]
334-
The address being learned or unlearned. This can be an IPv4 address
335-
such as :code:`"198.162.10.14"`, an IPv4 subnet such as
336-
:code:`"198.162.10.0/24"`, or an ethernet MAC address (when
337-
``--dev tap`` is being used) such as :code:`"00:FF:01:02:03:04"`.
334+
The address being learned or unlearned. This can be:
335+
336+
* an IPv4 address such as :code:`"198.162.10.14"`,
337+
* an IPv4 subnet such as :code:`"198.162.10.0/24"`,
338+
* an IPv6 address such as :code:`"2001:db8:1:2:3:4:5:6"`,
339+
* an IPv6 subnet such as :code:`"2001:db8:1:2:3:4:5::/112"`, or
340+
* an ethernet MAC address (when ``--dev tap`` is being used)
341+
such as :code:`"00:FF:01:02:03:04"`.
338342

339343
:code:`$3` - [common name]
340344
The common name on the certificate associated with the client linked
@@ -353,6 +357,10 @@ SCRIPT HOOKS
353357
high-level common name, rather than the low level client virtual
354358
addresses.
355359

360+
A dual-stack client connecting to a dual-stack server will cause two calls
361+
to the ``cmd`` script in quick succession, as the server learns each of the
362+
IPv4 and IPv6 client addresses.
363+
356364
--route-up cmd
357365
Run command ``cmd`` after routes are added, subject to ``--route-delay``.
358366

0 commit comments

Comments
 (0)