Content-type: text/html Man page of IPSEC_TNCFG

IPSEC_TNCFG

Section: File Formats (5)
Updated: 27 Jun 2000
Index Return to Main Contents
 

NAME

ipsec_tncfg - lists IPSEC virtual interfaces attached to real interfaces  

SYNOPSIS

ipsec tncfg

cat /proc/net/ipsec_tncfg  

DESCRIPTION

/proc/net/ipsec_tncfg is a read-only file which lists which IPSEC virtual interfaces are attached to which real interfaces, through which packets will be forwarded once processed by IPSEC.

Each line lists one ipsec I/F. A table entry consists of:

+
an ipsec virtual I/F name
+
a visual and machine parsable separator '->', separating the virtual I/F and the physical I/F,
+
a physical I/F name, to which the ipsec virtual I/F is attached or NULL if it is not attached,
+
the keyword mtu=,
+
the MTU of the ipsec virtual I/F,
+
the automatically adjusted effective MTU for PMTU discovery, in brackets,
+
a visual and machine parsable separator '->', separating the virtual I/F MTU and the physical I/F MTU,
+
the MTU of the attached physical I/F. .SHEXAMPLES
ipsec2 -> eth3 mtu=16260(1443) -> 1500

shows that virtual dang else (e.g., a terminating NUL) within that length. As a convenience for cases where an entire NUL-terminated string is to be converted, a srclen value of 0 is taken to mean strlen(src).

The af parameter of ttoaddr and ttosubnet specifies the address family of interest. It should be either AF_INET or AF_INET6.

The dstlen parameter of addrtot and subnettot specifies the size of the dst parameter; under no circumstances are more than dstlen bytes written to dst. A result which will not fit is truncated. Dstlen can be zero, in which case dst need not be valid and no result is written, but the return value is unaffected; in all other cases, the (possibly truncated) result is NUL-terminated. The freeswan.h header file defines constants, ADDRTOT_BUF and SUBNETTOT_BUF, which are the sizes of buffers just large enough for worst-case results.

The format parameter of addrtot and subnettot specifies what format is to be used for the conversion. The value 0 (not the character '0', but a zero value) specifies a reasonable default, and is in fact the only format currently available in subnettot. Addrtot also accepts format values 'r' (signifying a text form suitable for DNS reverse lookups, e.g. 4.3.2.1.IN-ADDR.ARPA. for IPv4 and RFC 2874 format for IPv6), and 'R' (signifying an alternate reverse-lookup form, an error for IPv4 and RFC 1886 format for IPv6). Reverse-lookup names always end with a ``.''.

The text-to-binary functions return NULL for success and a pointer to a string-literal error message for failure; see DIAGNOSTICS. The binary-to-text functions return 0 for a failure, and otherwise always return the size of buffer which would be needed to accommodate the full conversion result, including terminating NUL; it is the caller's responsibility to check this against the size of the provided