1 .\" Copyright (c) 2008 by Gerrit Renker <gerrit@erg.abdn.ac.uk>
3 .\" %%%LICENSE_START(VERBATIM)
4 .\" Permission is granted to make and distribute verbatim copies of this
5 .\" manual provided the copyright notice and this permission notice are
6 .\" preserved on all copies.
8 .\" Permission is granted to copy and distribute modified versions of this
9 .\" manual under the conditions for verbatim copying, provided that the
10 .\" entire resulting derived work is distributed under the terms of a
11 .\" permission notice identical to this one.
13 .\" Since the Linux kernel and libraries are constantly changing, this
14 .\" manual page may be incorrect or out-of-date. The author(s) assume no
15 .\" responsibility for errors or omissions, or for damages resulting from
16 .\" the use of the information contained herein. The author(s) may not
17 .\" have taken the same level of care in the production of this manual,
18 .\" which is licensed free of charge, as they might when working
21 .\" Formatted or processed versions of this manual, if unaccompanied by
22 .\" the source, must acknowledge the copyright and authors of this work.
25 .\" $Id: udplite.7,v 1.12 2008/07/23 15:22:22 gerrit Exp gerrit $
27 .TH UDPLITE 7 2021-03-22 "Linux" "Linux Programmer's Manual"
29 udplite \- Lightweight User Datagram Protocol
32 .B #include <sys/socket.h>
33 .\" FIXME . see #defines under `BUGS',
34 .\" when glibc supports this, add
35 .\" #include <netinet/udplite.h>
37 .B sockfd = socket(AF_INET, SOCK_DGRAM, IPPROTO_UDPLITE);
40 This is an implementation of the Lightweight User Datagram Protocol
41 (UDP-Lite), as described in RFC\ 3828.
43 UDP-Lite is an extension of UDP (RFC\ 768) to support variable-length
45 This has advantages for some types of multimedia transport that
46 may be able to make use of slightly damaged datagrams,
47 rather than having them discarded by lower-layer protocols.
49 The variable-length checksum coverage is set via a
52 If this option is not set, the only difference from UDP is
53 in using a different IP protocol identifier (IANA number 136).
55 The UDP-Lite implementation is a full extension of
57 is, it shares the same API and API behavior, and in addition
58 offers two socket options to control the checksum coverage.
62 address format described in
66 address format described in
69 To set or get a UDP-Lite socket option, call
73 to write the option with the option level argument set to
77 socket options are valid on a UDP-Lite socket.
82 The following two options are specific to UDP-Lite.
84 .BR UDPLITE_SEND_CSCOV
85 This option sets the sender checksum coverage and takes an
87 as argument, with a checksum coverage value in the range 0..2^16-1.
89 A value of 0 means that the entire datagram is always covered.
90 Values from 1\-7 are illegal (RFC\ 3828, 3.1) and are rounded up to
91 the minimum coverage of 8.
93 With regard to IPv6 jumbograms (RFC\ 2675), the UDP-Litev6 checksum
94 coverage is limited to the first 2^16-1 octets, as per RFC\ 3828, 3.5.
95 Higher values are therefore silently truncated to 2^16-1.
96 If in doubt, the current coverage value can always be queried using
99 .BR UDPLITE_RECV_CSCOV
100 This is the receiver-side analogue and uses the same argument format
102 .BR UDPLITE_SEND_CSCOV .
103 This option is not required to enable traffic with partial checksum
105 Its function is that of a traffic filter: when enabled, it
106 instructs the kernel to drop all packets which have a coverage
108 than the specified coverage value.
111 .B UDPLITE_RECV_CSCOV
112 exceeds the actual packet coverage, incoming packets are silently dropped,
113 but may generate a warning message in the system log.
114 .\" SO_NO_CHECK exists and is supported by UDPv4, but is
115 .\" commented out in socket(7), hence also commented out here
117 .\"Since UDP-Lite mandates checksums, checksumming can not be disabled
123 All errors documented for
126 UDP-Lite does not add further errors.
130 Basic UDP-Litev4 statistics counters.
133 Basic UDP-Litev6 statistics counters.
135 UDP-Litev4/v6 first appeared in Linux 2.6.20.
137 .\" FIXME . remove this section once glibc supports UDP-Lite
138 Where glibc support is missing, the following definitions are needed:
142 #define IPPROTO_UDPLITE 136
143 .\" The following two are defined in the kernel in linux/net/udplite.h
144 #define UDPLITE_SEND_CSCOV 10
145 #define UDPLITE_RECV_CSCOV 11
154 RFC\ 3828 for the Lightweight User Datagram Protocol (UDP-Lite).
156 .I Documentation/networking/udplite.txt
157 in the Linux kernel source tree