idnits 2.17.1 draft-ietf-fecframe-ldpc-01.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- No issues found here. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year -- The document date (November 29, 2011) is 4530 days in the past. Is this intentional? Checking references for intended status: Proposed Standard ---------------------------------------------------------------------------- (See RFCs 3967 and 4897 for information about using normative references to lower-maturity documents in RFCs) -- Looks like a reference, but probably isn't: '0' on line 408 -- Looks like a reference, but probably isn't: '1' on line 410 -- Looks like a reference, but probably isn't: '2' on line 412 -- Looks like a reference, but probably isn't: '3' on line 414 Summary: 0 errors (**), 0 flaws (~~), 1 warning (==), 5 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 FecFrame V. Roca 3 Internet-Draft INRIA 4 Intended status: Standards Track M. Cunche 5 Expires: June 1, 2012 NICTA 6 J. Lacan 7 ISAE/LAAS-CNRS 8 November 29, 2011 10 Simple LDPC-Staircase Forward Error Correction (FEC) Scheme for FECFRAME 11 draft-ietf-fecframe-ldpc-01 13 Abstract 15 This document describes a fully-specified simple FEC scheme for LDPC- 16 Staircase codes that can be used to protect media streams along the 17 lines defined by the FECFRAME framework. These codes have many 18 interesting properties: they are systematic codes, they perform close 19 to ideal codes in many use-cases and they also feature very high 20 encoding and decoding throughputs. LDPC-Staircase codes are 21 therefore a good solution to protect a single high bitrate source 22 flow, or to protect globally several mid-rate flows within a single 23 FECFRAME instance. They are also a good solution whenever the 24 processing load of a software encoder or decoder must be kept to a 25 minimum. 27 Status of this Memo 29 This Internet-Draft is submitted in full conformance with the 30 provisions of BCP 78 and BCP 79. 32 Internet-Drafts are working documents of the Internet Engineering 33 Task Force (IETF). Note that other groups may also distribute 34 working documents as Internet-Drafts. The list of current Internet- 35 Drafts is at http://datatracker.ietf.org/drafts/current/. 37 Internet-Drafts are draft documents valid for a maximum of six months 38 and may be updated, replaced, or obsoleted by other documents at any 39 time. It is inappropriate to use Internet-Drafts as reference 40 material or to cite them other than as "work in progress." 42 This Internet-Draft will expire on June 1, 2012. 44 Copyright Notice 46 Copyright (c) 2011 IETF Trust and the persons identified as the 47 document authors. All rights reserved. 49 This document is subject to BCP 78 and the IETF Trust's Legal 50 Provisions Relating to IETF Documents 51 (http://trustee.ietf.org/license-info) in effect on the date of 52 publication of this document. Please review these documents 53 carefully, as they describe your rights and restrictions with respect 54 to this document. Code Components extracted from this document must 55 include Simplified BSD License text as described in Section 4.e of 56 the Trust Legal Provisions and are provided without warranty as 57 described in the Simplified BSD License. 59 Table of Contents 61 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . . 3 62 2. Terminology . . . . . . . . . . . . . . . . . . . . . . . . . 4 63 3. Definitions Notations and Abbreviations . . . . . . . . . . . 4 64 3.1. Definitions . . . . . . . . . . . . . . . . . . . . . . . 4 65 3.2. Notations . . . . . . . . . . . . . . . . . . . . . . . . 6 66 3.3. Abbreviations . . . . . . . . . . . . . . . . . . . . . . 7 67 4. Common Procedures Related to the ADU Block and Source 68 Block Creation . . . . . . . . . . . . . . . . . . . . . . . . 7 69 4.1. Restrictions . . . . . . . . . . . . . . . . . . . . . . . 7 70 4.2. ADU Block Creation . . . . . . . . . . . . . . . . . . . . 7 71 4.3. Source Block Creation . . . . . . . . . . . . . . . . . . 9 72 5. LDPC-Staircase FEC Scheme for Arbitrary ADU Flows . . . . . . 10 73 5.1. Formats and Codes . . . . . . . . . . . . . . . . . . . . 10 74 5.1.1. FEC Framework Configuration Information . . . . . . . 10 75 5.1.2. Explicit Source FEC Payload ID . . . . . . . . . . . . 12 76 5.1.3. Repair FEC Payload ID . . . . . . . . . . . . . . . . 13 77 5.2. Procedures . . . . . . . . . . . . . . . . . . . . . . . . 14 78 5.3. FEC Code Specification . . . . . . . . . . . . . . . . . . 14 79 6. Security Considerations . . . . . . . . . . . . . . . . . . . 14 80 6.1. Attacks Against the Data Flow . . . . . . . . . . . . . . 14 81 6.1.1. Access to Confidential Content . . . . . . . . . . . . 15 82 6.1.2. Content Corruption . . . . . . . . . . . . . . . . . . 15 83 6.2. Attacks Against the FEC Parameters . . . . . . . . . . . . 15 84 6.3. When Several Source Flows are to be Protected Together . . 16 85 6.4. Baseline Secure FEC Framework Operation . . . . . . . . . 16 86 7. Operations and Management Considerations . . . . . . . . . . . 16 87 7.1. Operational Recommendations . . . . . . . . . . . . . . . 16 88 8. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 18 89 9. Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . 18 90 10. References . . . . . . . . . . . . . . . . . . . . . . . . . . 18 91 10.1. Normative References . . . . . . . . . . . . . . . . . . . 18 92 10.2. Informative References . . . . . . . . . . . . . . . . . . 19 93 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . . 20 95 1. Introduction 97 The use of Forward Error Correction (FEC) codes is a classic solution 98 to improve the reliability of unicast, multicast and broadcast 99 Content Delivery Protocols (CDP) and applications [RFC3453]. The 100 [RFC6363] document describes a generic framework to use FEC schemes 101 with media delivery applications, and for instance with real-time 102 streaming media applications based on the RTP real-time protocol. 103 Similarly the [RFC5052] document describes a generic framework to use 104 FEC schemes with with objects (e.g., files) delivery applications 105 based on the ALC [RFC5775] and NORM [RFC5740] reliable multicast 106 transport protocols. 108 More specifically, the [RFC5053] (Raptor) and [RFC5170] (LDPC- 109 Staircase and LDPC-Triangle) FEC schemes introduce erasure codes 110 based on sparse parity check matrices for object delivery protocols 111 like ALC and NORM. Similarly, the [RFC5510] document introduces 112 Reed-Solomon codes based on Vandermonde matrices for the same object 113 delivery protocols. All these codes are systematic codes, meaning 114 that the k source symbols are part of the n encoding symbols. 115 Additionally, the Reed-Solomon FEC codes belong to the class of 116 Maximum Distance Separable (MDS) codes that are optimal in terms of 117 erasure recovery capabilities. It means that a receiver can recover 118 the k source symbols from any set of exactly k encoding symbols out 119 of n. This is not the case with either Raptor or LDPC-Staircase 120 codes, and these codes require a certain number of encoding symbols 121 in excess to k. However, this number is small in practice when an 122 appropriate decoding scheme is used at the receiver [Cunche08]. 123 Another key difference is the high encoding/decoding complexity of 124 Reed-Solomon codecs compared to Raptor or LDPC-Staircase codes. A 125 difference of one or more orders of magnitude or more in terms of 126 encoding/decoding speed exists between the Reed-Solomon and LDPC- 127 Staircase software codecs [Cunche08][CunchePHD10]. Finally, Raptor 128 and LDPC-Staircase codes are large block FEC codes, in the sense of 129 [RFC3453], since they can efficiently deal with a large number of 130 source symbols. 132 The present document focuses on LDPC-Staircase codes, that belong to 133 the well-known class of "Low Density Parity Check" codes. Because of 134 their key features, these codes are a good solution in many 135 situations, as detailed in Section 7. 137 This documents inherits from [RFC5170] the specifications of the core 138 LDPC-Staircase codes. Therefore this document specifies only the 139 information specific to the FECFRAME context and refers to [RFC5170] 140 for the core specifications of the codes. To that purpose, the 141 present document introduces: 143 o the Fully-Specified FEC Scheme with FEC Encoding ID XXX that 144 specifies a simple way of using LDPC-Staircase codes in order to 145 protect arbitrary ADU flows. 147 Finally, publicly available reference implementations of these codes 148 are available [LDPC-codec] [LDPC-codec-OpenFEC]. 150 2. Terminology 152 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 153 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 154 document are to be interpreted as described in RFC 2119 [RFC2119]. 156 3. Definitions Notations and Abbreviations 158 3.1. Definitions 160 This document uses the following terms and definitions. Some of them 161 are FEC scheme specific and are in line with [RFC5052]: 162 Source symbol: unit of data used during the encoding process. In 163 this specification, there is always one source symbol per ADU. 164 Encoding symbol: unit of data generated by the encoding process. 165 With systematic codes, source symbols are part of the encoding 166 symbols. 167 Repair symbol: encoding symbol that is not a source symbol. 168 Code rate: the k/n ratio, i.e., the ratio between the number of 169 source symbols and the number of encoding symbols. By definition, 170 the code rate is such that: 0 < code rate <= 1. A code rate close 171 to 1 indicates that a small number of repair symbols have been 172 produced during the encoding process. 173 Systematic code: FEC code in which the source symbols are part of 174 the encoding symbols. The LDPC-Staircase codes introduced in this 175 document are systematic. 176 Source block: a block of k source symbols that are considered 177 together for the encoding. 178 Packet Erasure Channel: a communication path where packets are 179 either dropped (e.g., by a congested router, or because the number 180 of transmission errors exceeds the correction capabilities of the 181 physical layer codes) or received. When a packet is received, it 182 is assumed that this packet is not corrupted. 184 Some of them are FECFRAME framework specific and are in line with 185 [RFC6363]: 187 Application Data Unit (ADU): The unit of source data provided as 188 payload to the transport layer. Depending on the use-case, an ADU 189 may use an RTP encapsulation. 190 (Source) ADU Flow: A sequence of ADUs associated with a transport- 191 layer flow identifier (such as the standard 5-tuple {Source IP 192 address, source port, destination IP address, destination port, 193 transport protocol}). Depending on the use-case, several ADU 194 flows may be protected together by the FECFRAME framework. 195 ADU Block: a set of ADUs that are considered together by the 196 FECFRAME instance for the purpose of the FEC scheme. Along with 197 the F[], L[], and Pad[] fields, they form the set of source 198 symbols over which FEC encoding will be performed. 199 ADU Information (ADUI): a unit of data constituted by the ADU and 200 the associated Flow ID, Length and Padding fields (Section 4.3). 201 This is the unit of data that is used as source symbol. 202 FEC Framework Configuration Information: Information which controls 203 the operation of the FEC Framework. The FFCI enables the 204 synchronization of the FECFRAME sender and receiver instances. 205 FEC Source Packet: At a sender (respectively, at a receiver) a 206 payload submitted to (respectively, received from) the transport 207 protocol containing an ADU along with an optional Explicit Source 208 FEC Payload ID. 209 FEC Repair Packet: At a sender (respectively, at a receiver) a 210 payload submitted to (respectively, received from) the transport 211 protocol containing one repair symbol along with a Repair FEC 212 Payload ID and possibly an RTP header. 214 The above terminology is illustrated in Figure 1 (sender's point of 215 view): 217 +----------------------+ 218 | Application | 219 +----------------------+ 220 | 221 | (1) Application Data Units (ADUs) 222 | 223 v 224 +----------------------+ +----------------+ 225 | FEC Framework | | | 226 | |-------------------------->| FEC Scheme | 227 |(2) Construct source |(3) Source Block | | 228 | blocks | |(4) FEC Encoding| 229 |(6) Construct FEC |<--------------------------| | 230 | source and repair | | | 231 | packets |(5) Explicit Source FEC | | 232 +----------------------+ Payload IDs +----------------+ 233 | Repair FEC Payload IDs 234 | Repair symbols 235 | 236 |(7) FEC source and repair packets 237 v 238 +----------------------+ 239 | Transport Layer | 240 | (e.g., UDP) | 241 +----------------------+ 243 Figure 1: Terminology used in this document (sender). 245 3.2. Notations 247 This document uses the following notations: Some of them are FEC 248 scheme specific: 249 k denotes the number of source symbols in a source block. 250 max_k denotes the maximum number of source symbols for any source 251 block. 252 n denotes the number of encoding symbols generated for a source 253 block. 254 E denotes the encoding symbol length in bytes. 255 CR denotes the "code rate", i.e., the k/n ratio. 256 N1 denotes the target number of "1s" per column in the left side 257 of the parity check matrix. 258 N1m3 denotes the value N1 - 3. 259 a^^b denotes a raised to the power b. 261 Some of them are FECFRAME framework specific: 263 B denotes the number of ADUs per ADU block. 264 max_B denotes the maximum number of ADUs for any ADU block. 266 3.3. Abbreviations 268 This document uses the following abbreviations: 269 ADU stands for Application Data Unit. 270 ESI stands for Encoding Symbol ID. 271 FEC stands for Forward Error (or Erasure) Correction code. 272 FFCI stands for FEC Framework Configuration Information. 273 FSSI stands for FEC Scheme Specific Information. 274 LDPC stands for Low Density Parity Check. 275 MDS stands for Maximum Distance Separable code. 277 4. Common Procedures Related to the ADU Block and Source Block Creation 279 This section introduces the procedures that are used during the ADU 280 block and the related source block creation, for the FEC scheme 281 considered. 283 4.1. Restrictions 285 This specification has the following restrictions: 286 o there MUST be exactly one source symbol per ADUI, and therefore 287 per ADU; 288 o there MUST be exactly one repair symbol per FEC Repair Packet; 289 o there MUST be exactly one source block per ADU block; 290 o the use of the LDPC-Staircase scheme is such that there MUST be 291 exactly one encoding symbol per group, i.e., G MUST be equal to 1 292 [RFC5170]; 294 4.2. ADU Block Creation 296 Two kinds of limitations MUST be considered, that impact the ADU 297 block creation: 298 o at the FEC Scheme level: the FEC Scheme and the FEC codec have 299 limitations that define a maximum source block size; 300 o at the FECFRAME instance level: the target use-case MAY have real- 301 time constraints that MAY define a maximum ADU block size; 302 Note that terminology "maximum source block size" and "maximum ADU 303 block size" depends on the point of view that is adopted (FEC Scheme 304 versus FECFRAME instance). However, in this document, both refer to 305 the same value since Section 4.1 requires there is exactly one source 306 symbol per ADU. We now detail each of these aspects. 308 The maximum source block size in symbols, max_k, depends on several 309 parameters: the code rate (CR), the Encoding Symbol ID (ESI) field 310 length in the Explicit Source/Repair FEC Payload ID (16 bits), as 311 well as possible internal codec limitations. More specifically, 312 max_k cannot be larger than the following values, derived from the 313 ESI field size limitation, for a given code rate: 314 max1_k = 2^^(16 - ceil(Log2(1/CR))) 315 Some common max1_k values are: 316 o CR == 1 (no repair symbol): max1_k = 2^^16 = 65536 symbols 317 o 1/2 <= CR < 1: max1_k = 2^^15 = 32,768 symbols 318 o 1/4 <= CR < 1/2: max1_k = 2^^14 = 16,384 symbols 320 Additionally, a codec MAY impose other limitations on the maximum 321 source block size, for instance, because of a limited working memory 322 size. This decision MUST be clarified at implementation time, when 323 the target use-case is known. This results in a max2_k limitation. 325 Then, max_k is given by: 326 max_k = min(max1_k, max2_k) 327 Note that this calculation is only required at the encoder (sender), 328 since the actual k parameter (k <= max_k) is communicated to the 329 decoder (receiver) through the Explicit Source/Repair FEC Payload ID. 331 The source ADU flows MAY have real-time constraints. In that case 332 the maximum number of ADUs of an ADU block must not exceed a certain 333 threshold since it directly impacts the decoding delay. The larger 334 the ADU block size, the longer a decoder may have to wait until it 335 has received a sufficient number of encoding symbols for decoding to 336 succeed, and therefore the larger the decoding delay. When the 337 target use-case is known, these real-time constraints result in an 338 upper bound to the ADU block size, max_rt. 340 For instance, if the use-case specifies a maximum decoding latency, 341 l, and if each source ADU covers a duration d of a continuous media 342 (we assume here the simple case of a constant bit rate ADU flow), 343 then the ADU block size must not exceed: 344 max_rt = floor(l / d) 345 After encoding, this block will produce a set of at most n = max_rt / 346 CR encoding symbols. These n encoding symbols will have to be sent 347 at a rate of n / l packets per second. For instance, with d = 10 ms, 348 l = 1 s, max_rt = 100 ADUs. 350 If we take into account all these constraints, we find: 351 max_B = min(max_k, max_rt) 352 This max_B parameter is an upper bound to the number of ADUs that can 353 constitute an ADU block. 355 4.3. Source Block Creation 357 In its most general form the FECFRAME framework and the LDPC- 358 Staircase FEC scheme are meant to protect a set of independent flows. 359 Since the flows have no relationship to one another, the ADU size of 360 each flow can potentially vary significantly. Even in the special 361 case of a single flow, the ADU sizes can largely vary (e.g., the 362 various frames of a "Group of Pictures (GOP) of an H.264 flow). This 363 diversity must be addressed since the LDPC-Staircase FEC scheme 364 requires a constant encoding symbol size (E parameter) per source 365 block. Since this specification requires that there is only one 366 source symbol per ADU, E must be large enough to contain all the ADUs 367 of an ADU block along with their prepended 3 bytes (see below). 369 In situations where E is determined per source block (default, 370 specified by the FFCI/FSSI with S = 0, Section 5.1.1.2), E is equal 371 to the size of the largest ADU of this source block plus three (for 372 the prepended 3 bytes, see below). In this case, upon receiving the 373 first FEC Repair Packet for this source block, since this packet MUST 374 contain a single repair symbol (Section 5.1.3), a receiver determines 375 the E parameter used for this source block. 377 In situations where E is fixed (specified by the FFCI/FSSI with S = 378 1, Section 5.1.1.2), then E must be greater or equal to the size of 379 the largest ADU of this source block plus three (for the prepended 3 380 bytes, see below). If this is not the case, an error is returned. 381 How to handle this error is use-case specific (e.g., a larger E 382 parameter may be communicated to the receivers in an updated FFCI 383 message, using an appropriate mechanism) and is not considered by 384 this specification. 386 The ADU block is always encoded as a single source block. There are 387 a total of B <= max_B ADUs in this ADU block. For the ADU i, with 0 388 <= i <= B-1, 3 bytes are prepended (Figure 2): 389 o The first byte, FID[i] (Flow ID), contains the integer identifier 390 associated to the source ADU flow to which this ADU belongs to. 391 It is assumed that a single byte is sufficient, or said 392 differently, that no more than 256 flows will be protected by a 393 single instance of the FECFRAME framework. 394 o The following two bytes, L[i] (Length), contain the length of this 395 ADU, in network byte order (i.e., big endian). This length is for 396 the ADU itself and does not include the FID[i], L[i], or Pad[i] 397 fields. 399 Then zero padding is added to ADU i (if needed) in field Pad[i], for 400 alignment purposes up to a size of exactly E bytes. The data unit 401 resulting from the ADU i and the F[i], L[i] and Pad[i] fields, is 402 called ADU Information (or ADUI). Each ADUI contributes to exactly 403 one source symbol to the source block. 405 Encoding Symbol Length (E) 406 < -------------------------------------------------------------- > 407 +----+----+-----------------------+------------------------------+ 408 |F[0]|L[0]| ADU[0] | Pad[0] | 409 +----+----+----------+------------+------------------------------+ 410 |F[1]|L[1]| ADU[1] | Pad[1] | 411 +----+----+----------+-------------------------------------------+ 412 |F[2]|L[2]| ADU[2] | 413 +----+----+------+-----------------------------------------------+ 414 |F[3]|L[3]|ADU[3]| Pad[3] | 415 +----+----+------+-----------------------------------------------+ 416 \_______________________________ _______________________________/ 417 \/ 418 simple FEC encoding 420 +----------------------------------------------------------------+ 421 | Repair 4 | 422 +----------------------------------------------------------------+ 423 . . 424 . . 425 +----------------------------------------------------------------+ 426 | Repair 7 | 427 +----------------------------------------------------------------+ 429 Figure 2: Source block creation, for code rate 1/2 (equal number of 430 source and repair symbols, 4 in this example), and S = 0. 432 Note that neither the initial 3 bytes nor the optional padding are 433 sent over the network. However, they are considered during FEC 434 encoding. It means that a receiver who lost a certain FEC source 435 packet (e.g., the UDP datagram containing this FEC source packet) 436 will be able to recover the ADUI if FEC decoding succeeds. Thanks to 437 the initial 3 bytes, this receiver will get rid of the padding (if 438 any) and identify the corresponding ADU flow. 440 5. LDPC-Staircase FEC Scheme for Arbitrary ADU Flows 442 5.1. Formats and Codes 444 5.1.1. FEC Framework Configuration Information 446 The FEC Framework Configuration Information (or FFCI) includes 447 information that MUST be communicated between the sender and 448 receiver(s). More specifically, it enables the synchronization of 449 the FECFRAME sender and receiver instances. It includes both 450 mandatory elements and scheme-specific elements, as detailed below. 452 5.1.1.1. Mandatory Information 454 FEC Encoding ID: the value assigned to this fully-specified FEC 455 scheme MUST be XXX, as assigned by IANA (Section 8). 456 When SDP is used to communicate the FFCI, this FEC Encoding ID is 457 carried in the 'encoding-id' parameter. 459 5.1.1.2. FEC Scheme-Specific Information 461 The FEC Scheme Specific Information (FSSI) includes elements that are 462 specific to the present FEC scheme. More precisely: 463 PRNG seed (seed): a non-negative 32 bit integer used as the seed of 464 the Pseudo Random Number Generator, as defined in [RFC5170]. 465 Encoding symbol length (E): a non-negative integer that indicates 466 either the length of each encoding symbol in bytes (strict mode, 467 i.e., if S = 1), or the maximum length of any encoding symbol 468 (i.e., if S = 0). 469 Strict (S) flag: when set to 1 this flag indicates that the E 470 parameter is the actual encoding symbol length value for each 471 block of the session (unless otherwise notified by an updated FFCI 472 if this possibility is considered by the use-case or CDP). When 473 set to 0 this flag indicates that the E parameter is the maximum 474 encoding symbol length value for each block of the session (unless 475 otherwise notified by an updated FFCI if this possibility is 476 considered by the use-case or CDP). 477 N1 minus 3 (n1m3): an integer between 0 (default) and 7, inclusive. 478 The number of "1s" per column in the left side of the parity check 479 matrix, N1, is then equal to N1m3 + 3, as specified in [RFC5170]. 480 These elements are required both by the sender (LDPC-Staircase 481 encoder) and the receiver(s) (LDPC-Staircase decoder). 483 When SDP is used to communicate the FFCI, this FEC scheme-specific 484 information is carried in the 'fssi' parameter in textual 485 representation as specified in [RFC6364]. For instance: 487 fssi=seed:1234,E:1400,S:0,n1m3:0 489 If another mechanism requires the FSSI to be carried as an opaque 490 octet string (for instance after a Base64 encoding), the encoding 491 format consists of the following 7 octets: 492 o PRNG seed (seed): 32 bit field. 493 o Encoding symbol length (E): 16 bit field. 494 o Strict (S) flag: 1 bit field. 495 o Reserved: a 4 bit field that MUST be set to zero. 497 o N1m3 parameter (n1m3): 3 bit field. 499 0 1 2 500 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 501 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 502 | PRNG seed (seed) | 503 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 504 | Encoding Symbol Length (E) |S| resvd | n1m3| 505 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 507 Figure 3: FSSI encoding format. 509 5.1.2. Explicit Source FEC Payload ID 511 A FEC source packet MUST contain an Explicit Source FEC Payload ID 512 that is appended to the end of the packet as illustrated in Figure 4. 514 +--------------------------------+ 515 | IP Header | 516 +--------------------------------+ 517 | Transport Header | 518 +--------------------------------+ 519 | ADU | 520 +--------------------------------+ 521 | Explicit Source FEC Payload ID | 522 +--------------------------------+ 524 Figure 4: Structure of a FEC Source Packet with the Explicit Source 525 FEC Payload ID. 527 More precisely, the Explicit Source FEC Payload ID is composed of the 528 following fields (Figure 5): 529 Source Block Number (SBN) (16 bit field): this field identifies the 530 source block to which this FEC source packet belongs. 531 Encoding Symbol ID (ESI) (16 bit field): this field identifies the 532 source symbol contained in this FEC source packet. This value is 533 such that 0 <= ESI <= k - 1 for source symbols. 534 Source Block Length (k) (16 bit field): this field provides the 535 number of source symbols for this source block, i.e., the k 536 parameter. 538 0 1 2 3 539 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 540 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 541 | Source Block Number (SBN) | Encoding Symbol ID (ESI) | 542 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 543 | Source Block Length (k) | 544 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 546 Figure 5: Source FEC Payload ID encoding format. 548 5.1.3. Repair FEC Payload ID 550 A FEC repair packet MUST contain a Repair FEC Payload ID that is 551 prepended to the repair symbol(s) as illustrated in Figure 6. There 552 MUST be a single repair symbol per FEC repair packet. 554 +--------------------------------+ 555 | IP Header | 556 +--------------------------------+ 557 | Transport Header | 558 +--------------------------------+ 559 | Repair FEC Payload ID | 560 +--------------------------------+ 561 | Repair Symbol | 562 +--------------------------------+ 564 Figure 6: Structure of a FEC Repair Packet with the Repair FEC 565 Payload ID. 567 More precisely, the Repair FEC Payload ID is composed of the 568 following fields: (Figure 7): 569 Source Block Number (SBN) (16 bit field): this field identifies the 570 source block to which the FEC repair packet belongs. 571 Encoding Symbol ID (ESI) (16 bit field) this field identifies the 572 repair symbol contained in this FEC repair packet. This value is 573 such that k <= ESI <= n - 1 for repair symbols. 574 Source Block Length (k) (16 bit field): this field provides the 575 number of source symbols for this source block, i.e., the k 576 parameter. 577 Number of Encoding Symbols (n) (16 bit field): this field provides 578 the number of encoding symbols for this source block, i.e., the n 579 parameter. 581 0 1 2 3 582 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 583 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 584 | Source Block Number (SBN) | Encoding Symbol ID (ESI) | 585 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 586 | Source Block Length (k) | Number Encoding Symbols (n) | 587 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 589 Figure 7: Repair FEC Payload ID encoding format. 591 5.2. Procedures 593 The following procedures apply: 594 o The source block creation procedures are specified in Section 4.3. 595 o The SBN value is incremented for each new source block, starting 596 at 0 for the first block of the ADU flow. Wrapping to zero will 597 happen for long sessions, after value 2^^16 - 1. 598 o The ESI of encoding symbols is managed sequentially, starting at 0 599 for the first symbol. The first k values (0 <= ESI <= k - 1) 600 identify source symbols, whereas the last n-k values (k <= ESI <= 601 n - 1) identify repair symbols. 602 o The FEC repair packet creation procedures are specified in 603 Section 5.1.3. 605 5.3. FEC Code Specification 607 The present document inherits from [RFC5170] the specification of the 608 core LDPC-Staircase codes for a packet erasure transmission channel. 610 Because of the requirement to have exactly one encoding symbol per 611 group, i.e., because G MUST be equal to 1 (Section 4.1), several 612 parts of [RFC5170] are useless. In particular, this is the case of 613 Section 5.6. "Identifying the G Symbols of an Encoding Symbol 614 Group". 616 6. Security Considerations 618 The FEC Framework document [RFC6363] provides a comprehensive 619 analysis of security considerations applicable to FEC schemes. 620 Therefore the present section follows the security considerations 621 section of [RFC6363] and only discusses topics that are specific to 622 the use of LDPC-Staircase codes. 624 6.1. Attacks Against the Data Flow 625 6.1.1. Access to Confidential Content 627 The LDPC-Staircase FEC Scheme specified in this document does not 628 change the recommendations of [RFC6363]. To summarize, if 629 confidentiality is a concern, it is RECOMMENDED that one of the 630 solutions mentioned in [RFC6363] is used, with special considerations 631 to the way this solution is applied (e.g., before versus after FEC 632 protection, and within the end-system versus in a middlebox), to the 633 operational constraints (e.g., performing FEC decoding in a protected 634 environment may be complicated or even impossible) and to the threat 635 model. 637 6.1.2. Content Corruption 639 The LDPC-Staircase FEC Scheme specified in this document does not 640 change the recommendations of [RFC6363]. To summarize, it is 641 RECOMMENDED that one of the solutions mentioned in [RFC6363] is used 642 on both the FEC Source and Repair Packets. 644 6.2. Attacks Against the FEC Parameters 646 The FEC Scheme specified in this document defines parameters that can 647 be the basis of several attacks. More specifically, the following 648 parameters of the FFCI may be modified by an attacker 649 (Section 5.1.1.2): 650 o FEC Encoding ID: changing this parameter leads the receiver to 651 consider a different FEC Scheme, which enables an attacker to 652 create a Denial of Service (DoS). 653 o Encoding symbol length (E): setting this E parameter to a value 654 smaller than the valid one enables an attacker to create a DoS 655 since the repair symbols and certain source symbols will be larger 656 than E, which is an incoherency for the receiver. Setting this E 657 parameter to a value larger than the valid one has similar impacts 658 when S=1 since the received repair symbol size will be smaller 659 than expected. On the opposite it will not lead to any 660 incoherency when S=0 since the actual symbol length value for the 661 block is determined by the size of any received repair symbol, as 662 long as this value is smaller than E. However setting this E 663 parameter to a larger value may have impacts on receivers that 664 pre-allocate memory space in advance to store incoming symbols. 665 o Strict (S) flag: flipping this S flag from 0 to 1 (i.e., E is now 666 considered as a strict value) enables an attacker to mislead the 667 receiver if the actual symbol size varies over different source 668 blocks. Flipping this S flag from 1 to 0 has no major 669 consequences unless the receiver requires to have a fixed E value 670 (e.g., because the receiver pre-allocates memory space). 672 o N1 minus 3 (n1m3): changing this parameter leads the receiver to 673 consider a different code, which enables an attacker to create a 674 DoS. 676 It is therefore RECOMMENDED that security measures are taken to 677 guarantee the FFCI integrity, as specified in [RFC6363]. How to 678 achieve this depends on the way the FFCI is communicated from the 679 sender to the receiver, which is not specified in this document. 681 Similarly, attacks are possible against the Explicit Source FEC 682 Payload ID and Repair FEC Payload ID: by modifying the Source Block 683 Number (SBN), or the Encoding Symbol ID (ESI), or the Source Block 684 Length (k), or the Number Encoding Symbols (n), an attacker can 685 easily corrupt the block identified by the SBN. Other consequences, 686 that are use-case and/or CDP dependant, may also happen. It is 687 therefore RECOMMENDED that security measures are taken to guarantee 688 the FEC Source and Repair Packets as stated in [RFC6363]. 690 6.3. When Several Source Flows are to be Protected Together 692 The LDPC-Staircase FEC Scheme specified in this document does not 693 change the recommendations of [RFC6363]. 695 6.4. Baseline Secure FEC Framework Operation 697 The LDPC-Staircase FEC Scheme specified in this document does not 698 change the recommendations of [RFC6363] concerning the use of the 699 IPsec/ESP security protocol as a mandatory to implement (but not 700 mandatory to use) security scheme. This is well suited to situations 701 where the only insecure domain is the one over which the FEC 702 Framework operates. 704 7. Operations and Management Considerations 706 The FEC Framework document [RFC6363] provides a comprehensive 707 analysis of operations and management considerations applicable to 708 FEC schemes. Therefore the present section only discusses topics 709 that are specific to the use of LDPC-Staircase codes as specified in 710 this document. 712 7.1. Operational Recommendations 714 LDPC-Staircase codes have excellent erasure recovery capabilities 715 with large source blocks, close to ideal MDS codes. For instance, 716 independently of FECFRAME, with source block size k=1024, CR=2/3, 717 N1=5, G=1, with a hybrid ITerative/Maximum Likelihood (IT/ML) 718 decoding approach (see below) and when all symbols are sent in a 719 random order (see below), the average overhead amounts to 0.64% 720 (corresponding to 6.5 symbols in addition to k) and receiving 1046 721 symbols (corresponding to a 2.1% overhead) is sufficient to reduce 722 the decoding failure probability to 5.9*10^^-5. This is why these 723 codes are a good solution to protect a single high bitrate source 724 flow as in [Matsuzono10], or to protect globally several mid-rate 725 source flows within a single FECFRAME instance: in both cases the 726 source block size can be assumed to be equal to a few hundreds (or 727 more) source symbols. 729 LDPC-Staircase codes are also a good solution whenever processing 730 requirements at a software encoder or decoder must be kept to a 731 minimum. This is true when the decoder uses an IT decoding 732 algorithm, or an ML algorithm (we use a Gaussian Elimination as the 733 ML algorithm) when this latter is carefully implemented and the 734 source block size kept reasonable, or a mixture of both techniques 735 which is the recommended solution [Cunche08][CunchePHD10]. For 736 instance an average decoding speed between 1.3 Gbps (corresponding to 737 a very bad channel, close to the theoretical decoding limit and 738 requiring an ML decoding) and 4.3 Gbps (corresponding to a medium 739 quality channel where IT decoding is sufficient) are easily achieved 740 with a source block size composed of k=1024 source symbols, a code 741 rate CR=2/3 (i.e., 512 repair symbols), 1024 byte long symbols, G=1, 742 and N1=5, on an Intel Xeon 5120/1.86GHz workstation running Linux/64 743 bits. Additionally, with a hybrid IT/ML approach, a receiver can 744 decide if and when ML decoding is used, depending on local criteria 745 (e.g., battery or CPU capabilities), independently from other 746 receivers. 748 As the source block size decreases, the erasure recovery capabilities 749 of LDPC codes in general also decrease. In the case of LDPC- 750 Staircase codes, in order to compensate this phenomenon, it is 751 recommended to increase the N1 parameter (e.g., experiments carried 752 out in [Matsuzono10] use N1=7 if k=170 symbols, and N1=5 otherwise) 753 and to use a hybrid IT/ML decoding approach. For instance, 754 independently of FECFRAME, with a small source block size k=256 755 symbols, CR=2/3, N1=7, and G=1, 8he average overhead amounts to 0.71% 756 (corresponding to 1.8 symbols in addition to k), and receiving 271 757 symbols (corresponding to a 5.9% overhead) is sufficient to reduce 758 the decoding failure probability to 5.9*10^^-5. Using N1=9 or 10 759 further improves these results if need be, which also enables to use 760 LDPC-Staircase codes with k=100 symbols for instance. 762 With very small source blocks (e.g., a few tens symbols), using for 763 instance Reed-Solomon codes [SIMPLE_RS] or 2D parity check codes MAY 764 be more appropriate. 766 The way the FEC Repair Packets are transmitted is of high importance. 768 A good strategy, that works well for any kind of channel loss model, 769 consists in sending FEC Repair Packets in random order (rather than 770 in sequence) while FEC Source Packets are sent first and in sequence. 771 Sending all packets in a random order is another possibility, but it 772 requires that all repair symbols for a source block be produced 773 first, which adds some extra delay at a sender. 775 8. IANA Considerations 777 Values of FEC Encoding IDs are subject to IANA registration. 778 [RFC6363] defines general guidelines on IANA considerations. In 779 particular it defines a registry called FEC Framework (FECFRAME) FEC 780 Encoding IDs whose values are granted on an IETF Consensus basis. 782 This document registers one value in the FEC Framework (FECFRAME) FEC 783 Encoding IDs registry as follows: 784 o XXX refers to the Simple LDPC-Staircase [RFC5170] FEC Scheme for 785 Arbitrary Packet Flows. 787 9. Acknowledgments 789 The authors want to thank K. Matsuzono, J. Detchart and H. Asaeda for 790 their contributions in evaluating the use of LDPC-Staircase codes in 791 the context of FECFRAME [Matsuzono10]. 793 10. References 795 10.1. Normative References 797 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 798 Requirement Levels", RFC 2119. 800 [RFC5170] Roca, V., Neumann, C., and D. Furodet, "Low Density Parity 801 Check (LDPC) Forward Error Correction", RFC 5170, 802 June 2008. 804 [RFC6363] Watson, M., Begen, A., and V. Roca, "Forward Error 805 Correction (FEC) Framework", RFC 6363, September 2011. 807 [RFC6364] Begen, A., "Session Description Protocol Elements for the 808 Forward Error Correction (FEC) Framework", RFC 6364, 809 October 2011. 811 10.2. Informative References 813 [RFC3453] Luby, M., Vicisano, L., Gemmell, J., Rizzo, L., Handley, 814 M., and J. Crowcroft, "The Use of Forward Error Correction 815 (FEC) in Reliable Multicast", RFC 3453, December 2002. 817 [RFC5052] Watson, M., Luby, M., and L. Vicisano, "Forward Error 818 Correction (FEC) Building Block", RFC 5052, August 2007. 820 [RFC5510] Lacan, J., Roca, V., Peltotalo, J., and S. Peltotalo, 821 "Reed-Solomon Forward Error Correction (FEC) Schemes", 822 RFC 5510, April 2009. 824 [SIMPLE_RS] 825 Roca, V., Cunche, M., Lacan, J., Bouabdallah, A., and K. 826 Matsuzono, "Simple Reed-Solomon Forward Error Correction 827 (FEC) Scheme for FECFRAME", 828 draft-ietf-fecframe-simple-rs-01 (Work in Progress), 829 September 2011. 831 [RFC5053] Luby, M., Shokrollahi, A., Watson, M., and T. Stockhammer, 832 "Raptor Forward Error Correction Scheme", RFC 5053, 833 June 2007. 835 [RFC5740] Adamson, B., Bormann, C., Handley, M., and J. Macker, 836 "NACK-Oriented Reliable Multicast (NORM) Transport 837 Protocol", RFC 5740, November 2009. 839 [RFC5775] Luby, M., Watson, M., and L. Vicisano, "Asynchronous 840 Layered Coding (ALC) Protocol Instantiation", RFC 5775, 841 April 2010. 843 [Cunche08] 844 Cunche, M. and V. Roca, "Optimizing the Error Recovery 845 Capabilities of LDPC-Staircase Codes Featuring a Gaussian 846 Elimination Decoding Scheme", 10th IEEE International 847 Workshop on Signal Processing for Space Communications 848 (SPSC'08), October 2008. 850 [CunchePHD10] 851 Cunche, M., "High performances AL-FEC codes for the 852 erasure channel : variation around LDPC codes", PhD 853 dissertation (in 854 French) (http://tel.archives-ouvertes.fr/tel- 855 00451336/en/), June 2010. 857 [Matsuzono10] 858 Matsuzono, K., Detchart, J., Cunche, M., Roca, V., and H. 860 Asaeda, "Performance Analysis of a High-Performance Real- 861 Time Application with Several AL-FEC Schemes", 35th Annual 862 IEEE Conference on Local Computer Networks (LCN 2010), 863 October 2010. 865 [LDPC-codec] 866 Cunche, M., Roca, V., Neumann, C., and J. Laboure, "LDPC- 867 Staircase/LDPC-Triangle Codec Reference Implementation", 868 INRIA Rhone-Alpes and STMicroelectronics, 869 . 871 [LDPC-codec-OpenFEC] 872 "The OpenFEC project", . 874 Authors' Addresses 876 Vincent Roca 877 INRIA 878 655, av. de l'Europe 879 Inovallee; Montbonnot 880 ST ISMIER cedex 38334 881 France 883 Email: vincent.roca@inria.fr 884 URI: http://planete.inrialpes.fr/people/roca/ 886 Mathieu Cunche 887 NICTA 888 Australia 890 Email: mathieu.cunche@nicta.com.au 891 URI: http://mathieu.cunche.free.fr/ 893 Jerome Lacan 894 ISAE/LAAS-CNRS 895 1, place Emile Blouin 896 Toulouse 31056 897 France 899 Email: jerome.lacan@isae.fr 900 URI: http://dmi.ensica.fr/auteur.php3?id_auteur=5