idnits 2.17.1 draft-ietf-fecframe-ldpc-02.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 (March 8, 2012) is 4425 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 412 -- Looks like a reference, but probably isn't: '1' on line 414 -- Looks like a reference, but probably isn't: '2' on line 416 -- Looks like a reference, but probably isn't: '3' on line 418 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: September 9, 2012 NICTA 6 J. Lacan 7 ISAE/LAAS-CNRS 8 March 8, 2012 10 Simple LDPC-Staircase Forward Error Correction (FEC) Scheme for FECFRAME 11 draft-ietf-fecframe-ldpc-02 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 September 9, 2012. 44 Copyright Notice 46 Copyright (c) 2012 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 objects (e.g., files) delivery applications based on 105 the ALC [RFC5775] and NORM [RFC5740] reliable multicast transport 106 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. 276 SDP stands for Session Description Protocol. 278 4. Common Procedures Related to the ADU Block and Source Block Creation 280 This section introduces the procedures that are used during the ADU 281 block and the related source block creation, for the FEC scheme 282 considered. 284 4.1. Restrictions 286 This specification has the following restrictions: 287 o there MUST be exactly one source symbol per ADUI, and therefore 288 per ADU; 289 o there MUST be exactly one repair symbol per FEC Repair Packet; 290 o there MUST be exactly one source block per ADU block; 291 o the use of the LDPC-Staircase scheme is such that there MUST be 292 exactly one encoding symbol per group, i.e., G MUST be equal to 1 293 [RFC5170]; 295 4.2. ADU Block Creation 297 Two kinds of limitations MUST be considered, that impact the ADU 298 block creation: 299 o at the FEC Scheme level: the FEC Scheme and the FEC codec have 300 limitations that define a maximum source block size; 301 o at the FECFRAME instance level: the target use-case MAY have real- 302 time constraints that MAY define a maximum ADU block size; 303 Note that terminology "maximum source block size" and "maximum ADU 304 block size" depends on the point of view that is adopted (FEC Scheme 305 versus FECFRAME instance). However, in this document, both refer to 306 the same value since Section 4.1 requires there is exactly one source 307 symbol per ADU. We now detail each of these aspects. 309 The maximum source block size in symbols, max_k, depends on several 310 parameters: the code rate (CR), the Encoding Symbol ID (ESI) field 311 length in the Explicit Source/Repair FEC Payload ID (16 bits), as 312 well as possible internal codec limitations. More specifically, 313 max_k cannot be larger than the following values, derived from the 314 ESI field size limitation, for a given code rate: 315 max1_k = 2^^(16 - ceil(Log2(1/CR))) 316 Some common max1_k values are: 317 o CR == 1 (no repair symbol): max1_k = 2^^16 = 65536 symbols 318 o 1/2 <= CR < 1: max1_k = 2^^15 = 32,768 symbols 319 o 1/4 <= CR < 1/2: max1_k = 2^^14 = 16,384 symbols 321 Additionally, a codec MAY impose other limitations on the maximum 322 source block size, for instance, because of a limited working memory 323 size. This decision MUST be clarified at implementation time, when 324 the target use-case is known. This results in a max2_k limitation. 326 Then, max_k is given by: 327 max_k = min(max1_k, max2_k) 328 Note that this calculation is only required at the encoder (sender), 329 since the actual k parameter (k <= max_k) is communicated to the 330 decoder (receiver) through the Explicit Source/Repair FEC Payload ID. 332 The source ADU flows MAY have real-time constraints. When there are 333 multiple flows, with different real-time constraints, let us consider 334 the most stringent constraints (see [RFC6363], section 10.2, item 6 335 for recommendations when several flows are globally protected). In 336 that case the maximum number of ADUs of an ADU block must not exceed 337 a certain threshold since it directly impacts the decoding delay. 338 The larger the ADU block size, the longer a decoder may have to wait 339 until it has received a sufficient number of encoding symbols for 340 decoding to succeed, and therefore the larger the decoding delay. 341 When the target use-case is known, these real-time constraints result 342 in an upper bound to the ADU block size, max_rt. 344 For instance, if the use-case specifies a maximum decoding latency, 345 l, and if each source ADU covers a duration d of a continuous media 346 (we assume here the simple case of a constant bit rate ADU flow), 347 then the ADU block size must not exceed: 348 max_rt = floor(l / d) 349 After encoding, this block will produce a set of at most n = max_rt / 350 CR encoding symbols. These n encoding symbols will have to be sent 351 at a rate of n / l packets per second. For instance, with d = 10 ms, 352 l = 1 s, max_rt = 100 ADUs. 354 If we take into account all these constraints, we find: 355 max_B = min(max_k, max_rt) 356 This max_B parameter is an upper bound to the number of ADUs that can 357 constitute an ADU block. 359 4.3. Source Block Creation 361 In its most general form the FECFRAME framework and the LDPC- 362 Staircase FEC scheme are meant to protect a set of independent flows. 363 Since the flows have no relationship to one another, the ADU size of 364 each flow can potentially vary significantly. Even in the special 365 case of a single flow, the ADU sizes can largely vary (e.g., the 366 various frames of a "Group of Pictures (GOP) of an H.264 flow). This 367 diversity must be addressed since the LDPC-Staircase FEC scheme 368 requires a constant encoding symbol size (E parameter) per source 369 block. Since this specification requires that there is only one 370 source symbol per ADU, E must be large enough to contain all the ADUs 371 of an ADU block along with their prepended 3 bytes (see below). 373 In situations where E is determined per source block (default, 374 specified by the FFCI/FSSI with S = 0, Section 5.1.1.2), E is equal 375 to the size of the largest ADU of this source block plus three (for 376 the prepended 3 bytes, see below). In this case, upon receiving the 377 first FEC Repair Packet for this source block, since this packet MUST 378 contain a single repair symbol (Section 5.1.3), a receiver determines 379 the E parameter used for this source block. 381 In situations where E is fixed (specified by the FFCI/FSSI with S = 382 1, Section 5.1.1.2), then E must be greater or equal to the size of 383 the largest ADU of this source block plus three (for the prepended 3 384 bytes, see below). If this is not the case, an error is returned. 385 How to handle this error is use-case specific (e.g., a larger E 386 parameter may be communicated to the receivers in an updated FFCI 387 message, using an appropriate mechanism) and is not considered by 388 this specification. 390 The ADU block is always encoded as a single source block. There are 391 a total of B <= max_B ADUs in this ADU block. For the ADU i, with 0 392 <= i <= B-1, 3 bytes are prepended (Figure 2): 393 o The first byte, FID[i] (Flow ID), contains the integer identifier 394 associated to the source ADU flow to which this ADU belongs to. 395 It is assumed that a single byte is sufficient, or said 396 differently, that no more than 256 flows will be protected by a 397 single instance of the FECFRAME framework. 398 o The following two bytes, L[i] (Length), contain the length of this 399 ADU, in network byte order (i.e., big endian). This length is for 400 the ADU itself and does not include the FID[i], L[i], or Pad[i] 401 fields. 403 Then zero padding is added to ADU i (if needed) in field Pad[i], for 404 alignment purposes up to a size of exactly E bytes. The data unit 405 resulting from the ADU i and the F[i], L[i] and Pad[i] fields, is 406 called ADU Information (or ADUI). Each ADUI contributes to exactly 407 one source symbol to the source block. 409 Encoding Symbol Length (E) 410 < -------------------------------------------------------------- > 411 +----+----+-----------------------+------------------------------+ 412 |F[0]|L[0]| ADU[0] | Pad[0] | 413 +----+----+----------+------------+------------------------------+ 414 |F[1]|L[1]| ADU[1] | Pad[1] | 415 +----+----+----------+-------------------------------------------+ 416 |F[2]|L[2]| ADU[2] | 417 +----+----+------+-----------------------------------------------+ 418 |F[3]|L[3]|ADU[3]| Pad[3] | 419 +----+----+------+-----------------------------------------------+ 420 \_______________________________ _______________________________/ 421 \/ 422 simple FEC encoding 424 +----------------------------------------------------------------+ 425 | Repair 4 | 426 +----------------------------------------------------------------+ 427 . . 428 . . 429 +----------------------------------------------------------------+ 430 | Repair 7 | 431 +----------------------------------------------------------------+ 433 Figure 2: Source block creation, for code rate 1/2 (equal number of 434 source and repair symbols, 4 in this example), and S = 0. 436 Note that neither the initial 3 bytes nor the optional padding are 437 sent over the network. However, they are considered during FEC 438 encoding. It means that a receiver who lost a certain FEC source 439 packet (e.g., the UDP datagram containing this FEC source packet) 440 will be able to recover the ADUI if FEC decoding succeeds. Thanks to 441 the initial 3 bytes, this receiver will get rid of the padding (if 442 any) and identify the corresponding ADU flow. 444 5. LDPC-Staircase FEC Scheme for Arbitrary ADU Flows 446 5.1. Formats and Codes 448 5.1.1. FEC Framework Configuration Information 450 The FEC Framework Configuration Information (or FFCI) includes 451 information that MUST be communicated between the sender and 452 receiver(s). More specifically, it enables the synchronization of 453 the FECFRAME sender and receiver instances. It includes both 454 mandatory elements and scheme-specific elements, as detailed below. 456 5.1.1.1. Mandatory Information 458 FEC Encoding ID: the value assigned to this fully-specified FEC 459 scheme MUST be XXX, as assigned by IANA (Section 8). 460 When SDP is used to communicate the FFCI, this FEC Encoding ID is 461 carried in the 'encoding-id' parameter. 463 5.1.1.2. FEC Scheme-Specific Information 465 The FEC Scheme Specific Information (FSSI) includes elements that are 466 specific to the present FEC scheme. More precisely: 467 PRNG seed (seed): a non-negative 32 bit integer used as the seed of 468 the Pseudo Random Number Generator, as defined in [RFC5170]. 469 Encoding symbol length (E): a non-negative integer that indicates 470 either the length of each encoding symbol in bytes (strict mode, 471 i.e., if S = 1), or the maximum length of any encoding symbol 472 (i.e., if S = 0). 473 Strict (S) flag: when set to 1 this flag indicates that the E 474 parameter is the actual encoding symbol length value for each 475 block of the session (unless otherwise notified by an updated FFCI 476 if this possibility is considered by the use-case or CDP). When 477 set to 0 this flag indicates that the E parameter is the maximum 478 encoding symbol length value for each block of the session (unless 479 otherwise notified by an updated FFCI if this possibility is 480 considered by the use-case or CDP). 481 N1 minus 3 (n1m3): an integer between 0 (default) and 7, inclusive. 482 The number of "1s" per column in the left side of the parity check 483 matrix, N1, is then equal to N1m3 + 3, as specified in [RFC5170]. 484 These elements are required both by the sender (LDPC-Staircase 485 encoder) and the receiver(s) (LDPC-Staircase decoder). 487 When SDP is used to communicate the FFCI, this FEC scheme-specific 488 information is carried in the 'fssi' parameter in textual 489 representation as specified in [RFC6364]. For instance: 491 fssi=seed:1234,E:1400,S:0,n1m3:0 493 If another mechanism requires the FSSI to be carried as an opaque 494 octet string (for instance after a Base64 encoding), the encoding 495 format consists of the following 7 octets: 496 o PRNG seed (seed): 32 bit field. 497 o Encoding symbol length (E): 16 bit field. 498 o Strict (S) flag: 1 bit field. 499 o Reserved: a 4 bit field that MUST be set to zero. 501 o N1m3 parameter (n1m3): 3 bit field. 503 0 1 2 504 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 505 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 506 | PRNG seed (seed) | 507 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 508 | Encoding Symbol Length (E) |S| resvd | n1m3| 509 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 511 Figure 3: FSSI encoding format. 513 5.1.2. Explicit Source FEC Payload ID 515 A FEC source packet MUST contain an Explicit Source FEC Payload ID 516 that is appended to the end of the packet as illustrated in Figure 4. 518 +--------------------------------+ 519 | IP Header | 520 +--------------------------------+ 521 | Transport Header | 522 +--------------------------------+ 523 | ADU | 524 +--------------------------------+ 525 | Explicit Source FEC Payload ID | 526 +--------------------------------+ 528 Figure 4: Structure of a FEC Source Packet with the Explicit Source 529 FEC Payload ID. 531 More precisely, the Explicit Source FEC Payload ID is composed of the 532 following fields (Figure 5): 533 Source Block Number (SBN) (16 bit field): this field identifies the 534 source block to which this FEC source packet belongs. 535 Encoding Symbol ID (ESI) (16 bit field): this field identifies the 536 source symbol contained in this FEC source packet. This value is 537 such that 0 <= ESI <= k - 1 for source symbols. 538 Source Block Length (k) (16 bit field): this field provides the 539 number of source symbols for this source block, i.e., the k 540 parameter. 542 0 1 2 3 543 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 544 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 545 | Source Block Number (SBN) | Encoding Symbol ID (ESI) | 546 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 547 | Source Block Length (k) | 548 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 550 Figure 5: Source FEC Payload ID encoding format. 552 5.1.3. Repair FEC Payload ID 554 A FEC repair packet MUST contain a Repair FEC Payload ID that is 555 prepended to the repair symbol(s) as illustrated in Figure 6. There 556 MUST be a single repair symbol per FEC repair packet. 558 +--------------------------------+ 559 | IP Header | 560 +--------------------------------+ 561 | Transport Header | 562 +--------------------------------+ 563 | Repair FEC Payload ID | 564 +--------------------------------+ 565 | Repair Symbol | 566 +--------------------------------+ 568 Figure 6: Structure of a FEC Repair Packet with the Repair FEC 569 Payload ID. 571 More precisely, the Repair FEC Payload ID is composed of the 572 following fields: (Figure 7): 573 Source Block Number (SBN) (16 bit field): this field identifies the 574 source block to which the FEC repair packet belongs. 575 Encoding Symbol ID (ESI) (16 bit field) this field identifies the 576 repair symbol contained in this FEC repair packet. This value is 577 such that k <= ESI <= n - 1 for repair symbols. 578 Source Block Length (k) (16 bit field): this field provides the 579 number of source symbols for this source block, i.e., the k 580 parameter. 581 Number of Encoding Symbols (n) (16 bit field): this field provides 582 the number of encoding symbols for this source block, i.e., the n 583 parameter. 585 0 1 2 3 586 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 587 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 588 | Source Block Number (SBN) | Encoding Symbol ID (ESI) | 589 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 590 | Source Block Length (k) | Number Encoding Symbols (n) | 591 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 593 Figure 7: Repair FEC Payload ID encoding format. 595 5.2. Procedures 597 The following procedures apply: 598 o The source block creation procedures are specified in Section 4.3. 599 o The SBN value is incremented for each new source block, starting 600 at 0 for the first block of the ADU flow. Wrapping to zero will 601 happen for long sessions, after value 2^^16 - 1. 602 o The ESI of encoding symbols is managed sequentially, starting at 0 603 for the first symbol. The first k values (0 <= ESI <= k - 1) 604 identify source symbols, whereas the last n-k values (k <= ESI <= 605 n - 1) identify repair symbols. 606 o The FEC repair packet creation procedures are specified in 607 Section 5.1.3. 609 5.3. FEC Code Specification 611 The present document inherits from [RFC5170] the specification of the 612 core LDPC-Staircase codes for a packet erasure transmission channel. 614 Because of the requirement to have exactly one encoding symbol per 615 group, i.e., because G MUST be equal to 1 (Section 4.1), several 616 parts of [RFC5170] are useless. In particular, this is the case of 617 Section 5.6. "Identifying the G Symbols of an Encoding Symbol 618 Group". 620 6. Security Considerations 622 The FEC Framework document [RFC6363] provides a comprehensive 623 analysis of security considerations applicable to FEC schemes. 624 Therefore the present section follows the security considerations 625 section of [RFC6363] and only discusses topics that are specific to 626 the use of LDPC-Staircase codes. 628 6.1. Attacks Against the Data Flow 629 6.1.1. Access to Confidential Content 631 The LDPC-Staircase FEC Scheme specified in this document does not 632 change the recommendations of [RFC6363]. To summarize, if 633 confidentiality is a concern, it is RECOMMENDED that one of the 634 solutions mentioned in [RFC6363] is used, with special considerations 635 to the way this solution is applied (e.g., before versus after FEC 636 protection, and within the end-system versus in a middlebox), to the 637 operational constraints (e.g., performing FEC decoding in a protected 638 environment may be complicated or even impossible) and to the threat 639 model. 641 6.1.2. Content Corruption 643 The LDPC-Staircase FEC Scheme specified in this document does not 644 change the recommendations of [RFC6363]. To summarize, it is 645 RECOMMENDED that one of the solutions mentioned in [RFC6363] is used 646 on both the FEC Source and Repair Packets. 648 6.2. Attacks Against the FEC Parameters 650 The FEC Scheme specified in this document defines parameters that can 651 be the basis of several attacks. More specifically, the following 652 parameters of the FFCI may be modified by an attacker 653 (Section 5.1.1.2): 654 o FEC Encoding ID: changing this parameter leads the receiver to 655 consider a different FEC Scheme, which enables an attacker to 656 create a Denial of Service (DoS). 657 o Encoding symbol length (E): setting this E parameter to a value 658 smaller than the valid one enables an attacker to create a DoS 659 since the repair symbols and certain source symbols will be larger 660 than E, which is an incoherency for the receiver. Setting this E 661 parameter to a value larger than the valid one has similar impacts 662 when S=1 since the received repair symbol size will be smaller 663 than expected. On the opposite it will not lead to any 664 incoherency when S=0 since the actual symbol length value for the 665 block is determined by the size of any received repair symbol, as 666 long as this value is smaller than E. However setting this E 667 parameter to a larger value may have impacts on receivers that 668 pre-allocate memory space in advance to store incoming symbols. 669 o Strict (S) flag: flipping this S flag from 0 to 1 (i.e., E is now 670 considered as a strict value) enables an attacker to mislead the 671 receiver if the actual symbol size varies over different source 672 blocks. Flipping this S flag from 1 to 0 has no major 673 consequences unless the receiver requires to have a fixed E value 674 (e.g., because the receiver pre-allocates memory space). 676 o N1 minus 3 (n1m3): changing this parameter leads the receiver to 677 consider a different code, which enables an attacker to create a 678 DoS. 680 It is therefore RECOMMENDED that security measures are taken to 681 guarantee the FFCI integrity, as specified in [RFC6363]. How to 682 achieve this depends on the way the FFCI is communicated from the 683 sender to the receiver, which is not specified in this document. 685 Similarly, attacks are possible against the Explicit Source FEC 686 Payload ID and Repair FEC Payload ID: by modifying the Source Block 687 Number (SBN), or the Encoding Symbol ID (ESI), or the Source Block 688 Length (k), or the Number Encoding Symbols (n), an attacker can 689 easily corrupt the block identified by the SBN. Other consequences, 690 that are use-case and/or CDP dependant, may also happen. It is 691 therefore RECOMMENDED that security measures are taken to guarantee 692 the FEC Source and Repair Packets as stated in [RFC6363]. 694 6.3. When Several Source Flows are to be Protected Together 696 The LDPC-Staircase FEC Scheme specified in this document does not 697 change the recommendations of [RFC6363]. 699 6.4. Baseline Secure FEC Framework Operation 701 The LDPC-Staircase FEC Scheme specified in this document does not 702 change the recommendations of [RFC6363] concerning the use of the 703 IPsec/ESP security protocol as a mandatory to implement (but not 704 mandatory to use) security scheme. This is well suited to situations 705 where the only insecure domain is the one over which the FEC 706 Framework operates. 708 7. Operations and Management Considerations 710 The FEC Framework document [RFC6363] provides a comprehensive 711 analysis of operations and management considerations applicable to 712 FEC schemes. Therefore the present section only discusses topics 713 that are specific to the use of LDPC-Staircase codes as specified in 714 this document. 716 7.1. Operational Recommendations 718 LDPC-Staircase codes have excellent erasure recovery capabilities 719 with large source blocks, close to ideal MDS codes. For instance, 720 independently of FECFRAME, with source block size k=1024, CR=2/3, 721 N1=5, G=1, with a hybrid ITerative/Maximum Likelihood (IT/ML) 722 decoding approach (see below) and when all symbols are sent in a 723 random order (see below), the average overhead amounts to 0.64% 724 (corresponding to 6.5 symbols in addition to k) and receiving 1046 725 symbols (corresponding to a 2.1% overhead) is sufficient to reduce 726 the decoding failure probability to 5.9*10^^-5. This is why these 727 codes are a good solution to protect a single high bitrate source 728 flow as in [Matsuzono10], or to protect globally several mid-rate 729 source flows within a single FECFRAME instance: in both cases the 730 source block size can be assumed to be equal to a few hundreds (or 731 more) source symbols. 733 LDPC-Staircase codes are also a good solution whenever processing 734 requirements at a software encoder or decoder must be kept to a 735 minimum. This is true when the decoder uses an IT decoding 736 algorithm, or an ML algorithm (we use a Gaussian Elimination as the 737 ML algorithm) when this latter is carefully implemented and the 738 source block size kept reasonable, or a mixture of both techniques 739 which is the recommended solution [Cunche08][CunchePHD10]. For 740 instance an average decoding speed between 1.3 Gbps (corresponding to 741 a very bad channel, close to the theoretical decoding limit and 742 requiring an ML decoding) and 4.3 Gbps (corresponding to a medium 743 quality channel where IT decoding is sufficient) are easily achieved 744 with a source block size composed of k=1024 source symbols, a code 745 rate CR=2/3 (i.e., 512 repair symbols), 1024 byte long symbols, G=1, 746 and N1=5, on an Intel Xeon 5120/1.86GHz workstation running Linux/64 747 bits. Additionally, with a hybrid IT/ML approach, a receiver can 748 decide if and when ML decoding is used, depending on local criteria 749 (e.g., battery or CPU capabilities), independently from other 750 receivers. 752 As the source block size decreases, the erasure recovery capabilities 753 of LDPC codes in general also decrease. In the case of LDPC- 754 Staircase codes, in order to compensate this phenomenon, it is 755 recommended to increase the N1 parameter (e.g., experiments carried 756 out in [Matsuzono10] use N1=7 if k=170 symbols, and N1=5 otherwise) 757 and to use a hybrid IT/ML decoding approach. For instance, 758 independently of FECFRAME, with a small source block size k=256 759 symbols, CR=2/3, N1=7, and G=1, 8he average overhead amounts to 0.71% 760 (corresponding to 1.8 symbols in addition to k), and receiving 271 761 symbols (corresponding to a 5.9% overhead) is sufficient to reduce 762 the decoding failure probability to 5.9*10^^-5. Using N1=9 or 10 763 further improves these results if need be, which also enables to use 764 LDPC-Staircase codes with k=100 symbols for instance. 766 With very small source blocks (e.g., a few tens symbols), using for 767 instance Reed-Solomon codes [SIMPLE_RS] or 2D parity check codes MAY 768 be more appropriate. 770 The way the FEC Repair Packets are transmitted is of high importance. 772 A good strategy, that works well for any kind of channel loss model, 773 consists in sending FEC Repair Packets in random order (rather than 774 in sequence) while FEC Source Packets are sent first and in sequence. 775 Sending all packets in a random order is another possibility, but it 776 requires that all repair symbols for a source block be produced 777 first, which adds some extra delay at a sender. 779 8. IANA Considerations 781 Values of FEC Encoding IDs are subject to IANA registration. 782 [RFC6363] defines general guidelines on IANA considerations. In 783 particular it defines a registry called FEC Framework (FECFRAME) FEC 784 Encoding IDs whose values are granted on an IETF Consensus basis. 786 This document registers one value in the FEC Framework (FECFRAME) FEC 787 Encoding IDs registry as follows: 788 o XXX refers to the Simple LDPC-Staircase [RFC5170] FEC Scheme for 789 Arbitrary Packet Flows. 791 9. Acknowledgments 793 The authors want to thank K. Matsuzono, J. Detchart and H. Asaeda for 794 their contributions in evaluating the use of LDPC-Staircase codes in 795 the context of FECFRAME [Matsuzono10]. 797 10. References 799 10.1. Normative References 801 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 802 Requirement Levels", RFC 2119. 804 [RFC5170] Roca, V., Neumann, C., and D. Furodet, "Low Density Parity 805 Check (LDPC) Forward Error Correction", RFC 5170, 806 June 2008. 808 [RFC6363] Watson, M., Begen, A., and V. Roca, "Forward Error 809 Correction (FEC) Framework", RFC 6363, September 2011. 811 [RFC6364] Begen, A., "Session Description Protocol Elements for the 812 Forward Error Correction (FEC) Framework", RFC 6364, 813 October 2011. 815 10.2. Informative References 817 [RFC3453] Luby, M., Vicisano, L., Gemmell, J., Rizzo, L., Handley, 818 M., and J. Crowcroft, "The Use of Forward Error Correction 819 (FEC) in Reliable Multicast", RFC 3453, December 2002. 821 [RFC5052] Watson, M., Luby, M., and L. Vicisano, "Forward Error 822 Correction (FEC) Building Block", RFC 5052, August 2007. 824 [RFC5510] Lacan, J., Roca, V., Peltotalo, J., and S. Peltotalo, 825 "Reed-Solomon Forward Error Correction (FEC) Schemes", 826 RFC 5510, April 2009. 828 [SIMPLE_RS] 829 Roca, V., Cunche, M., Lacan, J., Bouabdallah, A., and K. 830 Matsuzono, "Simple Reed-Solomon Forward Error Correction 831 (FEC) Scheme for FECFRAME", 832 draft-ietf-fecframe-simple-rs-02 (Work in Progress), 833 March 2012. 835 [RFC5053] Luby, M., Shokrollahi, A., Watson, M., and T. Stockhammer, 836 "Raptor Forward Error Correction Scheme", RFC 5053, 837 June 2007. 839 [RFC5740] Adamson, B., Bormann, C., Handley, M., and J. Macker, 840 "NACK-Oriented Reliable Multicast (NORM) Transport 841 Protocol", RFC 5740, November 2009. 843 [RFC5775] Luby, M., Watson, M., and L. Vicisano, "Asynchronous 844 Layered Coding (ALC) Protocol Instantiation", RFC 5775, 845 April 2010. 847 [Cunche08] 848 Cunche, M. and V. Roca, "Optimizing the Error Recovery 849 Capabilities of LDPC-Staircase Codes Featuring a Gaussian 850 Elimination Decoding Scheme", 10th IEEE International 851 Workshop on Signal Processing for Space Communications 852 (SPSC'08), October 2008. 854 [CunchePHD10] 855 Cunche, M., "High performances AL-FEC codes for the 856 erasure channel : variation around LDPC codes", PhD 857 dissertation (in 858 French) (http://tel.archives-ouvertes.fr/tel- 859 00451336/en/), June 2010. 861 [Matsuzono10] 862 Matsuzono, K., Detchart, J., Cunche, M., Roca, V., and H. 864 Asaeda, "Performance Analysis of a High-Performance Real- 865 Time Application with Several AL-FEC Schemes", 35th Annual 866 IEEE Conference on Local Computer Networks (LCN 2010), 867 October 2010. 869 [LDPC-codec] 870 Cunche, M., Roca, V., Neumann, C., and J. Laboure, "LDPC- 871 Staircase/LDPC-Triangle Codec Reference Implementation", 872 INRIA Rhone-Alpes and STMicroelectronics, 873 . 875 [LDPC-codec-OpenFEC] 876 "The OpenFEC project", . 878 Authors' Addresses 880 Vincent Roca 881 INRIA 882 655, av. de l'Europe 883 Inovallee; Montbonnot 884 ST ISMIER cedex 38334 885 France 887 Email: vincent.roca@inria.fr 888 URI: http://planete.inrialpes.fr/people/roca/ 890 Mathieu Cunche 891 NICTA 892 Australia 894 Email: mathieu.cunche@nicta.com.au 895 URI: http://mathieu.cunche.free.fr/ 897 Jerome Lacan 898 ISAE/LAAS-CNRS 899 1, place Emile Blouin 900 Toulouse 31056 901 France 903 Email: jerome.lacan@isae.fr 904 URI: http://dmi.ensica.fr/auteur.php3?id_auteur=5